Files
invest-copilot/BRAIN.md
T
gitea a16050c80a
CI / lint-and-build (push) Has been cancelled
CI / python-checks (3.12) (push) Has been cancelled
feat: multiple updates - alerts, auth, sectors, rotation service, financials ingestion, task specs, and agent framework
2026-06-06 22:01:40 -04:00

19 lines
849 B
Markdown

# BRAIN.md
## Architecture (invest-copilot)
- **Backend:** FastAPI (`src/backend/main.py`) — routers, services, models, schemas, Celery tasks
- **Frontend:** Next.js 15 App Router — pages, components (shadcn/ui), Zustand stores, TanStack Query hooks
- **Data:** TimescaleDB (PostgreSQL), Redis cache, MinIO storage
- **Pipeline:** `src/data-pipeline/` — price/SEC/news ingestion, `pipeline.py` orchestrator
- **Real-time:** Celery → Redis Pub/Sub → SSE/WebSocket (`stream.py`) → frontend
## Key Patterns
- Frontend → FastAPI Router → Service → SQLAlchemy → TimescaleDB
- Auth: JWT + session via middleware
- Strategy → DB → Celery evaluation → Alert → SSE push
## Invariants
- TimescaleDB hypertables for all time-series data
- Never assume DB schema — read migrations first
- Research → design → implement flow