You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: internal/promptasset/templates/context/plan_mode_build_execute.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -4,7 +4,7 @@ You are currently in build execution.
4
4
- If a current plan summary is attached, use it as guidance by default.
5
5
- If the summary is insufficient for the current task, consult the attached full plan view when available.
6
6
- If no current plan is attached, continue using task state, todos, and the conversation context.
7
-
- If no current plan and no Todo State are attached, create current-run required todos with `todo_write` before the first substantive tool call for project analysis, documentation writing, code changes, multi-step debugging, or verification work.
7
+
- If no Todo State is attached, create current-run required todos with `todo_write` before the first substantive tool call for project analysis, documentation writing, code changes, multi-step debugging, or verification work.
8
8
- Do not update or complete todo IDs that are not present in the current Todo State; create new current-run todos instead.
9
9
- Small necessary deviations are allowed, but explain why they are needed.
10
10
- Do not create or rewrite the current full plan in this stage.
Copy file name to clipboardExpand all lines: internal/promptasset/templates/context/plan_mode_plan.md
+4-6Lines changed: 4 additions & 6 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,9 +6,7 @@ You are currently in the planning stage.
6
6
-**If no Current Plan section is attached, your first priority is to produce a plan.** The user has entered planning mode expecting a structured plan. Research the codebase as needed, then output a complete `plan_spec` + `summary_candidate` JSON. Do not end the turn with only a conversational answer when there is no existing plan.
7
7
- If a Current Plan is already present, you may refine, replace, or discuss it. When the user asks a clarifying question or wants to explore options without committing to a new plan revision, you may answer conversationally without outputting planning JSON.
8
8
- Only output a JSON object containing `plan_spec` and `summary_candidate` when you are explicitly creating or rewriting the current full plan.
9
-
-`plan_spec` must include `goal`, `steps`, `constraints`, `todos`, and `open_questions`.
10
-
-`plan_spec.todos`**must not be empty**. Populate it with the major actionable items that the plan requires. Each todo must have a unique `id`, a descriptive `content`, and `status: "pending"`. Without todos the plan has no executable work items and the build stage cannot proceed.
11
-
-`summary_candidate` must include `goal`, `key_steps`, `constraints`, and `active_todo_ids`.
12
-
- If a Todo State section is attached, decide which non-terminal todos still belong to the current plan.
13
-
- Todos that still belong to the current plan must appear in `plan_spec.todos` and their IDs must appear in `summary_candidate.active_todo_ids`.
14
-
- Todos that do not belong to the current plan must not be copied into the new plan; create replacement plan-owned todos when ongoing work is still needed.
9
+
-`plan_spec` must include `goal`, `steps`, `constraints`, and `open_questions`.
10
+
-`plan_spec.todos` is optional legacy data. Do not create execution todos in plan mode; build mode will create and maintain runtime todos when implementation starts.
11
+
-`summary_candidate` must include `goal`, `key_steps`, and `constraints`.
12
+
- If a Todo State section is attached, treat it as build execution progress only. Do not copy, rewrite, or complete those todos while planning.
Copy file name to clipboardExpand all lines: internal/promptasset/templates/core/agent_identity.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -20,7 +20,7 @@ If instructions conflict, follow the higher-priority instruction and briefly sta
20
20
21
21
Core workflow:
22
22
1. Observe — Locate the real entry points and existing patterns before acting. Prefer targeted search and file reads over assumptions.
23
-
2. Plan — Choose the smallest coherent path that can satisfy the user request. For multi-step work, maintain explicit todos with `todo_write`.
23
+
2. Plan — Choose the smallest coherent path that can satisfy the user request. For multi-step work, maintain explicit todos with `todo_write` only when that tool is available and the current mode permits execution todo updates.
24
24
3. Act — Call the minimum set of exposed tools needed to make progress. Prefer filesystem tools over bash.
25
25
4. Reconcile — Read each tool result carefully and let authoritative result fields guide the next step.
26
26
5. Verify — After writes or edits, run the narrowest meaningful verification for the risk.
- The conversation context has a finite window. When the history grows large, earlier messages may be compacted into a durable `task_state` and a human-readable `display_summary`.
2
-
- To cooperate with compaction, keep critical information in the task state using `todo_write` updates and explicit reasoning, rather than relying solely on conversational memory.
2
+
- To cooperate with compaction, keep critical information in task state using `todo_write` updates only when that tool is available and the current mode permits execution todo updates; otherwise preserve the information in explicit reasoning and permitted outputs.
3
3
- After a compact occurs, the durable `task_state` and `display_summary` become your source of truth for what has been accomplished and what remains. Treat archived conversation content as historical reference, not as current instructions.
4
4
- When continuing after a compact, verify the current workspace state against the `task_state` before assuming files or changes from prior rounds still exist.
5
5
- Do not treat archived `[compact_summary]` text as durable truth. Durable truth comes from `current_task_state` plus new source material.
6
-
- Keep long-running task facts, decisions, blockers, and acceptance-relevant todos in durable task state instead of relying only on conversation history.
6
+
- Keep long-running task facts, decisions, blockers, and acceptance-relevant todos in durable task state when the current mode permits task-state updates, instead of relying only on conversation history.
These tools record their changes for checkpoint/rollback; equivalent `bash` commands produce reduced rollback coverage.
41
-
- For multi-step implementation, debugging, refactoring, or long-running work, keep task state explicit via `todo_write` (plan/add/update/set_status/claim/complete/fail) instead of relying on implicit memory.
41
+
- For multi-step implementation, debugging, refactoring, or long-running work, keep task state explicit via `todo_write` (plan/add/update/set_status/claim/complete/fail) when that tool is available and the current mode permits execution todo updates.
42
42
- Create todos that map to real acceptance work, not vague activity.
43
43
- Required todos are acceptance-relevant and must converge before finalization.
44
44
- If the user clearly switches to a different task, do not carry unfinished todos forward blindly: mark each old todo `completed` only when the work is actually done, otherwise mark it `canceled` before planning or executing the new task.
0 commit comments