Skip to content

Providers

For a new setup, use onboarding to configure the writer and reviewer. It checks the selected models and stores the configuration for the current OS user, without creating a project or a .env file.

What you want to runUse
A native workbench Agent or a fix writer/reviewer on this computerLocal Ollama, with the version and model requirements below
A native workbench Agent or a fix writer/reviewer using hosted creditsOpenRouter, with an eligible model and credits-only account
Claude Code or Codex as a fix writerExternal agents; their reviewer still uses Ollama or OpenRouter
An existing compatibility SessionCompatibility hosted providers or compatible endpoints

Each Agent selects its provider and model. Provider endpoints and credential references live under providers: in YAML; a secret-store reference keeps the key itself out of that file. New data roots use native Session execution. Direct OpenAI, Anthropic, Gemini and Mistral adapters remain compatibility paths; an API-compatible endpoint alone does not establish native budget enforcement.

Native Sessions use your OpenRouter credits. Connect your OpenRouter account by signing in in the browser; you never see, copy, paste or type a key:

Terminal window
axocoatl connect openrouter --reviewer openai/gpt-oss-120b

axocoatl onboard runs the same sign-in when you choose OpenRouter and it asks how to get the key, and uses a key connected here without asking.

--writer and --reviewer are optional: name the OpenRouter models you plan to use (as openrouter.ai/models lists them, vendor/model) and they are checked before you sign in. The models above are examples. The command:

  1. Asks you to confirm that the account pays with OpenRouter credits and has no BYOK provider keys connected, the question onboarding asks. BYOK is not supported by native Session execution. --credits-only answers yes without a terminal.
  2. Checks each named model in OpenRouter’s public model catalog: listed, with tool calls, text in and out. A model that fails stops the command before any sign-in. The writer and the reviewer must be different models.
  3. Opens OpenRouter’s sign-in page in your browser and prints its address (--no-browser only prints it). This is OpenRouter’s OAuth PKCE flow: when you allow Axocoatl to create a key, the browser returns to http://127.0.0.1:<port>/callback on your computer, on a port the system picked. Axocoatl uses an answer only when it carries this sign-in’s state (any other request there is ignored, and the sign-in goes on waiting), then exchanges its code, with a verifier that never left your computer, for a new key labeled Axocoatl <date>. The sign-in may take 10 minutes (--sign-in-timeout MINUTES, 1 to 60); at a terminal, when that time ends, it asks whether to keep waiting (Enter waits as long again). Each connection to that address is written to a log, connect-openrouter-<time>.log beside onboarding’s (~/Library/Logs/Axocoatl on macOS, ~/.local/state/axocoatl on Linux), its method, path and Host only, never the code; the first connection makes the log. A sign-in that fails names the log, or says that no browser came back. In WSL the page opens with wslview, in Windows’ browser. Cancelling it in the browser, running out of time or pressing Ctrl-C stores nothing.
  4. Checks the key with OpenRouter (GET /api/v1/key) and shows its label, credit limit, usage and whether the account is on the free tier (it has not bought credits), never the key.
  5. Stores the key as the secret openrouter in the data root (0600, the way axocoatl secret set stores one; --secret NAME picks another name).
  6. Adds these lines under providers: in your configuration, leaving every other line as it was. A key written in the file before is taken out of it (it still works in your OpenRouter account until you delete it there). On a computer with no configuration yet, it writes a new one (0600) with only these lines and the server’s defaults: it has no Agents, since axocoatl run takes its models with --model; axocoatl onboard adds a default team for workbench Sessions.
providers:
openrouter_billing: credits
openrouter:
api_key_secret: openrouter # the key is in the secret store, not in this file

The daemon reads the key from the secret store when it starts, so restart a running Axocoatl after connecting. axocoatl connect openrouter --status shows whether a key is stored, with its label, limit and usage from OpenRouter; --remove deletes the stored key and its line in the configuration (delete the key itself at openrouter.ai/settings/keys). While Agents in the file use OpenRouter, --remove keeps the line and names them, and axocoatl doctor reports the key missing until you connect again. axocoatl doctor checks that the secret is stored. When a configuration file cannot be edited this way (a providers: written in flow style, for example), the command stops before the sign-in and shows the lines to add; --no-config stores the key without editing the file. Only for automation without a browser, api_key: "${OPENROUTER_API_KEY}" reads a key from the environment of the process that starts Axocoatl.

An Agent on OpenRouter names its model like this:

agents:
- id: coder
name: Coder
provider: openrouter
model: anthropic/claude-sonnet-5.5
tools: [read_file, list_dir, grep, glob, write_file, edit_file, bash]
sampling:
max_tokens: 4096
reasoning_effort: medium # optional; the model's own default otherwise
providers:
openrouter_billing: credits
openrouter:
api_key_secret: openrouter

The openrouter_billing: credits declaration must match the account’s billing configuration. Do not connect BYOK provider keys while using this execution path; Axocoatl cannot prevent changes made in your OpenRouter account.

Before Send, review Team & budget. Axocoatl reads the model’s entry in OpenRouter’s catalog and its endpoints, selects the cheapest qualifying endpoint that accepts the Agent’s sampling settings and fits its budget, and retains its capabilities, context and output limits, prices and, for a reasoning model, its reasoning contract. It also retains, cheapest first, up to three more of the model’s healthy endpoints that can take over each of its calls: at least the selected endpoint’s context and prompt limit, the same output limit and reasoning setting, and the smallest call within the approved budget. Each activation adds, as it opens, every other endpoint of the model that OpenRouter lists healthy then and that passes the same checks (When an endpoint is rate-limited or down). Every request pins one of them, disables OpenRouter’s automatic retries and fallbacks, and carries that endpoint’s prompt, completion and per-request price ceilings as max_price. The contract of the endpoint a request goes to is checked against the catalog again before each request; a changed or unsupported profile is refused before inference.

Each request reserves a bound computed from that exact request, not the endpoint’s context window:

  • Prompt: the byte length of the request body Axocoatl sends, plus 4,096 tokens for the provider’s chat template and tool preamble, plus the reasoning tokens of earlier tool turns it sends back (see below), at most the endpoint’s prompt limit. A token of these models’ byte-level tokenizers covers at least one byte of text, so the request’s bytes bound the tokens of its own text; the allowance covers what the provider adds.
  • Response: the call’s output limit (sampling.max_tokens) plus its reasoning allowance. The sum is sent as max_tokens. OpenRouter documents that on most providers this caps reasoning and visible output together; a provider that does not count reasoning against max_tokens can bill past the reservation, and that call is then refused as a breach after it was billed, with its spend kept.
  • Cost: the prompt bound at the endpoint’s highest input price, the response at its highest output price, and any per-request fee. The input price is the highest of the prompt, cache read and cache write prices; the output price is the higher of the completion and internal reasoning prices. When an endpoint has price tiers, such as a higher rate above 272,000 prompt tokens, the highest tier is used.

If the approved allowance cannot cover a request’s reservation, the request does not start. OpenRouter’s final usage and billed cost settle the reservation: only they stay charged, and the rest is available to later requests. Reasoning tokens are output: they count toward the call’s output, its tokens and its cost. A response whose usage exceeds its reservation is refused and its reported spend is kept. A missing final response stays unknown and does not release the reservation.

A request’s prompt grows with the Session, so its reservation does too; the smallest call (no request bytes, only the template allowance and the response allowance) must fit the approved budget for Team & budget to admit the Agent. Without sampling.max_tokens, the response allowance takes at most half of the Agent’s whole-call token capacity.

Because later calls reserve more than earlier ones, an Agent asks for its final answer while it can still pay for this call and the one after it, with that one’s prompt grown by this call’s whole response and as much again for the tool results. A lead starts a helper only when, after the helper’s limits, it can still pay for the call that reads the helper’s answer: the lead’s latest call grown by the reasoning it sends back, the turn it returned and the answer.

An Agent’s own token_budget with abort counts the whole response too: before each call it reserves the estimated input, including reasoning tokens sent back, plus the output limit and its reasoning allowance. When it derives the output limit from what is left, it picks the largest output whose response still fits, and refuses the call when not even the smallest response fits.

For a model whose catalog entry describes reasoning, Axocoatl sends the documented reasoning setting with every call: sampling.reasoning_effort when the Agent sets it (max, xhigh, high, medium, low, minimal or none), otherwise the model’s own default effort. An effort the model does not list is refused by name, and so is none for a model whose reasoning is mandatory.

The reasoning allowance follows OpenRouter’s share of max_tokens for each effort (95% for max and xhigh, 80% for high, 50% for medium, 20% for low, 10% for minimal), so the visible output keeps sampling.max_tokens: high adds four times the output limit, medium once, low a quarter. It is never less than OpenRouter’s 1,024-token minimum reasoning budget while reasoning is on, and none adds nothing. With max_tokens: 4096 at high, each call may produce 20,480 tokens.

The sum is never cut to fit. Team & budget refuses, by name, an output limit and effort whose sum passes the endpoint’s own output limit (8,192 at xhigh asks for 163,840 on an endpoint that allows 128,000), or whose streamed text could pass the 1 MiB a Session keeps of one response, counted at 10 bytes per token (5,300 at max is 106,000 tokens). Without sampling.max_tokens, the derived output stops below both.

When a reasoning model calls tools, its reasoning blocks are kept on the tool call and sent back unmodified with the tool results, as OpenRouter documents for tool use, so the model continues the same line of reasoning. They stay in the Session’s history.

Some endpoints also price features such as web search or image input. A native request cannot start them: it sends text and function tools only, no OpenRouter server tools, no modalities or web_search_options, an exact model id (a :online id is refused), and it turns the web plugin off explicitly, which overrides an account default. A response that reports a server tool, web citations, or image or audio output is refused. max_price leaves out image and audio prices: OpenRouter filters endpoints on their listed image and audio prices even for a text request, so a zero cap there would refuse every call to a model that lists them. An account setting that forces the web plugin with Prevent overrides is incompatible with this execution path.

The request also turns OpenRouter’s context compression off, which endpoints of 8,192 tokens or less use by default and an account can turn on: the model sees the exact conversation the Session recorded, including the reasoning it sends back, never one with messages dropped from the middle.

A request never opts into a service tier. Tier endpoints such as openai/flex, openai/fast or google-vertex/flex trade latency, availability or price, serve only a request that asks for them, and are never selected; :nitro and :floor model ids, which opt into them, are refused. A response that reports a tier other than the standard one is refused.

Eligible endpoints need an exact tag (a provider tag such as openai qualifies when no regional or other variant shares it; tier endpoints do not count, because a provider tag never selects them), text output, tool calling, max_tokens, reasoning for a reasoning model, every sampling setting the Agent sends (temperature, top_p, response_format), and prices Axocoatl can bound. An endpoint that charges for anything else is refused, and the error names the component; a sampling setting no endpoint accepts is named too. Dynamic router aliases and custom OpenRouter endpoints are unsupported. A model Axocoatl cannot run says why when Team & budget is applied.

An eligible endpoint is used only while OpenRouter reports it healthy (its status is 0). A degraded or unavailable one is never used, even when no healthy endpoint is left: it fails part of its calls, some part way through an answer and after they cost credits, which no move to another endpoint can undo. When OpenRouter reports every eligible endpoint of a model unavailable or degraded, the Session or run stops before any model call and says so: each endpoint’s status and its share of requests that succeeded over the last 30 minutes, that this is OpenRouter’s provider status and not your setup, and to try again later or choose another model. An endpoint that has become degraded since is not sent to; the call moves to the next endpoint, and when none is left the Session is told the same. Onboarding reads the endpoints of the models you choose before it writes the setup.

A call that an endpoint fails before it produced anything moves at once to the next endpoint of the same model that can carry it: the endpoint’s upstream rate-limited it (HTTP 429), it was unavailable (408 or 5xx), it timed out or closed the connection before its answer started, it reported a 429, 408 or 5xx inside an answer that had produced nothing yet, OpenRouter reports it degraded now, or its contract changed since Team & budget reviewed it. The endpoints are the one Team & budget selected, those it retained, and every other one the catalog listed healthy as the activation opened and that passes the same checks. The call is sent again as a new call, reserved at that endpoint’s own prices against the same approved budget (budgets are never raised), and that endpoint’s contract is checked against the catalog before it is sent. The move happens only when the grant can pay for the call there; otherwise the next endpoint is tried, and then the wait below. Later calls of the same activation stay on the endpoint the call moved to, unless the grant can no longer pay for a call there: then that call goes to the endpoint that reserves least of those that can carry it. Each activation starts again on the selected endpoint.

  • OpenRouter’s own limit on the account (a 429 that names no upstream provider) applies to every endpoint: the call is not moved, but waits its Retry-After and is sent again to the same endpoint.
  • When no endpoint is left to move to, the Session waits once, as long as the longest Retry-After the endpoints that failed the call stated (2 seconds without one), and tries them again, starting on the one that failed it last, or on the next one when that one asked to wait longer than 30 seconds: an endpoint that did is not sent to again for that call. If every endpoint fails again, the call ends. Its error says that OpenRouter reports every endpoint of the model that the Agent may use as rate-limited or unavailable right now, with each endpoint and its failure, that this is a provider outage and not your setup, and to try again later or choose another model. It never quotes OpenRouter’s raw error, which can carry a hint to add your own provider key (BYOK, which native Sessions refuse), or an error page that is not OpenRouter’s JSON.
  • An answer that names another provider than the endpoint its request pinned is refused on every endpoint, and the call is not moved again.
  • A request OpenRouter refused with an HTTP status before generating anything, or one never sent, is counted as costing nothing: it settles at zero tokens and $0 and gives its reservation back, so the run’s usage stays exact. OpenRouter bills the tokens a provider processed, and such a request processed none. A call whose answer had started (an error inside it included, whatever its message says), or that timed out after it was sent, keeps its reservation, and the run’s usage line names the Agent and how many of its calls did not report.
  • The run record shows each move as a provider retry (from endpoint A to endpoint B), the run’s notes name the endpoints that answered each model to the end and how many calls each answered, and the receipt names them in the Agent’s or reviewer’s program_version (openrouter endpoint deepinfra/fp8 (DeepInfra)).
  • A tool-calling turn’s reasoning goes back unchanged to the endpoint the next call goes to, as OpenRouter documents for tool use, whichever endpoint produced it.

A Session whose Team was applied by Axocoatl 1.4 or by a 1.5.0 build before this failover retained one endpoint. Its profile still loads unchanged, and its activations add the other endpoints as every activation does.

Native execution requires a loopback Ollama 0.40.6 or later that reports cloud-disabled mode, and a local GGUF completion model. Axocoatl checks the exact model identity, loaded context, and capabilities during Team review and before inference. Later 0.40 releases are accepted; a later 0.x release (0.41 or later) is accepted only once the contract probes below pass on each model, and doctor, onboarding and a loadout run’s receipt say it is newer than the audited 0.40.6. Native-turn receipts do not retain runtime versions. Older versions (0.20.6 included, which earlier Axocoatl releases required), pre-releases, development builds, a new major release, remote routing, and a generic compatible server do not satisfy this native contract. The broader Ollama adapter remains available for compatibility execution.

GGUF only. Ollama 0.40 runs every GGUF model in llama.cpp’s llama-server, which holds the context Axocoatl sends as a hard limit. On Apple silicon it runs some models with its MLX runner instead, and MLX’s limit is the model’s own maximum context, not num_ctx: Axocoatl refuses a model Ollama shows as non-GGUF or MLX, or loads with any runner but llama-server. When a tag on your Mac pulled its MLX variant, replace it with its GGUF variant when ollama.com has one, with ollama rm MODEL; ollama pull --runner llamacpp MODEL, or choose another model. Ollama does not document that flag, and a pull with it leaves a variant already installed in place (with the MLX qwen3.5:0.8b installed, Ollama 0.40.8 pulled nothing), hence the ollama rm first. The ; lets the pull run if a previous attempt already removed the model. Removal happens even if the pull fails; a model you created yourself is removed for good. qwen3-coder:30b (19 GB) and gpt-oss:20b (14 GB) are GGUF; they are the Lead and Reviewer pair onboarding offers with 48 to 95 GB of memory when no installed pair fits (how well gpt-oss:20b reviews has not been measured). Axocoatl sets nothing that keeps both loaded or unloads either (no keep_alive): whether both stay in memory is up to Ollama.

Another program on the same Ollama. To read a model’s context, Axocoatl loads it (a load without a prompt) and then asks Ollama which models it has loaded. When another program loads a model in between and Ollama unloads this one to make room (or the model is unloaded by ollama stop or a keep-alive of 0), Axocoatl loads it again, three times in all. When Ollama unloads it every time, the run is refused as infrastructure (exit 5), or Team & budget’s Apply fails, with “Ollama unloaded MODEL each of the 3 times Axocoatl loaded it to read its context”, naming what is loaded instead and what to do: run again when that program has finished with Ollama, or let Ollama keep both loaded (more memory, or a higher OLLAMA_MAX_LOADED_MODELS). Measured on a 48 GB Mac: a second client that loaded qwen3-coder:30b right after Axocoatl loaded gpt-oss:20b made Ollama unload gpt-oss:20b. When it did so once, axocoatl run --dry-run loaded gpt-oss:20b again and was ready; when it did so after each of the three loads, the dry run was refused (exit 5).

Contract probes. When Team & budget observes a model’s context, Axocoatl sends a few small requests to your server with that context and the settings every call uses (truncate: false, shift: false):

  • a prompt about four times longer than the context, which Ollama must refuse before generating anything;
  • a one-token request, which must stop after one token;
  • a request for hundreds of lines with an output limit of 64 tokens, which must stop by 64 generated tokens, report exactly 64 when the limit ended it, and stream no more pieces of text than the tokens it reports (a model Ollama runs with speculative decoding, such as the -mtp tags, accepts several drafted tokens at a time);
  • for a model that reports tool calling, a request to call the one tool it is offered, within 1,024 tokens (room for a thinking model’s reasoning: on Ollama 0.40.8, qwen3:4b called it after 195 to 309 tokens), which must come back as a call of that tool with a call id and a string argument, read the way Axocoatl reads every answer. A call to a tool it was not offered beside that one is no failure: a Session answers such a call with a tool error and the model goes on.

Each probe uses a fixed seed at the model’s own settings. This made the measured repeats on Ollama 0.40.8 consistent; it is not a guarantee that every model or runtime will always produce the same answer. A model that fails one is refused on that server for every Agent and every run, with or without tools, and the error names the guarantee that failed. A probe Ollama does not answer (an error status, or an answer that ends before its final record, as when the model’s runner stopped) refuses nothing: the error says the check did not run, and the next try probes again. Images are not probed: every call reserves the model’s whole context plus its output limit, whatever the prompt holds, and Ollama counts an image’s tokens in the prompt it checks against the context, so an image that does not fit is refused rather than cut. The result is kept per Ollama version, model digest, context and tool calling; after an upgrade to another accepted Ollama version, the probes run again on it before it serves an existing Team, and a Team reviewed on Ollama 0.20.6 asks to be reviewed again. Axocoatl’s own scheduled check runs the same probes against each new Ollama release and release candidate, with a small model, as they are published.

agents:
- id: local-coder
name: Local coder
provider: ollama
model: qwen3-coder:30b
tools: [read_file, list_dir, grep, glob, write_file, edit_file, bash]
providers:
ollama:
base_url: "http://localhost:11434"

axocoatl doctor treats a configured Ollama endpoint as a required check: the endpoint must respond, be a loopback address, report an accepted Ollama version (it prints the version and the reason for a refusal) and its cloud features disabled, and have the configured Agent models present as local GGUF completion models, with tool calling for an Agent that lists tools and a loaded context of at least 16384 tokens. axocoatl onboard turns Ollama’s cloud features off where the running server reads them: {"disable_ollama_cloud": true} in ~/.ollama/server.json of the user that runs Ollama (the Homebrew service or an ollama serve you run), the app’s Settings, or Environment="OLLAMA_NO_CLOUD=1" in a systemd drop-in for the Linux service, which runs as the user ollama; then it restarts the server. See Set up Axocoatl.

Qwen3-Coder on Ollama sometimes writes a tool call as answer text instead of Ollama’s structured tool_calls (it leaves out the opening <tool_call>). Both Ollama providers, native and OpenAI-compatible, run such calls only when they end the answer in Qwen3-Coder’s own <function=NAME> format: the first line that starts with a call tag starts a run of complete call blocks that goes to the end of the answer; every call names a tool the request offered; and its values fit that tool’s parameters (types, required parameters, enum). A <tool_call> that ends the line before the run is left out of the answer. A recovered call gets an id unique in the Session. When the answer also holds a call Ollama returned structured, only the structured calls run and the markup stays text. Nothing is read from text when the request set stop sequences or asked for JSON output.

Markup in a code fence, an indented code block or an HTML block such as <pre> or <!-- is quoted text, and so is a call tag after other text on its line in inline code (a code span may run over the lines of its paragraph), markup that names only tools the request did not offer, and a call tag mentioned in a sentence (the <function=glob> tag). An unfenced example in that format that ends an answer runs.

Otherwise, an answer that calls an offered tool in a way that cannot run is refused instead of ending the turn having run nothing:

  • a line that starts with a call tag but no runnable run: prose after the calls, a malformed block, a call to a tool the request did not offer next to one it did, values that do not fit, or a response cut at its output limit inside a call;
  • a call block (<function=NAME> with a <parameter=…> or </function> after it) written after other text on its line, anywhere in the answer, even before a run that begins a line;
  • a call written as JSON ({"name": …, "arguments": …}, the arguments as an object or as a string holding one, or {"NAME": {…}}) that ends the answer: the whole answer, the lines from its last line that starts with {, or a <tool_call> block;
  • an answer that ends with a call tag (<tool_call> or <function=) and nothing after it: the model began a call and wrote none of it (qwen3-coder:30b ended a fix with …let me create a test to verify what happens.<tool_call>, which earlier 1.5 builds took as its final answer, so the fix changed nothing).

Nothing from that response ran. The model is asked once more within the same activation, with a note from the host that says what was wrong with its answer, as a new, separately admitted and budgeted call; the record shows it as a provider retry, and the note is not kept in the conversation. When the answer to the note cannot run either, or the budget cannot pay for asking, the activation fails with the reason, the done reason and the number of tools offered; the workbench says “The model wrote a tool call as answer text that Axocoatl cannot run”, the turn needs attention, and a run’s Outcome lists it as unrunnable_tool_call, not as a provider failure. Continue asks the model again. JSON never runs as a call: JSON in a code fence, or followed by more text, stays the answer. Text from a line that starts a call is shown only when the response ends, and a <tool_call> that ends a line is shown only once the next line shows it opens no call.

gpt-oss:20b on Ollama can end a response having written only reasoning: no answer and no tool call. It can also call one of its own tools that nobody offered. Under a plain name (search, grep) such a call is answered with a tool error that names the tools the model has, and the model goes on. Under gpt-oss’s dotted names (browser.search, browser.open) it cannot be answered, so the response is refused, naming the call and the tools the model has. A response with no answer, or with such a call, ran nothing; its usage is counted, and the model is asked once more within the activation, as for a call that cannot run. A second one fails the activation of any Agent (writer, lead, helper or reviewer): the workbench says “The model gave no answer and no tool call Axocoatl could run”, and a run’s Outcome lists it as no_answer, not as a provider failure. A required reviewer’s round then runs again once in a fresh conversation. When Ollama’s own runner fails (it answered so when the GPU ran out of memory, measured on a 48 GB Mac running other models), the response it returns is empty too; the refusal names the output tokens Ollama counted, and its log says why.

Qwen2.5-Coder (qwen2.5-coder:14b in Axocoatl’s tests) returns its tool calls as JSON text rather than as calls Ollama lifts, so they never run. Onboarding offers it but never suggests it, nor a model whose capabilities lack tools, and axocoatl doctor warns about it for an Agent that lists tools.

Response text from other providers stays text, because Axocoatl cannot safely invent their native call ids, signatures or content-block sequence.

provider:Adapter
ollamaOllama at a configured local or remote endpoint
openaiOpenAI, or an OpenAI-compatible endpoint via base_url
anthropicAnthropic Messages API
geminiGoogle Gemini
mistralMistral Chat API
openrouterOpenRouter through its OpenAI-compatible endpoint

The onboarding wizard offers Ollama and OpenRouter for native Sessions. OpenAI, Anthropic, Gemini, and Mistral are configured manually for their supported compatibility paths.

New data roots use native Session execution, whose enforced budget boundary supports reviewed local Ollama profiles and eligible OpenRouter-credit profiles. The remaining adapters serve their existing compatibility paths; an API-compatible endpoint alone does not establish native budget enforcement.

The direct Anthropic example below configures compatibility execution. For a new native Session, use OpenRouter or Ollama instead. OpenRouter’s key comes from a browser sign-in, axocoatl connect openrouter, and stays in Axocoatl’s secret store; the configuration only names it. For manual compatibility configuration, the environment-placeholder form below keeps the key out of YAML; its value must be present in the process that starts Axocoatl. A key can also live in the secret store: store it with axocoatl secret set <name> and write api_key_secret: <name> in place of api_key.

The following is the equivalent manual YAML form:

agents:
- id: coder
name: Coder
provider: anthropic
model: claude-sonnet-4-6
providers:
anthropic:
api_key: "${ANTHROPIC_API_KEY}"

For the placeholder form, export the value in the environment that starts Axocoatl:

Terminal window
export ANTHROPIC_API_KEY=replace-me

Axocoatl interpolates ${NAME} before parsing YAML and wraps configured secret fields so debug formatting does not reveal them. That does not protect a secret committed in plaintext, exposed by shell history, or logged by an external server.

Axocoatl does not create or load a .env file. Use process-environment or service-manager injection when you choose a placeholder rather than the owner-only user configuration.

For compatibility execution, the openai adapter honors base_url. Include the API-version suffix expected by the server, commonly /v1.

agents:
- id: local-compatible
name: Local compatible model
provider: openai
model: your-model-id
providers:
openai:
api_key: "${LOCAL_MODEL_API_KEY}"
base_url: "http://localhost:1234/v1"

This can target implementations such as LM Studio, MLX/oMLX, or vLLM when their API behavior matches what the adapter uses. A non-empty key may still be required by Axocoatl even when the local server ignores its value.

Provider registration is shared, but the Agent’s configured model is sent on each request. Agents using the same provider may therefore target different models.

agents:
- { id: triage, name: Triage, provider: ollama, model: llama3.2 }
- { id: implement, name: Implement, provider: openai, model: gpt-5 }

Native Sessions retain exact approved models. Conversation displays those models read-only; change them through Team & budget, then preview and apply the revised team. Compatibility Sessions allow a per-turn model override within the Agent’s provider. That override does not supply another provider’s credentials.

A hosted provider may specify one fallback as provider or provider:model:

providers:
openai:
api_key: "${OPENAI_API_KEY}"
fallback: "anthropic:claude-sonnet-4-6"
anthropic:
api_key: "${ANTHROPIC_API_KEY}"

Axocoatl retries once only when the primary request is rate-limited before a stream is established. It does not traverse a fallback chain and does not switch providers for non-rate-limit or mid-stream failures.

This fallback applies to legacy Session and global Agent execution. Native Sessions require their retained primary route and reject configured OpenRouter fallbacks. Explore several ways uses each Way’s configured primary provider/model directly for now; a rate limit fails that Way so its retained provider/model and cost evidence cannot silently describe the wrong route.

For a plain-text-only history, that choice is per call. Once a response starts a tool exchange, Axocoatl records and pins the exact selected slot, provider, and model for every request that still carries that native transaction—including later user turns and a restored Session. This prevents provider-native call ids, thought signatures, or thinking blocks from crossing APIs. Removing the complete transaction during context compression removes the pin. Missing, conflicting, or stale route markers fail closed; start a new Session or restore the matching provider/model configuration instead of forcing incompatible history through a different endpoint.

If the primary is rate-limited before streaming and a fallback has a smaller known context limit than the already prepared request, Axocoatl fails locally instead of sending an oversized fallback call. Custom or otherwise unknown model IDs are not assigned invented limits or feature flags; their compatibility is validated by the configured endpoint.

Terminal window
axocoatl validate
axocoatl doctor

These commands use the user configuration independent of the current directory. For an explicit project-local configuration, pass its path:

Terminal window
axocoatl validate /absolute/path/to/axocoatl.yaml
axocoatl doctor --config /absolute/path/to/axocoatl.yaml

Next: Configure Agents and budgets →