How the Growth Intelligence Agent reasons over live SaaS data using tools, RAG, and an LLM.
Browser / API Client
โ
โผ
FastAPI Backend (api/main.py ยท Vercel serverless)
โ
โผ
LangGraph ReAct Agent (agent/agent.py)
โโโโโโโดโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ System prompt + tool descriptions โ
โ Max iterations: 8 ยท Model: Claude โ
โโโโโโโฌโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ selects tools as needed
โโโโโโโผโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ โผ โผ โผ โ
โ get_metric get_pipeline get_product_usage โ
โ (metrics.csv) (opps+accts) (usage events) โ
โ โ
โ โผ โผ โ
โ get_deals get_company_context โ
โ (CRM stages) (FAISS RAG over playbooks) โ
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
โ
โผ
Structured answer: Key Insight ยท Root Cause ยท Data ยท Actions
scripts/generate_data.py โ data/raw/*.csv
300 accounts ยท 800 deals ยท 2,000 leads ยท 300 subscriptions
7 industries ยท 4 regions ยท realistic distributions (seed=42)
metrics/compute_metrics.py โ data/processed/metrics.csv
dbt-style models: win_rate, NRR, pipeline_coverage, etc.
Regional win rates computed via accounts join
rag/build_vectorstore.py โ rag/vectorstore/ (FAISS index)
3 markdown playbooks ยท 800-char chunks ยท 18 total vectors