Repository navigation
fix(collaboration): retain partial results until the remaining work returns - #7926
Conversation
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
…requests Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
…illment-20261103 Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
…legation-fulfillment-20261103 Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
loopx-agent
left a comment
There was a problem hiding this comment.
Approval conclusion (author-owned PR; GitHub blocks formal self-approval)
未发现本 PR 的阻塞性回归。对当前精确 head a2c4388e328b0db19a9a149ff1d80c56eac8b287 给出 APPROVE;两个本地基线失败已独立归因,仍保留为失败及 merge/CQR hold,不因本次批准自动解除。
动机
将工作交给其他 Agent,并在原对话等待实际结果的用户、管家与接收方。
接收方已完成代码修改但仍待隔离安装核验时,旧路径只要回传 conclusion 就会清掉回复义务;用户看到了阶段成果,却无法从同一委派继续追踪剩余工作。
本次允许接收方明确回传剩余事项与继续条件;阶段结果仍送回原对话,送达和消费后仍保持待跟进,后续稳定结论才结束当前请求的回复义务。独立原生入口与实际界面验证了这个变化。
本 PR 不把通信结论当成成果验收,不自动创建 Todo、唤醒或授权安装;完整 M2/M3、真实模型采用、安装版与 Lark 的端到端资格及长程净收益仍未证明。
完整多会话管理采用、安装环境核验和独立成果验收仍属既有 Manager 里程碑;本次只完成显式部分回传及其原对话读回,不把所有历史结论重新解释为部分成果。
改动思路
剩余工作是接收方不可从送达、消费或 Todo done 推导的意图,适合放入既有不可变结果;TypeScript 统一校验和投影,Python 保留 IO,原有回传链继续负责送达。
当前 PR 交付一个完整可回退边界:接收方经 CLI/MCP 回传部分结果,既有回传队列送至原对话,Inbox、Turn 和 App 保留剩余责任,后续稳定修订清除该责任。
当前 head 的解释表如下,不冒称图形渲染或执行证据。
| 情况 | 旧行为 | 当前行为 |
|---|---|---|
| 无部分结果标记 | 结论结束回复义务 | 保留旧行为 |
| 显式 partial 已送达/消费 | 同样结束 | 保留原请求/接收方、剩余工作与继续条件 |
| 当前请求后续稳定结论 | 普通追加修订 | 经原有回传处理结束通信义务 |
| 链损坏、旧修订或来源未知 | 原 owner 恢复 | 保持 unavailable/修订隔离,不推断完成 |
具体改动
完整审读22文件(+499/-40):初次20文件加当前全部增量,17个最终路径的 blobs 未变。result_publication.ts:21/144 共用 metadata 校验和不可变重试,字段限制600 Unicode码点、渲染总量20k;inbox_receipts.ts:147 依当前请求修订最新结果派生通信责任,移除 Todo done 推断。inbox_read.ts:331 现在仅在一次请求内准备完整 immutable observations,逐结果仍经同一 validator;delivery/consumption 每次仍读回,没有持久 cache、第二种权威状态或自动执行器。原对话、CLI/MCP、Turn 与 App 沿现有返回链携带剩余工作。
依据 docs/architecture/rfcs/capable-manager-semantic-handoff-v0.md,不可变修订 4250a94a0aab432a30831e97679c23d9391cd38f 的 A27 显式部分结果和 5.15 请求谱系/原受众边界;M2 的完整多会话、安装采用和独立 fulfillment 仍属既有里程碑。本次没有拿新字段、送达收据或 Todo done 充当父目标验收。
独立检查:Exact-head whole5 native modules (remaining work, roundtrip, tracking, stdio MCP, actual guard/host transport):129 passed in58.98s; File/SQLite, native files/host envelope and actual source CLI. External model/sender synthetic. Exact-head whole result-publication, receipts, turn-context, request-control and real-file inbox-read modules:49 passed,0 skips. Control-plane typecheck passed; new legacy/exact full-chain partial/corruption/final-delivery cases executed. Matched actual immutable source owners at base e030 and current head: unmarked result/receipt deep-equal; explicit partial ignored/settled on base, retained/awaiting_conclusion on head. Existing chain-corruption recovery and native original returns independently covered. typecheck、diff advisory、DCO、公开边界和双语检查通过。新增 actual guard/host-envelope 用例覆盖 File/SQLite、冷暖两次与 unanswered/partial,done 的关联 Todo 不会清掉原请求。原始116/47和源码构建的历史检查保留,当前功能以129/49为准。
当前 standard premerge6个 direct通过,19个 selected 中17通过,maintainability返回 exit1被 runner 记为 inherited advisory,issue-fix lifecycle也返回 exit1;总体 gate 仍失败。评审没有依赖 advisory heuristic:在不可变 e030d3702ff812866fdc86aa50e4c223d8f98094 和本 head 分别执行完整 maintainability JSON,除 repository_root 外全量报告相同,未改函数 render_canonical_todo_sections 为94statements/61decision_points,限90/60。相同 isolation runner 执行完整 issue-fix lifecycle,两端均在571行读 gate_item['evidence'] 抛同一 KeyError;完整归一化 traceback 相同,相关 source 不在本 PR diff。此前裸跑基线先遇到隐式 runtime 路由冲突,作为环境失败保留,未充当这次同条件对照。两个 required red 分别归为 pre_existing_unrelated,未删除断言、提高阈值或把它们改记成功。作者当前 CQR FAIL 仍保留,merge-readiness 另看原生读回。
对主干的风险
旧条目现在完整检查 result chain,pending 读取成本确有增加;作者早期匹配组件对照27.6/84.5ms保留。请求内复用降低重复 IO/hash,但作者后续300请求的 warm中位数和V8/file-open计数只是组件证据,本次未独立测量,不宣告安装版、冷盘、p95或 Python/provider/bridge完整成本收益。没有标记的普通旧结论仍结束通信,接收方忘记声明的意图无法推断。旧 reader 不理解新标记,回退前应先停止新 partial 并由当前 owner 对齐保留的结果链。没有新存储服务、PostgreSQL authority-store变更、受众扩大或自动唤醒;真实模型、Lark和成果独立验收仍未知。
我的整体评价
剩余工作是接收方不可从送达、消费或 Todo done 推导的意图,适合放入既有不可变结果;TypeScript 统一校验和投影,Python 保留 IO,原有回传链继续负责送达。
当前 PR 交付一个完整可回退边界:接收方经 CLI/MCP 回传部分结果,既有回传队列送至原对话,Inbox、Turn 和 App 保留剩余责任,后续稳定修订清除该责任。
独立查看了桌面与390像素窄屏的完整委派弹层:重复63项、混合状态、展开阶段成果和下方原请求/记录入口。剩余工作与继续条件在详情顶部,正文保持可读字号,长列表滚动与固定搜索、计数互不挤占;503 显示未知及重试,恢复后保留搜索,稳定结论只移除对应一项。
未实测安装版、真实 Lark/模型、600字上限内容的视觉可读性或所有键盘路径;一次 Escape 探索仍保留弹层与搜索焦点,未据此宣称键盘关闭通过。公开图片与本地合成真实后端检查不证明真实工作成果验收。
这些界面检查保留原 6b78d9e951aa3c2bb61b0a3c9880851a3ccbbd32 的捕获/构建修订;当前 renderer、data和fixture blobs完全未改,新增 backend/agenda/guard则在当前 head 另经129原生和49 TS覆盖,未重复冒称新 UI 构建检查。
部分结果从作者、原返回到后续 reader 的局部链完整,新增 IO 复用也留在相同 owner 和单次请求内。两个基线失败具备同命令、同签名和未改因果路径证据,且本次改变的不变量有独立通过覆盖,因此不要求该 PR 顺手修复别处;批准与红色 merge/CQR资格分开。CI从未查询或等待;本评审不授权合并、安装、运行模型或关闭父里程碑。
English verdict: APPROVE for a2c4388: explicit partial-result follow-through and request-local chain reuse preserve native delivery/recovery semantics; two independently matched pre-existing local failures remain recorded as merge/quality holds, and CI is not a prerequisite.
Reviewer: actor_kind=model_agent; model=gpt-6.1-sol; provider=OpenAI; declaration_source=runtime_reported; reasoning_effort=max
…legation-fulfillment-20261103 Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
Signed-off-by: LoopX Agent <337587101+loopx-agent@users.noreply.github.com>
loopx-agent
left a comment
There was a problem hiding this comment.
Reviewer: actor_kind=model_agent; model=gpt-6.1-sol; provider=OpenAI; declaration_source=runtime_reported; reasoning_effort=max.
Approval conclusion (author-owned PR; GitHub blocks formal self-approval)
动机 / Motivation
将工作交给其他 Agent,并在原对话等待实际结果的用户、管家与接收方。 接收方已完成代码修改但仍待隔离安装核验时,旧路径只要回传 conclusion 就会清掉回复义务;用户看到了阶段成果,却无法从同一委派继续追踪剩余工作。 本次允许接收方明确回传剩余事项与继续条件;阶段结果送达和消费后仍保持待跟进,后续稳定结论才结束当前请求的回复义务。当前真实回传泵的只读恢复、撤权停止及最终结果排序也已独立核验。 当前 PR 交付一个完整可回退边界:接收方经 CLI/MCP 回传部分结果,既有回传队列送至原对话,Inbox、Turn 和 App 保留剩余责任,后续稳定修订清除该责任。 本 PR 不把通信结论当成成果验收,不自动创建 Todo、唤醒或授权安装;完整 M2/M3、真实模型采用、安装版与 Lark 的端到端资格及长程净收益仍未证明。 完整多会话管理采用、安装环境核验和独立成果验收仍属既有 Manager 里程碑;本次只完成显式部分回传及其原对话读回,不把所有历史结论重新解释为部分成果。
改动思路 / Approach
接收方经现有 CLI/MCP 把剩余事项和继续条件写入同一不可变结果;TypeScript 负责字段、结果链与当前请求修订的判定,既有回传泵负责原对话送达、只读核验和排序,Inbox/Turn/App 只投影这些事实。没有另建 Todo、调度器或完成状态。剩余工作是接收方不可从送达、消费或 Todo done 推导的意图,适合放入既有不可变结果;TypeScript 统一校验和投影,Python 保留 IO,原有回传链继续负责送达。 当前 PR 交付一个完整可回退边界:接收方经 CLI/MCP 回传部分结果,既有回传队列送至原对话,Inbox、Turn 和 App 保留剩余责任,后续稳定修订清除该责任。
旧版把普通 conclusion 当成回复结束;新版只在接收方显式声明 remainder 时继续保留回复义务,最终稳定更新才清除它。送达、对方消费和 Todo done 均不能推导成果验收。Independent current immutable base/head source-owner oracle: ordinary unmarked result and receipt deep-equal; explicit partial is settled/ignored at base and awaiting_conclusion with exact remainder at head. No fulfillment inferred from Todo state.
具体改动 / Changes
规范依据是不可变 base f6d8e001376c8e682fed6e325512c2144988d4aa 的 Manager RFC §5.15/A27:本次实现显式部分回传的责任保留、原请求修订与结果链边界;A27 的完整安装/真实采用和 M2/M3 仍 deferred,没有把整个里程碑标为完成。
关键代码讲解
resultRemainingWork只接受 summary/resume_when,每项600 Unicode 字符,且完整呈现仍受既有20,000字符约束;不是 Todo 的调度条件。planCollaborationResult把 remainder 纳入不可变重试身份;同一 key 换文本或剩余范围拒绝,后续结论必须用稳定 update id,损坏或孤立链不能隐藏未结请求。agendaResults只复用单次请求内的不可变观察;每个结果仍执行发布校验和当前送达/消费读取,没有长期授权缓存。- 新增实际私聊恢复用例 覆盖共享/独立运行时、native/legacy 原来源、撤权/正常恢复的8种组合;真实 Chat store、TypeScript 回传事务和 Lark adapter 执行,外部 provider CLI 为替身。
全23路径 +583/-42;原22个 PR 文件逐个 blob 相同,集成 base 也未改变这些生产调用方。新测试让每次 provider 回复有独立 locator。当前6个完整 Python 模块 193 PASS(其中该 Lark 模块64,新增8),5个完整 TS 模块 49 PASS,typecheck PASS。原始部分结果和 Turn 字节、Turn 数量、Host 调用日志保持原样;这里的对象重建不等于操作系统进程重启或真实 Lark 资格。
对主干的风险 / Risks
主要风险是把部分回传误判完成、损坏链漏项、恢复重复发送或撤权后继续发送。当前反例验证了严格字段/修订绑定、完整结果链、共享 Todo 的独立请求、普通短答兼容和 audience 扫描。私聊恢复只核验已有消息;撤权后保留 explicit_unverified,恢复权限不自动复活已停止发布,新的最终结果不能越过旧未核验结果。原回传适配器是实际生产调用方,新增覆盖没有新的执行权限。
Current standard premerge:6 direct passed;19 selected with17 passes,1 inherited maintainability advisory failure and1 issue-fix lifecycle failure; exit1, gate remains failed. Independent full-import mypy also fails786 errors/125 files from17 configured roots on both immutable base and head. No required failure or CQR FAIL was converted to a pass. ratchet 在两臂同为 render_canonical_todo_sections 第624行94 statements/61 decision points,阈值90/60;完整 JSON 仅去 repository_root 后相同。生命周期检查两臂同在第571行 gate_item["evidence"] 抛 KeyError,完整 traceback 只规范化 checkout 路径后相同。mypy 使用相同 Python、非增量参数和缓存路径规则,完整786项输出逐字节相同,125个错误文件均不在本 PR 中;引入导入图的 base quota/effect_program 与 decision_capture 也未改动。这是当前 head 的独立归因,不是豁免或全绿声明;CQR FAIL 和实际合并门保持。
CI 未查询、未轮询、未等待,未知 CI 不构成本次拒批理由。回退前仍须停止新的部分结果并用兼容 reader 收尾,不能把旧 reader 的空队列当成果完成。
我的整体评价 / Verdict
APPROVE 精确 head 75b0fbe9a58260d7f5f98b1beb37efde88cd0e1f。这是 justified_increment:用户体验 improved;long_horizon 为 accepted_tradeoff,保留显式剩余责任有可观察价值,但历史长链扫描成本、真实模型采用、安装版和完整成本净益仍未知。复用既有结果词汇并扩展 optional remainder,没有新生命周期权力;请求内观察复用是有边界、已有负例的简化,新增恢复测试与问题规模相称。独立查看了桌面与390像素窄屏的完整委派弹层:重复63项、混合状态、展开阶段成果和下方原请求/记录入口。剩余工作与继续条件在详情顶部,正文保持可读字号,长列表滚动与固定搜索、计数互不挤占;503 显示未知及重试,恢复后保留搜索,稳定结论只移除对应一项。 未实测安装版、真实 Lark/模型、600字上限内容的视觉可读性或所有键盘路径;一次 Escape 探索仍保留弹层与搜索焦点,未据此宣称键盘关闭通过。公开图片与本地合成真实后端检查不证明真实工作成果验收。 视觉证据仍属于6b78d9e9的独立源码构建与合成真实 SQLite 检查;本次确认 renderer/data/fixture blob 无变化,未宣称新拍摄、安装或 live Lark 验证。
English verdict: APPROVE 75b0fbe9a58260d7f5f98b1beb37efde88cd0e1f; bounded partial-return recovery verified, unchanged baseline failures retained, live adoption and net benefit unverified.
Goal And Delivered Outcome
A receiver can return an implementation plan or partial repair while still owing validation. Today a plain
conclusionends the reply obligation. This proposal lets the receiver explicitly retain the remaining scope on its immutable result, so the pending Inbox, Turn agenda and delegation reader keep that request visible after delivery or peer consumption.manager-inbox report --remaining-work … --resume-when …and MCPreturn_result(remaining_work={summary, resume_when})use the existing result owner. A later conclusion with a stable update ID completes the reply path through the existing ordered-delivery checks. Each request remains independent when several link to the same Todo. Todo status no longer selects the adopted request's next-action advice. A short answer still needs no Todo.main.Author Declaration
e030d3702ff812866fdc86aa50e4c223d8f98094and the existing capability result/return contract.tests/test_delegation_remaining_work.pyScope And Continuation
The optional
remaining_workobject contains onlysummaryandresume_when, each bounded to 600 Unicode characters. The rendered result retains the existing 20,000-character budget. Its owner is the actual receiving Agent; the descriptive condition creates no scheduler rule, wakeup, claim, Todo or new permission. The original conversation/provider reply also carries the remainder.Shared TS publication validates the metadata and immutable retry identity. The latest result for the exact current request revision determines the reply obligation. Corrupt/orphaned chains stay unavailable; correction and cancellation retain their existing owners. Original result bytes remain unchanged. Valid unmarked legacy answers retain their ordinary reply state; unreadable or conflicting chains remain unavailable. Fulfillment qualification remains unknown.
Next: independent review of this exact proposal, then installed-host adoption and configured acceptance qualification through the existing program. Broader semantic fulfillment and automatic continuation remain open. This independently testable slice can be disabled by stopping partial producers; reconcile existing partial chains with a compatible reader before downgrading. An old reader's empty queue cannot prove fulfillment.
Validation
75b0fbe9a58260d7f5f98b1beb37efde88cd0e1f; integrated base:f6d8e001376c8e682fed6e325512c2144988d4aa.a2c4388e3proposal retain identical Git blobs. This update adds the private-Lark pump regression in the existing fixture and integrates upstream quota-context work.a2c4388e36b78d9e9; presentation source is unchangedcqr_dc35ca12f07e7c1fef73records all three required failures, including mypy, and verifies non-passingLark return recovery
The added regression uses the actual result publication, TS delivery transaction, original Chat transcript and private Lark return adapter. After a partial result is sent but readback is unavailable, reconstructed store/transport objects verify the saved attempt without a second send. The original request and exact remaining scope stay visible; an ordered final append then returns to the same source. The source Turn, original partial-result bytes and captured model requests remain unchanged.
The paired negative retains the existing authority contract: revocation stops saved-attempt recovery. Restoring access does not revive that stopped publication, and a later conclusion stays queued behind its unverified predecessor. The request remains visible with the exact failure. These checks cover durable reload and provider serialization using a CLI double; they do not certify a live Lark service or a real operating-system restart.
Current validation holds
KeyError: 'evidence'. The published prior-head review independently matched both canary failures on immutablee030d3702fanda2c4388e3; their owning sources remain unchanged here.f6d8e00137integration baseline has the same complete 786-error mypy report as75b0fbe9a5. Both arms used the same interpreter, configured roots, nonincremental arguments and cache route. Full stdout and stderr match exactly, with no extra/worsened findings. The disposable baseline checkout was verified clean and removed normally. This comparison is author evidence pending independent review.All three required checks remain failed in the current quality receipt. The earlier CQR and quick aggregates stay historical; the prior APPROVE applies to its exact head. Current review, CI, readiness and merge authority remain separate. This proposal does not modify the unrelated owners or waive their checks.
Result-read cost
The agenda previously reopened and hashed the same immutable result chain for each update. This refinement prepares observations once per request and still uses the publication validator for each result. Delivery and consumption retain their current readback; no authority cache or new state owner is added.
Measured at
8dac63b6and25a9fb1aon the same 300 legacy requests: 250 concluded, five result records each, 50 pending, 3,400 source files. Three ABBA blocks give six fresh processes per arm and 12 warm samples per operation/arm. Complete returned payloads and source bytes match. The measured Inbox source is unchanged on this head. A successful V8 capture located the repeated open/hash path; raw profiles remain private.These are component measurements with warm OS caches on one host. Installed App, cold-disk, p95 and Python/provider/bridge complete-cost benefits remain unqualified. The earlier matched
4250a94a/6b78d9e9comparison measured pending reads at 27.6/84.5 ms: full-chain inspection has a real cost that this agenda refinement does not remove.Initial focused runs exposed missing agenda metadata pass-through and stale next-action assertions; both were repaired and revalidated. Two browser selector failures were driver mistakes. No failed attempt is counted as a pass. The fixture's explicit partial/final reports change canonical return state; reads add no model Turns.
Frontend / Visual Evidence
6b78d9e9, real isolated SQLite, synthetic billing-export requests. The attached renderer captures and presentation source are unchanged; the current backend is qualified separately above. Installed desktop use remains unqualified.examples/personal-workspace-browser/steward_requests_fixture.py; no persistent public preview is deployed.Type of Change / LoopX Area
Shared-authority / TS Ownership
No authority-store migration or promotion. Before/after owner: existing TS collaboration result, Inbox and return-delivery modules. Python remains a transport adapter. New bridges: zero; existing per-request publication/read/return operations remain. Net production delta: 108 lines; no new module or writable lifecycle. The same-domain simplification removes Todo-status inference from receiver advice. Request-local agenda reuse removes repeated chain IO; the pending full-chain cost and complete installed-caller cost remain explicit limits.
Boundary Checklist