BlueprintsAI TradingRuntime and Risk

Runtime and Risk

Trading service instances use sandboxed bots, explicit runtime backends, paper-first defaults, and validation modes that control when capital can move.

Runtime Backend Selection

Trading provision requests use strategy_config_json.runtime_backend.

ValueBehavior
dockerStandard bot sandbox path.
firecrackerMaps to sandbox runtime metadata; current provider wiring must be enabled before use.
teeConfidential runtime selection; TEE instance blueprints pin this by default.

Safety Knobs

SettingDefaultWhy it matters
TRADING_REQUESTER_ACCESS_MODEallowlistKeeps bot creation limited to allowed addresses.
TRADING_REQUESTER_ALLOWLISTOperator plus configured addressesDefines who can request bots in allowlist mode.
OPERATOR_MAX_CAPACITY10 in installer templatesCaps concurrent bots. Unset or 0 means unlimited.
DEFAULT_PAPER_TRADEtrue in templatesNew bots use live data and simulated fills, with no on-chain trades.
TRADING_ENABLE_DIRECT_BOT_CREATEfalsePrevents unauthenticated direct bot creation.

AI Spend

Deterministic strategy ticks can run without model credentials. Agentic activation and chat require provider credentials. If an operator sets model keys, inference is billed to that operator’s account.

The repo supports credentials such as ZAI_API_KEY, ANTHROPIC_API_KEY, and TANGLE_API_KEY. Treat these as provider secrets for the selected bot harness, not as the product integration boundary.

There is no built-in per-bot, per-day, or total LLM spend cap. Operators should enforce spend limits at the provider account, admission allowlist, and capacity levels.

The trading product boundary is a bot with strategy config, vault policy, risk limits, paper/live mode, and performance history. Agent harnesses are runtime backends for agentic work; deterministic ticks and risk checks continue without a model key.

Validation Trust

ModeBehaviorLatency
PerTradeValidator EIP-712 signatures required per trade.About 5-30 seconds.
EnvelopeDepositor-approved bounds allow instant execution inside the envelope.Near-zero.
SelfOperatedLocal policy only; envelope still enforced.Near-zero.

On-chain guards enforce token allowlists, position caps, leverage limits, rate limits, and replay protection through the policy and validator contracts.