fix(strategic-compact): the task list may not exist — stop promising it survives compaction

Claude Code 2.1.233 removed the todo/task tools by default on Opus 4.8, Sonnet 5,
Fable 5, Mythos 5 and newer models (TodoWrite, TaskCreate/Get/Update/List).
CLAUDE_CODE_ENABLE_TODO_TOOLS=1 restores them, but that is a per-machine
environment setting that does not travel with a skill, so this skill cannot assume
its reader has a task list at all.

Three claims are wrong for most readers on a current version:

- "What Survives Compaction" listed "TodoWrite task list" unconditionally
- "Plan is in TodoWrite or a file" as the reason to compact at Planning→Implementation
- "Once plan is finalized in TodoWrite, compact to start fresh"

This is load-bearing advice rather than a cosmetic detail: "my todo list survives
compaction" is a reason to compact INSTEAD of writing state down. If the tools are
absent there is no list to survive, so the reader follows the advice, compacts, and
the plan is simply gone.

Changes:
- Promote "Files on disk" into the survives table — the claim that holds on every
  version and model.
- Make the task-list row conditional and add a short caveat naming the version, the
  env var, and the fact that it does not travel with the skill.
- Point readers at a file as the durable record before compacting.
- Reword the Decision Guide and Best Practices lines so neither depends on the tool
  existing.

Applied identically to the Codex (.agents/) and Kiro (.kiro/) mirrors so the three
copies agree. Those mirrors have pre-existing drift from the main skill; this change
deliberately does not touch anything beyond the same three claims.

Verified locally: all eight scripts/ci/ validators pass (unicode-safety, skills,
agents, commands, rules, hooks, install-manifests, no-personal-paths), plus
catalog:check, command-registry:check, and harness-adapter-compliance (12 adapters).
No emoji in the added block, per check-unicode-safety.
This commit is contained in:
Nitay Kufert
2026-08-24 22:26:22 -03:00
committed by Alex Schmitt
parent 40c8235d48
commit dac72d1997
3 changed files with 54 additions and 12 deletions
+18 -4
View File
@@ -73,7 +73,7 @@ Use this table to decide when to compact:
| Phase Transition | Compact? | Why |
|-----------------|----------|-----|
| Research → Planning | Yes | Research context is bulky; plan is the distilled output |
| Planning → Implementation | Yes | Plan is in TodoWrite or a file; free up context for code |
| Planning → Implementation | Yes | Plan is written down (a file, or the task list if you have one); free up context for code |
| Implementation → Testing | Maybe | Keep if tests reference recent code; compact if switching focus |
| Debugging → Next feature | Yes | Debug traces pollute context for unrelated work |
| Mid-implementation | No | Losing variable names, file paths, and partial state is costly |
@@ -86,14 +86,28 @@ Understanding what persists helps you compact with confidence:
| Persists | Lost |
|----------|------|
| CLAUDE.md instructions | Intermediate reasoning and analysis |
| TodoWrite task list | File contents you previously read |
| Files on disk | File contents you previously read |
| Memory files (`~/.claude/memory/`) | Multi-step conversation context |
| Git state (commits, branches) | Tool call history and counts |
| Files on disk | Nuanced user preferences stated verbally |
| The task list — **only if you have the todo tools** (see below) | Nuanced user preferences stated verbally |
> ### Don't rely on the task list surviving — it may not exist
>
> Claude Code **2.1.233 removed the todo/task tools by default** on Opus 4.8, Sonnet 5,
> Fable 5, Mythos 5 and newer models (`TodoWrite`, `TaskCreate/Get/Update/List`).
> `CLAUDE_CODE_ENABLE_TODO_TOOLS=1` brings them back, but that is a per-machine
> environment setting — **it does not travel with this skill**, so you cannot assume the
> reader has it.
>
> This matters because "my todo list survives compaction" is a reason people compact
> *instead of* writing state down. If the tools are absent there is no list to survive,
> and the plan is simply gone. **Write the plan to a file before compacting** — a file
> persists on every version and every model. Treat the task list as a convenience that
> may be missing, never as your durable record.
## Best Practices
1. **Compact after planning** — Once plan is finalized in TodoWrite, compact to start fresh
1. **Compact after planning** — Once the plan is finalized **and written to a file**, compact to start fresh
2. **Compact after debugging** — Clear error-resolution context before continuing
3. **Don't compact mid-implementation** — Preserve context for related changes
4. **Read the suggestion** — The hook tells you *when*, you decide *if*
+18 -4
View File
@@ -71,7 +71,7 @@ Use this table to decide when to compact:
| Phase Transition | Compact? | Why |
|-----------------|----------|-----|
| Research → Planning | Yes | Research context is bulky; plan is the distilled output |
| Planning → Implementation | Yes | Plan is in TodoWrite or a file; free up context for code |
| Planning → Implementation | Yes | Plan is written down (a file, or the task list if you have one); free up context for code |
| Implementation → Testing | Maybe | Keep if tests reference recent code; compact if switching focus |
| Debugging → Next feature | Yes | Debug traces pollute context for unrelated work |
| Mid-implementation | No | Losing variable names, file paths, and partial state is costly |
@@ -84,14 +84,28 @@ Understanding what persists helps you compact with confidence:
| Persists | Lost |
|----------|------|
| CLAUDE.md instructions | Intermediate reasoning and analysis |
| TodoWrite task list | File contents you previously read |
| Files on disk | File contents you previously read |
| Memory files (`~/.claude/memory/`) | Multi-step conversation context |
| Git state (commits, branches) | Tool call history and counts |
| Files on disk | Nuanced user preferences stated verbally |
| The task list — **only if you have the todo tools** (see below) | Nuanced user preferences stated verbally |
> ### Don't rely on the task list surviving — it may not exist
>
> Claude Code **2.1.233 removed the todo/task tools by default** on Opus 4.8, Sonnet 5,
> Fable 5, Mythos 5 and newer models (`TodoWrite`, `TaskCreate/Get/Update/List`).
> `CLAUDE_CODE_ENABLE_TODO_TOOLS=1` brings them back, but that is a per-machine
> environment setting — **it does not travel with this skill**, so you cannot assume the
> reader has it.
>
> This matters because "my todo list survives compaction" is a reason people compact
> *instead of* writing state down. If the tools are absent there is no list to survive,
> and the plan is simply gone. **Write the plan to a file before compacting** — a file
> persists on every version and every model. Treat the task list as a convenience that
> may be missing, never as your durable record.
## Best Practices
1. **Compact after planning** — Once plan is finalized in TodoWrite, compact to start fresh
1. **Compact after planning** — Once the plan is finalized **and written to a file**, compact to start fresh
2. **Compact after debugging** — Clear error-resolution context before continuing
3. **Don't compact mid-implementation** — Preserve context for related changes
4. **Read the suggestion** — The hook tells you *when*, you decide *if*
+18 -4
View File
@@ -80,7 +80,7 @@ Use this table to decide when to compact:
| Phase Transition | Compact? | Why |
|-----------------|----------|-----|
| Research → Planning | Yes | Research context is bulky; plan is the distilled output |
| Planning → Implementation | Yes | Plan is in TodoWrite or a file; free up context for code |
| Planning → Implementation | Yes | Plan is written down (a file, or the task list if you have one); free up context for code |
| Implementation → Testing | Maybe | Keep if tests reference recent code; compact if switching focus |
| Debugging → Next feature | Yes | Debug traces pollute context for unrelated work |
| Mid-implementation | No | Losing variable names, file paths, and partial state is costly |
@@ -93,14 +93,28 @@ Understanding what persists helps you compact with confidence:
| Persists | Lost |
|----------|------|
| CLAUDE.md instructions | Intermediate reasoning and analysis |
| TodoWrite task list | File contents you previously read |
| Files on disk | File contents you previously read |
| Memory files (`~/.claude/memory/`) | Multi-step conversation context |
| Git state (commits, branches) | Tool call history and counts |
| Files on disk | Nuanced user preferences stated verbally |
| The task list — **only if you have the todo tools** (see below) | Nuanced user preferences stated verbally |
> ### Don't rely on the task list surviving — it may not exist
>
> Claude Code **2.1.233 removed the todo/task tools by default** on Opus 4.8, Sonnet 5,
> Fable 5, Mythos 5 and newer models (`TodoWrite`, `TaskCreate/Get/Update/List`).
> `CLAUDE_CODE_ENABLE_TODO_TOOLS=1` brings them back, but that is a per-machine
> environment setting — **it does not travel with this skill**, so you cannot assume the
> reader has it.
>
> This matters because "my todo list survives compaction" is a reason people compact
> *instead of* writing state down. If the tools are absent there is no list to survive,
> and the plan is simply gone. **Write the plan to a file before compacting** — a file
> persists on every version and every model. Treat the task list as a convenience that
> may be missing, never as your durable record.
## Best Practices
1. **Compact after planning** — Once plan is finalized in TodoWrite, compact to start fresh
1. **Compact after planning** — Once the plan is finalized **and written to a file**, compact to start fresh
2. **Compact after debugging** — Clear error-resolution context before continuing
3. **Don't compact mid-implementation** — Preserve context for related changes
4. **Read the suggestion** — The hook tells you *when*, you decide *if*