AgentDeck 6.0 is here: serve one deck over HTTP, AG-UI or the terminal.See what's new
AgentDeckv6.0.6
Reference

Settings

Generated from agentdeck/runtime/settings.py's LayeredSettings subclasses - this page cannot drift from the code because make check regenerates it and fails if the result differs (scripts/generate_docs_reference.py). Values come from process environment variables or the project-root .env; process values win.

OpenAISettings

OpenAI-compatible endpoint configuration.

Env varTypeDefaultDescription
OPENAI_MODELstr'gpt-4.1-mini'Default model for agents that do not declare model=.
OPENAI_API_KEYstr''API key for OpenAI. A custom OPENAI_BASE_URL may omit it when the endpoint needs no auth.
OPENAI_BASE_URLstr''OpenAI-compatible endpoint base URL. Empty uses the SDK default, api.openai.com.
OPENAI_CA_BUNDLEstr''Path to a CA/certificate bundle for verifying the endpoint's TLS certificate. Empty uses the system's default trust store.

ModelProviderSettings

Credentials for prefixed model providers.

Env varTypeDefaultDescription
ANTHROPIC_API_KEYstr''API key for anthropic/... models.
GEMINI_API_KEYstr''API key for gemini/... models.
OLLAMA_BASE_URLstr''Endpoint for ollama/... models.
OPENROUTER_API_KEYstr''API key for openrouter/... models.

RunnerSettings

Defaults for the host-side Agents SDK runner.

Env varTypeDefaultDescription
AGENTDECK_RUNNER_WORKFLOW_NAMEstr'agentdeck'Name recorded on the host Agents SDK run (RunConfig.workflow_name) - identifies which workflow produced a run in tracing/observability.
AGENTDECK_RUNNER_TEMPERATUREfloat1.0Sampling temperature for the host agent loop's model.
AGENTDECK_RUNNER_MAX_TURNSint30Maximum turns Runner.run/run_streamed may take before giving up.
AGENTDECK_RUNNER_MAX_TOKENSint or NoneNoneCap on tokens per response for the host agent loop's ModelSettings. None means the model's own default (uncapped).
AGENTDECK_RUNNER_HANDOFF_ENDS_ON_USER_TURNboolFalseAppend a synthetic user turn after a handoff's collapsed history so the transferred-to agent's request ends on a user role instead of an assistant one. Off by default: it changes what every model sees on every handoff, including against OpenAI, and only some OpenAI-compatible endpoints reject the assistant-terminated shape.
AGENTDECK_RUNNER_HANDOFF_CLOSING_TURNstr'Please continue.'Content of the synthetic user turn handoff_ends_on_user_turn appends. Override for a deployment whose conversations aren't English - the default is otherwise an English sentence injected into every handoff regardless of the conversation's own language.

RuntimeSettings

Knobs the Runtime itself reads.

Env varTypeDefaultDescription
AGENTDECK_RUNTIME_STALE_RUN_AFTER_SECONDSfloat3600.0How long, in seconds, a running open run may go without writing an event before it is treated as abandoned and its session ownership is released for another worker to claim. Never applies to a run paused or waiting on an answer - those hold their session until resumed, answered, or cancelled. Must be positive; set it above the longest gap a healthy turn can go quiet.
AGENTDECK_RUNTIME_LEASE_TTL_SECONDSfloat90.0How long, in seconds, a run's lease stays valid without renewal. A worker renews its lease six times per TTL while it plays a run, so a process killed outright frees its session within one TTL instead of one stale_run_after_seconds. Only takes effect with a lease backend shared across processes (AGENTDECK_CONTROL=sqlite:///<path>); with the in-memory default nothing is ever reported dead and the staleness timer remains the only backstop. Must be positive; set it above the longest the event loop can be blocked in one go.

LangfuseSettings

Langfuse LLM-observability export config.

Env varTypeDefaultDescription
AGENTDECK_LANGFUSE_PUBLIC_KEYstr''Langfuse public key. Tracing stays off unless this and secret_key are both set.
AGENTDECK_LANGFUSE_SECRET_KEYstr''Langfuse secret key. Tracing stays off unless this and public_key are both set.
AGENTDECK_LANGFUSE_BASE_URLstr'http://localhost:3000'Langfuse endpoint.
AGENTDECK_LANGFUSE_ENVIRONMENTstr'local'Langfuse environment tag attached to every exported span.
AGENTDECK_LANGFUSE_DEBUGboolFalseEnable the Langfuse SDK's own debug logging.
AGENTDECK_LANGFUSE_SAMPLE_RATEfloat1.0Fraction of traces exported to Langfuse, from 0.0 to 1.0.
AGENTDECK_LANGFUSE_SERVICE_NAMEstr'agentdeck'OpenTelemetry resource service.name for every exported span. Without it, spans fall back to unknown_service and are unattributed in the Langfuse UI.

TavilySettings

Tavily web-search API. One knob: TAVILY_API_KEY.

Env varTypeDefaultDescription
TAVILY_API_KEYstr''Tavily web-search API key. Empty makes the web_search tool return an error: string instead of raising - it degrades the same way an unavailable MCP server does, rather than disappearing.

EventsSettings

Where the Runtime's canonical event log is written, as one scheme-shaped URL.

Env varTypeDefaultDescription
AGENTDECK_EVENTSstr'memory://'Where the Runtime's canonical event log is written: memory:// (default, in-process, gone when the process exits), sqlite://<path>, redis://<url>/rediss://<url> (needs the [redis] extra), or postgresql://<dsn> (needs the [postgres] extra). The scheme names the backend.

ControlSettings

Where a run's pending control signals live - what pause and cancel are written to.

Env varTypeDefaultDescription
AGENTDECK_CONTROLstr'memory://'Where a run's pending control signals and its liveness lease live: memory:// (default, reachable only from this process) or sqlite://<path> (crosses process boundaries, and is required for the agentdeck runs signal CLI to reach a run, and for a killed worker's session to be freed by its lapsed lease rather than by stale_run_after_seconds). The scheme names the backend.

SessionSettings

Configuration for Redis-backed agent conversation memory.

Env varTypeDefaultDescription
AGENTDECK_SESSIONstr or NoneNoneRedis URL for RedisSession-backed agent conversation memory (agentdeck.adapters.executors.openai_agents.sessions.SessionFactory), needing the [redis] extra. None falls back to one in-process SQLiteSession per session key - no persistence across a restart, no sharing across workers.
AGENTDECK_SESSION_REDIS_KEY_PREFIXstr'agents:session'Key prefix under which RedisSession stores conversations in Redis.
AGENTDECK_SESSION_REDIS_TTLint or NoneNonePer-session TTL in seconds for Redis-backed conversations. None means sessions persist indefinitely.

Read directly from the environment

Owned by no settings model: read where it is used, so it takes no with_overrides and appears in no layered dump.

Env varTypeDefaultDescription
AGENTDECK_OPENAI_AGENTS_TRACING_ENABLEDboolFalseOpt in to the OpenAI Agents SDK's own trace exporter (adapters/executors/openai_agents/runconfig.py). Off by default: a keyless or fake-model run has no account to export to, and the exporter otherwise attempts a real HTTPS call per run. Langfuse traces are built from the event stream, and are a separate switch.
OPENAI_USE_RESPONSESboolTrueUse the SDK's Responses transport (runtime/settings.py). Set it false for a Chat-Completions-only model server. The default gives every message a real response id, which is what avoids the FAKE_RESPONSES_ID collision.