// DOCS

Setup & Reference

Everything needed to run the 6-agent pipeline locally against fixtures, then flip individual agents to live APIs as credentials arrive.

Quickstart

pip install -r requirements.txt
npm install
cp .env.example .env
python scripts/seed_db.py          # creates organizedmarket.db
python scripts/dev.py              # boots all 6 agents in mock mode
# another terminal:
npx wrangler pages dev dashboard   # serves /, /dashboard, /docs, /signals

Env Variables

All AGENT_*_LIVE flags default to 0. Every client has a mock and a live implementation; the flag selects which one is loaded at boot.

VariablePurpose
AGENT_SIGNAL_LIVETastyTrade REST + DXLink WebSocket
AGENT_POLY_LIVEPolymarket CLOB via py-clob-client
AGENT_KALSHI_LIVEKalshi REST w/ RSA-JWT auth
AGENT_SENTIMENT_LIVETwitter/X v2 filtered stream + NewsAPI
OPENCLAW_URLGateway URL (default http://127.0.0.1:18789)
SLACK_WEBHOOK_URL / DISCORD_WEBHOOK_URLHIGH-tier alerts; blank = no-op

Going Live (one agent at a time)

  1. Populate the credential block in .env for one agent (e.g. TastyTrade).
  2. Flip its flag: AGENT_SIGNAL_LIVE=1.
  3. Restart that agent only. Other five stay mocked.
  4. Capture real payloads back into fixtures/ via scripts/record_fixture.py for reproducible dev.

Message Topics (Pydantic)

TopicPublisherSubscriber
quote.updateagent-signalagent-correlator
odds.updateagent-poly, agent-kalshiagent-correlator
sentimentagent-sentimentagent-correlator
signalagent-correlatoragent-dispatcher

Confidence tiers: HIGH > 0.75 · MED 0.45–0.75 · LOW < 0.45.

Operational Checklist

OrganizedMarket surfaces signals — it does not execute trades.