Everything the agent reads — the system prompt assembled at conversation start, and the per-message decoration on every turn.
Context arrives in two rhythms. The system prompt is assembled when the conversation spawns — ten layers stacked top-to-bottom, followed by the first user turn. The per-message decoration wraps each inbound turn after that — attachments, scheduler fires, peer pushes, and other framework stimulus.
System prompt layers
Assembled top-to-bottom when the conversation spawns. Conditional layers whose source is absent are skipped silently. Layers 1 and 10 are expanded inline to show what they contain.
<cast-protocol>
from server-generated
Server-side runtime contract — what is mounted, what is reachable, what extensions have contributed. Composed by the prompt assembler from operator config and active extensions.
| Path | Purpose | Access |
|---|
| /home/agent | Working directory (CWD) | read-write |
| /identity | Identity files (whoami, skills) | read-only |
| /memory | Persistent memory across runs | read-write |
| /assets | Static reference data | read-only |
| /shared | Service-written agent context | read-only |
| /attachments | Received and sent files | read-only |
| /staging/in | Inbound files dropped by extensions and services for the agent to Read | read-write |
| /staging/out | Write files here to send them back | read-write |
Operator-configured resource mounts (/resources/<name>) append rows when present.
Network mode
set in config/agent.json
- none
- no network access; all operations local
- sdk-only
- only Anthropic API endpoints reachable; agent is told to use WebSearch rather than curl/wget
- full
- unrestricted egress (operator-set)
Tells the agent to use the pip__install tool — there is no system pip in the container. Packages install to /home/agent/.python-packages/ and persist across conversations; PYTHONPATH is preconfigured.
Each active extension appends its own block — see
Extensions for what each one carries.
↓
<agent-profile>
from profile.prompt
Filesystem conventions and behavior baseline from the chosen profile.
↓
<agent-profile-skills>
from profile.skills
Profile-level skills — e.g. the standard profile's framework-tag handling.
↓
blueprint/identity/prompt.md· no wrapping tag
Persona and core behavior — the agent's “who I am” text.
↓
<agent-identity>
from blueprint/identity/whoami.md
Structured identity facts (name, role, owner).
↓
<agent-peers>
from server-derived from ACL
Granted first-degree peer reach, computed from acl.json, alongside the live agent__list_peers discovery tool.
↓
<agent-skills>
from blueprint/identity/skills.md
Domain-specific guidance the agent should carry across all conversations.
↓
<channel-contract>
from server-derived from ACL
inserted only when the channel enforces a fixed reply protocol
Required shape of the agent's reply on this channel — what its output must look like to be accepted.
↓
<channel-instructions>
from blueprint/channels/NAME/prompt.md
Per-channel instructions — tone, scope, escalation rules.
↓
<service-context>
from shared/ext/service/agent-context.md
Dynamic context injected by the agent's service process — custom code attached to this agent, free to write whatever the agent should know right now.
↓
<conversation-context>
from server-generated, per spawn
The agent's situational awareness for this turn. Reassembled when the conversation re-spawns (idle timeout, channel handoff); stable within a single conversation.
<participant id="ID" declared-name="NAME" />
Who's talking to the agent.
- id[string]Bare identity address. Use for record-keeping and memory cross-referencing. The transport handle never reaches the agent.
- optional declared-name[string]User-chosen display name. Use in greetings; don't use as a stable key.
<channel name="NAME" />
Which channel this conversation is on. Sharded channels render with a qualifier appended via ~.
- name[string]Channel name as defined in blueprint/channels/. Sharded subdivisions append a qualifier with ~.
<agent name="NAME" />
Which agent this is — useful when one Claude session might serve more than one identity.
- name[string]Agent's display name from the host registry.
<time timezone="TIMEZONE">WEEKDAY ISO_TIMESTAMP</time>
Wall-clock time when the prompt was assembled, in the agent's timezone. The agent's clock does not advance during a conversation — use time__now to refresh.
- timezone[IANA timezone]Agent's configured timezone. Body is the current ISO timestamp with offset, prefixed by weekday.
<previous-session last-active="DURATION">SUMMARY</previous-session>
<previous-session last-active="DURATION" summary="unavailable" />
<previous-session first-time="true" />
- optional last-active[string]Rough Nh ago / Nd ago — when the previous session was last active.
- optional summary[string]Set to unavailable if the session has no recorded summary.
- optional first-time[boolean]Present (as first-time="true") when this is the participant's first conversation with the agent.
<other-participants>NAME (DURATION ago), …</other-participants>
<other-participants visibility="disabled" />
Ambient awareness of who else is active on this channel. When the channel has show_co_participants=false, the element renders with visibility="disabled" so the agent reads “I can't see who else is here, by policy” rather than “I'm alone.” The same flag also seals reach: with it disabled, co-participants are unreachable by cross-conversation push, not merely hidden.
- optional visibility[string]Set to disabled when the channel's show_co_participants is false. Otherwise omitted.
↓
CONVERSATION BEGINS
Per-message decoration
What gets added to a turn beyond its raw text. Regular user messages pass through verbatim — sender and timestamp metadata for the current conversation lives in the <conversation-context> envelope above, not per-turn. The decorations below only apply to turns that carry attachments, ingested archives, or non-user triggers.
[Attachment: LABEL | PATH | MIME_TYPE | SIZE_BYTES]
Inline marker prepended to inbound messages that carry files. The agent uses the path with the Read tool to view images/PDFs. All attachments are persisted to /attachments automatically.
<message sender="NAME" time="ISO_TIMESTAMP">BODY</message>
Messages bulk-imported from an outside source (email backlog, chat export, etc.) are wrapped so the agent can tell apart who sent each one and when. Live user turns never get this wrapper.
<cast:schedule>BODY</cast:schedule>
<cast:service>BODY</cast:service>
<cast:lifecycle>BODY</cast:lifecycle>
<cast:watch path="GLOB" since="ISO_TIMESTAMP" through="ISO_TIMESTAMP">FILE_LIST</cast:watch>
<cast:push fromAgent="NAME" fromParticipant="ID" fromChannel="NAME">BODY</cast:push>
<cast:rejection request="ID">REASON</cast:rejection>
<cast:pending request="ID">REASON</cast:pending>
Non-user triggers arrive wrapped in one of these. Full attribute schemas and validation rules on
Runtime › Wire format.