Reference·Instruction filesIndex

Instruction files

Which files Nodecode reads into the prompt, where the model finds them, and when an edit takes effect.

.mdllms.txt

Files read

FileApplies toBlock
~/.nodecode/AGENTS.mdEvery session, in any folder.operator-rules
The first project file foundSessions in that project.instructions

Both ride in the conversation's first user message, ahead of your prompt. Each is a <harness> block that starts From <path>:, operator-rules first. The system message holds only the session's folder and the manual's topics.

system · 1,555 characters · the base prompt, then <harness key="folder">, <harness key="help">
<harness key="operator-rules">From /home/you/.nodecode/AGENTS.md: Answer in British English.Commit messages are in the imperative mood.</harness> <harness key="instructions">From /home/you/shop/AGENTS.md: # shop Run `pnpm test` before you say a change works.Prices are integer cents, never floats.</harness> add a coupon field to checkout
What the model received~/shop, the turn's first request

A profile has its own home, so it has its own AGENTS.md. nodecode import writes another agent's rules into ~/.nodecode/AGENTS.md, one ## heading per file it read.

Chat bots also read ~/.nodecode/SOUL.md, for their voice. A terminal session does not. The channel cells under Cells say how.

Project file

Nodecode looks in the session's folder for AGENTS.md, then CLAUDE.md, then .cursorrules, and reads the first one there. Finding none, it climbs to the parent folder and looks again. It stops at the first file, at the folder that holds .git, at /, or after 64 folders.

LOOKED FOR, IN ORDER~/mono/HOLDS .GITpackages/api/AGENTS.md3 · READ, STOPsrc/AGENTS.mdCLAUDE.md.cursorrules2routes/AGENTS.mdCLAUDE.md.cursorrules1 · THE SESSION
A session in ~/mono/packages/api/src/routes. The search looks in three folders and reads packages/api/AGENTS.md. It never reaches ~/mono, where it would have stopped at .git.
RuleDetail
One fileOnly the first file found is read.
Git rootThe search ends at the folder that holds .git.
No gitThe search ends at /, or after 64 folders.
A folder by that nameA folder named AGENTS.md, CLAUDE.md or .cursorrules is passed over. Only a file counts.
Session in the home~/.nodecode/AGENTS.md is read once, as instructions.

AGENTS.md and CLAUDE.md side by side, for both to apply

Only AGENTS.md is read. The model gets From /home/you/shop/AGENTS.md: and not a line of CLAUDE.md.

Instead: One file. Link the other to it: ln -s AGENTS.md CLAUDE.md.

Rules in packages/api/AGENTS.md, the session opened at the repository root

The search climbs from the session's folder. It never looks down. The model gets no instructions block.

Instead: Open the session in packages/api, or put the rules at the root.

An AGENTS.md at the root and another in a package

In packages/api the package's file is found first. The model gets From /home/you/mono/packages/api/AGENTS.md: and none of the root's.

Instead: Write what the package needs from the root into the package's own file.

~/work/AGENTS.md, for every repository under ~/work

Each search stops at its repository's .git, below ~/work. The model gets no instructions block.

Instead: Rules for every session go in ~/.nodecode/AGENTS.md.

.cursor/rules/, GEMINI.md or .github/copilot-instructions.md

None of them is a name Nodecode looks for. The model gets no instructions block.

Instead: Keep the rules in AGENTS.md. Link the other tools' files to it.

Size limit

The limit is 64.0 KB per file: 65,536 characters.

CaseResult
Within the limitRead whole.
Over the limitRefused whole. Nothing is trimmed. No session reads it.
Blank or unreadableNo block.

The warning names the file, its size and the limit: ~/big/AGENTS.md is not read: 71.2 KB — trim to 64.0 KB

File over the limitWho is told
A project fileThe shell, once per file while the organism runs.
~/.nodecode/AGENTS.mdEvery shell, as it attaches, and the model, in its notices block. Until the file fits.
The shell in ~/big, one turn in

Pasting a reference into the file: an OpenAPI dump, a style guide

Past 64.0 KB the whole file is refused, the rules with it. The model gets no instructions block.

Instead: Keep the rules in the file, and name where the reference lives: The API reference is docs/openapi.yaml.

When edits apply

FileReadEdit takes effect
~/.nodecode/AGENTS.md, project fileAt the first request of each turn.At the next turn.

No restart is needed.

A conversation keeps the prompt of its first request. A later edit reaches the model at the next turn, as a <system-reminder> after your message. It lists the lines added (+) and removed (-), or the whole file when that is shorter. A deleted file reads (withdrawn). After an eviction the prompt is built again from the current files. See Context.

now the admin form
<system-reminder>Your standing context changed. Each block below replaces the one of its key you were shown before; one marked changed="lines" lists only the lines added (+) and removed (-). <harness key="instructions" changed="lines">+ Never edit files under migrations/ without asking first.</harness></system-reminder>
What the model received~/shop, turn 2, after a line was added
and the receipt
<system-reminder>Your standing context changed. Each block below replaces the one of its key you were shown before; one marked changed="lines" lists only the lines added (+) and removed (-). <harness key="instructions">(withdrawn)</harness></system-reminder>
What the model received~/shop, turn 3, after the file was deleted

Restarting, or /new, to pick up an edit

The next turn already carries it. A new session starts without the conversation.

Instead: Send the next message.

Editing the file during a turn, for that turn

The file is read at the turn's first request. The edit lands at the next turn.

Instead: Steer the running turn with the change, or wait for the next one.

Esc

    Loading the index…

    ↑↓ moveEnter openEsc close