Loading repository dataโฆ
Loading repository dataโฆ
Nevvyboi / repository
๐ค๐ฆ AI Private Banking Agent powered by a Personal Financial Knowledge Graph ๐ธ๏ธ๐ง -> ๐๏ธ voice-first, ๐ก๏ธ real-time fraud detection, ๐ก proactive financial intelligence, and ๐ฎ life simulation for South Africa ๐ฟ๐ฆ
๐ค AI Private Banking Agent with a Personal Financial Knowledge Graph
SentiVest is an autonomous AI banking agent built for the South African market. It goes beyond traditional banking dashboards by combining a personal financial knowledge graph with real-time transaction classification, voice-first interaction, and proactive financial intelligence.
๐ก Banks give you data. SentiVest gives you understanding.
| Traditional Banking | SentiVest |
|---|---|
| ๐ Shows balance | ๐ฎ Predicts when you'll run out |
| ๐ Lists transactions | ๐ก๏ธ Classifies and scores every one |
| ๐ฅ๏ธ Static dashboard | ๐งฌ Living knowledge graph |
| ๐ซ No memory | ๐ง Remembers your goals and habits |
| ๐ค You drive | ๐ค The agent drives |
| โณ Reactive | โก Proactive |
๐๏ธ Voice / Chat Interface 35+ handlers, multi-turn flows, persistent memory
|
๐ง AI Model Layer Qwen 2.5-3B (Ollama) + rule-based fallback
|
๐ธ๏ธ Knowledge Graph Accounts, merchants, loans, investments, insurance, tax
|
๐ก๏ธ Transaction Classifier 100+ merchants, 6 fraud indicators, SAFE/FLAG/ALERT/BLOCK
|
โ๏ธ Infrastructure FastAPI (async) + WebSocket + Investec API (OAuth2)
| Layer | Technology |
|---|---|
| โ๏ธ Backend | FastAPI (Python, async) |
| ๐ง AI Model | Qwen 2.5-3B via Ollama |
| ๐ธ๏ธ Knowledge Graph | Custom in-memory graph engine |
| ๐ก Real-time | WebSocket |
| ๐ฆ Banking API | Investec Open API (OAuth2) |
| ๐๏ธ Voice | Web Speech API + Google STT |
| ๐ Visualization | D3.js |
| ๐ฅ๏ธ Frontend | Single-page HTML/JS/CSS |
# Clone
git clone https://github.com/Nevvyboi/SentiVest.git
cd SentiVest
# Virtual environment
python -m venv venv
source venv/bin/activate # Linux/Mac
venv\Scripts\activate # Windows
# Install dependencies
pip install -r requirements.txt
# (Optional) Pull AI model
ollama pull qwen2.5:3b
# Run
python main.py 8000
๐ Open http://localhost:8000 in your browser.
Create a .env file:
INVESTEC_CLIENT_ID=your_client_id
INVESTEC_CLIENT_SECRET=your_secret
INVESTEC_API_KEY=your_api_key
Without these, the app uses realistic demo data.
SentiVest/
main.py # โ๏ธ FastAPI server, 28+ API routes, WebSocket
knowledge_graph.py # ๐ธ๏ธ Personal financial knowledge graph engine
voice.py # ๐๏ธ 35+ voice command handlers, payment flows, memory
model.py # ๐ง AI model integration (Ollama Qwen 2.5-3B + fallback)
agent.py # ๐ก๏ธ Transaction classifier (100+ merchants, fraud scoring)
simulator.py # ๐ฎ Life simulator, health score, loan eligibility
kg_routes.py # ๐ Knowledge graph API routes
investec_api.py # ๐ฆ Investec Open API wrapper (OAuth2)
test_all.py # ๐งช 71+ tests
static/
combined.html # ๐ฑ Single-page app (phone + dashboard)
presentation.html # ๐ค Project presentation slides
๐ See individual READMEs for detailed documentation:
static/README.md โ ๐ฑ Frontend UI documentation| Endpoint | Description |
|---|---|
POST /api/classify | ๐ก๏ธ Classify transaction (SAFE/FLAG/ALERT/BLOCK) |
POST /api/voice | ๐๏ธ Process voice command |
POST /api/chat | ๐ฌ AI chat with KG context |
GET /api/health | ๐ Financial health score (0-100) |
POST /api/loan/eligibility | ๐ฆ Loan eligibility assessment |
POST /api/transfer | ๐ Smart inter-account transfer |
GET /api/insights | ๐ก Proactive AI insights |
GET /api/transactions | ๐ Filtered transaction history |
GET /api/budgets | ๐ Budget status |
GET /api/alerts | ๐จ Active alerts |
POST /api/simulator/start | ๐ฎ Start life simulator |
WS /ws | ๐ก Real-time event stream |
Full API: 28+ main routes + 15+ knowledge graph routes.
| Metric | Count |
|---|---|
| ๐ API Endpoints | 28+ main + 15+ KG |
| ๐๏ธ Voice Commands | 35+ |
| ๐ช Known Merchants | 100+ |
| ๐ง AI Intent Types | 25+ |
| ๐ฑ UI Pages | 12 |
| ๐ฉ Fraud Indicators | 6 |
| ๐งช Tests | 71+ |
| โจ Total Features | 200+ |
python -m pytest test_all.py -v
Open presentation.html in a browser for the full project presentation (20 slides, keyboard/touch navigation, presenter notes).
๐ฎ Controls: Space/Arrow = navigate, F = fullscreen, N = speaker notes.
MIT