fix(cli): include __start__ message in nerve thread show #232
Reference in New Issue
Block a user
Delete Branch "fix/231-thread-show-start-message"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
What
When
nerve thread showis called without--before, the initial user prompt (__start__message) is now displayed first, followed by the most recent role rounds within the budget.Why
Workflow roles (planner, coder, etc.) that read the thread via
nerve thread showcould not see the original user prompt — they only saw outputs from previous roles. This caused planner to miss critical user requirements.Changes
packages/store/src/log-store.ts— addgetThreadStartMessage(runId)methodpackages/cli/src/commands/workflow.ts— modifybuildThreadCommandOutputto accept optionalstartRowpackages/cli/src/commands/thread.ts— pass start message whenbefore===0Fixes #231
LGTM ✅
Store 层
getThreadStartMessage()实现干净:role='__start__'round: 0,不影响getThreadRoundCount/getThreadRounds的编号before===0(第一页)时注入,后续分页不重复测试覆盖全面(存在/不存在 start message、budget 消耗、排序验证)。daemon mock 同步更新。
附带注意到
index.ts新增了cursorAgent和llmExtract的 re-export — 这是扩大了 public API,应该是后续 workflow 需要直接用,没问题。