The Phase 0 vibes-based heuristic warned users and forced a mode choice even with 80%+ context remaining. Full mode now runs by default; compact-safe mode stays available on explicit request. Co-authored-by: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -21,41 +21,11 @@ Captures problem solutions while context is fresh, creating structured documenta
|
||||
/ce:compound [brief context] # Provide additional context hint
|
||||
```
|
||||
|
||||
## Execution Strategy: Context-Aware Orchestration
|
||||
## Execution Strategy
|
||||
|
||||
### Phase 0: Context Budget Check
|
||||
**Always run full mode by default.** Proceed directly to Phase 1 unless the user explicitly requests compact-safe mode (e.g., `/ce:compound --compact` or "use compact mode").
|
||||
|
||||
<critical_requirement>
|
||||
**Run this check BEFORE launching any subagents.**
|
||||
|
||||
The /compound command is token-heavy - it launches 5 parallel subagents that collectively consume ~10k tokens of context. Running near context limits risks compaction mid-compound, which degrades output quality significantly.
|
||||
</critical_requirement>
|
||||
|
||||
Before proceeding, the orchestrator MUST:
|
||||
|
||||
1. **Assess context usage**: Check how long the current conversation has been running. If there has been significant back-and-forth (many tool calls, large file reads, extensive debugging), context is likely constrained.
|
||||
|
||||
2. **Warn the user**:
|
||||
```
|
||||
⚠️ Context Budget Check
|
||||
|
||||
/compound launches 5 parallel subagents (~10k tokens). Long conversations
|
||||
risk compaction mid-compound, which degrades documentation quality.
|
||||
|
||||
Tip: For best results, run /compound early in a session - right after
|
||||
verifying a fix, before continuing other work.
|
||||
```
|
||||
|
||||
3. **Offer the user a choice**:
|
||||
```
|
||||
How would you like to proceed?
|
||||
|
||||
1. Full compound (5 parallel subagents, ~10k tokens) - best quality
|
||||
2. Compact-safe mode (single pass, ~2k tokens) - safe near context limits
|
||||
```
|
||||
|
||||
4. **If the user picks option 1** (or confirms full mode): proceed to Phase 1 below.
|
||||
5. **If the user picks option 2** (or requests compact-safe): skip to the **Compact-Safe Mode** section below.
|
||||
Compact-safe mode exists as a lightweight alternative — see the **Compact-Safe Mode** section below. It's there if the user wants it, not something to push.
|
||||
|
||||
---
|
||||
|
||||
|
||||
Reference in New Issue
Block a user