WHAT NEW IN X10.29 THU

X 上的 AI 合集档案 · 22 个合集 · 58,925 条

claudeVIDEO

Claude Code 三模型分工:worktree 隔离跑测试,只回传三行失败契约

Sonnet 5.5 改代码、Haiku 5.5 在临时 git worktree 里跑测试并只回传三行失败摘要、Opus 5.5 把关边界;作者称 Jev 在更底层用毫秒级分叉替大模型挡掉无需思考的判断。

damkin
@damkina71 天前收录原推发布于 2026.10.26
damkin @damkina7原推发布于 2026.10.26
在 X 上打开原推

THIS IS AN ABSOLUTE F*CKING GOLDMINE Anthropic just shared one of the cleanest tricks for Claude Code The brutal reality: letting AI run test suites in your main session burns 40,000 tokens on raw compiler output, floods your terminal with useless stack traces, and drowns the model in context rot Zero context pollution: run test runners in an ephemeral git worktree, let Haiku 5.5 swallow 4,000 lines of stdout at 340 tok/s, and emit only a 3-line failure contract back to your clean workspace You just launch Claude Code like this: CLAUDE_CODE_SUBAGENT_MODEL=haiku claude --model sonnet --settings '{"isolation":"worktree"}' here's how the workload splits: → Sonnet 5.5 executes code fixes: patches source files, updates types, and synchronizes AST imports in your clean main workspace → Haiku 5.5 runs isolated test suites: executes vitest inside a detached git worktree at 340 tok/s, swallowing 4,000 lines of stdout and returning only a 3-line failure contract → Opus 5.5 architects boundary rules: evaluates whether the failure is an edge regression and signs off on the unified diff before merging → you stop burning Opus context on compiler logs and keep your main session locked under 6k tokens Opus only steps in at three moments: → before the detached worktree sandbox is provisioned → when the isolated test harness turns Green with zero collateral drift → before committing changes to main branch Sonnet builds · Haiku isolates · Opus signs off JEV engineering is the same move one layer down: the forks that need no thinker (which file, which tool, retry or stop) go to JEV in milliseconds, and the big models only see the ones that split the full tree > Sonnet 5.5 runs the main session and coordinates code implementation > detached worktree provisions in .claude/worktrees/ at 0 context cost > Haiku 5.5 runs headless test runners (swallows 4,000 lines of stdout at 340 tok/s) > isolated runner emits a 3-line JSON abstract (assert failure, line number, exit code 1) > Sonnet 5.5 applies surgical code fix to turn test Green > Opus 5.5 on call as architect, reviews synthesized diff before sign-off > JEV routes micro-forks in milliseconds paste the tree and this prompt into Claude Code ↓ "Reconfigure my Claude Code setup around this tree: 1. Run the main session on Sonnet 5.5 with Opus 5.5 as architect and supervisor 2. Set isolation: worktree on test execution so all test suites run inside detached worktrees without polluting main branch 3. Delegate all test runner execution and stack trace triage to Haiku 5.5 subagents at 340 tok/s 4. Restrict all test runner telemetry returned to main session to a concise 3-line JSON contract: failed assertion, exact AST file/line, and exit status 5. Keep main session context under 6k tokens. Reserve Opus 5.5 for final diff verification and pre-commit sign-off Show me every change as a diff first. No edits until I say go" ↳ http://code.claude.com/docs/en/worktrees bookmark this, your context window will never drown in test logs again ↓

这条是引用着另一条写的:x.com/damkina7/status/2107924159397560795

x.com/damkina7/status/2114703673435554270采集于 2026.10.27 09:59