How It Works

How the Coordinator and Agents work together to answer complex questions

Intent Classification

When a message arrives, the Coordinator classifies intent. Simple factual lookups get an immediate response. Anything requiring analysis, multiple sources, or judgment triggers the full multi-agent pipeline.

The coordinator reads the user model (risk profile, positions, preferences) before deciding how to route the question.

User MessageCoordinatorClassifies intent and reads user modelSimple / factualComplex / forecastingDirect ResponseNo agents needed"What's the price of AAPL?"Multi-Agent Flow3 phases of research & analysis"Will the Fed cut rates this year?"

Three-Phase Agent Flow

The Coordinator (Claude Opus) runs an orchestration loop. In each phase it spawns agents, waits for their results, reviews them, then decides what to do next. Results flow back to the coordinator between each phase — it's a loop, not a pipeline.

CoordinatorClaude Opus · orchestration looploopSpawns 4 researcher agents1Phase 1: Researchersparallel · context-isolatedResearchWeb, SEC filings, dataFermiFactor decompositionBase RatesHistorical comparablesSentimentNews & social signalsResults return to coordinatorCoordinator reviews resultsCross-compares all researcher findingsChatPreliminary response to userFactual disagreements?YesResearchers revisetheir workNoSpawns 3 analyst agents with full Phase 1 findings2Phase 2: Analystsreceive full Phase 1 findingsScenarioModels bull, base & bear outcomesContrarianChallenges the consensus viewCascadesMaps 2nd & 3rd-order effectsResults return to coordinatorCoordinator reviews analyst resultsCross-compares scenarios, contrarian view, cascadesChatUpdates user while analysts finishFactual disagreements?YesAnalysts revisetheir workNoFinal SynthesisClears preliminary response, delivers analysis + artifactsOffers at end of responseExplore trades?NoYesTrading AgentProposes specific trades with entry/exit,sizing, and risk parametersReceives all findings + user profile & positionsFinal Result

Each agent runs Claude Sonnet in an isolated OpenCode sandbox. The coordinator loops between phases, reviewing results before spawning the next batch.

Coordinator Tools

The coordinator (Claude Opus) uses these tools to manage the workflow. It delegates all research to agents; the one direct-data tool, fetch_page, is reserved for one-off reads where spawning an agent would be overkill.

The coordinator cannot search the web, call an LLM for sub-questions, or read any data source directly beyond fetch_page — everything else goes through agent spawns.

prompt_agent

Spawn a new agent by type, or send a follow-up message to a running one

cancel_agent

Stop a running agent that is no longer needed

set_preliminary_response

Show or clear interim synthesis (markdown, or named-key perspectives) while agents run

emit_artifact

Create or update a visualization in the user's panel — chart, table, forecast, knowledge graph, etc.

delete_artifact

Remove duplicate or withdrawn artifacts from the thread's panel

emit_forecast

Record, update, or withdraw a falsifiable forecast with probability and resolution criteria

suggest_follow_ups

Record 3 follow-up question chips shown under the final synthesis

fetch_page

Scrape a specific URL directly via Firecrawl (bypasses agent spawn for one-off reads)

Trade Terminal Tools

The Trade Terminal variant swaps the default toolset for a structured trade-card workflow. The coordinator can read market data directly, run web search, and progressively fill in the user's Trade Card (thesis → instrument → sizing → risk → finalize). Agent spawns are restricted to tweet-analyst and any artifacts those agents emit are suppressed so the Trade Card remains the single surface.

Trade Terminal replaces emit_artifact / emit_forecast / suggest_follow_ups with the Stage-1 thesis + Stage-2 structuring tools, and adds direct market / options / filings / web-search access.

update_trade_thesis

Patch Stage-1 thesis fields on the bound Trade Card

collect_instruments

Initialize Stage-2 structure with a single trade instrument

set_legs

Set Stage-2 sizing for the leg, compute tier / base gross / final gross

set_risk_params

Set stop, invalidation statement, profit targets, and max hold days

finalize_structuring

Validate Stage-2 structure and mark trade card status = ready

get_market_data

Current spot and daily OHLC history with ATR computed from OHLC (Massive)

get_options_chain

Options chain snapshot for an underlying ticker (Massive)

get_filings

Recent SEC filing context and references for a ticker (Exa)

web_search

Exa web search — titles, URLs, and content excerpts with category/domain/date filters

fetch_page

Firecrawl scrape of a specific URL

prompt_agent

Restricted to tweet-analyst; artifacts from spawned agents are suppressed

cancel_agent

Cancel the running tweet-analyst agent

Agent Sandbox Tools

Every agent runs inside an OpenCode sandbox. It reaches the outside world through two surfaces, both provisioned at session start — MCP servers called as native tool_use blocks, and sandbox skills (Python SDKs and HTTP proxies) invoked by writing and executing code. Both are scoped to the sandbox, both are proxied through the backend so credentials never touch the container.

MCP Servers (native tool_use)

axion

Sidecar tools for the sandbox: report_progress, emit_artifact, delete_artifact

exa

search (neural web search with filters) · answer (direct factual lookups with citations)

firecrawl

scrape_page — fetch arbitrary URLs with bot protection, JS-rendered pages, and PDFs

news

search_news — indexed Reuters + SeekingAlpha articles filterable by date and entity

youtube

transcribe_youtube_video — human captions where available, auto-generated otherwise

twitter (X)

search_tweets, get_user_tweets, get_tweet, get_tweet_thread, get_user, get_user_profile

prediction-markets

search_markets — Polymarket + Kalshi odds, prices, and order book depth

mediawikiDISABLED

Not enabled yet (toolsEnabled=false). When turned on: wiki_search, wiki_get_page, wiki_get_pages, wiki_list_category, wiki_get_backlinks, wiki_recent_changes, wiki_ask (read-only).

MediaWiki is wired up but currently gated off (mediawiki.toolsEnabled=false) — it does not register as a live MCP server until the flag is flipped.

Sandbox Skills (Python SDKs & HTTP proxies)

Massive

OHLCV, options chains with greeks & IV, technicals, forex, crypto, short interest, treasury yields, dividends, splits — Python SDK

sec-api

Mapping, Query, Section Extractor (10-K/10-Q), XBRL-to-JSON, Insider Trading, 13F/13D/G, Form 4, Exec Comp, N-PORT, Form D, S-1/424B4

Unusual Whales

Options flow alerts, dark pool prints, GEX / gamma exposure, market tide, congressional + insider trades, short selling, crypto whales

FRED

800K+ Federal Reserve macro time series (rates, inflation, labor, GDP) + CPI / NFP / FOMC release calendars

Finnhub

Forward EPS & revenue estimates, earnings calendar, analyst consensus, insider sentiment (MSPR), social sentiment, lobbying, gov contracts

Benzinga

Analyst upgrades / downgrades / price target changes + analyst track-record accuracy (via the Massive SDK)

CFTC

Weekly COT reports — leveraged fund and asset manager positioning in equity indices, rates, FX, VIX, energy, metals

CourtListener

US federal court docket search, PACER filing text, and full case records for litigation / securities fraud exposure

Semantic Scholar

220M+ papers, citation graphs with intent labels, semantic recommendations, author h-index (for peer-reviewed evidence & diligence)

Hugging Face Papers

Daily curated ML/AI feed ranked by upvote velocity + semantic search across HF-indexed papers and arXiv IDs

System-prompt source hierarchy: primary regulatory + market data (SEC, Massive, FRED, CFTC) > derived / alt signals (Benzinga, Unusual Whales, Finnhub) > news & web.