Polytraders Dev Guide
internal
v3 spine Phase 1 · Shared contracts 9 demo-wired · 0 shadow-ready · 0 production-live · 100 pending · 109 total 15/33 infra tasks the plan status board

Plan › Intelligence layer · Crypto decision-making

Crypto decision-making — what tells the system to buy or sell

Polymarket crypto markets (BTC-above-$X, ETH staked exceeds N, token launches by date, exploit larger than $X) settle on observable on-chain truths. That means we can model their fair value directly from feeds the rest of the market is slow to integrate. This page shows the bots we already have, the new valuator bots we’re adding, and the flow that turns them into a buy/sell decision.

← Politics decision-making M2 alignment All layers Signal.json

01 · how it fits together

Crypto decision flow

External feeds feed existing sensors. Existing sensors fan into the new crypto valuators. Valuators converge on the shared combiners (fairvalueengine → edgeranker → disagreementscorer). The combined Signal goes to Strategy, then Risk, then Execution. Every action emits an AuditEnvelope with the canonical builderCode.

External feeds Existing sensors New valuators (crypto) Shared combiners Decision Pyth Hermes WS Chainlink feeds Deribit options IV Polygon RPC (Alchemy) Forta alerts TokenUnlocks API GitHub releases onchainwatcher oraclewatcher wallet-flow-classifier anomalydetector orderflowanalyzer resolutionruleparser market_resolution_watcher crypto_price_fairvalue oracle_path_resolver onchain_state_valuator token_launch_tracker exploit_realtime_classifier crypto_regime_detector crypto_catalyst_calendar fairvalueengine edgeranker disagreementscorer Strategy Risk Execution CLOB V2 every action emits AuditEnvelope with reason code + builderCode
existing sensor new valuator shared combiner decision pipeline

02 · sensors we already specced

Existing crypto-relevant bots (7)

These are already specified at docs-complete and feed the new valuators below. They are the ground truth layer — they do not decide anything by themselves.

intel.onchainwatcher

Existing

Watches on-chain state changes on Polygon and Ethereum: balances, supply, contract events. Push-based.

I/O   in: RPC subscriptions · out: state-delta events

intel.oraclewatcher

Existing

Subscribes to oracle feeds (Chainlink, Pyth) and emits when a feed updates, deviates, or stops heart-beating.

I/O   in: oracle contracts · out: oracle-update events

intel.wallet-flow-classifier

Existing

Tags wallets as exchange, MM, project treasury, whale, retail. Emits attributed flow events when classified wallets move funds.

I/O   in: tx stream + wallet labels · out: classified flow events

intel.anomalydetector

Existing

Generic statistical anomaly detector on any time series (book pressure, on-chain flows, price). Emits when a series deviates beyond N-sigma.

I/O   in: any time-series · out: anomaly events

intel.orderflowanalyzer

Existing

Decomposes Polymarket book and trade flow into pressure, imbalance, sweep events.

I/O   in: Polymarket book + fills · out: flow features

intel.resolutionruleparser

Existing

Parses each market’s resolution rules text into a structured object: source, trigger condition, resolution time, oracle path.

I/O   in: market metadata · out: parsed resolution rule

intel.market_resolution_watcher

Existing

Tracks each market through its resolution lifecycle. Emits when resolution conditions are partially or fully met.

I/O   in: parsed rule + live data · out: resolution-progress events

03 · new bots to build

New crypto valuator bots (7)

Each new bot turns sensor output and external feeds into a Signal with a real fair-value or expected-edge number. They write to the locked Signal schema; nothing about the execution path changes.

intel.crypto_price_fairvalue

New

Prices “BTC above $X by date Y”-style markets. Black-Scholes on the underlying, calibrated to the exact oracle path the market settles against. Pulls spot from Pyth, IV from Deribit, time-to-resolution from the parsed rule.

I/O   in: oracle path, spot, IV, time-to-resolution · out: Signal{score_type='fair_value'} with confidence interval

intel.oracle_path_resolver

New

Links each Polymarket market to its actual on-chain oracle (Chainlink address, heartbeat, decimals, chain). Verifies the oracle is on the trusted allowlist. Required for crypto_price_fairvalue to model the right thing.

I/O   in: market metadata + trusted oracle registry · out: Signal{score_type='custom', oracle_address, oracle_chain, heartbeat}

intel.onchain_state_valuator

New

For “X exceeds N by date Y” markets (total staked ETH, DEX volume, bridge TVL, NFT mints). Reads the on-chain metric, extrapolates with confidence interval, accounts for seasonality.

I/O   in: on-chain metric history + trajectory · out: Signal{score_type='fair_value', trajectory_breakdown}

intel.token_launch_tracker

New

For “token X launches by date Y” markets. Combines GitHub release activity, dev wallet behaviour, audit status, Discord/Twitter velocity into a logistic model.

I/O   in: GitHub + wallet flow + social signals · out: Signal{score_type='fair_value', signal_breakdown}

intel.exploit_realtime_classifier

New

For “hack > $X by date Y” markets. Real-time classifier ingesting Forta alerts, anomalous outflows from known protocol wallets, bridge irregularities, Twitter chatter velocity.

I/O   in: Forta + outflow anomalies + social velocity · out: two Signals (active-suspected + window-of-market)

intel.crypto_regime_detector

New

Classifies the current crypto regime: risk_on / risk_off / deleveraging / low_vol / blow_off. Feeds into Strategy sizing and Risk caps.

I/O   in: funding, basis, BTC dominance, stable supply · out: Signal{score_type='custom', regime}

intel.crypto_catalyst_calendar

New

Maintains a calendar of crypto-specific catalysts: FOMC, ETF deadlines, mainnet launches, token unlocks, CPI. Reports time-to-next-catalyst and severity.

I/O   in: external calendars + on-chain unlock schedules · out: Signal{score_type='custom', next_catalyst_at, severity}

04 · cross-vertical infrastructure

Shared combiners (3, used by both crypto and politics)

Built once. Consumed by every vertical. Same contract: Signal in, Signal out, audited every step.

intel.fairvalueengine

Shared

Generic combiner that takes vertical-specific valuator Signals and emits the final fair-value Signal. Records source weights and a decomposition so the audit trail shows which inputs drove the number.

I/O   in: all fair_value Signals · out: Signal{score_type='fair_value', decomposition}

intel.edgeranker

Shared

Generic. Takes a fair_value Signal plus current book, fees, slippage estimate, and time-to-resolution; outputs an expected-edge Signal. Below a configurable threshold, no trade.

I/O   in: fair_value + book + fees · out: Signal{score_type='expected_edge', breakdown}

intel.disagreementscorer

Shared

Generic. Quantifies how much valuators disagree on the same market. High disagreement → reduce size; very high → Risk hard-block.

I/O   in: all fair_value Signals · out: Signal{score_type='confidence'}

Status. All 7 new bots are at described, not specced. We have the role and the I/O contract; we have not invented parameters, thresholds, acceptance tests, or runbooks. That work happens when you say go.
Ready to build — give the word.

On approval, each bot gets a full spec (the same 27-field shape every other bot has), a fixture pack, and an entry in the build order. Until then, this page is the contract.

awaiting go