Skip to content

governance(drift-399): AI_Toy 申报 + bootstrap 直推豁免 - #400

Merged
randypanding merged 1 commit into
mainfrom
fix/drift-399-ai-toy
Aug 29, 2026
Merged

governance(drift-399): AI_Toy 申报 + bootstrap 直推豁免#400
randypanding merged 1 commit into
mainfrom
fix/drift-399-ai-toy

Conversation

@randypanding

@randypanding randypanding commented Aug 28, 2026

Copy link
Copy Markdown
Contributor

Card: #399

变更摘要(治理级变更 / 对应 drift-399 四项漂移的 Fix-2 + Fix-3)

  • governance/REPOS.yaml(L2 / active / public / entry_protocol: true):线上存在的 AI_Toy 仓完成地图申报(drift §7 未申报仓)。
  • governance/expected-state.jsondirect_push_exemptions.AI_Toy 登记两条完整 SHA:
    • 71456ebd8e841fe2c5e18bcdfd7d5cf63e1e17b7(Initial commit,owner randypanding @ 2026-08-28T06:10:57Z)
    • 439617d6d3640aa513d6a21c739f9d7aec9a246d(Add files via upload,owner @ 2026-08-28T06:13:30Z)
      ——(b) 类(ADR-0021/ADR-0090/ADR-0092):空仓建仓时序上 PR 流程尚未就绪,破玻璃直推事实的机器可回填登记(§8),先例已在 Viral_Radar / Media-Monitor / QW_Arena1 同类登记。
  • 其余两项漂移(§基线异常、§11 治理标签缺失/颜色)已在 AI_Toy 仓经本仓 bash governance/apply.sh 幂等修复(基线=squash-only/delete-branch/auto-merge=on;12 治理标签按 expected-state.labels.items 对齐)。
  • 路径选择:治理层变更按 ADR-0095 单 PR 一件事;无新依赖;未改 workflows / Makefile;未触碰阈值或验收协议。

验证

  • drift-check:bash governance/drift-check.sh 应不再产生 AI_Toy 相关 §1/§7/§8/§16 条目
  • AI_Toy 基线 GET 接口返回:{allow_squash_merge:true, allow_merge_commit:false, allow_rebase_merge:false, delete_branch_on_merge:true, allow_auto_merge:true}(与 apply.sh §5 期望一致)
  • AI_Toy 标签:type:intent/type:card + 10×state:*state:ir-signed/state:ready/state:done 色=0E8A16state:in-progress=FB8C04state:spec=FBCA04 等逐色对齐)

Summary by CodeRabbit

  • 治理与配置
    • 新增 AI_Toy 仓库登记,完善其公开状态、技术栈、职责范围及治理信息。
    • 更新建仓直推豁免清单,补充 AI_Toy 等仓库及对应 SHA 记录。
    • 规范相关仓库条目排序,保持现有 SHA 内容不变。

Copilot AI lite review requested due to automatic review settings August 28, 2026 08:38

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has reached their quota limit.

@qodo-code-review

Copy link
Copy Markdown

PR Summary by Qodo

治理登记 AI_Toy 并豁免 bootstrap 直推

🐞 Bug fix ⚙️ Configuration changes 🕐 Less than 10 minutes

Grey Divider

AI Description

• 将 AI_Toy 登记为启用入口协议的公开 L2 产品仓。
• 按完整 SHA 豁免两笔建仓 bootstrap 直推,消除治理漂移。
Diagram

graph TD
  A["AI_Toy 元数据"] --> B["REPOS 清单"] --> E["漂移检测"] --> F["治理结果"]
  C["Bootstrap 提交"] --> D["预期状态"] --> E
Loading
High-Level Assessment

当前方案最合适:复用现有 REPOS 组织地图和 direct_push_exemptions 精确 SHA 白名单,同时登记仓库与 bootstrap 事实,避免分拆 PR 造成短暂不一致。相比修改检测逻辑或使用宽泛豁免,逐 SHA 声明确保后续直推不会搭便车。

Files changed (2) +47 / -29

Bug fix (1) +33 / -29
expected-state.json登记 AI_Toy bootstrap 直推豁免 +33/-29

登记 AI_Toy bootstrap 直推豁免

• 在 direct_push_exemptions 中加入 AI_Toy 的两笔完整提交 SHA,并扩展政策注释说明其建仓时序依据。现有仓库豁免条目同时按名称重排,内容保持不变。

governance/expected-state.json

Other (1) +14 / -0
REPOS.yaml将 AI_Toy 纳入组织仓库地图 +14/-0

将 AI_Toy 纳入组织仓库地图

• 新增 AI_Toy 的 L2、公开、启用状态及产品仓职责说明,并声明关键路径和入口协议要求。该登记使线上仓库进入组织治理覆盖范围。

governance/REPOS.yaml

@coderabbitai

coderabbitai Bot commented Aug 28, 2026

Copy link
Copy Markdown

Review Change Stack

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro Plus

Run ID: 86548650-e8ca-4ca4-a4e4-73dbd9850359

📥 Commits

Reviewing files that changed from the base of the PR and between f526751 and 5b60ad3.

📒 Files selected for processing (2)
  • governance/REPOS.yaml
  • governance/expected-state.json

Included review availability: Your plan provides up to 10 included reviews per hour; 6 remain after this review.


📝 Walkthrough

Walkthrough

本次变更登记 AI_Toy 仓库,并更新直推豁免说明、受管仓库 SHA 和仓库清单顺序。

Changes

仓库治理登记

Layer / File(s) Summary
AI_Toy 仓库注册与治理配置
governance/REPOS.yaml
新增 AI_Toy 的 L2、公开、活跃属性,以及产品职责、Python/TypeScript/Rust 技术栈、治理配置、关键路径、入口协议和 bootstrap 直推豁免信息。
直推豁免状态清单更新
governance/expected-state.json
新增 AI_Toy bootstrap 记录和多个仓库的豁免 SHA 登记。将 agent-toolscnb-bridgeholdoutmutual 调整到对应清单位置。

Suggested labels: security

Merge Risk: ⚪ Minimal · up to 5b60a

This change registers AI_Toy and records its documented bootstrap push exemptions in governance metadata; no actionable merge-blocking risk remains beyond normal checks and review.

🚥 Pre-merge checks | ✅ 1 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Title check ⚠️ Warning 标题准确描述了 AI_Toy 登记和 bootstrap 直推豁免,长度为 49 个字符,满足长度要求。但标题使用 governance 前缀,不符合要求的 Conventional Commits 前缀。 将标题前缀改为 featfixchorerefactordocstest,并保持总长度不超过 50 个字符。例如:chore: AI_Toy 申报与 bootstrap 直推豁免
✅ Passed checks (1 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
  • Fix all pre-merge checks with AI
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/drift-399-ai-toy

Comment @coderabbitai help to get the list of available commands.

@qodo-code-review

Copy link
Copy Markdown

Code Review by Qodo

🐞 Bugs (2) 📘 Rule violations (0) 📜 Skill insights (0)

Grey Divider


Remediation recommended

1. Fallback omits AI_Toy metrics 🐞 Bug ◔ Observability
Description
When sli-report.sh cannot fetch or parse REPOS.yaml, its hard-coded fallback omits the newly
active AI_Toy repository, so AI_Toy PRs are excluded from organization-wide merge, escape,
stuck-PR, duration, and sampling metrics during that failure mode. The fallback is then incomplete
precisely when it is used to preserve reporting through an infrastructure failure.
Code

governance/REPOS.yaml[R185-188]

+  - name: AI_Toy
+    layer: L2
+    visibility: public
+    status: active
Relevance

●●● Strong

Recent accepted precedents favor fixing incomplete repository enumeration and fail-closed reporting
coverage gaps.

PR-#19
PR-#195

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The added registry entry makes AI_Toy active, while the fallback list does not contain it; every PR
query and all downstream SLI calculations consume only the resulting $REPOS list.

governance/REPOS.yaml[185-188]
scripts/sli-report.sh[111-128]
scripts/sli-report.sh[131-160]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
The new active `AI_Toy` repository is absent from `sli-report.sh`'s repository fallback, so its PRs are omitted whenever canonical registry retrieval or parsing fails.

## Issue Context
The normal path reads `REPOS.yaml`, but the fallback is a separate static repository enumeration and must be extended for the new member.

## Fix Focus Areas
- governance/REPOS.yaml[185-188]
- scripts/sli-report.sh[111-128]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


2. Product metrics omit AI_Toy 🐞 Bug ◔ Observability
Description
AI_Toy is declared as an active product repository, but it is absent from metrics.yaml's
user_results.products, so the dashboard never reads or reports its required
metrics/user-result.yaml metric—even as pending. The current test checks only that listed products
exist in REPOS.yaml, allowing this reverse omission to pass silently.
Code

governance/REPOS.yaml[R188-190]

+    status: active
+    role: 产品仓——AI 陪伴玩具多模态 monorepo(唤醒词/声纹/IMU/情绪引擎/人格编译器/记忆图谱/
+      TTS/离线运行时/路由缓存 共 T1–T20 资产与 16 组门禁;Python uv 工作区 + TypeScript pnpm +
Relevance

●● Moderate

The omission is plausible and materially affects dashboard coverage, but no close precedent
addresses reverse product-list validation.

PR-#195
PR-#250

ⓘ Recommendations generated based on similar findings in past PRs

Evidence
The new role explicitly classifies AI_Toy as a product repository. The policy requires each product
repository's metric at a fixed path, the dashboard iterates only the static policy list, and
validation does not assert that all declared products are present in that list.

governance/REPOS.yaml[185-196]
governance/policy/metrics.yaml[70-80]
governance/dashboard-update.py[581-584]
governance/tests/test-metrics-policy.sh[91-99]

Agent prompt
The issue below was found during a code review. Follow the provided context and guidance below and implement a solution

## Issue description
Register `AI_Toy` in the product user-result metric scope so its metric is collected and rendered rather than silently omitted.

## Issue Context
The policy says every product repository has a user-result metric slot, but the static product list and its one-way validation do not include the newly declared product.

## Fix Focus Areas
- governance/REPOS.yaml[188-190]
- governance/policy/metrics.yaml[70-80]
- governance/tests/test-metrics-policy.sh[91-99]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools


Grey Divider

Context sources
✅ Compliance rules (platform): 22 rules
Review mode: ⚖️ Balanced: This changes governance configuration and direct-push exemption state that drive drift enforcement, so it has meaningful behavioral and policy impact; the scope is localized but not trivial enough for lite or dense enough for extended.

Grey Divider

Tip of the day
💡 Did you know, you can reply 'qodo' on any finding to push back, ask questions, or dig deeper

More tips ↗ | Customize Qodo ↗ | Qodo docs ↗

Grey Divider

Qodo Logo

Comment thread governance/REPOS.yaml
Comment on lines +185 to +188
- name: AI_Toy
layer: L2
visibility: public
status: active

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remediation recommended

1. Fallback omits ai_toy metrics 🐞 Bug ◔ Observability

When sli-report.sh cannot fetch or parse REPOS.yaml, its hard-coded fallback omits the newly
active AI_Toy repository, so AI_Toy PRs are excluded from organization-wide merge, escape,
stuck-PR, duration, and sampling metrics during that failure mode. The fallback is then incomplete
precisely when it is used to preserve reporting through an infrastructure failure.
Agent Prompt
## Issue description
The new active `AI_Toy` repository is absent from `sli-report.sh`'s repository fallback, so its PRs are omitted whenever canonical registry retrieval or parsing fails.

## Issue Context
The normal path reads `REPOS.yaml`, but the fallback is a separate static repository enumeration and must be extended for the new member.

## Fix Focus Areas
- governance/REPOS.yaml[185-188]
- scripts/sli-report.sh[111-128]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

Comment thread governance/REPOS.yaml
Comment on lines +188 to +190
status: active
role: 产品仓——AI 陪伴玩具多模态 monorepo(唤醒词/声纹/IMU/情绪引擎/人格编译器/记忆图谱/
TTS/离线运行时/路由缓存 共 T1–T20 资产与 16 组门禁;Python uv 工作区 + TypeScript pnpm +

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remediation recommended

2. Product metrics omit ai_toy 🐞 Bug ◔ Observability

AI_Toy is declared as an active product repository, but it is absent from metrics.yaml's
user_results.products, so the dashboard never reads or reports its required
metrics/user-result.yaml metric—even as pending. The current test checks only that listed products
exist in REPOS.yaml, allowing this reverse omission to pass silently.
Agent Prompt
## Issue description
Register `AI_Toy` in the product user-result metric scope so its metric is collected and rendered rather than silently omitted.

## Issue Context
The policy says every product repository has a user-result metric slot, but the static product list and its one-way validation do not include the newly declared product.

## Fix Focus Areas
- governance/REPOS.yaml[188-190]
- governance/policy/metrics.yaml[70-80]
- governance/tests/test-metrics-policy.sh[91-99]

ⓘ Copy this prompt and use it to remediate the issue with your preferred AI generation tools

@randypanding
randypanding merged commit 88e771e into main Aug 29, 2026
18 checks passed
@randypanding
randypanding deleted the fix/drift-399-ai-toy branch August 29, 2026 17:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants