Repository navigation
feat(runtime-host): establish hosted root execution foundation - #1551
Conversation
|
Reviewed at P1: The durable claim fingerprint does not constrain the prompt used for first execution.
P2: The existing-Run path bypasses RootTurnAdmission authority. If a matching terminal Run already exists, Require and validate the hosted admission identity on this path, including execution kind, run identity, user-message identity, and content. Add negative tests for missing admission and conflicting admission or message data. |
582d490 to
aec7282
Compare
Astro-Han
left a comment
There was a problem hiding this comment.
Rechecked aec7282f. The durable claim now binds the prompt before any execution side effect, and existing hosted Runs require the exact RootTurnAdmission and UserMessage through executeRoot. No findings in the increment. The focused builds and tests pass.
English
Context
This PR establishes the hosted root execution foundation for the Runtime Host M3 migration tracked by #1167.
It closes the admission, execution ownership, cancellation, recovery, and terminal handoff boundaries shared by linked child roots and durably claimed agent-graph roots. Runtime Host remains non-serving in production; this PR does not switch Desktop, TUI, CLI, or Headless entrypoints.
What changes
Canonical execution identity and admission
AgentGraphControlStorefor graph coordination and trusted claim reads; this PR does not introduce a second claim writer.executeRoot, require its exact durable admission and unique UserMessage, and never synthesize or backfill missing authority.Runtime execution ownership and cancellation
RuntimeExecutionClaimthat reserves the execution slot before asynchronous backend activation and exposes one stop signal for the complete startup and execution path.run.begin(), the first iterator step, and active execution.Host terminal and recovery boundary
Design decisions
Evidence
Coverage exercises the real SQLite graph control Store, complete claim-input fingerprinting, missing or conflicting existing-Run authority, exact claim retry behavior, linked child creation/resume/provider retry, claimed graph ordering, queued and pending-start cancellation, backend activation races, late-generation quarantine, terminal identity drift, owner cleanup failure, recovery, and ordinary backend failure containment.
git diff --checkpass.Scope
This slice intentionally does not add a real hosted model Backend, Prompt/Tool convergence, production surface wiring, Automation or Goal ownership, Native Provider, Runtime Resources, or the M4/M5 cutover.
Part of #1167. Related to #853.
简体中文
背景
本 PR 为 #1167 跟踪的 Runtime Host M3 迁移建立 hosted root execution foundation。
它关闭 linked child root 与 durable claimed agent-graph root 共同依赖的 admission、execution ownership、cancellation、recovery 和 terminal handoff 边界。Runtime Host 仍未进入 production serving;本 PR 不切换 Desktop、TUI、CLI 或 Headless 的任何入口。
改动内容
Canonical execution identity 与 admission
AgentGraphControlStore;本 PR 不引入第二个 claim writer。executeRoot,具备精确 durable admission 与唯一 UserMessage;缺失的 authority 不会被合成或回填。Runtime execution ownership 与 cancellation
RuntimeExecutionClaim,在异步 backend activation 前预留 execution slot,并为完整启动和执行路径提供统一 stop signal。run.begin()、首个 iterator step 与 active execution。Host terminal 与 recovery boundary
设计决策
验证证据
覆盖范围包括真实 SQLite graph control Store、完整 claim-input fingerprint、缺失或冲突的 existing-Run authority、精确 claim retry、linked child creation/resume/provider retry、claimed graph ordering、queued 与 pending-start cancellation、backend activation race、迟到 generation quarantine、terminal identity drift、owner cleanup failure、recovery,以及普通 backend failure containment。
git diff --check均通过。范围
本 slice 明确不加入真实 hosted model Backend、Prompt/Tool convergence、production surface wiring、Automation 或 Goal ownership、Native Provider、Runtime Resources,或 M4/M5 cutover。
属于 #1167;关联 #853。