Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.simplefunctions.dev/llms.txt

Use this file to discover all available pages before exploring further.

SF settings live in three places:
  • CLI config: ~/.config/simplefunctions/config.json — local-only.
  • Server config: portfolio_config, heartbeat_config, user_settings tables — server-side, per-user.
  • Per-resource config: thesis-level kill rules, watch-rule conditions, webhook endpoint metadata.

CLI config

~/.config/simplefunctions/config.json:
KeyTypePurpose
apiKeystringSF API key (sf_live_...)
apiUrlstringOverride base URL (default https://simplefunctions.dev)
kalshiKeyIdstringKalshi key id
kalshiPrivateKeyPathstringPath to Kalshi PEM file
polymarketWalletstringPolymarket wallet address
dataApiKeystringsf-terminal Data API key (sft_live_...)
defaultModelstringDefault model for sf agent
Read with sf status --json. Edit with sf setup or directly.

Portfolio config (portfolio_config)

Per-user, scoped to autopilot.
FieldDefaultPurpose
enabledfalseMaster on/off
executionModedry-rundry-run / live / halted
cronExpression0 7,19 * * *Schedule
decisionModelanthropic/claude-sonnet-4.6LLM for tick
maxTotalExposureCents300000Risk gate
maxPerMarketCents100000Risk gate
maxDailyLossCents15000Risk gate
maxPositions20Risk gate
minBalanceCents10000Risk gate
maxOrdersPerTick3Risk gate
maxSingleOrderCents20000Risk gate
cooldownAfterLossTicks4Risk gate
maxDrawdownHaltCents50000Auto-halt threshold
drawdownWarnCents30000Soft warn threshold
excludeCategories['sports','esports']Categories to skip
minAdjIy100Minimum adjusted IY%
maxLas0.15Maximum LAS
minTauDays3Minimum days to expiry
crossVenuePairsEnabledfalseUse cross-venue pairs in decisions
Update via sf portfolio config <key> <value> or PATCH /api/portfolio/config.

Heartbeat config (per-thesis)

FieldDefaultPurpose
cadenceHours4Active monitor cadence
dormantCadenceHours12Fallback when no signals
lowConfidenceSinceAtnullSustained-low detection start
killConditions[]Structured triggers to kill

Watch rule fields

FieldPurpose
conditionprice_above / price_below / econ_release / gov_action / semantic_match
thresholdNumeric threshold for price conditions
windowSecondsDedupe window
channelemail / webhook / telegram
endpointIdWebhook endpoint to deliver to

Webhook endpoint fields

FieldPurpose
urlHTTPS URL (HTTP rejected)
labelHuman label for the dashboard
eventsSubscribed event types (default: all)
secretSigning secret (server-issued)
stateactive / degraded / paused
See Env vars for runtime environment.