How susyanth-10/sentinel works
SENTINEL is a payment app with fraud and coercion safeguards. Its principal backend workflow accepts a transaction, evaluates risk, then either blocks or requests confirmation, executes a Ghost Mode transfer in an isolated in-memory ledger, or updates the normal account ledger. The sampled frontend provides transfer state and controls; the repository also contains Flutter native launchers, but no Dart application source is present in the tree. Backend route-to-service edges are based on the sampled route excerpt and SOURCE INDEX references; frontend-to-backend wiring is not shown, so no such connection is asserted.
Main entry points: main.py API and transaction routes · database.py SQLite access · TransferScreen.jsx Transfer screen · my_application.cc Linux Flutter host
Components 19
Client app
- Transfer screen
frontend/TransferScreen.jsx - Bank transfer state
frontend/BankContext.jsx - Linux launcher
MOBILE_APP/linux/runner/main.cc - Linux Flutter host
MOBILE_APP/linux/runner/my_application.cc - Linux plugin registry
MOBILE_APP/linux/flutter/generated_plugin_registrant.h - Windows launcher
MOBILE_APP/windows/runner/main.cpp - Windows Flutter host
MOBILE_APP/windows/runner/flutter_window.cpp - Windows windowing
MOBILE_APP/windows/runner/win32_window.cpp
API and contracts
- API and transaction routes
backend/main.py - Authentication helpers
backend/app/auth.py - Auth schemas
backend/app/schemas/auth.py - Transaction schema
backend/app/schemas/transaction.py - Risk schema
backend/app/schemas/risk.py
Risk and safeguards
- Risk assessment
backend/app/ml/inference.py - Ghost session ledger
backend/app/services/ghost_session_service.py
Accounts and ledgers
- Customer model
backend/app/models/customer.py - Transaction model
backend/app/models/transaction.py - SQLite access
backend/app/database.py
Other components
- Payment user
Connections 17
- Payment user → Transfer screen: initiates transfer
- Transfer screen → Bank transfer state: uses state
frontend/TransferScreen.jsx - Linux launcher → Linux Flutter host: starts
MOBILE_APP/linux/runner/main.cc - Linux Flutter host → Linux plugin registry: registers plugins
MOBILE_APP/linux/runner/my_application.cc - Windows launcher → Windows Flutter host: creates host
MOBILE_APP/windows/runner/main.cpp - Windows Flutter host → Windows windowing: extends window
MOBILE_APP/windows/runner/flutter_window.cpp - API and transaction routes → Authentication helpers: uses auth
backend/main.py - API and transaction routes → Auth schemas: validates auth
backend/main.py - API and transaction routes → Transaction schema: validates transfers
backend/main.py - API and transaction routes → Risk schema: validates risk input
backend/main.py - API and transaction routes → Risk assessment: assesses risk
backend/main.py - API and transaction routes → Ghost session ledger: executes shadow transfer
backend/main.py - API and transaction routes → SQLite access: queries and commits
backend/main.py - API and transaction routes → Customer model: queries customers
backend/main.py - API and transaction routes → Transaction model: queries transactions
backend/main.py - Customer model → SQLite access: maps to database
backend/app/models/customer.py - Transaction model → SQLite access: maps to database
backend/app/models/transaction.py