Reference·ConfigIndexClose
Config
The config file, how to change it, and every core key with type and default.
File
| Fact | Value |
|---|---|
| Path | ~/.nodecode/config.jsonc |
| Format | JSONC: JSON with comments. |
| Scope | One per home. The home is ~/.nodecode/, or a profile's folder. |
| Missing file | Allowed. Every key has a default or is optional. |
| Dotted names | These pages name a nested key with dots: goal.check_seconds is "goal": {"check_seconds": 600} in the file. A top-level key with a dot in it is read by nothing. When cells start, a notice names it with the nesting it meant, and /doctor lists it. |
The other files of the home are listed in Files.
Change it
Edit the file, or use eval. See Eval.
(config-get '("channels" "discord"))
(config-set '("channels" "discord") '(:require_mention :false))
(config-set '("providers" "old") :remove)
| Form | Does |
|---|---|
(config-get) | Returns the whole config. |
(config-get PATH) | Returns the value at PATH. PATH is a list of keys, or one key. A dot does not nest: "goal.check_seconds" is refused, and the path is '("goal" "check_seconds"). |
(config-set PATH VALUE) | Writes VALUE at PATH. Returns the change as one line. |
(config-set PATH :remove) | Removes the member at PATH. |
| Rule | Detail |
|---|---|
| Values | t, :false, :null, a string, a number, a keyword plist for an object, a list or vector for an array. nil is refused: #() is an empty array. |
| Comments | Kept. Every other byte of the file is kept too. |
| Object value | Merged member by member. It never removes a member. |
| Other value | Replaces the member. |
| Write | Atomic. The file mode is kept. |
| Secrets on read | A key ending in api_key, token, secret or password reads as [set]. |
| Secrets on write | config-set refuses to write [set] over a secret. |
| Whole section | A section read with secrets cannot be written back whole. Write single members. |
Apply a change
| Keys | Read | Apply with |
|---|---|---|
| Cell sections | When the cell starts. | (restart-cells) or (restart-cells "NAME") in eval. |
providers, failover | At the start of each turn, when the file changed. | The next turn. |
fork.seconds | At each (fork ...) call. | The next call. |
general.default_model, general.auxiliary_model | When the organism boots. An organism is a running Nodecode. | A restart, or /models: its Main and Auxiliary tabs. |
workspace.captures | When the gateway starts. The gateway is the local server shells attach to. | A restart. |
general.theme | When the shell starts. | /themes, or a new shell. |
(restart-cells) stops the cells, reads the file again and starts them.
general
| Key | Type | Default |
|---|---|---|
general.default_model | Object: provider, model, optional effort (a rung, or auto for the decider to pick per turn) | None. The build default applies. |
general.auxiliary_model | Same object | None. Session names, recaps and summaries run on the session's model. |
general.decider_model | Object: provider, a decider id (djev), and model | None. No decider. |
general.theme | String | Tungstene. A /themes pick outranks it. |
See Models and providers.
providers
One entry per provider id, under providers.<id>.
| Key | Type | Default |
|---|---|---|
sdk | openai-completions, openai-responses, anthropic or google | None |
base_url | String | By dialect. See Models and providers. |
api_key | String. A leading ! runs a shell command. | None |
display_name | String | The id |
models[].id | String | None |
models[].context_window | Integer above 0 | None |
models[].reasoning_options | The models.dev shape: [{"type": "effort", "values": ["low", "medium", "high", "xhigh", "max"]}] | The models.dev entry for the model id |
models[].sdk | A dialect, for this model only | The provider's sdk |
proxy | String | None |
request_max_retries | Integer, 0 or more | 4 |
stream_max_retries | Integer, 0 or more | 5 |
stream_idle_timeout_ms | Integer above 0 | 120000 |
stream_rerun_ceiling_seconds | Number, 0 or more. 0 disables it. | 120 |
reasoning_summary | String. off, none or false disables it. | auto |
session_token, access_key_id, secret_access_key | String | None |
session_token, access_key_id and secret_access_key only mark the provider as having credentials. No request sends them.
failover
| Key | Type | Default |
|---|---|---|
failover.chain | Array of {provider, model} | None: no failover |
failover.on | Array of trigger ids: rate_limit, outage, slow_start, broken_answer, refusal | Every trigger. [] turns every one off. |
failover.first_token_seconds | Number, 0 or more. 0 never cuts. | 60: seconds an attempt with a backup behind it waits for its first token |
/models' Backup tab writes chain and on. See Models and providers.
fork
(fork "task" ...) hands a turn's independent tasks to forks of its session. See Eval.
| Key | Type | Default |
|---|---|---|
fork.seconds | Integer, 30 or more | 900: seconds a fork's turn may run before its tools are refused |
gateway and workspace
| Key | Type | Default |
|---|---|---|
gateway.operator_token | String | None. Read after the environment and the operator-token file. |
workspace.captures | Boolean | true. false turns workspace snapshots off. |
See Gateway and Sessions and undo.
update
| Key | Type | Default |
|---|---|---|
update.mode | auto, ask or off | auto on an installed build. off on a checkout build. |
update.channel | String | stable |
update.check_minutes | Integer, 1 or more | 360 with a release feed. 30 without one. |
update.url | String: a release host | The host this build was installed from. |
update.feed | String: the feed address, or off | Beside the release host. |
See Updates.
request_bodies
Nodecode keeps the exact body of each model call in the store.
| Key | Type | Default |
|---|---|---|
request_bodies.keep_mb | Integer, 0 or more. 0 keeps none. | 256 |
Past the limit the oldest bodies go.
cache_warming
A request with cache breakpoints, as every Anthropic call has, writes its prompt into the provider's cache for 5 minutes, or an hour when the marker says so. A session that waits longer pays to write the whole prompt again on its next call. Nodecode sends the session's last request again at 90% of that time with one output token, which keeps the entry alive at the price of a cache read.
| Key | Type | Default |
|---|---|---|
cache_warming.mode | idle, streaming or off | idle |
| Mode | Warms |
|---|---|
idle | While a turn waits on a tool, for up to 60 minutes, and after it ends, for up to 30. |
streaming | Only while a turn waits on a tool. |
off | Never. |
A refresh goes out only when it is expected to save at least $0.05: the write the next call avoids, counted in full while the turn is open and at 15% once it ended, less the refresh's own price. It stops when the session moves to another model, when a refresh fails, and for a request that thinks on a token budget. What a refresh cost is counted in the session's usage as a side call, cache_warming.
notify
A desktop notice when a turn ends. The section's presence turns it on.
| Key | Type | Default |
|---|---|---|
notify.command | Array of strings: the command and its arguments. {title} and {body} are filled in. | notify-send on Linux, a toast on Windows and WSL, osascript on macOS |
notify.scope | attached or all | attached: only when a shell received the turn's end |
A cancelled turn sends no notice.
help, index, import, welcome and tui
| Key | Type | Default |
|---|---|---|
help.hot_budget | Integer, 0 or more | 8192: characters of the manual's topic list below its first line, which every request carries. Past it the first topics keep their one-line summary and the rest are named only. The names always stay, so 0 names every topic without a summary. (help) still lists every topic with its summary. |
index.hot_budget | Integer, 120 or more | 8192: characters of the index below its first line. A small budget names the definitions without describing them. |
index.stale_days | Integer, 1 or more | 30: a skill or a layer definition unused this long reads as cold. A memory never does. |
import.session_budget | Integer, 1 or more | 200: conversations one import carries before the rest wait |
welcome.note | Boolean | true: a short brief when Nodecode comes back after a stop, a crash or an update, as a row in a chat that has begun and in each channel's home room. The home screen shows none. false makes no model call for it. |
tui.notification_popups | Boolean | false. true shows notices as popups in the top-right corner. |
Cell sections
A cell is a folder of code under ~/.nodecode/cells/. Each cell reads its own section.
Every cell section takes enabled, a boolean, default true. "enabled": false stops that cell from starting.
A cell declares its section in its own code. /settings shows its fields. On /cells, Enter opens a cell's settings. See Cell API.