docs: design ordinary agent loop - #532
Draft
kachofugetsu09 wants to merge 1 commit into
Draft
Conversation
kachofugetsu09
marked this pull request as ready for review
September 3, 2026 03:15
kachofugetsu09
marked this pull request as draft
September 3, 2026 03:15
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
结论
把默认被动回复的
AgentLoop从 bootstrap/Core 固定链路迁成普通 pure-v3 插件。Core 只保留 Turn admission、exact snapshot、Session/delivery finality、terminal 和 plugin publication。唯一新增选择点是
REACT = ServiceKey[TurnExecutor]:ConversationRuntime先绑定 exact snapshot,再从该 Root 选择REACT。REACT返回现有ControlExecutionResult;terminalTurnResult仍只由 Core 生成。REACT是按 ServiceKey 检查的 required service;Core 不认识默认插件 ID。插件自更新同时收紧为维护者确认的规则:install candidate 默认晋升;parent 封口前调用
plugin-revert才丢弃。Core 不再用 child/parent terminal status 替 Agent 判断业务结果。现状与目标
规格记录了当前真实链:
ConversationRuntime → bootstrap closure → execute_control_turn → AgentLoop → PassiveTurnPipeline目标是:
ConversationRuntime → exact snapshot → REACT → ordinary agent-loop pluginTool search 的名字/文本解析、host 提示、人格与 Skill catalog 等特殊规则先迁到普通 Tool 或公开 typed event,再切换整个 loop。最终不保留旧链、deprecated alias、wrapper、shadow 或 gray 路径。
详细规格:
docs/design/ordinary-agent-loop.mdStacked PR
child_checked和 terminal status Gate。REACT,同 PR 删除 bootstrap 全局 loop 和旧被动链。每批只运行一条生产路径;能力等价由 base/candidate 隔离差分证明,不运行 runtime shadow。
研究与评审
dd6322d604e00eec1ba5e0c8541159906a21094a:agent-loop 是普通 Service 插件,Cordis 不认识 loop phase。Turn Plan、React Kit、Turn Capsule和 legacy wrapper 等重复模型。外部消费者
只读审查确认 hua-home 16 个启用 external 插件中,9 个可达插件仍有 18 个私有 Core import;本机 16/16 checkout HEAD 与 production artifact commit 不同。后续迁移必须从生产 artifact identity 开始,并升级已有、被 21 个 CI 使用的 plugin-contract checker,不创建第二个 checker。
本 PR 不修改外部插件、cache、正式 workspace 或 hua-home。
验证
git diff --check:通过docker/debug/reports/change-gate/20260902-171758-94967913状态
这是设计 PR:0055 为 proposed;0056 的 no-revert 语义已接受但尚未实现。运行时代码仍是 PR #527 baseline,不能把目标文档当作已部署证据。