Configuration reference
All settings load from agent.yaml at the project root (via Pydantic). Types and defaults match src/xcodon/config.py. Nested objects use YAML nesting under tools:, memory_hooks: and prompt_cache:.
Field-by-field schema (generated): config-reference.md — regenerate with python scripts/gen_config_reference.py after changing config.py.
Environment variables
At startup, xcodon loads unset keys from ~/.xcodon/.env. Host-wide defaults (model, API key, base URL, extra env) also live in ~/.xcodon/settings.json. The web workbench's Save defaults button writes it. The CLI and the web server apply it at startup, after .env. Each source sets only keys that are still unset, so shell exports win, then .env, then settings.json.
| Variable | Purpose |
|---|---|
| Model provider keys | As required by LiteLLM (e.g. OPENAI_API_KEY, ANTHROPIC_API_KEY, GEMINI_API_KEY). |
XCODON_SKIP_LLM_CHECK=1 | Skip the one-token startup LLM check (automation only). |
XCODON_SKIP_COALA_CHECK=1 | Skip the Coala availability check at startup. |
XCODON_COALA_SKILL_PATH | Override path to the bundled Coala skill SKILL.md. |
XCODON_GLOBAL_MEMORY_ROOT | Override the host memory root (default ~/.xcodon/memory). |
XCODON_PROJECTS_REGISTRY | Override the projects registry JSON path (default ~/.xcodon/projects_registry.json). |
XCODON_SKILL_CACHE_ROOT | Override the skills.sh download cache (default ~/.xcodon/cache/skills). |
XCODON_WEB_DIST | Built web frontend directory for serve / onboard. |
XCODON_LLM_TIMEOUT_SCALE | Multiply every LLM request deadline, for example 3 for a slow local server. See Timeouts. |
XCODON_STOP_AFTER_STEP | Test aid for autonomous plan-mode runs. Ends the run once the named checklist step is done: a number, or a word its title matches (last: picks the last match). The run-end stages do not run. Run the project again without the variable to resume. |
GITHUB_TOKEN or COALA_REPO_TOKEN | Optional GitHub token for Coala index and skill fetches. A token without read access to the repository causes 404 errors; unset it to use public access. |
XCODON_SYSTEM_CERTS=0 | Verify HTTPS (Hypertext Transfer Protocol Secure) with certifi's bundle only. By default xcodon trusts the operating system's certificate store too, so a company proxy that re-signs HTTPS works. |
XCODON_ALLOW_NATIVE_WINDOWS=1 | Start on native Windows anyway (unsupported). xcodon runs on Windows through WSL2 (Windows Subsystem for Linux); see Windows (WSL2). |
If the LLM check fails at start, the TUI prompts to fix keys and retry; one-shot run -m exits with hints.
Example
model: gemini/gemini-3.8-flash
max_steps: 20
super_mode: false
heartbeat_excerpt_max_chars: 6000
vfs_roots: [inputs, workspace, outputs]
vfs_prompt_max_chars: 8000
vfs_index_max_entries: 50000
skill_auto_apply: true
reflection_enabled: true
mcp_tools_max: 0
memory_hooks:
enabled: true
on_tool_error: true
on_compaction: true
mcp_servers:
- name: coala-runtime
command: coala-runtime
args: []
env: {}
tools:
allow_shell: true
shell_block_outside_project: true
shell_extra_allowed_absolute_prefixes:
- /scratch
coala_runtime_server: coala-runtime
coala_runtime_default_r_image: bioconductor/bioconductor_docker:RELEASE_3_20
coala_runtime_container_engine: singularity
coala_runtime_tmpdir_project_relative: workspace/tmp
coala_mcp_container_engine: apptainer
coala_runtime_mcp_extra_env:
SINGULARITY_CACHEDIR: /scratch/your-user/singularity
coala_mcp_extra_env:
CWLTOOL_EXTRA_ARGS: "--singularity"
external_cli:
command: gemini
args: []
timeout_sec: 600
harness_gate_enabled: true
harness_gate_groups: [core, integrity] # or: all
harness_judge_enabled: true
harness_judge_scope: all # or: graded
plan_reasoning_effort: highTop-level fields (AgentProjectConfig)
| Field | Default | Description |
|---|---|---|
model | gemini/gemini-3.8-flash | LiteLLM model id. The TUI /model menu and the web model picker list current Google, Anthropic and OpenAI models; any other LiteLLM id still works when typed in. After v0.6.1, both lists also offer ChatGPT subscription models (chatgpt/…), and the web picker offers acp/antigravity, an Agent Client Protocol (ACP) coding agent that runs only in direct mode. Providers, keys, gateways and local servers: LLM configuration. Gemini 3 and later ids (e.g. gemini/gemini-3.8-flash, gemini/gemini-4-argon) omit sampling params in xcodon — LiteLLM defaults to temperature=1.0 (lower values can cause loops or degraded reasoning on Google's side). |
llm_tool_choice | "auto" | tool_choice for the agent loop. "auto" sends none (the provider decides) and "required" once after a turn stalls in prose. null never sends one; local vLLM needs this unless started with --enable-auto-tool-choice and --tool-call-parser. Other values ("required", "none") are sent on every request with tools. |
llm_max_output_tokens | null | Most tokens one agent reply may use, reasoning included (sent as max_tokens; at least 1024). null leaves it to the provider. Set it for a self-hosted server whose default is the whole context window. |
llm_temperature | 0.2 | Sampling temperature for the agent loop and /compact (0.0–2.0). null leaves it to the provider (usually 1.0). Never sent to models that refuse it: GPT-5, Gemini 3, Claude Opus 4.7+ / Sonnet 5+ / Fable, and any Claude model while thinking. |
max_steps | 20 | Max LLM rounds per user message; feeds LangGraph recursion limit (hard cap — no silent overrun). |
same_tool_max_repeats | 5 | Blocks identical (tool_name, arguments) beyond this count in one turn (0 disables). |
execution_approval | true | Until the user approves, only read/list/discover tools run. |
human_in_the_loop | true | Prompt asks the model to pause between major steps. |
super_mode | false | Disables approval + HITL; autonomous checklist pacing (--super). |
super_mode_max_continuations | 8 | In super mode, nudge the agent to continue when it ends a turn with text only while the checklist is incomplete (per user message). |
harness_enabled | true | Append session + tool I/O to outputs/harness_notebook.md. |
harness_solution_llm | true | LLM pass to format Solution/Output/Notes in harness_report.md per step. |
harness_solution_llm_model | null | Model for harness solution step; default = model. |
harness_solution_llm_total_budget_chars | 96000 | Total char budget for merged step bodies sent to solution LLM. |
harness_validation_llm | true | Deprecated pre-gate switch. false turns off the LLM judge (harness_judge_enabled) but not the deterministic gate — use harness_gate_enabled: false for that. |
harness_validation_llm_model | null | Validation model; default = harness_solution_llm_model then model. |
harness_validation_agent_retry | true | When validation fails after a step is marked complete (in-loop or post-turn rebuild), nudge the agent to redo that step with tools. |
harness_validation_max_continuations | 3 | Max agent continuations per user message on validation failure. Only used when harness_gate_enabled: false; with the gate on, the budget is harness_gate_max_rounds + harness_judge_max_rounds. |
harness_gate_enabled | true | Run the deterministic step gate before any LLM judge. A red gate is reported to the agent as a table with no LLM call. Which checks run is set by harness_gate_groups and harness_rules.yaml (Harness rules). |
harness_gate_groups | [core, integrity] | Gate check groups that run: any of core, integrity, plan_binding, tools, or all. plan_binding and tools are off by default: across 40 benchmark runs the tool checks raised only false alarms and the plan-binding checks caught nothing. An unknown name is a config error. Single checks are switched in harness_rules.yaml. |
harness_gate_max_rounds | 3 | Agent rounds a step may spend clearing its gate before it is marked fail_blocked. |
harness_gate_per_step | true | In super mode, run the step gate as soon as a checklist step is announced done, and send a red step back into the live run instead of waiting for the run to end. A green step costs nothing. |
harness_judge_enabled | true | Run the LLM judge for analysis and synthesis steps whose gate is green. Single judge rules are switched in harness_rules.yaml. |
harness_judge_scope | all | Which steps the judge reviews. all: every analysis and synthesis step. graded: only the last step and steps whose Expected output names a file the task grades (every step when the task names none). graded makes fewer judge calls, but a step that builds a graded value in an intermediate file goes unjudged. |
harness_judge_max_rounds | 1 | Solution-LLM revision rounds after a judge fail_fixable. |
harness_judge_mechanical_steps | false | Also judge mechanical steps (acquire / inventory / upstream pipeline). |
harness_final_review_enabled | true | One referee pass over the graded deliverables before the run may stop; it can only append checklist steps for a missing piece of the investigation. In super mode it also adds one step, "Honest estimate of the task's score", when the task sets bars or says how it scores and at least half the model calls and an hour of job time are left. |
harness_final_review_max_rounds | 1 | Referee passes a session may spend. |
skill_auto_apply | true | skill_apply_pending runs a compose step in the same turn: one model call decides MERGE, REVISE or KEEP for the proposal in skills/_pending/<name>.md. xcodon validates the result and keeps the old file under skills/<name>/.history/. Set false to hold proposals in skills/_pending/ for manual review. Does not affect skill loading. |
skill_file_max_chars | 20000 | Largest skills/<name>/SKILL.md the compose step may write. A merge result over this size is rejected and the skill stays unchanged. |
plan_model | null | Optional stronger model for the planning-side calls only (research plan and its regeneration, plan-instruction review, /codon plan, /codon split, skills.sh keyword extraction and match gate). null uses model. Pair with harness_validation_llm_model to give the step judge and final referee the same model: one fast runner, one strong planner/reviewer. |
plan_reasoning_effort | high | Thinking budget for planning (initial plan, own-data regeneration, /codon plan, plan-instruction review, end-of-run referee) on reasoning-capable models. high because a weak plan is not recoverable downstream; drop to medium if a provider truncates long plan bodies. |
validation_reasoning_effort | high | Thinking budget for the LLM validation judge and the run-end fabrication review. null sends no reasoning_effort, so the provider default applies (the behavior before 0.5.9). |
agent_reasoning_effort | high | Thinking budget for the agent loop itself. It is the busiest call by far, so it moves both quality and output cost more than any other setting. null sends nothing and lets the provider decide (the behavior before 0.5.9). xcodon sends reasoning_effort only to models that take it. |
plan_excerpt_max_chars | 40000 | Max chars of outputs/research_plan.md in system prompt. |
heartbeat_excerpt_max_chars | 6000 | Max chars of HEARTBEAT.md (0 = off). |
vfs_roots | inputs, workspace, outputs | Project-relative dirs indexed by WorkspaceVfs. |
vfs_prompt_max_chars | 8000 | Max chars of VFS tree + delta in system prompt (0 = off). Legacy YAML key project_snapshot_max_chars is accepted as an alias. |
vfs_index_max_entries | 50000 | Cap on paths stored in state/vfs_index.json. |
skill_digest_max_chars | 800 | Max chars per SKILL excerpt in prompt. |
plan_context_digest_max_chars | 8000 | Recent outputs/plan_context_digest.md in /codon plan (0 = off). |
plan_context_digest_file_max_chars | 48000 | Trim oldest digest sections to cap file size. |
plan_digest_substance_min_chars | 400 | If digest file ≥ this, /codon plan uses shorter checkpoint tail. |
context_budget_tokens | 200000 | Most tokens one agent model call should carry. The working budget is the smaller of this and the model's context window. 0 uses the full window; any other value must be at least 32000. |
compaction_trigger_fraction | 0.8 | Share of the context budget at which the conversation is compacted (0.5–0.95). Compaction keeps the most recent 15% of the budget word for word and replaces the rest with a recap. |
model_context_window_tokens | null | Context window of the agent model, for models LiteLLM does not know (for example a local vLLM server). null asks LiteLLM and falls back to 128,000 tokens. |
reflection_enabled | true | Post-turn reflection LLM pass. When the turn shows a finding a later run could not work out again from its files (a strategy, a checked rule, a tool quirk or a fix that took several tries), it writes a lesson entry to the project lesson log, or bumps Seen on a known lesson; otherwise it writes nothing. |
host_memory_enabled | true | Read and dream host memory (~/.xcodon/memory/) for this project. false (use it for benchmark runs) drops the host memory index, page prefetch, host domain rules and the /global-memory/ mount. xcodon dream and /codon wrap then refuse the project, and /codon tidy is off. See Host memory. |
reflection_skill_folder | reflections | Project memory/<folder>/ for the lesson log. /codon wrap and xcodon dream fold it into host ~/.xcodon/memory/lessons.md. |
reflection_model | null | Reflection model; default = model. |
reflection_transcript_max_chars | 24000 | Checkpoint transcript sent to reflection. |
reflection_harness_tail_max_chars | 12000 | Tail of harness sent to reflection (0 = skip). |
reflection_skill_file_max_chars | 40000 | Size cap for lesson logs and memory/hooks.md. Lesson logs drop the lowest-Seen, oldest entries first. |
reflection_on_step_limit | false | Also reflect when turn ends only due to max_steps. |
cwl_failure_reflection_enabled | true | Append terminal CWL MCP failures to outputs/cwl_failures.md. |
cwl_failure_reflection_max_chars | 120000 | FIFO cap for that file. |
memory_hooks | (see below) | Deterministic memory hook appends to memory/hooks.md. |
prompt_cache | (see below) | Provider prompt / KV cache markers on the stable system prefix. |
checkpoint_tool_content_max_chars | 12000 | Truncate each retained tool message in checkpoint (0 = off). |
llm_round_tool_output_max_chars | 48000 | Max total tool output chars returned to the model in one LLM round (0 = no round budget). |
llm_round_max_tool_calls | 0 | Optional hard cap on tool calls per LLM round (0 = unlimited). |
checkpoint_keep_recent_tool_messages | 8 | Full tool bodies kept for last N tools; older become placeholders (0 = keep all, truncate only). |
session_pruning_enabled | true | Per LLM call: copy history with old tool results cleared/trimmed. |
session_pruning_keep_recent_tools | 8 | Last N tool messages kept (soft-trim possible); 0 = never hard-clear. |
session_pruning_soft_trim_if_longer_than | 4000 | Soft-trim retained tools longer than this (0 = off). |
session_pruning_soft_trim_head_chars | 2000 | Head chars when soft-trimming. |
session_pruning_soft_trim_tail_chars | 2000 | Tail chars when soft-trimming. |
mcp_servers | [] | List of stdio MCP servers (merged with project JSON — see MCP merge). |
tools | (see below) | Tool-related sub-options. |
mcp_tools_max | 0 | Cap MCP tools exposed (0 = no cap). |
Context compression is handled by Deep Agents SummarizationMiddleware (automatic near context limits) plus TUI /compact. xcodon builds that middleware itself, sized by context_budget_tokens and compaction_trigger_fraction (agent/compaction.py). Summaries append to outputs/plan_context_digest.md via XCodonCompactionHooksMiddleware. See Agent backend.
Run mode settings
A project runs in plan mode (a stepped plan and a checklist) or in direct mode (no plan; one conversation does the task, then fresh conversations review it). How each mode works: Direct mode. Every field with its full text: Config field reference.
| Field | Default | Description |
|---|---|---|
run_mode | auto | What the TUI and web setup pick once the subject is known. Only your own plan or a typed task can run in direct mode; a paper, a template or a software project always runs in plan mode. auto and direct: your own plan runs in direct mode, and the setup step lets you pick plan mode instead. plan: every subject runs in plan mode. Setup writes the result to direct_mode. |
direct_mode | false | The switch a run reads. A headless run reads only this field. xcodon init --run-mode direct sets it. |
direct_mode_steps | 150 | Model-call cap for the work turn of a direct run. |
direct_mode_check_steps | 30 | Model-call cap for the last review conversation. 0 turns every review off. |
direct_mode_condition_steps | 20 | Model-call cap for the review of one condition the task names. |
direct_mode_reviews | auto | After v0.6.1. each: one fresh review per condition the task names, then the last review. one: only the last review. auto: one for an ACP agent, each for xcodon's own loop. |
direct_mode_agent | null | After v0.6.1. A /codon handoff preset with protocol: acp, for example antigravity. Each direct-mode turn then goes to that coding agent instead of xcodon's own loop, and no LiteLLM model or key is needed. A model id acp/<preset> does the same. In plan mode, xcodon refuses to run with an ACP agent. See Coding agents over ACP. |
direct_mode_agent_sec_per_step | 60 | After v0.6.1. Time limit for an ACP agent's turn: this many seconds per model call the turn would have had. |
direct_mode_tool_search | true | Give a direct run coala_search and skill import, so it looks for an established tool before it writes a known method by hand. |
plan_style | goal | Plan mode. goal: each step states its goal and expected result; the agent picks the method after it looks at the data. method: each step carries its full method, written before any code runs; an exploration step and a re-plan then revise it. |
cheap_looks | true | Plan mode. A look at the data costs one model call: inline scripts, plain output and no digest message after a tool round. |
plan_review | true | Headless plan-mode runs. Once the checklist is complete, run direct mode's reviews of each condition the task names, then check the files. |
plan_drafts | 3 | Plan drafts written and merged before the review. Used only with plan_style: method; goal writes one draft. |
explore_first | true | Add a first exploration step to a fresh plan. Used only with plan_style: method. |
The config field reference lists the rest: direct_mode_condition_close_steps, direct_mode_domain_skills, direct_mode_method_rules, direct_mode_fix_rounds, explore_before_plan, round_digest_enabled, history_arg_truncation, step_data_facts and improve_rounds.
Harness rules (harness_rules.yaml)
xcodon checks each finished step in two ways: the gate (fixed code checks, no model call) and the judge (a model that reviews the step's report). Every gate check and every judge rule has an id and can be switched on or off for one project.
Gate check groups
harness_gate_groups in agent.yaml turns whole groups on.
| Group | Default | Checks |
|---|---|---|
core | on | declared_check (the agent's own checks file passes and is not loosened), artifact (promised files exist), deliverable (graded write-ups keep their sections and are current), lineage (outputs trace to inputs), quarantine (no fabricated file re-created), method_test (each method module in workspace/methods has a planted-truth test that passes) |
integrity | on | data_facts (only with step_data_facts), claim (claims agree with the step's tables), visual_check, fabrication (code draws or types values instead of reading data; graded files are scanned again at run end), id_values (identifiers in a deliverable table come from the input tables), output_consistency (one value per quantity) |
plan_binding | off | restriction (a stated subset is proven on the output), expected_number (plan numbers bound to their column), expected_coverage, row_key |
tools | off | tool_ran, tool_unused, source_used, workload |
With restriction or expected_number off, the step rules no longer ask the agent for a restriction check or for plan-number bindings.
Switching single rules
Put harness_rules.yaml in the project folder. A rule listed there uses that value. A gate check left out follows harness_gate_groups; a judge rule left out keeps its default (all judge rules are on by default).
gate:
tool_ran: true # on, though the tools group is off
restriction: false
judge:
method-fidelity: false # left out of the judge's promptxcodon rules myproject lists every gate check and judge rule, whether it is on, and why (group tools, switch or default). xcodon rules myproject --write writes harness_rules.yaml with every rule, its current state and a one-line description, ready to edit; it does not replace an existing file without --force.
An unknown rule id, a value that is not true or false, or a file that does not parse is reported as a warning (by xcodon rules and in the run log) and never stops a run; the defaults stand. harness_gate_enabled: false or harness_judge_enabled: false still turns the whole gate or judge off.
Where the rules are defined
Both lists ship with xcodon in src/xcodon/agent/rules/:
gate_rules.yaml: one entry per gate check, in the order they run (id,group,category,summary, and thebuilderfunction that makes its rows).judge_rules.yaml: the judge's prompt, assembled from one entry per rule (id,section,default,summary,text).
Each file's header explains its format. A new gate check is a builder function plus one entry; a new judge rule is one entry.
memory_hooks (MemoryHooksConfig)
Hooks append ## Memory hook — notes to <project>/memory/hooks.md with no extra LLM call. reflection_skill_file_max_chars caps that file.
| Field | Default | Description |
|---|---|---|
enabled | true | Master switch for programmatic hooks. |
on_tool_error | true | Append stub after failed-looking tool output. |
on_compaction | true | Append stub after successful compaction. |
target_folder | reflections | No longer used: hooks always write to memory/hooks.md. Still accepted so older agent.yaml files load. |
prompt_cache (PromptCacheConfig)
When prompt_cache.enabled is true (default), xcodon attaches a cache marker to the stable system-prefix block for Claude models (anthropic/…, vertex_ai/claude-…), which cache only what a marker covers. Gemini and OpenAI cache a repeated prompt start on their own and get no marker: on Gemini a marker would narrow the cache to the marked system text alone. The stable/volatile prompt split always applies regardless of this flag — enabled only toggles whether cache breakpoints are sent. Savings depend on provider billing and session shape; do not expect cache hits on single-round turns. MCP hot-load and /compact intentionally change the prefix and cause misses. Set enabled: false to disable markers only.
tools (ToolsConfig)
Container engine fallback. When coala_runtime_container_engine or coala_mcp_container_engine is docker but no Docker daemon answers, the session runs Coala containers and CWL toolsets on xcrunner, a rootless runtime for Docker images, and logs a warning saying so. agent.yaml is not rewritten, and a working Docker is never replaced. The switch needs an installed coala-runtime and coala that support xcrunner; when they do not, the session keeps docker and the warning names the package that lacks it. Version numbers are no guide: coala-runtime 0.1.4 and coala 0.2.1 each exist both with and without xcrunner support. Set container_engine_fallback: false to turn this off.
Memory. Each long job runs inside a systemd user scope with shell_job_memory_max as a hard ceiling, so one runaway is killed inside its own cgroup instead of taking the machine down. Run one sample at a time and give that run the cores with the tool's own thread option — one process per sample in parallel multiplies memory, which is what the ceiling stops. On a host without systemd user scopes (an HPC compute node), there is no ceiling; shell_job_oom_score_adj then at least steers a global OOM at the job rather than your session.
Long jobs. A multi-hour command costs one tool call. run_shell never kills a command at shell_timeout_sec; past that mark the job is tracked by a watcher that samples it every shell_job_watch_sec and writes to state/jobs/<id>/. Detached children (nohup … &) are waited for too, so backgrounding never returns early, and sleep is refused. Container scripts and MCP tools already block inside one call; they share the same 4 h cap. The model never polls.
The watcher sees only the job's own process group. A submission client — srun, sbatch --wait, ssh host cmd — burns no CPU and writes nothing while the real work runs on another node, so it looks idle and shell_job_stall_sec kills it. On HPC or remote hosts set shell_job_stall_sec: 0 and rely on shell_job_max_sec as the only backstop.
| Field | Default | Description |
|---|---|---|
allow_shell | true | Enable run_shell. |
shell_timeout_sec | 120 | Quick-command budget. A longer command is not killed; it becomes a long job that xcodon waits for. The result gets a footer with the run time and log path. Web-app processes (webapps/runner.py) still use it as a hard kill. |
shell_job_max_sec | 14400 | Hard cap on one run_shell command (4 h). Inside a Slurm job, the cap rises to the job's remaining time less 10 minutes when that is longer. The process group is killed at the cap. |
shell_job_watch_sec | 30 | Watcher interval: one line per tick to state/jobs/<id>/watch.log, and one "still running" line during long container/MCP calls. |
shell_job_stall_sec | 1800 | Kill a long job when CPU time, output bytes and disk writes all stop growing for this long. Must be larger than shell_job_watch_sec. 0 = off. Linux only. Only the job's own process group is sampled, so a quiet submission client (srun, sbatch --wait, ssh host cmd) looks idle while the work runs elsewhere — set 0 on HPC or remote hosts. |
shell_job_memory_max | 80% | Memory ceiling for one long job, as a systemd value (80%, 40G). The job runs in a systemd user scope, so the kernel's cgroup OOM killer stays inside that scope and a runaway takes itself down instead of the machine. "" runs without a ceiling. Ignored where systemd user scopes are unavailable. |
shell_job_memory_high | "" (off) | Optional throttle below the ceiling. Off by default: measured, a throttle leaves a runaway thrashing until shell_job_max_sec instead of being killed in a fraction of a second. |
shell_job_oom_score_adj | 700 | oom_score_adj for a long job's processes. If a global OOM (out-of-memory) kill happens anyway (a host with no scope support), the kernel takes the job instead of the user's desktop session. 0 disables. |
trace_executions | true | Record what every execution reads, writes and runs in state/provenance/ledger.jsonl: run_shell under strace (when installed), container scripts through a short tracing preamble, MCP tool calls through the paths their arguments name, and files the agent writes itself. The step gate uses this ledger to check that outputs trace back to the input data and that the tools the plan names actually ran. Set false to run without tracing; the gate then skips those checks. |
shell_job_keep | 50 | How many state/jobs/<id>/ directories to keep. A new long job deletes the oldest first (ids sort by their UTC timestamp). 0 = keep every job. |
shell_job_log_max_bytes | 20000000 | Cap on each stdout.log / stderr.log left on disk after a job ends (20 MB). A larger log is rewritten as head + a one-line marker + tail, so one runaway command cannot fill the project disk. 0 = keep the whole log. |
shell_block_outside_project | true | Reject shell that reads outside project (+ allowed temp paths). Exception: project-relative inputs/… paths that resolve outside via a symlink are allowed for list/read (read-only linked datasets); writes through those links are refused. |
shell_extra_allowed_absolute_prefixes | [] | e.g. ["/scratch"] — extra absolute path roots run_shell may list/read when shell_block_outside_project is true (HPC job scratch used by Singularity/coala-runtime). Built-in allowlist still includes /tmp, /var/tmp, device paths. |
shell_output_max_chars | 12000 | Truncate run_shell stdout/stderr returned to the model (0 = no cap). |
read_file_max_bytes | 65536 | Max chars from read_*_file / Deep Agents read per file (head+tail excerpt when larger; 0 = no cap). |
read_inputs_max_bytes | 32768 | Stricter cap under inputs/ when read_inputs_extra_strict is true. |
read_file_refuse_bytes | 5242880 | Refuse reads when file size exceeds this (~5 MiB; 0 = never refuse on size alone). |
read_inputs_extra_strict | true | Apply read_inputs_max_bytes under inputs/. |
shell_refuse_inputs_read_bytes | 5242880 | Refuse run_shell cat/less/more on large inputs/ files (0 = off). |
shell_head_max_lines | 500 | Reject head -n N when N exceeds this value. |
allow_coala_cli | true | Allow coala_search / coala_invoke in the loop. |
plan_allow_coala_search | true | /codon plan may still search even if allow_coala_cli is false. |
plan_allow_coala_skill_import | true | /codon plan may coala_invoke skill import even if loop disallows coala. |
coala_plain_output | false | Return a coala_execute_* result as the script's plain output instead of the executor's JSON record. cheap_looks and direct mode turn it on for the run. |
coala_default_mounts | false | Mount inputs, workspace and outputs at /inputs, /workspace_host and /outputs when a coala_execute_* call names no input_files. cheap_looks and direct mode turn it on for the run. |
coala_short_script_tools | false | Give the two coala_execute_* tools a short schema with no params wrapper. cheap_looks turns it on for a plan-mode run; direct mode has its own short tools. |
library_skill_prefetch | true | Before the first analysis script write or coala_execute_* with library packages, auto-run coala_search → coala skill → fetch_local_skill and defer the write/execute until SKILL.md is loaded. A CLI the script installs itself (micromamba create … hisat2, apt-get install …) counts as a dependency too, so it takes the same route instead of skipping Coala. With allow_coala_cli, a result that shows a CLI is missing names its Coala MCP toolset when the registry has one, and a local download-install of such a tool (wget …/tool-1.2.tar.gz, git clone …/tool) is deferred once. |
allow_coala_skill_import | true | Let the live agent run coala_invoke ["coala","skill",…] to import a toolset's SKILL.md into .agents/skills/. false removes tool-level playbooks but keeps coala_search and MCP imports working. plan_allow_coala_skill_import governs the separate /codon plan prefetch. |
coala_skill_skip_libraries | pandas, numpy, scipy, scikit-learn, sklearn, matplotlib, seaborn | Libraries for which no Coala skill is fetched. The automatic prefetch skips them, and a manual coala_search / coala_invoke skill import for them is refused with the reason. Names match case-insensitively, with . and - treated alike. [] fetches a skill for every library. |
skill_finder_enabled | true | When true (default), plan generation and /codon plan search skills.sh for a matching domain skill, confirm it against the aim or step text with an LLM gate, and on a match download and install third-party skill code into the project (.agents/skills/). Set false to disable all skills.sh discovery/installation. See Skill discovery below. |
skill_finder_timeout_sec | 120 | Timeout (seconds) for each skills.sh discovery/install HTTP call or coala skill … subprocess. |
skill_finder_max_candidates | 5 | Max candidates kept per query from the skills.sh search API before the LLM match gate runs. |
skill_finder_owner | null | Optional GitHub owner/org filter passed to the skills.sh search (owner=); null searches all owners. |
coala_search_timeout_sec | 90 | Coala search timeout. |
coala_invoke_timeout_sec | 600 | Coala invoke (mcp/skill import) timeout. |
coala_execute_timeout_sec | 3600 | Default params.timeout for coala_execute_* when omitted (1 h; coala-runtime's own default is 300s). |
coala_execute_timeout_max_sec | 3600 | Clamp for params.timeout (explicit or default). The coala-runtime executor rejects anything above 3600 outright, so a larger value fails the call rather than lengthening it. |
mcp_call_timeout_sec | 14700 | Read timeout on every MCP tool call. A hung CWL job returns an error instead of blocking the run. Inside a Slurm job, it rises to the job's remaining time less 10 minutes when that is longer. Five minutes above shell_job_max_sec, and well above coala_execute_timeout_max_sec, on purpose: at the same value the two caps race, and the bare MCP timeout would beat the container's own timeout message and its partial stdout. 0 = unlimited. |
coala_dispatch_python | true | Use coala-client APIs vs coala subprocess. |
external_cli | command: gemini, args: [], timeout_sec: 600 | Default handoff CLI (see below). |
handoff_cli_presets | {} | Named presets for /codon <name> (merges over built-ins). |
coala_runtime_server | "coala-runtime" | MCP server name for coala_execute_python / coala_execute_r; set null to disable runtime tools. |
coala_runtime_default_python_image | null | Default docker_image for coala_execute_python when the tool call omits it (e.g. python:3.12-slim). Per-call params.docker_image and SKILL frontmatter still win. |
coala_runtime_default_r_image | null | Default docker_image for coala_execute_r when omitted (e.g. bioconductor/bioconductor_docker:RELEASE_3_20 instead of the stock coala-runtime-r:latest image, published as ghcr.io/coala-info/coala-runtime-r). |
coala_runtime_enforce_default_images | false | When true, coala_runtime_default_*_image replaces any LLM-supplied params.docker_image (pinned-runtime runs). |
coala_runtime_base_python_packages | pandas, numpy, scipy, scikit-learn, matplotlib, seaborn | Packages the stock coala-runtime-python image already ships. xcodon drops them from params.packages before deciding to build a derived image, so a run that needs only these runs on the default image. Applies only when the run uses the default image. Set [] if your image is not the stock one. |
coala_runtime_container_engine | "docker" | docker, singularity, apptainer, podman, xcrunner — sets COALA_CONTAINER_ENGINE on that MCP server (coala-runtime; same as --engine). Also sets legacy COALA_RUNTIME_CONTAINER_ENGINE. |
coala_runtime_tmpdir_project_relative | null | If set (e.g. workspace/tmp), sets TMPDIR on the coala-runtime MCP process to <project_root>/<path> so host staging dirs from coala-runtime (tempfile.mkdtemp) use the project instead of system /tmp. Directory is created if missing. Override with coala_runtime_mcp_extra_env.TMPDIR. |
xcrunner_env_project_relative | ".xcrunner-env" | Folder, relative to the project root, that holds the xcrunner writable layer. When the coala-runtime engine is xcrunner, xcodon passes it as XCRUNNER_ENV_DIR, so tools installed inside a container (pip, apt, R) persist across calls and runs, keyed by image id. It sits outside workspace/ so the agent's file tools never see it. Set null to disable; override with coala_runtime_mcp_extra_env.XCRUNNER_ENV_DIR. With the xcrunner engine, xcodon also puts docker, conda, mamba and micromamba shims in <folder>/bin at the front of its own PATH and sets XCRUNNER_ENV_DIR for every command it starts, so the agent's docker builds and conda installs go through xcrunner. |
coala_mcp_container_engine | "docker" | Passed to coala mcp --container-runner / coala-client container_runner on coala_invoke mcp imports (apptainer → singularity). Injected as COALA_MCP_CONTAINER_ENGINE on run_mcp.py servers. |
container_engine_fallback | true | When an engine above is docker and no Docker daemon answers, run on xcrunner for this session instead of failing. Only docker is switched; agent.yaml is not rewritten. false keeps docker and lets it fail. |
coala_runtime_mcp_extra_env | {} | Merged onto the coala_runtime_server entry after defaults (override engine key if needed); e.g. SINGULARITY_CACHEDIR. Xcodon also sets COALA_CONTAINER_USER to the host uid:gid so bind-mount files are not root-owned; set COALA_CONTAINER_USER: "" to keep the image USER. |
coala_mcp_extra_env | {} | Merged onto each run_mcp.py MCP server after defaults (e.g. CWLTOOL_EXTRA_ARGS). |
deps_backend | "container_artifact" | How built_image_label deps are persisted for coala-runtime: bake a Docker tag or Apptainer .sif. Values pixi / auto are accepted for compat but ignored for coala-runtime save/reuse (pixi is host-local only). |
pixi_enabled | false | Deprecated for coala-runtime; previously allowed auto → pixi after a failed bake. Leave false. |
pixi_project_relative | workspace/.pixi-env | Directory containing pixi.toml for host-local pixi tooling (not coala-runtime). |
pixi_extra_deps | [] | Extra conda package names for host-local pixi manifests. |
container_cache_relative | workspace/container_cache | Recipes, .sif files, and Docker build contexts. |
auto_built_image_label | true | If coala_execute_* has packages but no built_image_label, use python-deps / r-deps for this project (save after first success; reuse when request ⊆ cached packages; delta-install extras on the baked image). Set false to require an explicit label. |
container_build_fakeroot | true | Pass --fakeroot to apptainer/singularity build. |
container_build_timeout_sec | 3600 | Timeout for container / .sif builds. |
pixi_install_timeout_sec | 1800 | Timeout for pixi install. |
Skill discovery
Search keywords. For onboarding, the model splits the paper (its Abstract, Methods and Code availability) or the aim into at most 8 analysis stages. Each stage's method (spatial deconvolution, fine-mapping), its assay (bulk RNA-seq) and each tool the paper names (without its version) are searched on their own, keeping the top skill_finder_max_candidates results per query; at most 40 distinct skills are downloaded per run. When the stage split gives no stages, the model's method keywords for the whole aim are searched instead, and without a model an offline term-scoring heuristic builds the query. A run whose downloads or searches failed (for example skills.sh rate limiting) is shown but not saved, so the next run tries again.
Fetching and installing. No node tooling is involved. Search calls the skills.sh api/search endpoint (the same one the skills CLI uses, with the same limit/owner parameters); SKILL.md text and installs come from the unauthenticated api/download endpoint, which returns the whole skill directory (scripts included) in one call. That endpoint allows 60 requests per hour, so a fetched directory is cached for 24 h under ~/.xcodon/cache/skills/ (override with XCODON_SKILL_CACHE_ROOT) — reading a candidate for the gate and installing it costs one download, re-running onboarding costs none — and when the API refuses, the skill is taken from a shallow sparse git clone of its repository (the same fallback the skills CLI uses; needs git). Further fallbacks: coala skill against the GitHub tree, then the fetched SKILL.md text alone.
Choosing skills before the plan. After subject intake and the data-source choice (the paper's data, or your own with its paths — the same order in the TUI and on the web), xcodon splits the paper or aim into analysis stages and searches skills.sh for each stage, judges each candidate, and asks you in the chat (TUI) or on the onboarding page (web): the menu lists each analysis stage with the skill that covers it, then the numbered skills; pick candidates by number (1 3) — the reply also confirms and generates the plan — 0 for no external skill, or local <path> to import your own skill or template (a .md file or a folder with SKILL.md, anywhere on your machine; it is copied into skills/). The result is saved per paper, model and prompt version, so reopening the same paper shows it at once; reply refresh (or use Search skills.sh again on the web) to search again. Only then is the plan generated, shaped by your choice; no automatic skill decision is made at plan time once you have answered. Unattended (--super) runs and research templates skip the question.
Stage routing. When a matched skill describes a workflow, xcodon maps the skill's stages onto the pending checklist once — one low-effort model call per skill, run at the same time (state/skill_finder.json → stage_maps). A stage that spans several steps, splits a step, or has no step triggers a checklist re-partition: applied directly at plan time, applied automatically in super mode, and proposed in human-in-the-loop runs, where you answer with /codon skill-domain apply (rewrite the pending steps) or /codon skill-domain keep (keep the steps; the skill then guides each one). At every such prompt you can also answer /codon skill-domain none (no extra skill) or /codon skill-domain local <name|path> to use your own skill or template from the project (skills/<name>/SKILL.md, or any .md inside the project); a pinned local skill is stage-mapped and routed exactly like a skills.sh match. Completed steps are never changed. A skill whose stages map 1:1 onto steps is injected per step, scoped to that step's stage. Several skills can match together when their own SKILL.md files cover different stages (one the LD matrix and fine-mapping, another the colocalization): each is used only for the stage it covers, their maps are merged into one plan alignment, and /codon skill-domain 1 3 accepts several complementary candidates at once. Coverage claims are grounded in the skill text; nothing is inferred beyond what a skill describes. Every lookup, choice and re-partition is announced in the chat and recorded in the notebook; the web onboarding page lists plan-time lookups.
tools.external_cli (ExternalCliConfig)
| Field | Default | Description |
|---|---|---|
command | gemini | Executable for default handoff. |
args | [] | Args passed to command. |
timeout_sec | 600 | Handoff timeout. |
protocol | cli | After v0.6.1. cli runs command *args handoff/prompt.md and reads its output. acp starts command *args as an Agent Client Protocol (ACP) server and sends the prompt over the protocol. |
mode | null | ACP only. Session mode to set first, as the agent names it (Antigravity: default, accept-edits, auto, plan). |
model | null | ACP only. Value for the agent's model session option. |
permission | allow | ACP only. The answer to each permission request: allow or reject (once each). The result lists every answer. |
xcodon_tools | true | ACP only. Give the agent xcodon's script tools (coala_execute_python, coala_execute_r) and, with direct_mode_tool_search, the tool search, as a Model Context Protocol (MCP) server. false leaves the agent its own tools only. |
Each handoff_cli_presets entry has the same fields: command (required), args, an optional timeout_sec override, and the ACP fields. Built-in presets: gemini and gemini-cli (command gemini), codex, and, after v0.6.1, antigravity and agy (command agy acp, protocol: acp). An entry with the same name replaces a built-in one.
tools:
handoff_cli_presets:
antigravity:
command: agy
args: [acp]
protocol: acp
mode: accept-edits
timeout_sec: 1800MCP server entry (mcp_servers[])
| Field | Required | Description |
|---|---|---|
name | yes | Stable server id; tools become mcp__<name>__…. |
command | yes | Stdio executable. |
args | no | Default []. |
env | no | String map passed to subprocess. |
