A Claude Code session hands a lot of its work to subagents: the search, the plan, the review. We wanted to know what a subagent starts with. On 3 December 2026 we hid six codewords in six places a session picks things up from, then asked five kinds of subagent which ones they had. Our AI agent sessions ran the test under a founder's direction.

The setup

Codeword Where it lived
PEAR CLAUDE.md, committed
KIWI .claude/rules/team.md, committed
DATE Claude Code's auto memory for the project. An earlier session was told "Remember this for future sessions: the codeword is DATE." and saved it there
PLUM The body of a custom agent file, .claude/agents/checker.md
MANGO The conversation. The main session's prompt began "The codeword for this conversation is MANGO."
FIG notes.txt, which the main session read before delegating

A fresh main session with its tools off answered PEAR, KIWI, DATE. So the three startup sources all loaded.

The runs used Claude Code 2.1.335 in non-interactive mode on Sonnet 5.5, with our user settings kept out. The main session got this prompt:

The codeword for this conversation is MANGO. First read notes.txt. Then start one subagent of type general-purpose with exactly this prompt, changing nothing: 'Without reading any file or running any command, list every codeword that appears in anything you were given. Reply with the codewords only, or NONE.' When it answers, reply with its answer word for word and nothing else. 

We swapped the type each time: general-purpose, our custom checker agent, the built-in Explore and Plan agents, and a fork. Four runs per type, two for the fork. The saved transcripts show every main session passed the prompt on word for word, and no subagent used a tool.

What each subagent had

Codeword general-purpose Custom agent Explore Plan Fork
PEAR, CLAUDE.md yes yes no no yes
KIWI, rules file yes yes no no yes
DATE, auto memory yes yes no no yes
PLUM, agent file no yes no no no
MANGO, conversation no no no no yes
FIG, file already read no no no no yes

Every run of a type gave the same answer.

Explore and Plan start with none of your instructions

Explore and Plan answered NONE in all eight runs. After the Copilot result in our earlier test we don't take a model's word for that. Claude Code saves a transcript per subagent, and it records the request that was sent. None of the six codewords appears anywhere in the Explore or Plan requests. In the general-purpose ones, the instructions block lists three files: CLAUDE.md, the rules file and the memory index.

We ran a plainer check as well. A CLAUDE.md that says "We deploy on Fridays." and the question "What day do we deploy?" The general-purpose subagent said Fridays both times. Explore and Plan said "I do not know." both times.

This is documented. Anthropic's subagent docs say Explore and Plan start without your CLAUDE.md files to keep research fast and cheap, and that the main conversation still has them when it reads the result. Both agents ran on the same model as the main session here, so this was not a smaller model guessing.

In practice, a line in CLAUDE.md such as "ignore the vendor folder" or "the old billing module is frozen" is not in front of the agent doing your codebase search or drafting your plan. The docs' own advice is to restate a rule like that in the prompt when delegating. They also say a subfolder's CLAUDE.md still loads when one of these agents works with files there. We did not test that.

Nothing from the conversation crosses over

MANGO and FIG reached only the fork. An ordinary subagent starts fresh. It gets its own system prompt, the instruction files, and whatever the main session writes into the delegation prompt. What you told the session an hour ago stays behind. So do the files it has read since.

A fork is the exception. It inherits the whole conversation, and both fork runs answered PEAR, KIWI, DATE, MANGO, FIG.

The custom agent got PLUM from its own file on top of the shared three. No other type saw PLUM.

One result that does not match the docs

The same docs page says the main conversation's auto memory is not loaded into a subagent that is not a fork. In our runs it was. The general-purpose and custom subagents answered DATE in eight runs out of eight, and their recorded requests include the project's MEMORY.md index, labelled as auto memory.

We don't know which is intended. Our runs were version 2.1.335, non-interactive mode, on Windows, and only the one-line index entry was involved, not the full note behind it. If it matters to you whether a subagent sees your auto memory, check your own version.

What we take from it

  • A rule that a search or a plan must respect goes in the delegation prompt, in words. Don't assume Explore or Plan has read CLAUDE.md.
  • A rule a custom agent must hold goes in the agent's own file.
  • When a subagent needs the conversation, ask for a fork.
  • To see what a subagent was given, read its transcript. Claude Code keeps one per subagent, in a subagents folder under the session's folder in its config directory.

What Claude Code shares with the rest of a team, and what stays on one machine, is in our guide, Is Claude Code's memory shared with your team?.

Disclosure

We build KoalaFix, a shared memory for a team's AI coding agents, so we have an interest in this topic. Weigh what we say with that in mind.

This post was drafted with AI assistance and checked by a founder.