feat(stride): add read-only shadow stride observation (M1) - #3207
Merged
Conversation
Derive a provider-neutral hierarchical_stride_observation_v0 from existing public-safe run receipts: delivery material slices and evidence freshness, authority bounded-slices-since-change, and an explicit unknown effect layer. Shadow-only and evaluator-only: no runtime, quota, scheduler, notification, gate, or execution behavior changes (RFC #3204 M1). Tracks #3203
huangruiteng
commented
Aug 14, 2026
huangruiteng
left a comment
Owner
Author
There was a problem hiding this comment.
Approval conclusion (author-owned PR; GitHub blocks formal self-approval)
详细中文评审:只读 Shadow Stride Observation M1(PR #3207)
评审目标 head:a0f81edb5aeeb9395bafe742ce07d2c2b5535f77(base: main,2 文件,+214/-0;Tracks #3203,RFC #3204 M1)
内容与边界
- 新增
loopx/control_plane/runtime/stride_observation.py:从现有 public-safe run receipt(runs/index.jsonl)派生hierarchical_stride_observation_v0,只读、shadow-only(shadow_only=True恒真),不触碰 Todo 选择、scheduler、quota、通知、gate 或执行路径。 - delivery 层:material slices、latest outcome、evidence freshness(6h 窗口);authority 层:自最近 replan/vision/gate run 以来的 bounded slices,segment disposition 保持
unknown;effect 层显式unknown: True(fail-closed,符合 RFC §8.1/§11“缺失 host 指标不得猜测”)。 - 离线 evaluator 只报告可派生 mismatch signal(
settlement_lag),recommendations 恒为空。 - 4 个聚焦测试:空 runtime fail-closed、字段派生、陈旧证据信号、跨 agent 归因隔离。
与 RFC #3204 的一致性
严格落在 M1 最小切片内:只读 observation + offline evaluator + public-safe fixtures;无新 capability、无 executor、无 adaptive policy、无 shadow recommendation 之外的任何动作。放置于 control_plane/runtime(最近的 status read model 区域),符合 scope-fit。
非阻塞问题
无。合入前等 CI(pytest)完成即可;后续 M2(effect-stride 实验)应另开 todo/PR。
我的整体评价
窄小、诚实(未知即未知)、可逆,且用测试钉死归因与 fail-closed 语义。结论:APPROVE。
English Verdict (PR #3207)
- Exact head reviewed:
a0f81edb5aeeb9395bafe742ce07d2c2b5535f77 - Verdict: APPROVE (author-owned PR; GitHub blocks formal self-approval, recorded as COMMENTED)
- Key findings: Adds a read-only, shadow-only
hierarchical_stride_observation_v0projection over existing public-safe run receipts (delivery material slices/evidence freshness, authority bounded-slices-since-change, explicit unknown effect layer) plus an offline evaluator that reports only derivable signals (settlement_lag) and recommends nothing. No runtime, quota, scheduler, notification, gate, or execution behavior changes; 4 focused tests cover fail-closed empty state, field derivation, stale-evidence signals, and cross-agent attribution isolation; ruff and py_compile are clean.
Owner
Author
|
CI status: pytest / build / dependency-review all SUCCESS at head a0f81ed. Merge-ready pending owner merge. |
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.
Summary
loopx/control_plane/runtime/stride_observation.py: a read-only, shadow-only projection that derives a provider-neutralhierarchical_stride_observation_v0from existing public-safe run receipts.unknown.unknown: True(fail-closed; host metrics absent).settlement_lag) and recommends nothing.Issue Or Task
ae31e498)Validation
python -m pytest -q tests/control_plane/test_stride_observation.py— 4 passedruff checkclean on both filespython -m py_compilepassesType of Change
Boundary Checklist