Are you an LLM? Read llms.txt for a summary of the docs, or llms-full.txt for the full context.
Skip to content

Config Reference

This reference maps directly to crates/core/src/config/toml_types.rs.

Top-Level Structure

[defaults]
[memory]
[budget]
[plugins]
[permissions]
[sandbox]
[hooks]
[session]
[tui]
[tui.colors]
[mcp]
[server]
 
[providers.<name>]
[agents.<name>]
[wasm_tools.<name>]
[mcp.servers.<name>]

[defaults]

FieldTypeDescription
modelstringDefault model id.
providerstringDefault provider name.
modestringDefault runtime mode.

[memory]

FieldTypeDescription
enabledboolEnable project memory injection.
max_prompt_linesintegerMax memory lines injected into prompt.

[budget]

FieldTypeDescription
hard_capfloatHard budget cap.
soft_capfloatSoft warning cap.
warning_threshold_pctintegerWarning threshold percentage.

[plugins]

FieldTypeDescription
dirsarray(path)Plugin discovery directories.

[providers.<name>]

FieldTypeDescription
typestringProvider type identifier.
authenticationstringAuthentication mode (for example API key or OAuth).
api_key_envstringEnv var name for API key lookup.
base_urlstringProvider API base URL.

[agents.<name>]

FieldTypeDescription
modelstringAgent-specific model override.
providerstringAgent-specific provider override.
instructionsstringAgent-specific instruction override.
modestringAgent runtime mode.
tools_allowarray(string)Tool allowlist rules.
tools_denyarray(string)Tool denylist rules.
mcp_serversarray(string)MCP server names enabled for this agent.
max_turnsintegerPer-agent max turns.
cwdpathAgent working directory override.
worktreeboolEnable isolated worktree for this agent.

[permissions]

FieldTypeDescription
trust_levelstringTrust level selector.
presetstringPermission preset (safe, standard, full).
allowarray(string)Explicit allow rules.
sandboxarray(string)Sandbox rules.
askarray(string)Escalation rules.
denyarray(string)Deny rules.
default_modestringDefault policy mode for unresolved calls.

[sandbox]

FieldTypeDescription
allowed_pathsarray(string)Allowed filesystem roots.
denied_pathsarray(string)Denied filesystem roots.
allowed_domainsarray(string)Allowed network domains.

[hooks]

Each event key takes [{ matcher = "...", hooks = [ ... ] }].

Supported event keys:

  • session_start
  • user_prompt_submit
  • permission_request
  • pre_tool_use
  • post_tool_use
  • post_tool_use_failure
  • stop
  • pre_compact
  • config_change
  • session_end
  • subagent_start
  • subagent_stop
  • teammate_idle
  • teammate_idle_warning
  • task_completed
  • notification
  • stall_detected

Hook handler variants:

  • type = "command": command, timeout, async, status_message
  • type = "prompt": prompt, model, provider, timeout
  • type = "agent": prompt, model, provider, tools, max_turns, timeout

[session]

FieldTypeDescription
max_consecutive_errorsintegerStop after N consecutive errors.
max_total_errorsintegerStop after N total errors.
max_turnsintegerSession turn cap.
livenesstableOptional liveness controls.

[session.liveness]

FieldTypeDescription
enabledboolEnable liveness monitoring.
idle_nudge_after_secsintegerSeconds before first idle nudge.
idle_nudge_interval_secsintegerInterval between nudges.
max_nudgesintegerMax nudges before escalation.
idle_warn_after_secsintegerSeconds before idle warning event.
stall_timeout_secsintegerStall timeout threshold.
auto_interrupt_stalledboolAuto-interrupt stalled runs.

[tui]

FieldTypeDescription
themestringTheme name.
frame_rate_capintegerMax frame rate cap.
colorstableTheme color overrides.

[tui.colors]

Color keys: primary, success, error, warning, muted, accent, text, bg_subtle, border, spinner, text_weak, text_strong, border_focus, info, background.

[wasm_tools.<name>]

FieldTypeDescription
pathstringWASM artifact path.
capabilitiesarray(string)Capability list.
limitstableResource limits.
secretsarray(string)Secret names injected at runtime.
workspace_prefixesarray(string)Allowed workspace prefixes.
endpoint_allowlistarray(string)Allowed outbound endpoints.
tool_aliasestable(string->string)Alias names for this tool.

[wasm_tools.<name>.limits]

Field
max_memory_bytes
fuel_limit
execution_timeout_secs
max_log_entries
max_http_requests
max_tool_invocations
max_file_read_bytes

[mcp] and [mcp.servers.<name>]

[mcp] contains the servers map.

Server fields:

FieldTypeDescription
enabledboolEnable server.
typestringTransport type.
commandstringCommand for stdio transport.
argsarray(string)Command arguments.
urlstringURL for HTTP transport.
headerstable(string->string)HTTP headers.
envtable(string->string)Environment variables.

[server]

FieldTypeDescription
portintegerWeb server port.
hostnamestringBind address/hostname.
passwordstringServer password.
corsarray(string)Additional CORS origins.
permission_timeout_secsintegerPermission response timeout in web mode.