Skip to content
This repository was archived by the owner on Oct 17, 2026. It is now read-only.

feat(orchestration): 主动委派边界清晰的只读问题 - #37

Merged
TimWongUp merged 1 commit into
mainfrom
feat/proactive-read-only-delegation
Sep 25, 2026
Merged

TimWongUp merged 1 commit into
mainfrom
feat/proactive-read-only-delegation

Conversation

@TimWongUp

Copy link
Copy Markdown
Owner

背景

Codex 宿主会在会话中注入开发者指令:除非用户或适用的 AGENTS.md/Skill 指令明确要求委派,否则不派子代理。原有全局块只规定"派发前加载 codex-orchestration",没有说明什么时候应该委派;Skill 里又写成 "Delegate only when…",读起来是限制。所以普通模式下几乎只在用户开口时才委派,本地日志里 explorer 用得很少,可写 worker 从未使用。

变更

  • examples/global-agents-block.md:遇到边界清晰、只需要结论和证据的只读问题时,也要加载 Skill,具体包括大范围代码搜索或调用链梳理、版本相关的外部事实、公开实践证据。全局块仍然只是一句指针。
  • SKILL.md:
    • description 补上这些正向场景;
    • "Delegate only when" 改为 "Delegate when";
    • Route the work 一节明确要求把上述问题委派给 explorer / reference-researcher / web-researcher,互不依赖的问题并行派发;
    • 列出留给主代理的情形:随后要亲自修改的代码、下一步取决于上一步发现的逐步排查、单文件或已知位置、一两次搜索就能回答的问题。
  • docs/configuration.md:记录这样措辞的原因,避免后续简化时删掉。
  • scripts/validate.py:检查 SKILL.md 中是否保留明确要求委派的短语。
  • 同步 docs/hooks-and-prompts.md 与中英文 README。

写代码的规则不变:单写者租约和 worker 准入条件都没有调整。

验证

  • python3 scripts/validate.py 通过
  • python3 -m unittest discover -s tests:71 个测试通过,跳过 2 个
  • ruff check .、ruff format --check .、pyright 全部通过

🤖 Generated with Claude Code

Codex 宿主会注入"除非用户或 AGENTS.md/Skill 明确要求,否则不派子代理"的指令,
原有全局块只规定派发前加载 Skill,Skill 措辞也偏限制,导致普通模式几乎不主动委派。

- 全局块在边界清晰的只读问题(大范围代码搜索与调用链、版本相关外部事实、公开实践证据)时加载 Skill
- SKILL.md 明确要求对上述问题委派只读子代理,独立问题并行派发,并列出留给主代理的情形
- 在 configuration 文档记录措辞原因,validate.py 保护该明确要求短语
- 同步 hooks-and-prompts 文档与中英文 README

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@TimWongUp
TimWongUp merged commit 0749098 into main Sep 25, 2026
7 checks passed
@TimWongUp
TimWongUp deleted the feat/proactive-read-only-delegation branch September 25, 2026 04:40
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant