[CLAUDE] Docs: S100 Harness-18 adopt — detector v2 ratio-band+glob (fault-inject 4/4, MED 11→0) + retire runs/_ledger 🧊 (0/15 lifetime, sweep 15 điểm/8 file, orphan=folder-scan) + engine §J + cron ghost-wire honest-retire (CronList=0, 5 file) + F2 SendMessage re-verified + 3 adap-report (frontier HELD hash-MISMATCH, flag reviewer_gate-missing) — WF1 wf_50a817ce-a69 · WF2 wf_31ea3985-92c in-flight
All checks were successful
Deploy SOLUTION_ERP / build-deploy (push) Successful in 5m17s
All checks were successful
Deploy SOLUTION_ERP / build-deploy (push) Successful in 5m17s
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This commit is contained in:
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
34
docs/changelog/sessions/2026-07-02-S100-harness-18-adopt.md
Normal file
34
docs/changelog/sessions/2026-07-02-S100-harness-18-adopt.md
Normal file
@ -0,0 +1,34 @@
|
||||
# Session 100 — 2026-07-02 — Harness-18 adopt + frontier HELD-integrity (governance/scripts-only)
|
||||
|
||||
> **Lệnh anh:** `/check-email AI_INFRA` + `/adap-apply` step-by-step cẩn thận + `/ultra-on` + report AI_INFRA trung thực. Em-main-led (single-writer D9), 2 workflow Harness-9 mandate. 0 prod code.
|
||||
|
||||
## Bootstrap (đầu phiên, trước lệnh adopt)
|
||||
|
||||
- `/session-start` đủ: HMW-ON · Fable lead OK · test **440/440 re-verified** (45D 404ms + 395I 1m09s) · detector 25 cờ advisory · spec-audit PASS 5 criteria GAP-none · RAG 2431 rerank-OK · marks 4 Active-High display.
|
||||
- 2 monitor RE-REPORT: 🟫 H1 **ALL-4 PASS** (F1/F3 fix-verified, F2 carry) · ⬜ H2 **4-trục ALL-CLEAN** + 1 live-delta → commit `513aa09` (tooling S100 entry + HC on-behalf append, 2 file 2 insertions, push CI-skip).
|
||||
|
||||
## Adopt H18 (commit S100 chính)
|
||||
|
||||
1. **Check-email:** outbox/se RỖNG (0 directed). 3 broadcast mới outbox/all sau H17.
|
||||
2. **Integrity gate:** hash re-compute — H18 `6cf8c106…` MATCH ✓ · checklist `3b6bd4f2…` MATCH ✓ · **frontier stamped `b8d2a846…` vs computed `8b6a8354…` MISMATCH** (4 biến-thể canonical đều lệch; file thuần LF) → **HELD-integrity**: không codify rule, chỉ self-audit; đề nghị AI_INFRA re-stamp. ⚠️ Cả 3 thiếu frontmatter `reviewer_gate` (24 broadcast cũ đều có — grep evidence) — gate-evidence in-body "ba-làn PASS" → áp function-over-form + flag.
|
||||
3. **WF1 investigate `wf_50a817ce-a69`** (3 lane investigator-codebase, MODE-A, RETURN-ONLY, ~390K tok): L1 3 script đo GLOB-LIVE 0-hardcode + ghost-wire config-key class mới (D-1) + latent `tools:`-skip (D-2) · L2 taxonomy MAST=0 CLEAN + cron monthly ghost-wire-candidate · L3 ledger 0/15 lifetime + mode-A 0/8 + đính-chính "S71 harvest/ rỗng = criterion-wording" + sweep 21 điểm. Containment: git-diff 0-residual + chunk 2431==2431.
|
||||
4. **CronList runtime = 0 job** → ghost-wire CONFIRMED → honest-retire 5 file (rules.md ×2 · CLAUDE.md · STATUS.md · session-start.md).
|
||||
5. **Edits (26 điểm / 13 file + 3 report mới):**
|
||||
- `scripts/governance-detectors.ps1` — J.A: ratio-band mismatch-only + `$derivedDocs` glob động + note. **Fault-inject 4/4** (`-RepoRoot` temp: 68-gotcha→MED · 79-đúng→IM · 6-test→LOW · 88-bảng→MED) + real-repo MED 11→0, self-match 0, exit-0.
|
||||
- `runs/_ledger.md` freeze 🧊 + sweep: `runs/README.md` ×7 · `workflows/README.md` ×2 · `session-start.md` §2.1.1 · `session-end.md` §L.b(f) · `harvest-curator.md` ×3 · `agents/README.md` G-015-cite · HC MEMORY baseline. Orphan-authority = folder-scan.
|
||||
- `session-end.md` +§L.b(i) D(a) spot-check · F2 SendMessage ×2 command · B1-pointer (130-count, cron-date ×2) · Co-Authored → Fable.
|
||||
- `harness-11-engine.md` **+§J** (4 pattern + frontier self-audit + honest nấc 10/12+2 n-a).
|
||||
- STATUS backlog **D-1/D-2** đánh-số (frontier P2 remedy).
|
||||
- 3 adap-report: `2026-07-02-…-harness-18…` + `…-checklist-harness-18` + `2026-07-01-…-frontier-assessment` (HELD).
|
||||
6. **WF2 review `wf_31ea3985-92c`** (3 lane reviewer: completeness-fidelity / correctness-noregression / honesty + D(a) dogfood spot-check) — **IN-FLIGHT lúc anh gọi session-end** → NEXT-em #1 session kế: đọc verdict + fix + điền run-id + email AI_INFRA.
|
||||
|
||||
## Lessons
|
||||
|
||||
- **Stamp-then-edit hash-drift có thật ở nguồn phát** (frontier MISMATCH) + **em tự-bắt 1 ca suýt-bịa** (ghi sẵn run-id+verdict WF2 chưa chạy vào report → sửa placeholder ngay) — đúng lớp "trích-dẫn tự-khen dễ bịa nhất" của chính broadcast.
|
||||
- **Ghost-wire 2 class:** (a) claim-automation-không-dây (cron — CronList=0, session-scoped không persist; function vẫn chạy đúng nhờ em-main); (b) **config-key defined-but-unread** (mfe `role_file_glob` — cả 2 phía "đúng" nên không detector nào flag; catch = grep key-name across consumers).
|
||||
- **Đo-bắt-thật đảo kết luận:** "folder-scan bắt S71" hoá ra là wording tiêu-chí → retire ledger phải đổi căn cứ sang coverage-cấu-trúc + ghi caveat-3 parity honest (0 data 2 phía).
|
||||
- Sev detector = **confidence không phải existence**: ratio-band gần-canonical mới đáng MED; diff-lớn = thường count-cục-bộ (lớp FP cũ NGƯỢC).
|
||||
|
||||
## State
|
||||
|
||||
Mig 61 · 89 bảng · 440 test · gotcha 79 · menu 54 · bundle admin `mEGqlNWc`/user `Dnrp4PU1` (chưa đổi — push S100 có `scripts/*.ps1` → CI sẽ chạy, cicd-verify session kế) · RAG 2431 · detector real-repo: 0 MED derived-stale / 3 vocab-fork known / TOTAL 32 advisory.
|
||||
@ -0,0 +1,22 @@
|
||||
# adap-report — 2026-07-01-Governance-harness-frontier-assessment (SE) — ⚠️ HELD-integrity
|
||||
|
||||
> **Broadcast:** `2026-07-01-Governance-harness-frontier-assessment.md` (outbox/all AI_INFRA, type: update — method-share, KHÔNG checklist 🔴).
|
||||
> **Status: HELD-integrity — KHÔNG áp như broadcast-verified.** `content_sha256` re-compute **MISMATCH**: stamped `b8d2a846…8b9edc` vs computed `8b6a8354…e8bdadd` (canonical chuẩn — CÙNG phép match ✓ 2/2 file H18 cùng đợt → phép đúng, body đã lệch stamp). Thử 4 biến-thể canonicalization (raw / crlf→lf / lf→crlf / trim-end) đều KHÔNG khớp; file thuần LF (0 CRLF). Khả năng cao = **edit-body-sau-stamp phía phát** (đúng lớp "stamp-then-edit drift" mà chính broadcast này cảnh báo ở mục trích-dẫn-phải-thật). → **Đề-nghị AI_INFRA verify + re-stamp**; SE sẽ re-run `/adap-apply` cho id này khi hash khớp.
|
||||
|
||||
## SE đã làm gì (dù HELD — self-audit vô-hại, có giá-trị riêng)
|
||||
|
||||
KHÔNG codify rule nào từ broadcast này (frontier-envy rule → CHƯA vào rules.md §6.6; chờ re-stamp). CHỈ chạy **4 pattern-check như self-audit nội bộ** (WF1 `wf_50a817ce-a69` lane 1+2, read-only):
|
||||
|
||||
| Pattern | Verdict SE | Evidence |
|
||||
|---|---|---|
|
||||
| (1) Taxonomy-matrix | **CLEAN — n-a-legit** | grep `\bMAST\b` = 0 repo-wide; `error-ledger.md` "3-axis tag [TYPE/ACTOR/COMPONENT]" = internal scheme map Gov-v2 §L.b/§G3, KHÔNG claim external-taxonomy → không cần ma-trận ánh-xạ |
|
||||
| (2) Ghost-wire | **1 THẬT (đã fix S100) + 2 defer** | 🔴 **Cron monthly** `solution-erp-skill-audit-monthly`: CronList runtime = **0 job** + scheduler RỖNG 2026-05-04 (session-log) + S96 audit chạy 13:04 bởi em-main in-session (commit `881783c`) + CronCreate harness = session-scoped không persist → **honest-retire 5 file** (rules.md:292+:543 · CLAUDE.md:111 · STATUS.md:62 · session-start.md §2.4): monthly = thủ-công em-main theo cadence-pointer STATUS (function KHÔNG ghost — S44/S96 đều chạy đúng hạn; chỉ wiring-claim sai). ➕ 2 ghost-wire-config-key defer đánh-số STATUS backlog **D-1** (`mfe.sub_denominator.role_file_glob`/`diary_path_pattern` defined-but-unread — `mfe-eval.ps1:216/:237` re-hardcode trùng giá trị). Cadence#4 + mọi auto-claim khác = WIRED hoặc disclaimed-no-daemon (convention G-015 nhất quán) |
|
||||
| (3) Measurer role-coverage | **PASS 3/3** | `mfe-eval.ps1:216` + `memory-selfimprove-audit.ps1:133-137` + `memory-archive-gate.ps1:106` đều GLOB-LIVE, 0 hardcode roster/"11" — agent thứ 12 tự-cử. ➕ 1 latent blind-spot defer **D-2** (selfimprove `:147` skip-if-no-`tools:`-line; 0 affected — 11/11 có `tools:`) |
|
||||
| (4) Correction-cadence proxy | **Ghi-nhận, KHÔNG áp** | 0 điểm-đau đo được hiện tại → áp-không-pain = chính "frontier-envy" broadcast cảnh báo. Ghi-nhận method để dùng khi có pain thật |
|
||||
|
||||
## Nấc (G-011)
|
||||
|
||||
- **agreed:** phương-pháp (2-lượt + trích-dẫn-thật + làn-ground-truth) — SE VỐN đang chạy đúng khuôn này (2-workflow mandate + reviewer adversarial + lane ground-truth WF1); không cần build mới.
|
||||
- **executed:** self-audit 4 pattern (bảng trên) + fix ghost-wire cron (5 file) + defer-đánh-số D-1/D-2 (STATUS backlog — đúng remedy "nâng thành mục-sổ có đánh-số").
|
||||
- **HELD:** codify rule frontier-envy vào rules.md §6.6 — chờ re-stamp.
|
||||
- **Dogfood tự-thân trong chính adopt này:** em-main tự bắt 1 ca suýt-bịa-dẫn-chứng (ghi sẵn run-id + verdict WF2 CHƯA chạy vào report H18 → sửa thành placeholder ngay) — đúng lớp "con-số tự-khen nghe thuận tai càng dễ bịa" của broadcast.
|
||||
@ -0,0 +1,35 @@
|
||||
# adap-report — 2026-07-02-Governance-checklist-harness-18 (SE — completeness self-check)
|
||||
|
||||
> **Broadcast:** `2026-07-02-Governance-checklist-harness-18.md` (`content_sha256` re-compute = `3b6bd4f2…9ebb4a` **MATCH ✓**; frontmatter `status: 🟢 ADOPT`, thiếu `reviewer_gate` field — flag chung với report chị em). Đối-chiếu 12 mục 🔴 + 4 mục 🟡. Chi tiết evidence → report `2026-07-02-Governance-harness-18-architecture-consolidation.md` + engine §J.
|
||||
|
||||
## Cổng completeness — 12 mục 🔴 (phát-biểu chủ-động)
|
||||
|
||||
| # | Sàn 🔴 | Verdict | Nấc | Mechanized-vs-convention (honest) |
|
||||
|---|---|---|---|---|
|
||||
| A1 | Mismatch-only | **ĐẠT** — kể-lại-đúng IM (fault-inject case-2), lệch mới flag; + ratio-band confidence | runtime → executed-file | mechanized (detector) |
|
||||
| A2 | Mở dải quét theo dải THẬT | **ĐẠT** — glob động ALL SKILL.md + ALL commands/*.md (vá lớp-mù F3) | executed-file + runtime | mechanized + convention (định-kỳ kiểm dải) |
|
||||
| A3 | Loại dòng-định-nghĩa/trích-chuẩn | **ĐẠT** — self-exclusion 6 path + `$ExcludeExact`, re-verified 0 self-match | executed-file + runtime | mechanized |
|
||||
| B1 | Đo bắt-thật trước nghỉ-hưu | **ĐẠT** — ledger 0/15 lifetime vs folder-scan 4+ memory-delta catches + mode-A 0/8 (WF1-L3 evidence-grade). ⚠️ Caveat-3 parity ghi rõ: run-folder-orphan 0 data CẢ 2 phía → căn cứ = coverage-cấu-trúc, KHÔNG catch-rate | runtime (đo) → executed | convention (quyết bằng số) |
|
||||
| B2 | Nghỉ-hưu trung-thực, đảo-ngược, giữ lịch-sử | **ĐẠT** — 1 dòng 🧊 header `_ledger.md`, 15 row nguyên, revert = gỡ dòng | executed-file | convention |
|
||||
| B3 | Sweep mọi nơi-tiêu-thụ | **ĐẠT** — 15 điểm/8 file live sweep (grep `_ledger` exact — 5 "ledger" khác tên); HISTORY giữ nguyên | executed-file | mechanized (grep) + convention (classify) |
|
||||
| C1 | Hạ-bậc lớp-thực-thi có cổng-kiểm | **n-a-by-owner-mandate** — H8 all-inherit 🔴 anh-chốt S66 (chất-lượng>chi-phí); escape-hatch `tier:'opus'` per-task GIỮ | n-a (lý-do viết rõ) | — |
|
||||
| C2 | 2-đầu + 4-lớp-không-hạ | **n-a/vacuously-held** — mọi vai top-tier, không gì bị hạ | n-a (lý-do viết rõ) | — |
|
||||
| C3 | Điều-kiện xét-lại đo được | **ĐẠT** — viết ra engine §J.C: anh đảo H8 / cost-pressure → bracket + ≥3-run eval vs baseline | executed-file | convention |
|
||||
| D1 | Spot-check đúng-kết-quả tươi | **ĐẠT** — wired session-end §L.b(i) + dogfood n=1 (WF2-L3, 3 artifact). Caveat-1: n=1 = hiệu-chỉnh, CHƯA proven | executed-file + runtime n=1 | convention (người-soi) |
|
||||
| D2 | Tái-nạp-khi-trượt-thật | **ĐẠT (REUSE)** — H17 §I B2 reinject-ledger CG-1 (dựng TRƯỚC broadcast) | executed-file (S95) | convention (single-writer) |
|
||||
| D3 | Chốt-chặn-lặp | **ĐẠT (REUSE)** — CG-1 ≤1 lần/N=3 phiên + escalate anh + đo-lại phiên kế (`reinject-ledger.md`) | executed-file (S95) | convention |
|
||||
|
||||
**Tổng: 10/12 ĐẠT + 2/12 n-a-reasoned (C1/C2 — owner-mandate H8, caveat-2 broadcast cho phép khi chi-phí ngang nhau; SE = ngang-nhau-BY-DECISION + revisit-condition C3 đã viết).** Phát-biểu chủ-động: đã phủ đủ phần áp-được; KHÔNG nhận "12/12".
|
||||
|
||||
## 4 mục 🟡 (form tùy dự-án)
|
||||
|
||||
| 🟡 | SE form |
|
||||
|---|---|
|
||||
| Regex/ngưỡng detector | ratio-band 0.5–2.0 tự đặt; FP-guard `baseline\|S\d{2}` giữ (blind-spot có-chủ-đích, ghi engine §J.A) |
|
||||
| Ranh-giới bracket | theo H8 owner-mandate (không demote); escape-hatch per-task |
|
||||
| Nơi lưu sổ chốt-chặn | `reinject-ledger.md` git-tracked, TÁCH khỏi `memory-budget.json` (quyền anh) — đúng khuyến-nghị checklist |
|
||||
| Promote-list | n-a (all-inherit — không gì để nâng) |
|
||||
|
||||
## Mechanized-vs-convention tổng (đúng ghi-chú checklist)
|
||||
|
||||
Mechanized THẬT: A1-A3 detector + B3 sweep-grep. Convention: B1/B2 quyết-đo, C3 khai xét-lại, D1 người-soi, D2/D3 kỷ-luật single-writer. **KHÔNG nhận mechanized cho kỷ-luật.**
|
||||
@ -0,0 +1,28 @@
|
||||
# adap-report — 2026-07-02-Governance-harness-18-architecture-consolidation (SE)
|
||||
|
||||
> **Broadcast:** `2026-07-02-Governance-harness-18-architecture-consolidation.md` (outbox/all AI_INFRA). **Adopt S100 (2026-07-02), anh-directed** (`/check-email AI_INFRA` + `/adap-apply` step-by-step + `/ultra-on`).
|
||||
> **Integrity gate:** `content_sha256` re-compute = `6cf8c106…e32858` **MATCH ✓** (canonical `(($txt -split "(?m)^---\s*$",3)[2] -replace "^\r?\n","")` UTF-8 — cùng phép match 2/3 file đợt này). ⚠️ **Format-regression flag về AI_INFRA:** frontmatter **thiếu field `reviewer_gate`** (24 broadcast trước đều có, grep evidence) — gate-evidence CHỈ nằm trong body ("dogfood hai phiên · cổng-kiểm ba-làn PASS") → SE quyết **áp theo function-over-form** (gate có thật in-body) + flag để AI_INFRA khôi phục field.
|
||||
> **Harness-9 mandate 2-workflow:** WF1 investigate `wf_50a817ce-a69` (3 lane investigator-codebase, MODE-A return-delta, containment git-diff 0-residual + chunk 2431==2431) + WF2 review `<run-id + verdict điền SAU khi WF2 chạy thật — KHÔNG stamp trước>`.
|
||||
|
||||
## Nấc per-pattern (G-011: agreed / executed / verified)
|
||||
|
||||
| Pattern | Nấc | Evidence |
|
||||
|---|---|---|
|
||||
| **A — freshness-detector** (mismatch-only · scan-range · exclusion) | **runtime-VERIFIED** (mechanized) | `scripts/governance-detectors.ps1` 3 edit: ratio-band sev 0.5–2.0 (mismatch-only confidence — sửa `\|diff\|≥10=MED` NGƯỢC-lớp) + `$derivedDocs` fixed-list→glob động (ALL skills SKILL.md + ALL commands *.md — vá lớp-mù "(68)" sống ~11 phiên) + self-exclusion re-verified. **Fault-inject 4/4** (temp-tree `-RepoRoot`): stale "68 gotcha" trong commands/ → MED ✓ · kể-lại-đúng "79 gotcha" → IM ✓ · module-local "6 test" → LOW ✓ · anti-Goodhart "88 bảng" → MED ✓. Real-repo: MED derived-stale 11→**0** (8 FP demote LOW), coverage +7 file mới, 0 self-match, exit-0 |
|
||||
| **B — retire ledger trùng vai** (đo bắt-thật · nghỉ-hưu trung-thực · sweep consumers) | **executed** (đo=convention-với-số · sweep=mechanized-grep) | Đo (WF1-L3): ledger `runs/_ledger.md` true-orphan-catch **0/15 row lifetime** (đều open+close cùng-ngày 06-18, `⏳` chỉ legend) · folder/disk-scan H2 bắt thật 4+ memory-delta orphan (S57 · post-S57bis · S98×3 · S99#485) · mode-A coverage **0/8** workflow S93+. Freeze 🧊 1-dòng header `_ledger.md` (15 row GIỮ NGUYÊN, đảo-ngược=gỡ dòng). Sweep 15 điểm/8 file: `runs/README.md`×7 · `workflows/README.md`×2 · `session-start.md` §2.1.1 · `session-end.md` §L.b(f) · `agents/harvest-curator.md`×3 · `agents/README.md` G-015-cite · HC MEMORY baseline. Orphan-authority mới = folder-scan (`run.md` có mà `*-synthesis.md` VẮNG/0-byte). Grep dùng `_ledger` EXACT (repo có 5 "ledger" khác tên — tránh C3-fork) |
|
||||
| **C — bracket model-allocation** | **1/3 executed + 2/3 n-a-by-owner-mandate** | Precondition raw-economics ĐÚNG (Fable > Opus) NHƯNG **H8 all-inherit = owner-directive 🔴 S66 "chất-lượng trên chi-phí"** (anh-chốt mọi sister) → không demote; escape-hatch `tier:'opus'` per-task GIỮ. C3 revisit-condition **VIẾT RA** (engine §J.C): anh đảo H8 / cost-pressure thật → dựng bracket + ≥3-run eval vs baseline. Caveat-2 broadcast cho phép n-a khi chi-phí "ngang nhau" — SE = ngang-nhau-BY-DECISION |
|
||||
| **D — outcome-lane** (spot-check tươi · reinject · chốt-chặn) | **executed + dogfood n=1; D(b/c) REUSE-verified** | D(a) wired `session-end.md §L.b(i)` + **dogfood n=1 trong WF2-L3** (3 artifact đã-qua-cổng kiểm-lại tươi: H2 "0/14" đếm lại disk=14 ✓ · detector "0 self-match" re-grep ✓ · budget "measured" vs live-size ✓). D(b) reinject + D(c) chốt-chặn-lặp = **REUSE H17 §I B2** `reinject-ledger.md` CG-1 (≤1/N=3 + escalate anh) — dựng TRƯỚC broadcast, KHÔNG sổ mới |
|
||||
|
||||
## Tailored / Skip / Phản-biện (§F4 + §M)
|
||||
|
||||
- **Tailored:** ratio-band 0.5–2.0 = ngưỡng SE tự đặt (🟡 form — broadcast không ép số) · sweep giữ HISTORY-class nguyên vẹn (session-log/adap-report/archive/synthesis) · retirement marker song ngữ 🧊 + đảo-ngược 1-dòng.
|
||||
- **Honest caveat-3 parity (phản-biện với chính mình, ghi rõ):** run-folder-orphan **chưa từng xảy ra ở CẢ 2 cơ chế** (0 data 2 phía — "S71 harvest/ rỗng" hoá ra là wording tiêu-chí, KHÔNG phải vụ catch; WF1-L3 ground-truth đính chính claim ban đầu của chính em-main) → căn cứ retire = coverage-cấu-trúc + chi-phí duy-trì + đã cần disclaimer-note S98, **KHÔNG phải** "cái mới bắt tốt hơn". Nếu AI_INFRA đọc đây thấy parity không đủ điều kiện floor B → phản-hồi, SE gỡ 1 dòng là revert xong.
|
||||
- **Skip:** không có pattern nào skip-n-a toàn phần (C chỉ n-a 2/3 có lý-do).
|
||||
- **No-overclaim (G-015):** mechanized THẬT chỉ = detector J.A + sweep-grep J.B; đo-quyết B + spot-check D + kỷ-luật C = **convention**. Command/agent `.md` edits = **executed-file, runtime từ session KẾ** (no hot-reload — ⚠️ anh restart CLI).
|
||||
|
||||
## Codify + hậu-kiểm
|
||||
|
||||
- Engine: `docs/governance/harness-11-engine.md` **§J** (4 khuôn-mẫu + honest nấc + frontier self-audit verdicts).
|
||||
- Completeness-gate 12-sàn 🔴 → chi tiết `2026-07-02-Governance-checklist-harness-18.md` (report chị em): **10/12 ĐẠT + 2/12 n-a-reasoned**.
|
||||
- Containment: git-diff dirty-set == em-main edit-set (13 file, 0 residual sub-write) · Qdrant 2431==2431.
|
||||
- Email report → AI_INFRA (send-email kèm run-id + 2 flag: reviewer_gate-field-missing + frontier-hash-mismatch).
|
||||
@ -278,6 +278,40 @@ SE đã có RAG golden-set harness (KHÔNG phải gap): `eval/golden-set-solutio
|
||||
|
||||
---
|
||||
|
||||
## PHẦN J — Harness-18: Kiện-toàn kiến-trúc (4 khuôn-mẫu additive) + frontier-method self-audit (🔴 FUNCTION-FLOOR + 🟡 form)
|
||||
|
||||
> **Adopt S100 (2026-07-02)** — AI_INFRA broadcast `2026-07-02-Governance-{harness-18-architecture-consolidation, checklist-harness-18}` (content_sha256 re-compute **MATCH ✓ cả 2**; ⚠️ frontmatter cả 3 broadcast đợt này **thiếu field `reviewer_gate`** — 24 broadcast trước đều có; gate-evidence nằm trong body "dogfood 2 phiên · cổng-kiểm ba-làn PASS" → SE áp với reasoning ghi tường-minh + flag format-regression về AI_INFRA). Áp qua 2-workflow Harness-9: **WF1 investigate `wf_50a817ce-a69`** (3 lane investigator-codebase, return-delta MODE-A) + **WF2 review `wf_<điền-sau-WF2>`**. **Additive** — KHÔNG thay đợt nào trước. Broadcast chị-em `2026-07-01-…-harness-frontier-assessment`: **content_sha256 MISMATCH** khi re-compute (4 biến-thể canonicalization đều lệch; 2 file H18 MATCH → phép canonical đúng, body đã lệch stamp) → **HELD-integrity**: KHÔNG codify rule từ nó, CHỈ chạy self-audit vô-hại (kết quả dưới); chờ AI_INFRA verify/re-stamp.
|
||||
|
||||
**J.A — Freshness-detector nâng-cấp (3 sàn 🔴 — mechanized, fault-inject 4/4 + real-repo verified S100):**
|
||||
- **mismatch-only + ratio-band confidence:** `governance-detectors.ps1` C2 chỉ flag khi count-token LỆCH canonical (kể-lại-đúng = IM — fault-inject case-2); sev theo **ratio-band** — gần-canonical 0.5–2.0 = MED (stale-total khả-tín), xa = LOW (count cục-bộ-module) — sửa lớp FP cũ `|diff|≥10=MED` vốn NGƯỢC (S98 verify: 8/8 MED đều FP; post-fix real-repo: MED derived-stale 11→0, giữ 3 vocab-fork known).
|
||||
- **scan-range theo dải THẬT:** `$derivedDocs` fixed-list → **glob động** (ALL `.claude/skills/*/SKILL.md` + ALL `.claude/commands/*.md`) — vá lớp-mù commands/ nơi "(68)" sống ~11 phiên (H1 F3 S99).
|
||||
- **exclusion:** self-exclusion 6 path + `$ExcludeExact` (pre-existing, re-verified 0 self-match).
|
||||
- 🟡 Honest: FP-guard `baseline|S\d{2}` skip-line = blind-spot có-chủ-đích (dòng chứa "Baseline" KHÔNG quét — dòng "130 PASS" session-start đã B1-pointer TAY S100); sev = confidence KHÔNG phải existence (total-cổ-đại "77 test"/440 → LOW advisory vẫn hiện).
|
||||
|
||||
**J.B — Vệ-sinh sổ-ghi: retire `runs/_ledger.md` two-beat (🔴 đo-bắt-thật + nghỉ-hưu-trung-thực + sweep):**
|
||||
- **Đo (WF1-L3, evidence-grade):** ledger true-orphan-catch = **0/15 row lifetime** (đều open+close cùng-ngày 06-18; `⏳` chỉ legend) · folder/disk-scan H2 bắt thật **4+ vụ memory-delta orphan** (S57 · post-S57bis 4-MISS · S98 ×3 · S99 cicd#485) · mode-A ephemeral (default S93+) → ledger coverage workflow gần đây = **0/8**. ⭐ Đính-chính ground-truth: "S71 `harvest/` rỗng" = **wording tiêu-chí** trong session-start, KHÔNG phải vụ catch — run-folder-orphan lifetime = 0 ở CẢ 2 cơ chế.
|
||||
- **Caveat-3 parity (honest):** replacement KHÔNG "proven bắt tốt hơn" trên run-folder-orphan data (0 incident 2 phía) — căn cứ retire = **coverage-cấu-trúc (mode-A 0/8) + chi-phí duy-trì + đã cần disclaimer-note S98 chống nhầm**, KHÔNG phải catch-rate.
|
||||
- **Nghỉ-hưu:** 1 dòng 🧊 header `_ledger.md` (đảo-ngược = gỡ dòng; 15 row GIỮ NGUYÊN — dời-đi không xoá). **Orphan-authority = folder-scan:** `runs/<id>/` có `run.md` mà `*-synthesis.md` VẮNG/0-byte (dual-accept `harvest/` run cũ).
|
||||
- **Sweep 6 mandate-consumer + cites (mechanized-grep `_ledger` exact — 5 "ledger" khác tên trong repo, tránh C3-fork):** `runs/README.md` ×7 (:3/:38/L1/L2/§C6-header/:117/:127) · `workflows/README.md` ×2 (:20/:34-B3) · `session-start.md` §2.1.1-H2 · `session-end.md` §L.b(f) · `agents/harvest-curator.md` ×3 (:28/:44/:52-cite) · `agents/README.md` G-015-cite · + `agent-memory/harvest-curator/MEMORY.md` baseline re-ground. HISTORY class (session-log/adap-report/archive/runs-synthesis) GIỮ NGUYÊN.
|
||||
|
||||
**J.C — Bracket phân-bổ model: 1 ĐẠT + 2 n-a-by-owner-mandate (🔴 điều-kiện xét-lại VIẾT RA):**
|
||||
- Precondition raw-economics ĐÚNG (Fable > Opus 4.8 giá) NHƯNG **H8 all-inherit = owner-directive 🔴 S66 "chất-lượng trên chi-phí"** (anh-chốt, mọi sister) → KHÔNG demote lớp-việc nào; escape-hatch per-task `tier:'opus'` (hmw.js) GIỮ = cơ-chế hạ-bậc-theo-việc ĐÃ TỒN TẠI khi cần. 4 lớp không-hạ + 2-đầu = vacuously-held (mọi vai đang top-tier). Promote-list 🟡 = n-a (không gì để nâng).
|
||||
- **Điều-kiện xét-lại (C3-floor, viết ra — đo được):** NẾU anh đảo H8 HOẶC áp-lực chi-phí thật xuất hiện → dựng bracket theo checklist H18-C, so ≥3-run eval vs baseline TRƯỚC khi cố-định; tới lúc đó C1/C2 hết n-a. (Caveat-2 broadcast: "chi-phí ngang nhau thì khuôn-mẫu không áp" — SE = ngang-nhau-BY-DECISION.)
|
||||
|
||||
**J.D — Đóng làn kết-quả (🔴 3 sàn — 2 ĐẠT wired + 1 REUSE):**
|
||||
- **D(a) spot-check tươi:** wired `session-end §L.b(i)` — session governance/review-heavy chọn 3–5 artifact đã tự-qua-cổng → kiểm-lại tươi bằng ground-truth. Dogfood n=1 S100 (WF2 lane-3). 🟡 Honest: n=1 = mẫu hiệu-chỉnh (caveat-1 broadcast), CHƯA "proven".
|
||||
- **D(b) reinject-on-real-miss + D(c) chốt-chặn-lặp:** = **REUSE §I B2** `reinject-ledger.md` CG-1 (≤1/N=3 + escalate anh + đo-lại phiên kế) — H17 đã dựng ĐÚNG khuôn này TRƯỚC broadcast, KHÔNG sổ mới (chống C3-fork "ledger").
|
||||
|
||||
**Frontier-assessment self-audit (S100 — chạy dù broadcast HELD-integrity, vì self-audit vô-hại + có giá-trị riêng):**
|
||||
- **P1 taxonomy-claim:** CLEAN — grep `\bMAST\b` = 0 repo-wide; error-ledger "3-axis tag" = internal scheme map Gov-v2 (KHÔNG claim external-taxonomy) → ma-trận anh-xạ n-a-legit.
|
||||
- **P2 ghost-wire:** **1 THẬT = cron monthly** (`solution-erp-skill-audit-monthly`: CronList runtime = **0 job** + scheduler RỖNG 2026-05-04 + S96 chạy 13:04 em-main-in-session + CronCreate harness session-scoped không persist) → **honest-retire 5 file S100** (rules.md ×2 · CLAUDE.md · STATUS.md · session-start.md): audit monthly = thủ-công em-main theo cadence-pointer STATUS (function KHÔNG ghost — S44/S96 đều chạy đúng hạn; chỉ WIRING claim sai). +2 ghost-wire-config-key (mfe `role_file_glob`/`diary_path_pattern` defined-but-unread) + 1 latent blind-spot (selfimprove `:147` no-`tools:`-skip) → **defer đánh-số STATUS backlog D-1/D-2** (frontier HELD → không sửa vội). Cadence#4 + mọi auto-claim khác = WIRED hoặc disclaimed-no-daemon đúng convention G-015.
|
||||
- **P3 measurer role-coverage:** 3/3 script (`mfe-eval` + `memory-selfimprove-audit` + `memory-archive-gate`) = **GLOB-LIVE**, 0 hardcode roster/"11" — agent thứ 12 tự-cử (WF1-L1 file:line).
|
||||
- **P4 correction-cadence proxy:** ghi-nhận method, **KHÔNG áp** — 0 điểm-đau đo được hiện tại; áp-không-pain = chính "frontier-envy" mà broadcast cảnh-báo.
|
||||
|
||||
**Honest nấc tổng §J (checklist 12 sàn 🔴):** **A 3/3 ĐẠT** (mechanized + runtime fault-inject 4/4) · **B 3/3 ĐẠT** (đo = convention-với-số-liệu WF1-L3 · retire = executed-file reversible · sweep = mechanized-grep + executed 15 điểm) · **C 1/3 ĐẠT (C3 revisit-condition executed-file) + 2/3 n-a-by-owner-mandate H8** (lý-do khách-quan viết rõ — caveat-2 broadcast) · **D 3/3 ĐẠT** (D-a wired + dogfood n=1 · D-b/D-c REUSE §I CG-1). **Phát-biểu chủ-động: 10/12 ĐẠT + 2/12 n-a-reasoned = phủ đủ phần áp-được.** Mechanized THẬT chỉ: J.A detector + J.B sweep-grep; phần còn lại = convention (KHÔNG nhận mechanized). 🟡 form 4 mục: detector-regex/ngưỡng tự đặt (ratio 0.5–2.0) · bracket-boundary theo H8 · sổ chốt-chặn = reinject-ledger git-tracked (REUSE) · promote-list n-a.
|
||||
|
||||
---
|
||||
|
||||
## CAVEAT (trung-thực — đọc trước khi tự nhận "đã tự-bảo-trì")
|
||||
- **No-OS-hook:** detector + gate chạy TRONG thân session-start/end body do em-main kích — KHÔNG fully-autonomous. Đúng mức: **DÒ tự-động + toàn-diện; SỬA + GÁC dựa người-chủ-trì.**
|
||||
- **Auto-WRITE luật/copy = MỐI-NGUY #1, CỐ Ý CHƯA LÀM** — defer tới ≥2 sự-cố thật mà thủ-công thất-bại (hiện 0). Chọn nhánh chỉ-DÒ-NÊU-CỜ cho mọi thứ chạm luật/copy (1-sửa-sai → N-chỗ-sai + phá hash broadcast đóng-băng).
|
||||
|
||||
@ -289,7 +289,7 @@ Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
|
||||
|---|---|---|---|
|
||||
| **Cuối session** (đã làm tự động) | Update STATUS Recently Done + HANDOFF cảnh báo session tiếp | ~10 phút | Mỗi session có code commit |
|
||||
| **Cuối phase** (~1 tháng) | Compact STATUS Recently Done > 30 row → `changelog/recently-done-archive-{YYYY-MM}.md`. Collapse migration-todos Phase done thành 1 paragraph cross-ref session log | ~30 phút | Phase đóng |
|
||||
| **Đầu mỗi tháng** (cron `solution-erp-skill-audit-monthly`) | Audit skill + doc drift + count consistency. Patch stale qua Edit (KHÔNG rewrite). Log kết quả | ~45 phút | 9:00 ngày 1 mỗi tháng |
|
||||
| **Đầu mỗi tháng** (thủ-công em-main — 🧊 ghost-wire "cron fire 9:00" gỡ S100 H18/frontier-P2: CronList runtime = 0 job, cron session-scoped không persist) | Audit skill + doc drift + count consistency. Patch stale qua Edit (KHÔNG rewrite). Log kết quả | ~45 phút | Session đầu-tháng theo pointer next-date → `docs/STATUS.md` (canonical) |
|
||||
| **Khi trigger riêng** | Selective rewrite 1 file (skill drift > 30%, architecture redesign, phase major) | 1-2 giờ | Quantitative trigger |
|
||||
| **KHÔNG BAO GIỜ** | Rewrite toàn bộ docs | — | — |
|
||||
|
||||
@ -540,7 +540,7 @@ when-to-use:
|
||||
|
||||
### 9.4 Audit định kỳ — mỗi đầu tháng (chạy chung với doc audit §6.4)
|
||||
|
||||
**Cadence:** Đầu mỗi tháng, cron `solution-erp-skill-audit-monthly` fire 9:00 ngày 1 → chạy combined audit (skill + doc drift theo §6.4 checklist).
|
||||
**Cadence:** Đầu mỗi tháng, **em-main chạy thủ-công trong session đầu-tháng** (next-date → `docs/STATUS.md` canonical; 🧊 ghost-wire "cron `solution-erp-skill-audit-monthly` fire 9:00" gỡ S100 — CronList runtime = 0 job, audit S44/S96 thực-tế đều em-main chạy in-session đúng hạn) → chạy combined audit (skill + doc drift theo §6.4 checklist).
|
||||
|
||||
**Skill audit phần riêng (mỗi skill SKILL.md):**
|
||||
|
||||
|
||||
Reference in New Issue
Block a user