How namanjain221995/personal-llm-chabot works
TechSara is a local-first AI analyst for Salesforce and other user-provided sources. A user asks through the chat UI; the orchestrator prepares context and dispatches to an answering mode such as warehouse SQL, record retrieval, live Salesforce, web research, or document analysis, then streams a cited answer and optional artifacts. The graph also retains documented memory, reporting, video, and developer-API capabilities. Evidence is limited to the README, tree, and sampled excerpts; uncertain internal wiring is omitted.
Main entry points: router.py Engine router · main.py Chat orchestrator · sql.py Warehouse SQL · report.py Report generation
Components 24
User experience
- Chat interface
frontend/components/ChatApp.tsx - API proxy
frontend/lib/proxy.ts
Request orchestration
- Chat orchestrator
orchestrator/app/main.py - Cross-chat memory
orchestrator/app/memory_semantic.py - Context compaction
orchestrator/app/compaction.py - Engine router
orchestrator/app/engines/router.py
Answer engines
- Warehouse SQL
orchestrator/app/engines/sql.py - Record retrieval
orchestrator/app/engines/rag.py - Salesforce intelligence
orchestrator/app/engines/sf_intel.py - Web search
orchestrator/app/engines/search.py - Deep research
orchestrator/app/engines/deep_research.py - Document analysis
orchestrator/app/engines/document.py - Report generation
orchestrator/app/engines/report.py - Video analysis
orchestrator/app/video/pipeline.py
Data and integrations
- Analytics warehouse
sync-worker/syncworker/storage.py - Salesforce Brain
brain/Salesforce-Org-Data-main/src/graphrag/graph.py - Salesforce org
- Self-hosted search
- Application database
orchestrator/app/db.py
Platform services
- Artifact pipeline
orchestrator/app/artifacts/pipeline.py - Chart preparation
orchestrator/app/core/chart_pipeline.py - Developer API
orchestrator/app/publicapi/endpoints.py - Authentication
orchestrator/app/authn/api.py
Other components
- Analyst
Connections 26
- Analyst → Chat interface: asks
- Chat interface → API proxy: sends request
- API proxy → Chat orchestrator: proxies chat
- Chat orchestrator → Cross-chat memory: recalls context
- Chat orchestrator → Context compaction: compacts context
- Chat orchestrator → Engine router: dispatches turn
- Engine router → Warehouse SQL: selects mode
- Engine router → Record retrieval: selects mode
- Engine router → Salesforce intelligence: selects mode
- Engine router → Web search: selects mode
- Engine router → Deep research: selects mode
- Engine router → Document analysis: selects mode
- Engine router → Report generation: selects mode
- Warehouse SQL → Analytics warehouse: queries
- Record retrieval → Salesforce Brain: retrieves knowledge
- Salesforce intelligence → Salesforce org: queries org
- Web search → Self-hosted search: searches sources
- Deep research → Self-hosted search: searches sources
- Document analysis → Artifact pipeline: reads uploads
- Report generation → Artifact pipeline: renders deliverables
- Video analysis → Application database: checkpoints stages
- Warehouse SQL → Chart preparation: prepares chart
- Report generation → Chart preparation: prepares chart
- Chat orchestrator → Video analysis: starts analysis
- Developer API → Engine router: dispatches requests
- Authentication → Application database: stores identity