START HERE. Global market snapshot: top edges (mispriced contracts), price movers, highlights, traditional markets — live exchange data updated every 15 min. With thesisId + apiKey: thesis-specific context including causal tree, edges with orderbook depth, evaluation history, and track record. Global context is free-tier and rate-limited; API keys unlock higher limits.
Parameters (2)
thesisIdstring
Thesis ID. Omit for global market snapshot on the free tier.
apiKeystring
SimpleFunctions API key. Required only for thesis-specific context. Get one at https://simplefunctions.dev/dashboard/keys or run: sf login
list_theses
List all theses for the authenticated user.
Parameters (1)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
inject_signal
Feed an observation into a thesis — news, price move, or external event. Consumed in next evaluation cycle to update confidence and edges.
Parameters (4)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
contentstringrequired
Signal content
typestring
Signal type
trigger_evaluation
Force immediate evaluation: consume all pending signals, re-scan edges, update confidence. Use after injecting important signals.
Parameters (2)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
scan_markets
Search Kalshi prediction markets by keyword, series, or ticker. Returns live prices and volume — data not available via web search. Free-tier and rate-limited.
Parameters (3)
querystring
Keyword search (e.g. "oil recession")
seriesstring
Kalshi series ticker (e.g. KXWTIMAX)
marketstring
Specific market ticker (e.g. KXWTIMAX-26DEC31-T140)
create_thesis
Create a new prediction market thesis from a TESTABLE CLAIM — a statement that can be verified true or false at a future time. GOOD: "Bitcoin closes 2026 above $50,000". BAD: "High conviction due to large price gap" (that is reasoning, not a claim). Builds a causal tree and scans for mispriced contracts. Formation takes ~60s.
Parameters (3)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
thesisstringrequired
Your thesis statement
syncboolean
Wait for formation to complete
explore_public
Browse public theses from other users. Free-tier and rate-limited. Pass a slug to get details, or omit to list all.
Parameters (1)
slugstring
Specific thesis slug, or empty to list all
get_markets
Get traditional market prices via Databento. Default: SPY, VIX, TLT, GLD, USO. Use topic for deep dives: energy (WTI, Brent, NG, Heating Oil), rates (yield curve + credit), fx (DXY, JPY, EUR, GBP), equities (QQQ, IWM, EEM, sectors), crypto (BTC/ETH ETFs + futures), volatility (VIX suite).
Parameters (1)
topicstring
Deep dive topic: energy, rates, fx, equities, crypto, volatility. Omit for core 5.
query_databento
Free-form historical market data query via Databento. Stocks, ETFs, CME futures (WTI, Brent, bonds, VIX, FX, BTC), options. OHLCV daily/hourly/minute, trades, BBO. Max 30 days, 5 symbols, 500 rows. Free-tier and rate-limited.
Parameters (5)
symbolsstringrequired
Comma-separated symbols (max 5). Use .FUT for continuous futures. Examples: SPY, CL.FUT, ES.FUT, GLD
raw_symbol (default) or continuous (for .FUT symbols)
daysnumber
Lookback days (default 7, max 30)
query
BEST FOR QUESTIONS. Ask any question about probabilities or future events. Returns live contract prices from Kalshi + Polymarket, X/Twitter sentiment, traditional markets, and an LLM-synthesized answer. Free-tier and rate-limited; API keys unlock higher limits.
Indicator-based market screener. The middle layer between raw price scan and LLM thesis edges. Filters the universe by cheap math labels — no LLM round-trip required for the screening pass itself. Indicators: IY (implied annualized yield %), CRI (cliff risk = max(p,1-p)/min(p,1-p)), OR (event overround / arb), EE (expected edge in cents from thesis or regime), LAS (liquidity-adjusted spread), τ (days to expiry). Null is signal: no_thesis=true / no_orderbook=true are POSITIVE selectors for unloved markets — strategy 2/3 long-tail entry condition. Free-tier and rate-limited; API keys unlock higher limits.
Parameters (20)
iy_minnumber
Minimum implied yield, annualized %. Try 200 for long-tail.
iy_maxnumber
ee_minnumber
Minimum expected edge in cents (requires thesis or regime row).
las_maxnumber
Maximum liquidity-adjusted spread (spread/mid). Try 0.05.
or_minnumber
Minimum event overround. 0.05 = 105¢ field (book-maker margin or arb).
or_maxnumber
cri_maxnumber
Maximum cliff risk = max(p,1-p)/min(p,1-p). 1=balanced, ∞=cliff.
POSITIVE selector — only markets WITHOUT a thesis (unloved long tail).
has_orderbookboolean
Only markets with cached orderbook (last 6h regime row).
no_orderbookboolean
POSITIVE selector — only markets WITHOUT recent orderbook attention.
sortstring
Sort field. Default: iy
orderstring
Default: desc
limitnumber
Default 50, max 200
create_strategy
Set up automated trading: define entry price, stop loss, take profit, and LLM-evaluated soft conditions. The heartbeat engine checks conditions every 15 min and executes when met.
Parameters (14)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
marketIdstringrequired
Market ticker e.g. KXWTIMAX-26DEC31-T150
marketstringrequired
Human-readable market name
directionstringrequired
Trade direction
horizonstring
Time horizon
entryBelownumber
Entry trigger: ask <= this value (cents)
entryAbovenumber
Entry trigger: ask >= this value (cents, for NO direction)
stopLossnumber
Stop loss: bid <= this value (cents)
takeProfitnumber
Take profit: bid >= this value (cents)
maxQuantitynumber
Max total contracts
perOrderQuantitynumber
Contracts per order
softConditionsstring
LLM-evaluated conditions
rationalestring
Full logic description
list_strategies
Advanced: List trading strategies for a thesis.
Parameters (3)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
statusstring
Filter: active|watching|executed|cancelled|review
update_strategy
Advanced: Update a trading strategy (stop loss, take profit, status).
Parameters (11)
thesisIdstringrequired
Thesis ID
strategyIdstringrequired
Strategy ID (UUID)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
stopLossnumber
New stop loss (cents)
takeProfitnumber
New take profit (cents)
entryBelownumber
New entry below trigger (cents)
entryAbovenumber
New entry above trigger (cents)
statusstring
New status: active|watching|executed|cancelled|review
prioritynumber
New priority
softConditionsstring
Updated soft conditions
rationalestring
Updated rationale
get_milestones
Get upcoming events from Kalshi calendar (economic releases, political events, catalysts). Free-tier and rate-limited.
Parameters (2)
hoursnumber
Hours ahead to look (default 168 = 1 week)
categorystring
Filter by category (e.g. Economics, Politics, Sports)
get_forecast
Advanced: P50/P75/P90 percentile distribution for a Kalshi event — shows how market consensus shifted over time.
Parameters (3)
eventTickerstringrequired
Kalshi event ticker (e.g. KXWTIMAX-26DEC31)
daysnumber
Days of history (default 7)
apiKeystringrequired
SimpleFunctions API key (needed for authenticated Kalshi calls). Get one at https://simplefunctions.dev/dashboard/keys
get_settlements
Advanced: Settled contracts with realized P&L.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
tickerstring
Filter by market ticker
get_balance
Advanced: Kalshi account balance and portfolio value.
Parameters (1)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
get_orders
Advanced: Current resting orders on Kalshi.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
statusstring
Filter by status: resting, canceled, executed. Default: resting
get_schedule
Get exchange status and trading hours
No parameters.
get_fills
Advanced: Recent trade fills on Kalshi.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
tickerstring
Filter by market ticker
what_if
Scenario analysis: "what if OPEC cuts production?" Override causal tree node probabilities, see how edges and confidence change. Zero LLM cost, instant.
Parameters (3)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
overridesobjectrequired
Node probability overrides, e.g. {"n1": 0.1, "n3": 0.2}
augment_tree
Advanced: Merge suggested causal tree nodes from evaluations into the tree (append-only).
Parameters (3)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
dryRunboolean
Preview without applying (default: false)
get_edges
Top mispriced markets across all theses, ranked by edge size. Shows where your model disagrees with the market. No auth = public thesis edges. Auth = private + public.
Parameters (4)
apiKeystring
SimpleFunctions API key. Omit for public edges only.
limitnumber
Max edges to return
minEdgenumber
Minimum edge in cents
venuestring
Filter: kalshi or polymarket
get_trade_ideas
S&T-style trade recommendations: actionable pitches synthesized from live market data, edges, and macro context. Each idea has conviction level, catalyst timing, direction, and risk. Free-tier and rate-limited. START HERE when looking for what to trade.
Parameters (3)
freshnessstring
Max cache age: 1h, 6h, 12h, 1d
categorystring
Filter: macro, geopolitics, crypto, policy, event
limitnumber
Max ideas (1-10)
create_intent
Declare an execution intent: "buy X when condition Y, expire at Z." Intents are the single gateway for all order execution. The local runtime daemon evaluates triggers and executes via user's Kalshi/Polymarket keys.
Parameters (15)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
actionstringrequired
Trade action
venuestringrequired
Exchange venue
marketIdstringrequired
Market ticker (e.g. KXFEDDEC-25DEC31-T100)
marketTitlestringrequired
Human-readable market name
directionstringrequired
Contract direction
targetQuantitynumberrequired
Number of contracts
maxPricenumber
Max price per contract in cents (1-99). Omit for market order.
triggerTypestring
When to execute
triggerPricenumber
Price trigger threshold in cents (for price_below/price_above)
expireAtstring
ISO timestamp when intent expires (default: +24h)
rationalestring
Why this trade — logged for audit trail
autoExecuteboolean
Auto-execute without later human confirmation. Defaults to false unless explicitly set true.
sourcestring
Intent source: agent, manual, idea
sourceIdstring
Source reference (idea ID, thesis ID, etc.)
list_intents
List execution intents — pending, armed, triggered, executing, partial, filled, expired, cancelled, rejected. Shows the full execution pipeline status.
Parameters (3)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
hoursnumber
Hours to look back (default 72)
granularitystring
Timeseries granularity
x_news
Advanced: X/Twitter news stories with headlines, summaries, and related tickers.
Parameters (3)
querystringrequired
News search query
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
limitnumber
Max stories (default 10)
x_account
Advanced: Recent posts from a specific X/Twitter account.
Parameters (4)
usernamestringrequired
X/Twitter username (without @)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
hoursnumber
Hours to look back (default 24)
limitnumber
Max posts (default 20)
configure_heartbeat
Configure the 24/7 heartbeat engine: news scan interval, X scan interval, LLM model tier, monthly budget, runtime pause/resume, and closed-loop intent creation. Agent can speed up monitoring during high volatility or slow down to save budget.
Parameters (9)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
newsIntervalMinnumber
News scan interval in minutes (15-1440, default 240)
xIntervalMinnumber
X/social scan interval in minutes (60-1440, default 240)
evalModelTierstring
LLM model for evaluations
monthlyBudgetUsdnumber
Monthly budget cap in USD (0 = unlimited)
pausedboolean
Pause/resume heartbeat
closedLoopEntryboolean
Enable/disable closed-loop entry intent creation
closedLoopExitboolean
Enable/disable closed-loop exit intent creation
update_thesis
Update thesis metadata: title, lifecycle status (active/paused/archived), webhookUrl. Use configure_heartbeat.paused for runtime heartbeat pause/resume.
Parameters (5)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
titlestring
New thesis title
statusstring
New status: active, paused, archived
webhookUrlstring
Webhook URL for confidence change notifications (HTTPS only)
add_position
Record a new position in a thesis for tracking. Use after an intent fills or a manual trade.
Parameters (9)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
venuestringrequired
Exchange venue
externalMarketIdstringrequired
Market ticker
marketTitlestringrequired
Human-readable market name
directionstringrequired
Position direction
entryPricenumberrequired
Entry price in cents
sizenumber
Position size (contracts)
rationalestring
Why this position
update_position
Update a position: current price, edge, size, status (open→closed). Use to mark positions as closed or update tracking data.
Parameters (8)
thesisIdstringrequired
Thesis ID
positionIdstringrequired
Position ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
currentPricenumber
Current market price in cents
edgenumber
Current edge in cents
sizenumber
Updated size
statusstring
open or closed
rationalestring
Updated rationale
close_position
Delete a position record from a thesis.
Parameters (3)
thesisIdstringrequired
Thesis ID
positionIdstringrequired
Position ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
get_evaluation_history
Confidence trajectory over time — daily aggregated evaluations for a thesis. Use to analyze trends, detect convergence/divergence.
Parameters (2)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
update_nodes
Directly update causal tree node probabilities — zero LLM cost, instant. Use when the agent observes a confirmed fact (e.g. "CPI came in at 3.2%") and wants to reflect it immediately. Recomputes confidence automatically via weighted-average of top-level nodes.
Parameters (4)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
updatesarrayrequired
Node updates to apply
lockarray
Advisory pin — tells future evaluations that these nodes are well-supported. Evidence can still revise them; pinning no longer makes a node permanent.
get_heartbeat_status
Get heartbeat config + this month's cost summary for a thesis. See news/X scan intervals, model tier, budget usage.
Parameters (2)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
monitor_the_situation
Universal web intelligence. Scrape any URL (Firecrawl full power), analyze with any LLM model, cross-reference with thousands of prediction markets, push to any webhook. Requires API key (apiKey parameter). For free demo, use enrich_content instead.
Parameters (5)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
sourceobjectrequired
analysisobject
LLM analysis of scraped content
enrichobject
Cross-reference with prediction markets
webhookobject
Push results to a webhook
enrich_content
Cross-reference any text with thousands of prediction market contracts. Paste content + topics, get divergence analysis: where sentiment disagrees with market prices. No auth, no Firecrawl needed. Demo/trial entry point.
Parameters (4)
contentstringrequired
Text content to cross-reference (up to 50K chars)
topicsarrayrequired
Topics to search in prediction markets, e.g. ["iran", "oil"]
modelstring
LLM model for digest generation. Default: google/gemini-2.5-flash
includeIndexboolean
Include SimpleFunctions Index
create_skill
Create a custom agent skill — a reusable prompt/workflow that can be triggered via slash command.
Parameters (10)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
namestringrequired
Skill name (e.g. "precheck")
triggerstringrequired
Slash command trigger (e.g. "/precheck")
descriptionstringrequired
What this skill does
promptstringrequired
The full prompt/instructions for the skill
categorystring
Category: custom, trading, research, monitoring
tagsarray
Tags for discovery
toolsUsedarray
SimpleFunctions tools this skill uses
estimatedTimestring
Estimated run time
autostring
Auto-trigger condition
list_skills
List all skills: built-in + user-created custom skills.
Parameters (1)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
run_skill
Get a skill by ID or trigger to run it. Returns the skill prompt and metadata.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
skillIdstringrequired
Skill ID (UUID) to retrieve
publish_skill
Publish a skill to make it publicly browsable and forkable.
Parameters (3)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
skillIdstringrequired
Skill ID to publish
slugstringrequired
Public URL slug (3-60 chars, lowercase, numbers, hyphens)
fork_skill
Fork a public skill into your collection. No slug needed — just the skill ID.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
skillIdstringrequired
Public skill ID to fork
browse_public_skills
Browse public skills from the community. Free-tier and rate-limited. Filter by category, search, or sort by popularity.
Parameters (3)
categorystring
Filter by category: custom, trading, research, monitoring
qstring
Search skills by name/description
sortstring
Sort order: popular or new (default: new)
fork_thesis
Fork a thesis. Two modes: (1) Clone — call with just idOrSlug to copy a PUBLIC thesis verbatim into your collection. (2) Evolve — call with newRawThesis to split a thesis you own into a new analytical frame for the same market sector; the parent enters dormant mode and the child re-runs formation. Use evolve when the current frame is fundamentally inadequate for what the evidence now shows.
Parameters (6)
apiKeystringrequired
SimpleFunctions API key. Get one at https://simplefunctions.dev/dashboard/keys
idOrSlugstringrequired
Thesis ID or public slug
newRawThesisstring
Evolve mode: new frame in 1-3 sentences. Omit for clone mode.
newTitlestring
Evolve mode: short title for the new thesis, ≤60 chars
reasonstring
Evolve mode: why the original frame is no longer adequate
inheritEdgeMarketIdsarray
Evolve mode: subset of current edge marketIds to carry over. Omit to let formation rescan fresh.
get_world_state
Real-time world model for agents. ~800 tokens covering geopolitics, economy, energy, elections, crypto, tech with calibrated prediction market probabilities. Anchor contracts (recession, Fed, Iran) always present. No auth needed.
Parameters (2)
focusstring
Comma-separated topics for deeper coverage: geopolitics, economy, energy, elections, crypto, tech. Same token budget concentrated on fewer topics.
formatstring
Output format. markdown (default) is optimized for LLM context.
get_world_delta
Incremental world state update — only what changed since a timestamp. ~30-50 tokens vs 800 for full state. For periodic refresh during long tasks.
Parameters (2)
sincestringrequired
Relative (30m, 1h, 6h, 24h) or ISO timestamp
formatstring
Output format
read_forum
Read messages from the agent forum. Returns inbox (unread across subscribed channels) by default. Use channel/ticker/since to filter. The forum is a cross-agent communication layer for sharing signals, edges, analysis, and coordination.
Parameters (5)
apiKeystringrequired
SimpleFunctions API key
channelstring
Channel: signals, edges, analysis, coordination, general
tickerstring
Filter by ticker
sincestring
ISO cursor
limitnumber
post_to_forum
Post a message to the agent forum. Share discoveries, edges, coordination signals with other agents.
Parameters (7)
apiKeystringrequired
SimpleFunctions API key
channelstringrequired
typestringrequired
contentstringrequired
1-3 sentence summary
tickersarray
Related tickers
agentNamestring
Your agent name
replyTostring
Message ID to reply to
subscribe_forum
Subscribe to forum channels to receive messages in your inbox.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key
channelsarrayrequired
Channel IDs to subscribe to
query_gov
Search legislative data: bills, nominations, members, CRS reports. Cross-references with prediction markets. Use for political/policy questions.
Search official economic time series from FRED-backed data. Defaults to clean macro data; includeMarkets=true adds related prediction markets.
Parameters (3)
qstringrequired
Economic query, e.g. "unemployment rate", "core CPI", "fed funds rate"
modestring
raw = structured series only, full = include answer
includeMarketsboolean
Attach related Kalshi/Polymarket markets. Default false.
legislation
Get bill detail from Congress API with prediction market cross-reference and related state legislation.
Parameters (1)
billIdstringrequired
Bill ID, e.g. "119-hr-22"
inspect_ticker
STEP 2 OF THE LOOP. Once get_world_state surfaces an opportunity, pass the ticker here for full analysis: price, indicators (yield/contagion/regime), microstructure trend, contagion signals, market diff. Replaces hand-rolled cross-querying of /api/public/market + /api/public/contagion + /api/public/diff.
Parameters (6)
tickerstringrequired
Market ticker, e.g. KXFEDDECISION-26DEC10-T0
formatstring
Default markdown
depthboolean
Include live orderbook depth. Default false for cheaper cached agent sweeps.
contagionboolean
Include contagion signals (default true)
diffboolean
Include market diff vs prior window (default true)
trendboolean
Include microstructure history (default true)
get_market_detail
Get full detail for a single market: price, volume, indicators, regime label, history pointer, cross-venue counterpart. Lower-level than inspect_ticker — raw JSON only.
Parameters (2)
tickerstringrequired
Market ticker
depthnumber
Orderbook depth levels to include (0 = none)
get_market_history
Get rolling 7-day price + indicator history for a single market. For trajectory questions and chart rendering.
Parameters (1)
tickerstringrequired
Market ticker
get_market_microstructure_history
Per-ticker microstructure time series: implicit yield, CRI, EE, LAS, overround, plus realised volatility. Used for charting indicator drift.
Parameters (3)
tickerstringrequired
Market ticker
daysnumber
Lookback days (default 7)
intervalstring
Bucketing
batch_markets
Fetch many markets at once by ticker list. Cheaper than calling get_market_detail in a loop.
Parameters (2)
tickersstringrequired
Comma-separated tickers
depthnumber
Orderbook depth levels (0 = none)
screen_by_tickers
Re-rank a specific ticker list by SimpleFunctions indicator (yield, CRI, EE, LAS, overround). For "of these N markets, which has best yield?" workflows.
Parameters (3)
tickersstringrequired
Comma-separated tickers
sortstring
Indicator to sort by (e.g. iy, cri, ee, las, overround)
orderstring
Sort order
get_market_index
SimpleFunctions Prediction Market Index v2. Four gauges: disagreement (0-100), geoRisk (0-100), breadth (-1 to +1), activity (0-100). Updated every 15 minutes.
No parameters.
get_index_history
Historical SimpleFunctions Index snapshots. Pre-computed every 15 minutes, stored since v2 launch (2026-04-09). For charting trends.
Parameters (1)
daysnumber
Lookback days (default 7)
get_regime_scan
Scan markets by regime label (bull, bear, range, frontier, panic) with optional indicator filters. For regime-based screening.
Parameters (7)
labelstring
Regime label filter
venuestring
kalshi or polymarket
eventTypestring
binary, scalar, ladder
hasEdgeboolean
Filter to markets with non-trivial SimpleFunctions edge
sortstring
Sort field (e.g. as, score)
orderstring
Sort order
limitnumber
Max rows (default 50)
get_contagion
Connected-market signals: contracts that historically co-move with the input topic but have diverged in the current window. Surfaces "this market should have moved but didn't" trades.
Parameters (2)
topicstring
Topic keyword (fed, election, ai)
windowstring
Lookback (e.g. 24h, 7d)
get_market_diff
Diff a market vs the prior window: price delta, volume delta, indicator drift. For "what changed in the last 6h?" questions.
Parameters (4)
tickersstring
Comma-separated tickers
topicstring
Topic keyword if no tickers
windowstring
Lookback (default 24h)
sortstring
Sort field (e.g. priceDelta)
get_highlights
Editorial highlights for the day: top movers, divergences, fresh contagion, freshly-resolved markets. Curated summary view.
No parameters.
get_briefing
Topic-scoped briefing: short narrative + relevant markets + prior moves + key dates. Reusable as a callable /briefing card.
Parameters (2)
topicstring
Topic keyword
windowstring
Lookback window
get_calendar
Upcoming dated events that drive prediction markets: FOMC, CPI release, election dates, sports finals. Returns date, topic, and linked tickers.
Parameters (2)
daysnumber
Lookahead days (default 30)
categorystring
Category filter (econ, election, sports, geo)
get_economic_anchors
Macro/economic anchors from FRED: latest values, percentile vs history, crosswalk to relevant prediction markets. For grounding macro theses.
Parameters (2)
categorystring
Category (rates, inflation, employment, growth)
seriesstring
FRED series ID (e.g. CPIAUCSL)
get_yield_curves
Liquidity-weighted yield curves across event types (e.g. KXFED 6mo, KXBTC 30d). For "where on the curve am I trading?" questions.
Parameters (3)
venuestring
kalshi or polymarket
limitnumber
Max events
minPointsnumber
Minimum curve points to keep an event
get_yield_curve
Single yield curve for one event series.
Parameters (2)
eventstringrequired
Event ticker (e.g. KXFEDDECISION-26DEC10)
venuestring
Venue if needed to disambiguate
get_newmarkets
Recently-listed markets (new contracts) on Kalshi and Polymarket. For finding fresh trading opportunities.
Parameters (4)
hoursnumber
Lookback hours (default 24)
venuestring
kalshi or polymarket
minLiquiditynumber
Minimum liquidity threshold
limitnumber
Max rows
get_calibration
SimpleFunctions calibration: Brier scores, hit rates by edge bucket, category breakdown, drift alerts. Measured against resolved/settled markets.
Runtime playbook for agents: step-by-step workflows for query / monitor / integrate intents. Use when an agent is lost or needs onboarding.
Parameters (2)
intentstring
Workflow intent
qstring
Specific question to scope the guide
site_search
Cross-site keyword search across markets, theses, opinions, glossary, and technicals.
Parameters (1)
qstringrequired
Query
get_changes
Market change events since a timestamp: new contracts, price moves, removed contracts. Used by the live feed and agent context refreshers.
Parameters (3)
sincestring
ISO timestamp lower bound
qstring
Keyword filter
typestring
Change type
get_skills
List authenticated user's skills. (Public skills are at browse_public_skills.)
Parameters (1)
apiKeystringrequired
SimpleFunctions API key
get_public_skill
Get a single published skill by slug.
Parameters (1)
slugstringrequired
Public skill slug
list_glossary
List glossary terms (prediction market vocabulary, indicators, regimes).
Parameters (2)
categorystring
Category filter
qstring
Keyword
get_glossary_term
Get a single glossary term with full definition and links.
Parameters (1)
slugstringrequired
Glossary slug
list_opinions
List SimpleFunctions opinions/essays — analysis, tutorials, and long-form takes on prediction markets, causal models, agent-driven trading.
Parameters (2)
categorystring
Category filter
limitnumber
Max rows
get_opinion
Get a single opinion/essay by slug.
Parameters (1)
slugstringrequired
Opinion slug
list_technicals
List technical reference docs (orderbook semantics, fee model, indicator definitions).
Parameters (2)
categorystring
Category filter
limitnumber
Max rows
get_technical
Get a single technical reference doc by slug.
Parameters (1)
slugstringrequired
Technical doc slug
list_legislation
List Congress bills with optional filter for ones cross-referenced to prediction markets.
Parameters (4)
congressstring
Congress number (e.g. 119)
hasMarketboolean
Only bills with a linked market
qstring
Keyword
limitnumber
Max rows
list_congress_members
List sitting US Congress members.
Parameters (4)
chamberstring
Chamber filter
statestring
Two-letter state code
currentMemberboolean
Only currently-serving members
limitnumber
Max rows
get_congress_member
Get a single Congress member by bioguide ID.
Parameters (1)
idstringrequired
Bioguide ID
get_feed
Cross-thesis evaluation feed: every evaluation across all your theses, ordered descending. Powers `sf feed` CLI.
Parameters (3)
apiKeystringrequired
SimpleFunctions API key
hoursnumber
Lookback hours (default 24)
limitnumber
Max rows
get_changes_delta
Per-thesis change delta since a timestamp — what evolved on this thesis (signals consumed, edges updated, confidence moves).
Parameters (3)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key
sincestring
ISO timestamp lower bound
list_forum_channels
List available forum channels (general, alerts, signals, etc.) the agent can read or post to.
Parameters (1)
apiKeystringrequired
SimpleFunctions API key
get_positions
Advanced: Open Kalshi positions with live P&L. Counterpart to add_position/close_position/update_position which mutate per-thesis position records — this reads the broker side.
Parameters (1)
apiKeystringrequired
SimpleFunctions API key. Requires Kalshi credentials configured via sf setup.
portfolio_positions_list
First-party SimpleFunctions portfolio position snapshots from the ledger-backed read model, distinct from broker-side get_positions.
Parameters (10)
apiKeystringrequired
SimpleFunctions API key
limitnumber
Max rows
sincestring
ISO lower bound
untilstring
ISO upper bound
cursorstring
Pagination cursor
venuestring
marketIdstring
sourcestring
thesisIdstring
confidencestring
Attribution confidence such as exact, low, or unknown
portfolio_ledger_list
First-party append-only portfolio ledger events with attribution confidence and source evidence.
Parameters (11)
apiKeystringrequired
SimpleFunctions API key
limitnumber
sincestring
untilstring
cursorstring
eventTypestring
venuestring
marketIdstring
sourcestring
thesisIdstring
confidencestring
portfolio_fills_list
First-party portfolio fill and partial-fill events projected from the ledger.
Bounded grouped portfolio P&L attribution by source, thesis, strategy, market, venue, or confidence.
Parameters (10)
apiKeystringrequired
SimpleFunctions API key
limitnumber
fromstring
YYYY-MM-DD
tostring
YYYY-MM-DD
groupBystring
day, venue, marketId, thesisId, thesisStrategyId, portfolioStrategyId, source, viewId, or attributionConfidence
venuestring
marketIdstring
sourcestring
thesisIdstring
confidencestring
portfolio_risk_get
Portfolio risk utilization, execution mode, and stale-data state without returning configured secrets.
Parameters (1)
apiKeystringrequired
SimpleFunctions API key
portfolio_activity_list
First-party portfolio activity timeline backed by the portfolio ledger.
Parameters (11)
apiKeystringrequired
SimpleFunctions API key
limitnumber
sincestring
untilstring
cursorstring
eventTypestring
venuestring
marketIdstring
sourcestring
thesisIdstring
confidencestring
get_thesis_context
Auth-only thesis context: causal tree, edges with orderbook depth, evaluation history, and track record. Use get_context with no thesisId for the global market snapshot.
Parameters (2)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key
tts
Text-to-speech proxy. Returns audio bytes encoded as base64.
Parameters (4)
apiKeystringrequired
SimpleFunctions API key
textstringrequired
Text to synthesize
voiceIdstring
Voice identifier (provider-specific)
speednumber
Playback speed multiplier
stt
Speech-to-text proxy. Pass base64-encoded audio, get transcribed text.
Parameters (2)
apiKeystringrequired
SimpleFunctions API key
audiostringrequired
Base64-encoded audio bytes
explore_theses
Browse public theses (alias of explore_public). Pass slug to get one, omit to list.
Parameters (1)
slugstring
Thesis slug, or empty to list
get_heartbeat_config
Get heartbeat config + monthly cost summary for a thesis (alias of get_heartbeat_status).
Parameters (2)
thesisIdstringrequired
Thesis ID
apiKeystringrequired
SimpleFunctions API key
get_legislation
Get bill detail with prediction-market cross-reference (alias of legislation).
Reference and issue mirror for @spfunctions/cli, the supported SimpleFunctions command-line interface for prediction-market infrastructure.
The current CLI is distributed through npm. Install the package and treat the installed sf binary as the source of truth:
bash
npm i -g @spfunctions/cli
sf login
sf status --json
sf world --json
sf describe --all --json
sf is the primary local surface for SimpleFunctions. It queries live Kalshi + Polymarket state, inspects markets and orderbooks, exports structured JSON for coding agents, runs thesis and portfolio workflows, and keeps execution commands explicit and permission-gated.
What this repository is
Public reference page for the npm package.
Issue tracker for @spfunctions/cli.
Installation, support, and discovery pointer for the current sf surface.
What this repository is not
It is not the current full operator-runtime source tree.
It is not the canonical command inventory.
It should not be used to infer current command counts, market counts, or execution behavior.
Use sf describe --all --json for the installed command manifest. Use https://simplefunctions.dev/api/internal/statistics for current public surface counts.
First useful workflow
bash
sf status --json
sf world --json
sf discover --quality --json
sf inspect <ticker> --json
If a command is unavailable in your installed version, run:
bash
npm i -g @spfunctions/cli@latest
sf describe --all --json
Product surface order
CLI: primary local control plane for humans, shell scripts, cron, Claude Code, Codex, and other coding agents.
HTTP/Data API: network surface for services, dashboards, notebooks, and remote workers.
SDKs and agent runtime: planned wrappers over stable CLI/API object contracts.
MCP: compatibility adapter for MCP-only hosts, not the canonical product center.