Welcome to the Moncho Analyst Workbench. This repository contains the tools and instructions required for discovering and submitting market intelligence data to Moncho.ai.
Root (start here)
README.md,AGENTS.md,instructions.md,analyst_instructions.md— agent entry points.cursorrules/.cursor/rules/— IDE contracts (submit gate, QA, discovery)skills/,samples/,roles/,scripts/,data/,test/
Docs — see docs/README.md
docs/onboarding/— handbook, ICT grant, sectors, dashboard, MCP setupdocs/reference/— schema, scoring, product rubrics, IDE agent mistakesdocs/discovery/— discovery MCP guideskills/data_injection_planning.md— required before sector/landscape injection plans
If you are joining as Data Ops or GTM Ops on the Bangladesh ICT grant, start here:
docs/onboarding/ICT_GRANT_ONBOARDING.md— shared onboarding stepsdocs/onboarding/GRANT_TEN_SECTORS.md— 10 grant sectors and Moncho slugsdocs/reference/DATABASE_SCHEMA_OVERVIEW.md— tables and JSON shapesroles/DATA_OPS_ONBOARDING.mdorroles/GTM_OPS_ONBOARDING.mdroles/TWO_MONTH_PLAN_TEMPLATE.md— submit after discovery; founder approvesdocs/discovery/ANALYST_DISCOVERY_MCP.md— IDE discovery MCPdocs/onboarding/MCP_SETUP_AFTER_MERGE.md— post-merge MCP setup
Grant KPIs and deeper engineering docs stay with the founder. Use this workbench for day-to-day instructions.
scripts/utils/validate-analyst-data.ts— mechanical QA (required before submit)scripts/qa_agent.ts,scripts/qa_reviewer.ts,scripts/deep_fact_check.ts— QA pipelinescripts/submit_data.ts— submit JSON (QA-gated)scripts/extraction/,scripts/discovery/— discovery helpersskills/validation_submission.md— submit ritual for IDE agentssamples/— JSON schemas for Organizations, Products, Landscapes, Experts
-
Activate analyst access at app.moncho.ai/analyst/apply (one click, no application wait).
-
Clone this repository (or download the zip).
-
Install dependencies:
npm install
-
Configure Environment
Create a.envfile in the repo root (do not commit it). Add the following variables:Moncho API (required for submission):
MONCHO_API_URL="https://app.moncho.ai" MONCHO_AUTH_TOKEN="your_copied_api_key_here" # copy from Analyst Dashboard → Workbench Access (see Walkthrough: DASHBOARD_WALKTHROUGH.md#3-managing-workbench-access-api-keys)
Discovery & enrichment APIs (required for the IDE agent's discovery workflow):
# Tavily – web search for discovering organizations and content TAVILY_API_KEY="your_tavily_api_key" # Exa – semantic search for companies, reports, and products EXA_API_KEY="your_exa_api_key" # Logo.dev – fetch organization/product logo URLs by domain LOGO_DEV_API_KEY="your_logo_dev_api_key"
Agentic QA (Stage 2 deep fact-check) — required only when running
--deep-check:# Anthropic – LLM entailment on rationale claims (uses Tavily/Exa for search) ANTHROPIC_API_KEY="your_anthropic_api_key"
Get API keys from: Tavily, Exa, Logo.dev, Anthropic. Keep
.envin.gitignore. -
Sync reference taxonomy IDs (required once per clone, and after taxonomy changes):
npm run reference:sync
This writes
data/reference/valid-sector-ids.jsonandvalid-segment-ids.jsonfrom the live Moncho API. QA uses these to catch guessed sector/segment IDs.
- Agent context: Have your IDE agent read
instructions.md,README.md,docs/reference/IDE_AGENT_MISTAKES.md,analyst_instructions.md,skills/validation_submission.md, andsamples/so it understands schemas and the QA gate. - Discovery (see
analyst_instructions.md): Discover orgs → select top by scoring rubrics → fetch logos (Logo.dev) → discover products → select top products → fetch product URLs. - Generate: Ask the agent to write JSON under
data/pending/matchingsamples/. - QA (required for humans and IDE agents):
Optional deep fact-check (Tavily/Exa): add
npx tsx scripts/utils/validate-analyst-data.ts data/pending/your-file.json --type organization npx tsx scripts/qa_agent.ts --file data/pending/your-file.json --type organization
--deep-checktoqa_agent.ts. Reports land indata/qa-reports/(gitignored). Fix everyFAILbefore submit. - Submit (re-runs Stage 1 mechanical QA for org/product/landscape/expert; max 50 JSON objects per batch):
Or use Bulk inject at
npm run submit -- --file data/pending/orgs.json --type organization npm run submit -- --file data/pending/products.json --type product npm run submit -- --file data/pending/facts.json --type market_fact
/analyst/bulk-inject(Organization, Product, Market fact, Metadata, Landscape). Do not use--skip-qaunless an admin ordered it. Cursor rules:.cursor/rules/submit-gate.md.
Full documentation: scripts/README.md — agentic QA setup, commands, flags, and scale guidance.
QA agent contract: .cursor/rules/qa-reviewer.md
| Stage | Script | What it does |
|---|---|---|
| 1 — Mechanical | scripts/qa_reviewer.ts |
Schema, URLs, duplicates, slugs, landscape/expert ID validation |
| 2 — Agentic | scripts/deep_fact_check.ts |
Tavily/Exa search + Anthropic LLM entailment on rationales |
| Orchestrator | scripts/qa_agent.ts |
Runs both stages + unified report + executive summary |
Reference ID enforcement (never guess sector/segment IDs):
data/reference/valid-sector-ids.jsondata/reference/valid-segment-ids.json- Refresh with
npm run reference:sync
Run examples:
# Organizations — full pipeline
npx tsx scripts/qa_agent.ts --file data/pending/test-batch.json --type organization --deep-check
# Landscape — catches fake UUIDs and guessed IDs
npx tsx scripts/qa_agent.ts --file data/pending/test-landscape-real.json --type landscape
# Expert profiles
npx tsx scripts/qa_agent.ts --file data/pending/test-expert-real.json --type expert
# Cost-controlled deep-check
npx tsx scripts/qa_agent.ts --file data/pending/your-file.json --deep-check --only-flagged --sample-rate 0.2
# Verify agent logic (no API keys)
npm run qa:testReports in data/qa-reports/ (local only, not committed):
*-qa-report.json— mechanical PASS/FLAGGED/FAIL*-factcheck-report.json— per-claim ai_verified / requires_human_review*-unified-qa-report.json— merged per-record final status*-executive-summary.json— what to do next
Submission format rules:
- Top level: one object or an array (max 50 objects per batch = 50 orgs, products, or facts).
- Types:
organization,product,market_fact,landscape,expertvia--type; or Bulk inject in the dashboard. - New records: omit
id. Updates: include existingid. - Market facts: see
samples/market_fact_sample.json; stages tostaging_market_facts(not change requests). - Match field names in
samples/; optional fields can be omitted.
- Data Review: Log in to the Analyst Dashboard to review, curate, and edit existing data (see the Dashboard Walkthrough for details).
- Data Input: Use this workbench to research and input new data via the API.