How tienbob/intelligence-platform works
This is an AI-powered investment research product: users browse market and company data, request analysis, and explore portfolio, alert, and backtest results. The React application calls a Rails gateway; Rails owns authentication and user-company access grants, while forwarding Python-owned data and analysis requests. Python mounts enabled domain APIs and runs the domain-neutral intelligence pipeline with Stock-specific ingestion, retrieval, LLM analysis, validation, and scoring. The README documents additional pipeline stages beyond the sampled excerpts; uncertain internal stage wiring is not expanded here.
Main entry points: pipeline.py Intelligence pipeline · routes.rb API routes · App.jsx Research app · proxy_controller.rb Python proxy
Components 23
Research UI
- Research app
intelligence-platform-frontend/src/App.jsx - API client
intelligence-platform-frontend/src/services/api.js - Auth client
intelligence-platform-frontend/src/services/auth.jsx
Rails Gateway
- API routes
intelligence-platform-api/config/routes.rb - Authentication
intelligence-platform-api/app/controllers/api/v1/auth_controller.rb - User records
intelligence-platform-api/app/models/user.rb - Python proxy
intelligence-platform-api/app/controllers/api/v1/proxy_controller.rb - Company grants
intelligence-platform-api/app/models/user_company.rb - Python client
intelligence-platform-api/app/services/python_client.rb
Intelligence Framework
- Intelligence pipeline
intelligence-platform-stock/app/intelligence/pipeline.py - Generic RAG
intelligence-platform-stock/app/intelligence/rag/service.py - LLM engine
intelligence-platform-stock/app/intelligence/llm/client.py - Evidence services
intelligence-platform-stock/app/intelligence/evidence/service.py - Platform database
intelligence-platform-stock/app/core/database.py
Stock Domain
- Domain API host
intelligence-platform-stock/app/main.py - Stock endpoints
intelligence-platform-stock/app/domains/stock/api/router.py - Stock pipeline factory
intelligence-platform-stock/app/domains/stock/pipeline_factory.py - Data ingestion
intelligence-platform-stock/app/domains/stock/workers/ingestion_worker.py - Embedding ingestion
intelligence-platform-stock/app/domains/stock/workers/embedding_worker.py - Stock analysis services
intelligence-platform-stock/app/domains/stock/scoring
Other components
- Investor
- Market data providers
- Research results
Connections 26
- Investor → Research app: uses
- Research app → Auth client: authenticates via
- Research app → API client: requests data
- Auth client → API routes: calls auth routes
- API client → API routes: calls API routes
- API routes → Authentication: dispatches auth
- Authentication → User records: reads/writes
- API routes → Python proxy: dispatches data
- Python proxy → Company grants: creates access grant
- Python proxy → Python client: forwards requests
- Python client → Domain API host: calls internal API
- Domain API host → Stock endpoints: mounts domain routes
- Stock endpoints → Stock pipeline factory: starts analysis
- Stock pipeline factory → Intelligence pipeline: constructs and runs
- Stock pipeline factory → Stock analysis services: wires Stock services
- Intelligence pipeline → Evidence services: collects evidence
- Intelligence pipeline → Generic RAG: retrieves context
- Intelligence pipeline → LLM engine: generates analysis
- Intelligence pipeline → Stock analysis services: scores result
- Intelligence pipeline → Research results: returns analysis
- Data ingestion → Market data providers: fetches market data
- Data ingestion → Platform database: persists ingested data
- Embedding ingestion → Platform database: reads and persists sources
- Embedding ingestion → Stock analysis services: uses embedding ingestion
- Generic RAG → Platform database: retrieves indexed context
- LLM engine → Research results: produces structured output