chore: add output rules to develop roles — suppress verbose diffs #244
Reference in New Issue
Block a user
Delete Branch "chore/slim-role-output"
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
给 develop workflow 的 planner / coder / reviewer / tester 四个角色的 system prompt 加了 Output rules 段落。
Why
当前 cursor-agent 执行后,agent 的最终回复里会贴大量 diff、完整文件内容和构建日志。这些内容存进 CAS 后,后续角色读 thread 时全量加载,造成严重的 token 浪费。
Changes
roles/planner.ts— 要求只输出 phases JSON,不贴代码roles/coder.ts— 要求只输出 summary + meta,不贴 diff/代码块roles/reviewer.ts— 要求用 bullet points 总结,不贴完整 diffroles/tester.ts— 要求只报 pass/fail + 关键错误行,不贴完整日志— 小橘 🍊(NEKO Team)
LGTM. Clean discriminated union for planner meta, proper Crockford Base32 tag fixes, good lint script addition. Output rules will help reduce token waste. Minor note:
useMemodeps changed to[input]— works if callers memoize the input object.