🛡️

CashGuard.AI — Visual Agent Architecture

Autonomous Financial Exception Guardian • Powered by AWS Strands Agents SDK & OpenRouter

🏆 AWS Agents for Humans Hackathon
OpenRouter Multi-Model Gateway
1
Read-Only Feeds
📄 Invoices Feed
data/invoices.json
Billed totals, payment terms, due dates, client identifiers.
🏦 Bank Statement CSV
data/bank_feed.csv
Real-time ledger credits, settled ACH/wire deposits, bank memos.
✉️ Client Inbox Feed
data/client_emails.json
Payment promises, wire references, milestone dispute context.
🔒 Zero Mutation Guarantee: Agent core holds strictly read-only handles. Raw accounts are never altered.
⚙️ Step 2 • AWS Strands Agent Core (Orchestrator)
🔍 Monitor Tool
tools/monitor.py
Ingests 3 feeds into unified, normalized financial state.
⚖️ Matching Tool
tools/matcher.py
Deterministic arithmetic reconciliation & token correlation.

🤫 Silent Auto-Resolution

Exact matches and current invoices reconciled 100% silently. Zero freelancer alert fatigue.

⚠️ Exception Escalation

Underpayments (PARTIAL), unpaid overdue debts (UNMATCHED), and duplicate wire claims.

📊 Cash-Impact Prioritizer (tools/prioritizer.py)
Score = (Amount at Risk) × (Days Overdue)
🌐 Reasoning Layer: OpenRouter Multi-Model LLM Gateway
Distinguishing Technical Choice
Zero-Cost Free Tier

Meta-routes to openrouter/free (Llama 3.3 70B, Gemini 2.0, Mistral).

Structured Tool Calling

Deterministic JSON invocation of draft_message, eliminating hallucinations.

Resilient Failover Chain

Automatic exponential backoff & model cascade upon HTTP 429 rate limits.

📝 Action Drafter Tool

tools/drafter.py
Enforces non-sending safety contract:
contract: { sent: false }
🛑

Human Approval Gate

tools/approval_gate.py

Demands explicit human authorization before any outbound dispatch.

3
Interface & Governance
📱 Clay Web UI / WhatsApp Web
🤖 CashGuard Agent Just now
⚠️ Acme Corp underpaid by $750 on INV-2026-001 (Due 10d ago). Shall I follow up with John?
✓ Approve & Dispatch
✕ Reject / Hold
Freelancers can review, edit copy inline, or approve/dismiss with 1-click.
📋 Responsible AI Audit Trail
data/audit_log.jsonl IMMUTABLE
data/audit_log.md EXECUTIVE
Logs silent background reconciliations, exception flags, LLM reasoning tokens, and human approval signatures.