How captain-rage-rgb/raw_bank_sentients works
Rawbank Sentient is a fraud-intelligence platform with a command-centre dashboard and an investigation copilot. Analysts review operational KPIs and alerts, select a transaction for forensic drill-down, and can use the copilot to combine deterministic customer, device and beneficiary context with similar historical incidents. The backend exposes these capabilities through FastAPI; DuckDB analytics, retrieval and rule metadata form the principal internal layers. The source excerpts establish the backend calls and frontend fetches, but do not show all UI wiring or the full retrieval/cache lifecycle.
Main entry points: copilot.py Investigation context · database.py Command analytics · main.py HTTP endpoints · generate_data.py Synthetic data generator
Components 18
Analyst interface
- Command centre
frontend/src/app/page.tsx - Alert table
frontend/src/components/AlertsTable.tsx - KPI ribbon
frontend/src/components/KpiRibbon.tsx - Analytics charts
frontend/src/components/ChartsGrid.tsx - Investigation drawer
frontend/src/components/InvestigationDrawer.tsx - Copilot panel
frontend/src/components/CopilotPanel.tsx - API client
frontend/src/lib/api.ts
Service API
- HTTP endpoints
backend/main.py
Fraud analysis
- Command analytics
backend/database.py - Investigation context
backend/copilot.py - Dual retrieval
backend/retrieval.py - Fraud rule catalog
backend/rules_meta.py
Canonical data
- Canonical transactions
RAWBANK_SENTIENT_KB.csv - Evaluation ground truth
RAWBANK_SENTIENT_GROUND_TRUTH.csv - Semantic index cache
backend/cache - Synthetic data generator
generate_data.py
Other components
- Fraud analyst
- Groq LLM
Connections 12
- Fraud analyst → Command centre: uses
frontend/src/app/page.tsx - Command centre → API client: fetches data
frontend/src/app/page.tsx - HTTP endpoints → Command analytics: calls analytics
backend/main.py - HTTP endpoints → Investigation context: routes copilot
backend/main.py - Investigation context → Dual retrieval: queries context
backend/copilot.py - Investigation context → Fraud rule catalog: reads rules
backend/copilot.py - Command analytics → Fraud rule catalog: uses catalog
backend/database.py - Command analytics → Canonical transactions: queries data
backend/database.py - Investigation context → Groq LLM: reasons with
- Synthetic data generator → Canonical transactions: generates
generate_data.py - Synthetic data generator → Evaluation ground truth: generates
generate_data.py - Dual retrieval → Semantic index cache: caches index
backend/retrieval.py