Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
52 changes: 52 additions & 0 deletions .github/workflows/banking-evals.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
name: Banking — Eval Suite

on:
pull_request:
paths:
- "banking/skills/**"
- "banking/commands/**"
- "banking/evals/**"

jobs:
eval:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install uv
uses: astral-sh/setup-uv@v4

- name: Validate skill structure
run: |
cd banking
for skill_dir in skills/*/; do
skill_name=$(basename "$skill_dir")
skill_file="${skill_dir}SKILL.md"
test -f "$skill_file" || { echo "FAIL: ${skill_name} missing SKILL.md"; exit 1; }
grep -q "^name:" "$skill_file" || { echo "FAIL: ${skill_name} missing name field"; exit 1; }
grep -q "^description:" "$skill_file" || { echo "FAIL: ${skill_name} missing description field"; exit 1; }
echo "OK: ${skill_name}"
done

- name: Validate eval cases
run: |
cd banking
uv run --with pyyaml python3 -c "
import yaml
with open('evals/cases.yaml') as f:
data = yaml.safe_load(f)
cases = data['cases']
assert len(cases) >= 10, f'Expected 10+ eval cases, got {len(cases)}'
categories = set(c.get('category') for c in cases)
print(f'Eval cases: {len(cases)} across {categories}')
for c in cases:
assert 'id' in c, f'Case missing id: {c}'
assert 'prompt' in c, f'Case {c[\"id\"]} missing prompt'
assert 'content_checks' in c, f'Case {c[\"id\"]} missing content_checks'
print('All eval cases valid.')
"

- name: Dry-run eval harness
run: |
cd banking
uv run evals/run.py --dry-run
112 changes: 112 additions & 0 deletions .github/workflows/banking-release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,112 @@
name: Banking — Build Downloadable Zips

on:
push:
tags:
- "banking-v*"
workflow_dispatch:
inputs:
plugin:
description: "Plugin to release"
default: "banking"

permissions:
contents: write

env:
PLUGIN: banking

jobs:
validate:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Validate plugin structure
run: |
PLUGIN_DIR="${PLUGIN}"

echo "Checking plugin structure..."
test -f "${PLUGIN_DIR}/.claude-plugin/plugin.json" || { echo "FAIL: missing plugin.json"; exit 1; }
test -d "${PLUGIN_DIR}/skills" || { echo "FAIL: missing skills/"; exit 1; }
test -d "${PLUGIN_DIR}/commands" || { echo "FAIL: missing commands/"; exit 1; }

for skill_dir in "${PLUGIN_DIR}"/skills/*/; do
skill_name=$(basename "$skill_dir")
skill_file="${skill_dir}SKILL.md"
test -f "$skill_file" || { echo "FAIL: ${skill_name} missing SKILL.md"; exit 1; }
grep -q "^name:" "$skill_file" || { echo "FAIL: ${skill_name} missing name field"; exit 1; }
grep -q "^description:" "$skill_file" || { echo "FAIL: ${skill_name} missing description field"; exit 1; }
echo "OK: ${skill_name}"
done

python3 -m json.tool "${PLUGIN_DIR}/.claude-plugin/plugin.json" > /dev/null || { echo "FAIL: invalid plugin.json"; exit 1; }
python3 -m json.tool marketplace.json > /dev/null || { echo "FAIL: invalid marketplace.json"; exit 1; }

echo "All validations passed."

build-zips:
needs: validate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Create download zips
run: |
mkdir -p dist
cd "${PLUGIN}"

zip -r ../dist/${PLUGIN}-full.zip \
. -x '*.git*' -x '*/.DS_Store'

if [ -d exercises ] && [ -d references ]; then
zip -r ../dist/${PLUGIN}-exercise-data.zip \
exercises/ references/ -x '*.git*'
elif [ -d exercises ]; then
zip -r ../dist/${PLUGIN}-exercise-data.zip \
exercises/ -x '*.git*'
fi

if [ -d workflow-recipes ]; then
zip -r ../dist/${PLUGIN}-workflow-recipes.zip \
workflow-recipes/ -x '*.git*'
fi

cd ..
echo "Built zips:"
ls -lh dist/

- name: Extract version from tag
id: version
run: |
TAG="${GITHUB_REF_NAME}"
VERSION="${TAG#${PLUGIN}-}"
echo "version=${VERSION}" >> "$GITHUB_OUTPUT"
echo "Version: ${VERSION}"

- name: Create GitHub Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ github.ref_name }}
name: "${{ env.PLUGIN }} ${{ steps.version.outputs.version }}"
files: dist/*.zip
body: |
## Banking Domain Agents Plugin ${{ steps.version.outputs.version }}

### Install
```bash
claude plugin install banking@agentfactory-business
```

### Downloads

| File | Contents | For |
|------|----------|-----|
| `banking-full.zip` | Plugin + exercises + recipes + references | Complete setup |
| `banking-exercise-data.zip` | 14 exercises + reference tables | Chapter exercises |
| `banking-workflow-recipes.zip` | 8 operational playbooks | Production workflows |

### Quick Start
1. Install the plugin (command above)
2. Download `banking-exercise-data.zip`
3. Unzip and start with Exercise 1 (Retail Mortgage Staging)
68 changes: 48 additions & 20 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,12 @@ Marketplace for business domain agent plugins from **[The AI Agent Factory](http

## Available Plugins

| Plugin | Description | Version | Install |
|--------|-------------|---------|---------|
| **[islamic-finance](./islamic-finance/)** | 12 product skills, 13 jurisdiction overlays, 4 domain commands for Islamic finance accounting across AAOIFI, IFRS, and local standards | v2.0.0 | `claude plugin install islamic-finance@agentfactory-business` |
| **[idfa-financial-architect](./idfa-financial-architect/)** | Intent-Driven Financial Architecture (IDFA) — four guardrails, three layers, two skills for human-readable, AI-operable, audit-proof financial models | v2.0.0 | `claude plugin install idfa-financial-architect@agentfactory-business` |
| Plugin | Description | Version | Install |
| ----------------------------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------- | ------- | ---------------------------------------------------------------------- |
| **[islamic-finance](./islamic-finance/)** | 12 product skills, 13 jurisdiction overlays, 4 domain commands for Islamic finance accounting across AAOIFI, IFRS, and local standards | v2.0.0 | `claude plugin install islamic-finance@agentfactory-business` |
| **[idfa-financial-architect](./idfa-financial-architect/)** | Intent-Driven Financial Architecture (IDFA) — four guardrails, three layers, two skills for human-readable, AI-operable, audit-proof financial models | v2.0.0 | `claude plugin install idfa-financial-architect@agentfactory-business` |
| **[banking](./banking/)** | 16 product skills, 7 jurisdiction overlays, 4 domain commands for banking regulatory compliance across IFRS 9, Basel III/IV, AML/KYC/sanctions | v1.0.0 | `claude plugin install banking@agentfactory-business` |
| **[legal-ops](./legal-ops/)** | 8 product skills, 5 jurisdiction overlays, 4 domain commands for legal operations — contract review, NDA triage, IP protection, regulatory monitoring, DSAR management | v1.0.0 | `claude plugin install legal-ops@agentfactory-business` |

> Individual plugins may have their own license terms. See each plugin's LICENSE file for details.

Expand All @@ -23,6 +25,8 @@ Marketplace for business domain agent plugins from **[The AI Agent Factory](http
# Install a plugin
claude plugin install islamic-finance@agentfactory-business
claude plugin install idfa-financial-architect@agentfactory-business
claude plugin install banking@agentfactory-business
claude plugin install legal-ops@agentfactory-business

# Verify installation
claude --list-plugins
Expand All @@ -40,6 +44,8 @@ claude --list-plugins
git clone https://github.com/panaversity/agentfactory-business-plugins.git
claude --plugin-dir ./agentfactory-business-plugins/islamic-finance
claude --plugin-dir ./agentfactory-business-plugins/idfa-financial-architect
claude --plugin-dir ./agentfactory-business-plugins/banking
claude --plugin-dir ./agentfactory-business-plugins/legal-ops
```

---
Expand All @@ -65,6 +71,22 @@ agentfactory-business-plugins/
│ ├── evals/ # Two-tier eval harness
│ ├── tests/ # Unit tests
│ └── examples/ # Reference models
├── banking/ # Banking Regulatory Compliance plugin
│ ├── .claude-plugin/ # Plugin manifest
│ ├── skills/ # 16 product skills (auto-loaded)
│ ├── commands/ # 4 slash commands (auto-loaded)
│ ├── hooks/ # Session + validation hooks (auto-loaded)
│ ├── evals/ # Golden-file tests
│ └── exercises/ # Exercise data (download as zip)
├── legal-ops/ # Legal Operations and Compliance plugin
│ ├── .claude-plugin/ # Plugin manifest
│ ├── skills/ # 9 skills (auto-loaded)
│ ├── commands/ # 4 slash commands (auto-loaded)
│ ├── hooks/ # Session + validation hooks (auto-loaded)
│ ├── scripts/ # Test harness
│ ├── evals/ # Golden-file tests
│ ├── exercises/ # 8 exercises (download as zip)
│ └── workflow-recipes/ # 4 operational playbooks (download as zip)
└── [future plugins...] # More business domain plugins planned
```

Expand All @@ -74,10 +96,12 @@ agentfactory-business-plugins/

Each plugin is a companion to a specific chapter in The AI Agent Factory:

| Plugin | Chapter | What You Learn |
|--------|---------|---------------|
| islamic-finance | Ch 20: Islamic Finance Domain Agents | Build jurisdiction-aware Islamic finance agents using 3 accounting regimes |
| Plugin | Chapter | What You Learn |
| ------------------------ | ------------------------------------------- | ------------------------------------------------------------------------------------ |
| islamic-finance | Ch 20: Islamic Finance Domain Agents | Build jurisdiction-aware Islamic finance agents using 3 accounting regimes |
| idfa-financial-architect | Ch 18: Intent-Driven Financial Architecture | Build audit-proof financial models using Named Ranges, four guardrails, three layers |
| banking | Ch 21: Banking Regulatory Compliance | Build jurisdiction-aware banking regulatory agents for IFRS 9, Basel III/IV, AML/KYC |
| legal-ops | Ch 22: Legal Operations and Compliance | Build legal operations agents for contract review, NDA triage, IP protection, DSAR |

### Downloading Exercise Data

Expand All @@ -86,13 +110,17 @@ After installing a plugin, download the exercise data:
1. Go to the [Releases page](https://github.com/panaversity/agentfactory-business-plugins/releases/latest)
2. Download the zip you need:

| Download | What's Inside | Use With |
|----------|--------------|----------|
| `islamic-finance-full.zip` | Everything | Complete setup / capstone |
| `islamic-finance-exercise-data.zip` | 14 exercises + reference tables | Chapter exercises |
| `islamic-finance-workflow-recipes.zip` | 4 operational playbooks | Production workflows |
| `idfa-financial-architect-full.zip` | Plugin + examples + evals | Complete setup |
| `idfa-financial-architect-examples.zip` | Example models (GP Waterfall) | Quick start |
| Download | What's Inside | Use With |
| --------------------------------------- | ------------------------------- | ------------------------- |
| `islamic-finance-full.zip` | Everything | Complete setup / capstone |
| `islamic-finance-exercise-data.zip` | 14 exercises + reference tables | Chapter exercises |
| `islamic-finance-workflow-recipes.zip` | 4 operational playbooks | Production workflows |
| `idfa-financial-architect-full.zip` | Plugin + examples + evals | Complete setup |
| `idfa-financial-architect-examples.zip` | Example models (GP Waterfall) | Quick start |
| `banking-full.zip` | Everything | Complete setup / capstone |
| `legal-ops-full.zip` | Everything | Complete setup / capstone |
| `legal-ops-exercise-data.zip` | 8 exercises | Chapter exercises |
| `legal-ops-workflow-recipes.zip` | 4 operational playbooks | Production workflows |

3. Unzip into your project:

Expand All @@ -106,12 +134,12 @@ unzip islamic-finance-exercise-data.zip -d my-project/

Only Claude Code / Cowork get full plugin functionality (auto-routing, commands, hooks). For other platforms, copy the skill content as custom instructions:

| Agent | Instructions Path | What to Copy |
|-------|------------------|-------------|
| GitHub Copilot | `.github/copilot-instructions.md` | Router SKILL.md + relevant product skills |
| VS Code Copilot | `.vscode/copilot-instructions.md` | Same |
| Cursor | `.cursorrules` | Same |
| Codex | `AGENTS.md` or system prompt | Same |
| Agent | Instructions Path | What to Copy |
| --------------- | --------------------------------- | ----------------------------------------- |
| GitHub Copilot | `.github/copilot-instructions.md` | Router SKILL.md + relevant product skills |
| VS Code Copilot | `.vscode/copilot-instructions.md` | Same |
| Cursor | `.cursorrules` | Same |
| Codex | `AGENTS.md` or system prompt | Same |

---

Expand Down
31 changes: 31 additions & 0 deletions banking/.claude-plugin/plugin.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
{
"name": "banking",
"version": "1.0.0",
"description": "Jurisdiction-aware banking regulatory domain agent. 16 product skills (IFRS 9, Basel III/IV, AML/KYC, sanctions, reconciliation), 7 jurisdiction overlays, 4 domain commands. Covers IFRS 9 ECL, Basel capital and liquidity, AML/CFT compliance, and bank reconciliation across UK, EU, US, Australia, Singapore, UAE, and Pakistan.",
"author": {
"name": "Panaversity",
"url": "https://github.com/panaversity"
},
"homepage": "https://agentfactory.panaversity.org",
"repository": "https://github.com/panaversity/agentfactory-business-plugins",
"license": "Apache-2.0",
"keywords": [
"banking",
"ifrs9",
"ecl",
"basel",
"capital-adequacy",
"rwa",
"lcr",
"nsfr",
"aml",
"kyc",
"sanctions",
"sar",
"reconciliation",
"stress-testing",
"frtb",
"jurisdiction",
"domain-agent"
]
}
23 changes: 23 additions & 0 deletions banking/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
# OS
.DS_Store
Thumbs.db

# Python
__pycache__/
*.pyc
*.pyo
.venv/
venv/

# IDE
.idea/
.vscode/
*.swp
*.swo

# Eval results (generated)
evals/results/

# Environment
.env
.env.local
51 changes: 51 additions & 0 deletions banking/CLAUDE.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
# Banking Domain Agent -- Claude Code Instructions

## Plugin Identity

You are a banking regulatory domain agent. You provide jurisdiction-aware expertise across IFRS 9 ECL, Basel III/IV capital and liquidity, AML/KYC/sanctions compliance, and bank reconciliation.

## Activation

Auto-activate when ANY of these terms appear in a query:
IFRS 9, ECL, expected credit loss, Stage 1, Stage 2, Stage 3, SICR, PD, LGD, EAD,
Basel III, Basel IV, CET1, RWA, capital ratio, LCR, NSFR, HQLA, ICAAP, stress test,
AML, KYC, CDD, EDD, SAR, STR, sanctions, OFAC, HMT, PEP, FATF, FinCEN, NCA,
nostro, reconciliation, suspense, FRTB, market risk, provision recon.

## Routing

Always start by identifying the jurisdiction and domain, then load the appropriate skill and overlay via the banking-global-router.

## Mandatory Output Header

Every banking regulatory output MUST begin with:

```
GOVERNING STANDARD: [e.g. IFRS 9 / Basel III SA]
DOMAIN: [e.g. IFRS 9 ECL -- Stage Assessment]
JURISDICTION: [e.g. United Kingdom -- PRA Rulebook / UK CRR]
```

## Critical Rules

1. NEVER use incurred-loss thinking for IFRS 9 -- it is forward-looking
2. NEVER recognise Stage 3 interest on the gross carrying amount
3. NEVER confuse capital (Basel) with liquidity (LCR/NSFR)
4. NEVER file a SAR without specifying jurisdiction and receiving FIU
5. NEVER apply IFRS 9 to US banks -- they use CECL (ASC 326)
6. NEVER default to any jurisdiction -- always ASK if not identifiable
7. This agent executes, flags, escalates, documents. The professional judges.

## Skills Available

- **Router**: banking-global-router (routes to product + jurisdiction)
- **IFRS 9**: ifrs9-ecl, ifrs9-staging, ifrs9-scenarios, ifrs9-disclosure
- **Basel**: basel-capital, basel-rwa-credit, basel-rwa-market
- **Liquidity**: liquidity-lcr, liquidity-nsfr
- **Stress**: stress-testing
- **AML/KYC**: aml-typologies, aml-sar-drafting, aml-cdd-edd, sanctions-screening, kyc-risk-rating
- **Recon**: bank-reconciliation

## Jurisdictions

UK (PRA), EU (CRR), USA (Federal), Australia (APRA), Singapore (MAS), UAE (CBUAE), Pakistan (SBP)
Loading