Skip to main content

Module prompt

Module prompt 

Source
Expand description

One place for the wording every ambient Haiku call shares, so the plain-text rules, the “this is data, not a conversation” framing and the reply format aren’t copy-pasted (and drifting) across each call site.

Every one-line prompt ends with the reply format (reply::FORMAT_RULES): the model answers ANSWER: <text> or SKIP, and nothing else is used. docs/reports/REPORT_AMBIENT_FRAMEWORK_REASSESSMENT_2026_10_08.md section 6.1.

Constants§

AMBIENT_SYSTEM_PROMPT
Sent as the CLI’s system prompt for every ambient call. Replaces Claude Code’s default assistant prompt: left alone, the model answers in the assistant’s voice (“I don’t have access to…”) instead of producing the requested text.
PLAIN_TEXT_RULES
Formatting rules shared by every call whose output is a bare line of text.

Functions§

build_definition_summary_prompt
The one-shot preview for a definition with no structured snapshot.
build_dispatch_name_prompt
A Workflow dispatch’s display name, from its first member’s task prompt.
build_next_prompt_prompt
The prompt for session:next_prompt_suggestion. A pure function so its shape is unit-testable. Asked to “output nothing”, the model wrote sentences about doing so, and one reached the composer; SKIP is the only way to decline.
build_session_title_prompt
Build the session-goal-title prompt, for the pane’s own request (session:activity_summary) and for the recovery sweep (tasks::generate_recovered_title).
build_subagent_name_prompt
A subagent’s display name, from its own task prompt.
clip_material
text cut to its first head and last tail characters, with a marker where the middle was, when it is longer than both together.
continued_note_prompt
The note a pane shows when a fresh session continues the conversation from AgentMux’s record (backend::continued_note). record is that record: the running summary, then the latest exchange. The user has typed nothing yet, so the note says where things stand and asks what’s next.
narration_prompt
Build the prompt for one narration kind.
with_material
instruction, then material under label inside a tagged block, so the model reads the material as source data rather than as a message to answer.