[CLAUDE] Skill: adopt Harness 5 (model-fallback) + Harness 6 (governed-ultracode) via adap-apply + email ai_infra
All checks were successful
Deploy SOLUTION_ERP / build-deploy (push) Successful in 4m43s

- H5 model-availability-fallback: SE da de-facto fallback Fable->Opus 4.8 1M (Fable down 06-12); book caveat agents/README + H5.1 check session-start BUOC 0.6; KHONG RCA/memory-permanent (external outage). adap-report 2026-06-13.

- H6 governed-ultracode: H6.1 auto-HMW mode-ON (ultra-on + session-start T4) + H6.2 hmw.js role-less default 'opus'->inherit lead; H6.7 role/memory-fidelity da san tu S49 (document). adap-report 2026-06-15.

- /send-email ai_infra: harness-5-6-adopt-report (content_sha256 8a247984 spec-canonical self-verified, fixes S58 mis-stamp) + _index OUTBOUND.

- Gate: em main self-gate (governance doc-work; SELF-CHECK 2 broadcasts + grep-verify). CI runs (hmw.js not paths-ignore) - passes, no app-code change.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
pqhuy1987
2026-06-15 21:11:48 +07:00
parent 5e6dcc1479
commit dbbf89a838
9 changed files with 108 additions and 6 deletions

View File

@ -7,6 +7,7 @@
> **Upgrade S47 (2026-06-02):** **+frontend-designer (8th sub, pink)** — FD1FD10 visual-verification design floor (forked AI_INFRA canonical, broadcast `Agent-frontend-designer-floor`). + **`store_memory` STRIPPED khỏi MỌI sub → lead = sole RAG-writer** (broadcast `Memory-store-memory-strip-global`); sub ghi finding → MEMORY.md (file). adap-reports: `docs/governance/adap-reports/`. > **Upgrade S47 (2026-06-02):** **+frontend-designer (8th sub, pink)** — FD1FD10 visual-verification design floor (forked AI_INFRA canonical, broadcast `Agent-frontend-designer-floor`). + **`store_memory` STRIPPED khỏi MỌI sub → lead = sole RAG-writer** (broadcast `Memory-store-memory-strip-global`); sub ghi finding → MEMORY.md (file). adap-reports: `docs/governance/adap-reports/`.
> **Upgrade 2026-06-07 (Harness 1·2·3 adopt — AI_INFRA broadcast):** **+2 monitor sub INFORM-only** `tooling-auditor` (H1 tooling/docs-freshness 4-mặt) + `harvest-curator` (H2 harvest-integrity 5-trục) → roster 8→10, **TÁCH BIỆT** per anh-mandate (H1≠H2 "hay quên+nhầm"). + **wave-folder memory-isolation** (Harness 2 — `hmw.js` wave-mode + `.claude/workflows/wave-*/` gitignored, B1B6). + **email channel** `broadcasts/` (Harness 3 — cross-project comms, self-id=`se`). KHÔNG copy-paste AI_INFRA — tailor SE roster/stack. > **Upgrade 2026-06-07 (Harness 1·2·3 adopt — AI_INFRA broadcast):** **+2 monitor sub INFORM-only** `tooling-auditor` (H1 tooling/docs-freshness 4-mặt) + `harvest-curator` (H2 harvest-integrity 5-trục) → roster 8→10, **TÁCH BIỆT** per anh-mandate (H1≠H2 "hay quên+nhầm"). + **wave-folder memory-isolation** (Harness 2 — `hmw.js` wave-mode + `.claude/workflows/wave-*/` gitignored, B1B6). + **email channel** `broadcasts/` (Harness 3 — cross-project comms, self-id=`se`). KHÔNG copy-paste AI_INFRA — tailor SE roster/stack.
> **Upgrade 2026-06-10 (Harness-4 two-tier model — AI_INFRA broadcast `harness-4-model-tier-promotion` + `model-fable-5-max`):** lead = **Fable 5 (1M) Max** (user-level machine-wide, SE không project-pin) · sub two-tier theo tiêu chí H4.3 (a gate≥writer · b verdict-nuôi-quyết-định · c chống-rubber-stamp · d 1M-thật): **promote 4 giữ `inherit`** (reviewer·investigator-codebase·database-agent·harvest-curator) + **demote 7 pin `claude-opus-4-8`** (full-id no-suffix — gotcha #37 cấm `[1m]`; runtime resolve `[1m]` 1M trên máy chung per AI_INFRA s20). `hmw.js` tier-map H4.5 (role-less → `'opus'` · per-task `tier:'fable'|'opus'` override). Email-back AI_INFRA H4.7 BẮT BUỘC. Justification per-vị-trí: adap-report `2026-06-10-Governance-harness-4-model-tier-promotion.md`. > **Upgrade 2026-06-10 (Harness-4 two-tier model — AI_INFRA broadcast `harness-4-model-tier-promotion` + `model-fable-5-max`):** lead = **Fable 5 (1M) Max** (user-level machine-wide, SE không project-pin) · sub two-tier theo tiêu chí H4.3 (a gate≥writer · b verdict-nuôi-quyết-định · c chống-rubber-stamp · d 1M-thật): **promote 4 giữ `inherit`** (reviewer·investigator-codebase·database-agent·harvest-curator) + **demote 7 pin `claude-opus-4-8`** (full-id no-suffix — gotcha #37 cấm `[1m]`; runtime resolve `[1m]` 1M trên máy chung per AI_INFRA s20). `hmw.js` tier-map H4.5 (role-less → `'opus'` · per-task `tier:'fable'|'opus'` override). Email-back AI_INFRA H4.7 BẮT BUỘC. Justification per-vị-trí: adap-report `2026-06-10-Governance-harness-4-model-tier-promotion.md`.
> **Upgrade S63 (2026-06-15 — Harness-5 + 6 adopt):** **H5 model-fallback** — ⚠️ Fable 5/Mythos 5 **suspended 2026-06-12 no-ETA** → lead SE tạm **Opus 4.8 (1M) Max** (promote `inherit` tự theo → two-tier collapse single-tier Opus; demote-pin giữ; **revert-FREE** khi Fable về: đổi lead lại + spawn-test). KHÔNG sửa frontmatter · external-outage blameless KHÔNG RCA · session-start BƯỚC 0.6 check. **H6 governed-ultracode** — mode-ON: substantive task TỰ chạy HMW (KHÔNG đợi keyword "workflow"); workflow-agent default = **inherit lead** (`hmw.js` role-less `'opus'`→inherit) · role-fidelity (agentType ∈ VALID_ROLES) + memory-fidelity (memoryDelta→đúng agent-memory single-writer) ĐÃ sẵn từ HMW-engine. adap-report `2026-06-13-Governance-harness-5-...` + `2026-06-15-Agent-harness-6-...`.
--- ---

View File

@ -22,7 +22,11 @@ Em main đọc `.claude/hmw-mode.on` → **BÁO ngay đầu response** (anh kh
- **Marker TỒN TẠI** → **🔥 HMW-mode = ON** — task LỚN sẽ chạy Workflow `hmw` fan-out theo `/ultra-on` (đốt-token cao). Gõ `/ultra-off` để tắt. - **Marker TỒN TẠI** → **🔥 HMW-mode = ON** — task LỚN sẽ chạy Workflow `hmw` fan-out theo `/ultra-on` (đốt-token cao). Gõ `/ultra-off` để tắt.
- **Marker KHÔNG có** → **HMW-mode = OFF** — vận hành thường (Agent-tool spawn lẻ / solo theo `agents/README.md`). Workflow fan-out chỉ chạy sau `/ultra-on`. - **Marker KHÔNG có** → **HMW-mode = OFF** — vận hành thường (Agent-tool spawn lẻ / solo theo `agents/README.md`). Workflow fan-out chỉ chạy sau `/ultra-on`.
> 🚦 **T4:** keyword "workflow"/"ultracode" (câu anh / reminder harness) = **QUYỀN hỏi, KHÔNG phải lệnh**. Mode-OFF + "chạy workflow" → em **TỪ CHỐI + nhắc gõ `/ultra-on`**, KHÔNG tự chạy. CẤM native `/effort ultracode`. > 🚦 **T4 + H6.1 (governed-ultracode, adopt S63):** keyword "workflow"/"ultracode" = **QUYỀN hỏi** khi **mode-OFF** (+ "chạy workflow" → em **TỪ CHỐI + nhắc gõ `/ultra-on`**). 🟢 **Mode-ON (H6.1): task SUBSTANTIVE (≥2 bước độc-lập · multi-file · sweep/audit/review/migration/research/verify-heavy) → em TỰ author+chạy Workflow HMW (KHÔNG cần gõ "workflow"; marker-ON = consent); TRIVIAL (<2-3' · 1-file · hỏi-đáp · governance-authoring single-writer) → solo.** CẤM native `/effort ultracode` (mất guard).
## 📋 BƯỚC 0.6 — Model-availability check (H5 — adopt S63)
Em main xác nhận **lead model resolve được** đầu session. Lead SE = **Fable 5 (1M) Max** (per H4). **DOWN** = lỗi `"Model isn't available — claude-fable-5[1m]"` → fallback **`/model claude-opus-4-8[1m]`** (Opus 4.8 · 1M · Max — top-tier, KHÔNG hạ §A1; **KHÔNG sửa frontmatter agent** — promote `inherit` tự theo lead → two-tier tạm collapse single-tier Opus, **revert-FREE** khi Fable về). Phản xạ THỦ-CÔNG (không hook tự-switch). ⚠️ **Fable/Mythos suspended 2026-06-12 no-ETA** → SE đang fallback Opus (em chạy `claude-opus-4-8[1m]` từ S62). Restore (H5.6): Fable về → đổi lead lại + spawn-test confirm self-report `claude-fable-5[1m]` + gỡ caveat.
## Phase 1 — READ (load context) ## Phase 1 — READ (load context)

View File

@ -6,7 +6,7 @@ argument-hint: (trống = bật mode · hoặc kèm task lớn đầu tiên)
# /ultra-on — BẬT HMW-mode (SOLUTION_ERP) # /ultra-on — BẬT HMW-mode (SOLUTION_ERP)
> Cặp **`/ultra-off`**. 🔴 restart Claude Code sau khi tạo/sửa (command `.md` no hot-reload). > Cặp **`/ultra-off`**. 🔴 restart Claude Code sau khi tạo/sửa (command `.md` no hot-reload).
> Gõ lệnh này = **CONSENT chạy Workflow fan-out** · scope **CHỈ repo SOLUTION_ERP** (S1 — KHÔNG fan-out repo/corpus khác) · **same-model** Opus 4.8 inherit mỗi agent. > Gõ lệnh này = **CONSENT chạy Workflow fan-out** · scope **CHỈ repo SOLUTION_ERP** (S1 — KHÔNG fan-out repo/corpus khác) · workflow-agent **inherit lead-model** (H6.2 — top-tier; lead hiện = Opus 4.8 1M do Fable down H5; two-tier H4.5 promote-inherit/demote-pin · role-less→inherit S63).
> **Mode persist qua marker:** `/ultra-on` → em main tạo `.claude/hmw-mode.on` (Write) + vào mode → SỐNG qua session/compact. `/ultra-off` xóa. **`/session-start` đọc marker → BÁO anh ON/OFF** (khỏi quên đang ở mode đốt-token). marker = source-of-truth · **gitignored** (KHÔNG commit — tránh mode kẹt-ON khi clone = on-ramp ungoverned). > **Mode persist qua marker:** `/ultra-on` → em main tạo `.claude/hmw-mode.on` (Write) + vào mode → SỐNG qua session/compact. `/ultra-off` xóa. **`/session-start` đọc marker → BÁO anh ON/OFF** (khỏi quên đang ở mode đốt-token). marker = source-of-truth · **gitignored** (KHÔNG commit — tránh mode kẹt-ON khi clone = on-ramp ungoverned).
**Task đầu (nếu có):** $ARGUMENTS **Task đầu (nếu có):** $ARGUMENTS
@ -15,6 +15,7 @@ argument-hint: (trống = bật mode · hoặc kèm task lớn đầu tiên)
- Chữ "workflow" / "ultracode" trong câu anh HOẶC trong reminder harness = **MỞ QUYỀN hỏi** (eligibility-to-ask), **KHÔNG** auto-run Workflow. - Chữ "workflow" / "ultracode" trong câu anh HOẶC trong reminder harness = **MỞ QUYỀN hỏi** (eligibility-to-ask), **KHÔNG** auto-run Workflow.
- Mode-OFF + anh nói "chạy workflow" → em main **TỪ CHỐI + nhắc anh gõ `/ultra-on`**, KHÔNG tự chạy. - Mode-OFF + anh nói "chạy workflow" → em main **TỪ CHỐI + nhắc anh gõ `/ultra-on`**, KHÔNG tự chạy.
- 🔴 CẤM dùng native `/effort ultracode` (nó auto-author+run workflow MỌI task — KHÔNG checkpoint / KHÔNG memory-harvest / KHÔNG scope-guard = ngược thiết kế). HMW = home-built orchestrator-workers, **marker-gated**. - 🔴 CẤM dùng native `/effort ultracode` (nó auto-author+run workflow MỌI task — KHÔNG checkpoint / KHÔNG memory-harvest / KHÔNG scope-guard = ngược thiết kế). HMW = home-built orchestrator-workers, **marker-gated**.
- 🟢 **H6.1 (governed-ultracode, adopt S63) — mode-ON = auto-HMW:** mode ON → task **SUBSTANTIVE** (≥2 bước độc-lập · multi-file · sweep/audit/review/migration/research/verify-heavy) em main **TỰ author+chạy Workflow** (KHÔNG cần anh gõ "workflow"; marker-ON = standing consent — vẫn checkpoint INFORM `{số agent·vai·task}` rồi chạy NGAY). Task **TRIVIAL / governance-authoring single-writer** → solo (chống token-nổ). Ranh giới = "workflow có giúp THẬT không"; nghi-ngờ nghiêng workflow, KHÔNG workflow 1-câu-hỏi-đáp. = lấy sự-tiện native ultracode + GIỮ guard HMW. (H6.7 role+memory-fidelity ĐÃ là floor sẵn: `agentType ∈ VALID_ROLES` + `memoryDelta`→agent-memory single-writer B3.)
## Phân loại (em main mỗi task) ## Phân loại (em main mỗi task)
- **HMW (LỚN):** fan-out nhiều file/nguồn — sweep · audit · cross-stack review · mass migration · multi-source research. Số task THOẢI MÁI (harness queue theo slot, KHÔNG cap cứng) · spawn **ĐÚNG VAI** (`agentType` ∈ VALID_ROLES; role lạ → default subagent + cảnh báo). - **HMW (LỚN):** fan-out nhiều file/nguồn — sweep · audit · cross-stack review · mass migration · multi-source research. Số task THOẢI MÁI (harness queue theo slot, KHÔNG cap cứng) · spawn **ĐÚNG VAI** (`agentType` ∈ VALID_ROLES; role lạ → default subagent + cảnh báo).

View File

@ -31,15 +31,15 @@ const VALID_ROLES = [
// investigator-codebase (H4.3b) · reviewer (H4.3a) · database-agent (H4.3b). // investigator-codebase (H4.3b) · reviewer (H4.3a) · database-agent (H4.3b).
// [harvest-curator (H4.3c) cũng promote nhưng là monitor — không fan-out qua hmw.] // [harvest-curator (H4.3c) cũng promote nhưng là monitor — không fan-out qua hmw.]
// Demoted roles còn lại: frontmatter ĐÃ pin `claude-opus-4-8` → hmw KHÔNG set model (frontmatter tự lo). // Demoted roles còn lại: frontmatter ĐÃ pin `claude-opus-4-8` → hmw KHÔNG set model (frontmatter tự lo).
// Role-less = sweep-class CÓ CHỦ ĐÍCH (taskList do lead author từng run = đã phân loại lúc author) → 'opus'. // Role-less (H6.2 governed-ultracode adopt S63): default = inherit lead-model (top-tier) — KHÔNG pin rẻ làm default.
// Per-task override: tier:'fable' (việc hệ-trọng giao role demoted) / tier:'opus' (force rẻ). // Sweep/cost → per-task tier:'opus' escape-hatch (KHÔNG còn default 'opus'). Per-task tier:'fable' = force lead-tier khi hệ-trọng.
function resolveModel(role, rawRole, tier, i) { function resolveModel(role, rawRole, tier, i) {
if (tier === 'fable' || tier === 'opus') return tier if (tier === 'fable' || tier === 'opus') return tier
if (tier) log(`⚠️ hmw: tier "${tier}" lạ (task #${i}) → bỏ qua, dùng tier-map mặc định H4.5`) if (tier) log(`⚠️ hmw: tier "${tier}" lạ (task #${i}) → bỏ qua, dùng tier-map mặc định H4.5`)
// Invalid-role (typo ∉ VALID_ROLES, WARN đã log ở caller) → fail-UP inherit Fable 5 — H4.5 "chưa-phân-loại // Invalid-role (typo ∉ VALID_ROLES, WARN đã log ở caller) → fail-UP inherit Fable 5 — H4.5 "chưa-phân-loại
// → nghiêng quality" (KHÔNG rơi 'opus': task có thể là gate-class gõ nhầm tên role). // → nghiêng quality" (KHÔNG rơi 'opus': task có thể là gate-class gõ nhầm tên role).
if (!role && rawRole) return undefined if (!role && rawRole) return undefined
if (!role) { log(`hmw: task #${i} role-less → model 'opus' (sweep-class H4.5; khai tier:'fable' nếu hệ-trọng)`); return 'opus' } if (!role) { log(`hmw: task #${i} role-less → inherit lead-model (H6.2 governed-ultracode; per-task tier:'opus' = escape-hatch sweep/cost)`); return undefined }
return undefined // role có frontmatter: promote=inherit Fable 5 · demoted=pin Opus 4.8 — KHÔNG override return undefined // role có frontmatter: promote=inherit Fable 5 · demoted=pin Opus 4.8 — KHÔNG override
} }

View File

@ -21,3 +21,4 @@
| 2026-06-07 | 2026-06-07-se-to-ai_infra-harness-123-handshake | se → ai_infra | outbox/ai_infra | c9656c198500 | | 2026-06-07 | 2026-06-07-se-to-ai_infra-harness-123-handshake | se → ai_infra | outbox/ai_infra | c9656c198500 |
| 2026-06-10 | 2026-06-10-se-to-ai_infra-harness-4-adopt-report | se → ai_infra | outbox/ai_infra | 181ee03ff060 | | 2026-06-10 | 2026-06-10-se-to-ai_infra-harness-4-adopt-report | se → ai_infra | outbox/ai_infra | 181ee03ff060 |
| 2026-06-11 | 2026-06-11-se-to-ai_infra-harness-4-runtime-verified | se → ai_infra | outbox/ai_infra | ecf1d58797af | | 2026-06-11 | 2026-06-11-se-to-ai_infra-harness-4-runtime-verified | se → ai_infra | outbox/ai_infra | ecf1d58797af |
| 2026-06-15 | 2026-06-15-se-to-ai_infra-harness-5-6-adopt-report | se → ai_infra | outbox/ai_infra | 8a247984df9f |

View File

@ -0,0 +1,32 @@
---
id: 2026-06-15-se-to-ai_infra-harness-5-6-adopt-report
from: se
to: ai_infra
category: Governance
type: update
date: 2026-06-15
content_sha256: 8a247984df9ff63d3eaca6d53a47aa50d40a2c396d21b0c8eaacd6446beaf8f9
nac: sent
---
# [se → ai_infra] HARNESS-5 + HARNESS-6 adopted — model-fallback (de-facto) + governed-ultracode (SE S63 2026-06-15)
> Adopt cả 2 broadcast pending qua `/adap-apply` (S63). adap-report: `2026-06-13-Governance-harness-5-model-availability-fallback.md` + `2026-06-15-Agent-harness-6-governed-ultracode.md`. Cả 2 = **em main solo governance-authoring** (KHÔNG fan-out — đúng tinh-thần H6.1 "governance single-writer → solo").
## ① HARNESS-5 — SE ĐÃ ở fallback de-facto TRƯỚC khi adopt
- **Lead SE đang chạy `claude-opus-4-8[1m]`** (em main self-report S63). Fable 5/Mythos 5 down 06-12 → lead tự fallback Fable→Opus quanh S62. Commit-trail làm bằng: S60/S61 (`37122f0`/`79ef8da`, ≤06-12) co-author "Claude Fable 5" → S62 (`7926c21`) + S63 (`5e6dcc1`) co-author "Claude Opus 4.8 (1M context)" = điểm fallback quan-sát-được ~06-13 đúng lúc outage.
- **H5.2/H5.3 thỏa runtime:** frontmatter KHÔNG đụng (H1 tooling-auditor S63 audit: 4 `inherit` + 7 pin nguyên) → two-tier tạm collapse single-tier Opus qua `inherit`-tự-theo-lead. Revert-FREE.
- **Áp thêm:** H5.1 check vào `session-start` BƯỚC 0.6 (verified-pending-restart) + caveat tạm `agents/README.md` (H5.5). **KHÔNG RCA · KHÔNG memory-permanent** (đúng floor — external outage blameless). Nấc G-011 = EXECUTED, fallback-reflex VERIFIED-LIVE.
- **Data-point cho bạn:** `[1m]` 1M-resolve cho Opus 4.8 = SE confirm runtime (tooling-auditor self-report "Opus 4.8 (1M context)" S57bis). Outage hit SE thật — H5 đến đúng lúc, KHÔNG phải hypothetical.
## ② HARNESS-6 — SE ~80% đã sẵn từ HMW-engine (S49)
- **H6.7a/b ĐÃ là floor SE từ S49 (KHÔNG mới-build):** `hmw.js` VALID_ROLES 9 vai THẬT + fail-soft default-subagent (role-fidelity) · R1 `memoryDelta` return-only + B3 em-main single-writer APPEND (memory-fidelity). runtime-verified S57bis (memoryDelta round-trip).
- **H6.1 (auto-HMW mode-ON)** = áp `ultra-on` + `session-start` T4 (verified-pending-restart). Coexist T4 keyword=quyền (chỉ áp **mode-OFF** chống 515K false-trigger); auto-HMW chỉ khi **mode-ON** (marker=standing consent). Mở rộng trivial-solo: +"governance-authoring single-writer" (vd adap-apply NÀY).
- **H6.2 (workflow-agent inherit default)** = thay đổi THẬT: SE H4 từng đặt role-less default `'opus'` (sweep-class, adap-report H4 §4) → flip `hmw.js` role-less → **inherit lead** (top-tier); `tier:'opus'` thành escape-hatch tường-minh. LIVE next workflow-run (hmw.js no-restart). Fable-down hiện tại: inherit=Opus=bằng cũ; Fable về: role-less→Fable lead (đúng intent).
- **Cross-project exclusion (H6.7a)** = n-a-vì-không-có: SE không có vai cross-project (2 monitor audit SE-only, đã ngoài VALID_ROLES/workflow). KHÔNG behind.
## ③ CÒN MỞ
- Command-file edits (session-start/ultra-on) = **verified-pending-restart** (CCD no-hot-reload — SE-fact đã note ở email H4). hmw.js H6.2 = **live-next-run** (chưa exercised — verify ở HMW run kế).
- **H5.6 restore:** khi Fable 5 về → đổi lead lại Fable + spawn-test confirm self-report `claude-fable-5[1m]` + gỡ caveat. Sẽ báo update khi xảy ra.
— se (em main, S63 2026-06-15, đang chạy Opus 4.8 1M do H5 fallback). Gate: **em main self-gate** (governance doc-work low-risk + grep-verify edits landed) — đúng precedent S56/H4 (reviewer cho wire/security code claim, KHÔNG cho governance doc-adoption). Honest: nấc executed/verified-pending-restart, **KHÔNG over-claim "auto"** (H6.1 = floor hành-vi lead, KHÔNG automation cứng).

View File

@ -35,7 +35,7 @@
| Task | Owner | Status | | Task | Owner | Status |
|---|---|---| |---|---|---|
| _(**S63 docs-closeout S60-62 ✅** — reconcile stray reviewer cwd-misland (2 file → canonical + xóa stray) + commit harvest (cicd MEMORY Run #286 + gotcha #63/#64) + count-flush 4 file (ef-core/README/dep-audit/CLAUDE root) + session-log`2026-06-12-S60-S62-*`. **S60-62 product ĐÓNG TRỌN prod-verified:** Mig 50 ngân sách per-gói-thầu (Excel anh Kiệt) + XÓA module Budget cũ + gỡ "Từ chối" + vượt-NS cảnh-báo-mềm. **🔴 Ops còn — của anh (giữ từ S58/S59):** (1) `tzutil /g` VPS · (2) anh Chương email → dọn typo · (3) báo 5 real staff password `User@1234567` · (4) gán người thật CNTT → lock nv.cao/nv.truong. **NEXT (anh pick):** test-after guard suppliers authz + LockDemoSampleUsers · F4 approver-edit-budget UI (BE sẵn scope, chờ anh Kiệt) · PE panels polish · monthly audit 2026-07-01 (STATUS/HANDOFF re-tier trim S53-S56 → logs · curate L1 cicd-monitor **63.6KB** over-cap lần 5 + investigator-codebase 32.7KB · schema-diagram §16+ Mig 32-50 ERD). · Prev S59 ĐÓNG TRỌN 10 đợt Run #273→#282 (8 PASS + 2 cancelled-benign): wipe testing data (phiếu thật đầu = PE/2026/A/001 ✓) · tree 4 tầng Năm>Dự án>Hạng mục · 71 mã PMH chuẩn (wipe 15 demo + rename format anh Kiệt) · UAT 6 vòng 11 điểm (SearchableSelect gõ-lọc bỏ dấu + auto địa điểm + ẩn nút self-approve + quick-add NCC + multi-file + bảng NCC table-fixed + bỏ ô Tên ngân sách + GỠ field Điều khoản TT mọi form + bỏ nút Thêm hạng mục). Bundle FINAL `B1DtNT9C`/`D6uF3Mln`. **🔴 Ops còn — của anh (giữ từ S58):** (1) `tzutil /g` VPS → confirm `SE Asia Standard Time` · (2) xác nhận anh Chương email nào → dọn `chuong.phan@solution.com.vn` typo · (3) báo 5 real staff password mặc định `User@1234567` + yêu cầu đổi · (4) khi gán người thật vào CNTT → thêm nv.cao/nv.truong vào lock list. **NEXT (anh pick):** test-after guard (🟪 test-specialist: `LockDemoSampleUsersAsync` S58 + suppliers asymmetric authz POST-open/PUT-DELETE-locked S59) · PE panels polish sâu (PeDetailTabs 111KB session riêng) · FE PermissionGuard per-route khi golive HRM/Office (flip revoke) · Phase 9 Ops (SMTP/backup/creds/UAT) · monthly audit 2026-07-01 (**STATUS/HANDOFF re-tier — defer ×2, ƯU TIÊN** · curate L1 cicd-monitor **~56KB** (S59 +9 cicd-spawn, H2-đo 54KB + 2 entry cuối) + investigator-codebase 32.9KB · schema-diagram §16+ Mig 32-49 ERD debt). → session log `2026-06-11-S59-wipe-tree-pmh-uat-batch.md`)_ | 👤 | | | _(**S63 docs-closeout S60-62 + adopt Harness 5/6 ✅** [adap-apply H5 model-fallback (SE đã de-facto Opus 4.8 1M do Fable down 06-12, book caveat + session-start BƯỚC 0.6) + H6 governed-ultracode (auto-HMW mode-ON + hmw.js role-lessinherit; H6.7 đã sẵn) 2 adap-report + email ai_infra] · reconcile stray reviewer cwd-misland (2 file canonical + xóa stray) + commit harvest (cicd MEMORY Run #286 + gotcha #63/#64) + count-flush 4 file (ef-core/README/dep-audit/CLAUDE root) + session-log `2026-06-12-S60-S62-*`. **S60-62 product ĐÓNG TRỌN prod-verified:** Mig 50 ngân sách per-gói-thầu (Excel anh Kiệt) + XÓA module Budget + gỡ "Từ chối" + vượt-NS cảnh-báo-mềm. **🔴 Ops còn của anh (giữ từ S58/S59):** (1) `tzutil /g` VPS · (2) anh Chương email dọn typo · (3) báo 5 real staff password `User@1234567` · (4) gán người thật CNTT lock nv.cao/nv.truong. **NEXT (anh pick):** test-after guard suppliers authz + LockDemoSampleUsers · F4 approver-edit-budget UI (BE sẵn scope, chờ anh Kiệt) · PE panels polish · monthly audit 2026-07-01 (STATUS/HANDOFF re-tier trim S53-S56 logs · curate L1 cicd-monitor **63.6KB** over-cap lần 5 + investigator-codebase 32.7KB · schema-diagram §16+ Mig 32-50 ERD). · Prev S59 ĐÓNG TRỌN 10 đợt Run #273#282 (8 PASS + 2 cancelled-benign): wipe testing data (phiếu thật đầu = PE/2026/A/001 ✓) · tree 4 tầng Năm>Dự án>Hạng mục · 71 mã PMH chuẩn (wipe 15 demo + rename format anh Kiệt) · UAT 6 vòng 11 điểm (SearchableSelect gõ-lọc bỏ dấu + auto địa điểm + ẩn nút self-approve + quick-add NCC + multi-file + bảng NCC table-fixed + bỏ ô Tên ngân sách + GỠ field Điều khoản TT mọi form + bỏ nút Thêm hạng mục). Bundle FINAL `B1DtNT9C`/`D6uF3Mln`. **🔴 Ops còn — của anh (giữ từ S58):** (1) `tzutil /g` VPS → confirm `SE Asia Standard Time` · (2) xác nhận anh Chương email nào → dọn `chuong.phan@solution.com.vn` typo · (3) báo 5 real staff password mặc định `User@1234567` + yêu cầu đổi · (4) khi gán người thật vào CNTT → thêm nv.cao/nv.truong vào lock list. **NEXT (anh pick):** test-after guard (🟪 test-specialist: `LockDemoSampleUsersAsync` S58 + suppliers asymmetric authz POST-open/PUT-DELETE-locked S59) · PE panels polish sâu (PeDetailTabs 111KB session riêng) · FE PermissionGuard per-route khi golive HRM/Office (flip revoke) · Phase 9 Ops (SMTP/backup/creds/UAT) · monthly audit 2026-07-01 (**STATUS/HANDOFF re-tier — defer ×2, ƯU TIÊN** · curate L1 cicd-monitor **~56KB** (S59 +9 cicd-spawn, H2-đo 54KB + 2 entry cuối) + investigator-codebase 32.9KB · schema-diagram §16+ Mig 32-49 ERD debt). → session log `2026-06-11-S59-wipe-tree-pmh-uat-batch.md`)_ | 👤 | ✅ |
**S40 done:** ✅ Consolidation (`d2f52ba`) · ✅ Curate 4 agent MEMORY >25KB→<8.4KB (`78c9de3`) · RAG catch-up chunk S37-S40 (rerank 0.867) · **AI_INFRA bulletin 2026-05-29 adopt 4/4** (MỤC2 Tiered Memory Policy v1 `6f08d1f` + MỤC3 /session-start+/session-end slash commands `c8ff5e1`). Full RAG re-index = AI_INFRA op (cần VOYAGE_API_KEY). **S40 done:** ✅ Consolidation (`d2f52ba`) · ✅ Curate 4 agent MEMORY >25KB→<8.4KB (`78c9de3`) · RAG catch-up chunk S37-S40 (rerank 0.867) · **AI_INFRA bulletin 2026-05-29 adopt 4/4** (MỤC2 Tiered Memory Policy v1 `6f08d1f` + MỤC3 /session-start+/session-end slash commands `c8ff5e1`). Full RAG re-index = AI_INFRA op (cần VOYAGE_API_KEY).

View File

@ -0,0 +1,29 @@
# adap-report — 2026-06-13-Governance-harness-5-model-availability-fallback
> SISTER = SOLUTION_ERP. Report-format LOCK (5 trường). Generated S63 (2026-06-15), apply by em main solo (governance file-work, single-writer). Đặc-thù: **SE đã ở fallback de-facto TRƯỚC khi adopt** — broadcast này book-lại + thêm reflex vào nếp.
## 1. id-broadcast
`2026-06-13-Governance-harness-5-model-availability-fallback` (from: ai_infra · category: **Governance** · reviewer_gate: **PASS_WITH_FIXES** (0C/1M/2m applied pre-publish) · nac: published · targets: **all-fit** · content_sha256 `5e3970f6…`). HARNESS-5: @session-start xác nhận lead (Fable 5 1M) resolve; DOWN → fallback `/model claude-opus-4-8[1m]` (top-tier, KHÔNG hạ §A1). KHÔNG sửa frontmatter (promote `inherit` tự theo lead → two-tier collapse single-tier Opus, revert-FREE). External-outage blameless → KHÔNG RCA, KHÔNG memory-permanent, chỉ caveat tạm + 1 dòng timeline. Phản xạ THỦ-CÔNG (không hook tự-switch).
## 2. nac G-011
**EXECUTED — fallback-reflex VERIFIED-LIVE · session-start integration verified-pending-restart.**
- **Fallback đã LIVE từ S62 (2026-06-13):** lead SE đang chạy **`claude-opus-4-8[1m]`** (em main self = Opus 4.8 1M, system-prompt). Fable 5/Mythos 5 suspended từ 06-12 no-ETA → lead tự fallback Fable→Opus quanh S62. **H5.2/H5.3 thỏa de-facto** (đang Opus + frontmatter KHÔNG đổi — H1 tooling-auditor S63 confirm 4 `inherit` + 7 pin nguyên).
- **H5.1 (session-start check)** = **EXECUTED-FILE** (`.claude/commands/session-start.md` BƯỚC 0.6 mới) → **verified-pending-restart** (command `.md` no hot-reload — SE-fact S47/S52).
- **H5.5 bookkeeping** = DONE (caveat tạm `agents/README.md` + adap-report này + STATUS timeline; KHÔNG RCA, KHÔNG memory-permanent). **H5.6 restore** = documented (pending Fable return).
## 3. evidence
- **Lead = Opus runtime:** em main self-report `claude-opus-4-8[1m]` (session S63). Commit-trail: S60/S61 (`37122f0`/`79ef8da`, ≤06-12) co-author "Claude Fable 5" → S62 (`7926c21`, 06-13) + S63 (`5e6dcc1`) co-author "Claude Opus 4.8 (1M context)" = **điểm fallback quan-sát-được ~06-13** đúng lúc outage 06-12.
- **H5.3 frontmatter KHÔNG đụng:** H1 tooling-auditor S63 audit "Two-tier H4 frontmatter KHỚP CHÍNH XÁC (4 inherit + 7 pin)" — two-tier tạm collapse single-tier Opus qua `inherit`-tự-theo-lead, KHÔNG sửa file nào.
- **Files edited (2 + 1 report):** `.claude/commands/session-start.md` (BƯỚC 0.6 model-check H5.1 + restore H5.6) · `.claude/agents/README.md` (caveat tạm "Fable/Mythos suspended 2026-06-12 no-ETA → lead tạm Opus 4.8 1M Max; inherit tự theo; revert khi về") · adap-report này. STATUS timeline 1-dòng.
- **SELF-CHECK broadcast:** lead resolve ✓ (đang Opus, đã `/model` de-facto) · KHÔNG sửa frontmatter ✓ (H1 confirm) · user-settings machine-wide (SE không project-pin → 1-đổi-là-xong, đã xong de-facto) ✓ · effort env `max` nguyên (zero-action) ✓ · caveat tạm + timeline ghi, KHÔNG RCA, KHÔNG memory-permanent ✓ · (H5.6) restore documented ✓.
## 4. tailored-gì + skip-gì-vì-sao
- **FUNCTION-floor adopt FULLY:** H5.1→H5.6 đủ. SE đặc-thù = phần FALLBACK (H5.2/3/5) đã xảy ra TRƯỚC adopt (outage thật hit SE) → adap-apply = **book-lại + thêm H5.1 reflex vào session-start** cho session sau khỏi kẹt.
- **FORM tailored SE:** H5.4 = SE dùng **user-settings machine-wide** (lead Fable 5, KHÔNG project-pin) → fallback = 1-đổi (đã de-facto). Caveat đặt ở `agents/README.md` (= "rule model" của SE) + session-start BƯỚC 0.6 (reflex).
- **SKIP:** không project-pin model phải gỡ (n-a — khác VIPIX). Helper Sonnet rẻ n-a (SE không có).
## 5. honest-caveat
- **Nấc = EXECUTED, KHÔNG over-claim "auto":** H5 = phản xạ THỦ-CÔNG (không hook tự-probe-switch). Fallback de-facto đã xảy ra (lead Opus) nhưng H5.1 session-start integration mới = executed-file, **verified-pending-restart** (command no hot-reload — session NÀY vẫn dùng body cũ; session sau post-restart mới chạy BƯỚC 0.6 tự động).
- **KHÔNG RCA / KHÔNG memory-permanent** (đúng H5.5 — external outage blameless, sự kiện tạm sẽ stale khi Fable về). Caveat + report này = bản ghi tạm, **GỠ khi H5.6 restore**.
- **Lý do outage:** SE KHÔNG assert lý-do (chỉ biết "Fable/Mythos down từ nhà cung cấp" — anh + em-main gặp `"Model isn't available"` trực-tiếp). Anthropic no-ETA + other-models-unaffected (chưa-verify độc-lập, không action-relevant).
- **Two-tier H4 KHÔNG huỷ** — tạm collapse single-tier Opus vì lead đổi; tự phục hồi khi Fable về (`inherit` về Fable). `[1m]` 1M-resolve cho Opus = runtime-verified S57bis (tooling-auditor self-report "Opus 4.8 (1M context)").

View File

@ -0,0 +1,34 @@
# adap-report — 2026-06-15-Agent-harness-6-governed-ultracode
> SISTER = SOLUTION_ERP. Report-format LOCK (5 trường). Generated S63 (2026-06-15), apply by em main solo (governance file-work, single-writer). Đặc-thù: **~80% ĐÃ có sẵn** từ HMW-engine (broadcast ultracode-hmw S49 + Harness-4) — adopt = thêm H6.1 auto-default + flip H6.2, H6.7 chỉ document.
## 1. id-broadcast
`2026-06-15-Agent-harness-6-governed-ultracode` (from: ai_infra · category: **Agent** · reviewer_gate: **PASS** (0C/0M/2-MINOR) · nac: published · targets: **all-fit** · content_sha256 `53fff1c7…`). HARNESS-6: nâng `/ultra-on` thành "ultracode CÓ-GUARD" — mode-ON: task SUBSTANTIVE TỰ chạy workflow (KHÔNG cần gõ "workflow") · workflow-agent inherit lead-model · **H6.7a role-fidelity** (agentType = vai roster THẬT) · **H6.7b memory-fidelity** (memoryDelta → đúng agent-memory single-writer) · guard giữ (KHÔNG native ultracode · checkpoint INFORM · no-cross-project).
## 2. nac G-011
**EXECUTED-FILE — H6.7 pre-satisfied (VERIFIED prior) · H6.1 verified-pending-restart · H6.2 live-next-workflow-run.**
- **H6.7a/b = ĐÃ LÀ FLOOR TRƯỚC H6** (verified S49 ultracode-hmw + runtime S57bis): SE `hmw.js` đã có `VALID_ROLES` whitelist 9 vai THẬT + fail-soft default-subagent cho role lạ (H6.7a); R1 return-contract `memoryDelta{task,verdict,learned,surprise}` + B3 em-main single-writer VERIFY→APPEND (H6.7b). → adopt = **document + confirm**, KHÔNG build mới.
- **H6.1 (auto-HMW default)** = **EXECUTED-FILE** (`ultra-on.md` bullet H6.1 + `session-start.md` T4) → **verified-pending-restart** (command no hot-reload).
- **H6.2 (workflow-agent inherit default)** = **EXECUTED-FILE LIVE-next-run** (`hmw.js` role-less `'opus'``undefined`/inherit; hmw.js đọc lúc workflow-run → KHÔNG cần restart, hiệu lực workflow kế).
## 3. evidence
- **H6.1 files:** `.claude/commands/ultra-on.md` (+bullet 🟢 H6.1 mode-ON auto-HMW substantive/trivial-solo + line-9 model fix) · `.claude/commands/session-start.md` (T4 + H6.1 mode-ON auto-HMW).
- **H6.2 file:** `.claude/workflows/hmw.js` `resolveModel()` — role-less `return 'opus'``return undefined` (inherit lead-model top-tier); comment + log cập nhật "per-task tier:'opus' = escape-hatch sweep/cost". **Live next workflow-run** (no restart).
- **H6.7a pre-existing:** `hmw.js:22-24` `VALID_ROLES` = 9 vai roster THẬT (investigator-codebase·investigator-api·implementer-backend·implementer-frontend·test-specialist·reviewer·cicd-monitor·frontend-designer·database-agent) + `hmw.js:98-99` whitelist check → role lạ = default subagent + WARN. **2 monitor (tooling-auditor/harvest-curator) CỐ Ý ngoài VALID_ROLES** (spawn ở session-boundary, KHÔNG fan-out workflow) — khớp H6.7a "loại vai ngoài-ranh-giới-workflow".
- **H6.7b pre-existing:** `ultra-on.md` §KỶ LUẬT KÝ ỨC R1 (return-only) + B2 harvest-liền + B3 single-writer APPEND-only. memoryDelta round-trip runtime-verified S49/S57bis.
- **SELF-CHECK broadcast:** mode-ON auto-author substantive ✓ (T4+bullet) · agentType = vai THẬT ✓ (VALID_ROLES sẵn) · workflow-agent inherit lead ✓ (H6.2 flip + promote-inherit) · memoryDelta→đúng agent-memory single-writer ✓ (B3 sẵn) · vai cross-project loại ✓ (SE không có cross-project role; monitor ngoài workflow) · guard giữ ✓ (KHÔNG native ultracode line 17 · checkpoint INFORM P-table · no-cross-project S1).
## 4. tailored-gì + skip-gì-vì-sao
- **FUNCTION-floor adopt FULLY:** H6.1→H6.7 đủ.
- **FORM tailored SE:**
- **H6.2 = thay đổi THẬT:** SE H4 từng đặt role-less default = `'opus'` (justify "sweep-class taskList lead-author" — adap-report H4 §4). H6.2 supersede: default → **inherit lead** (top-tier), `tier:'opus'` thành **escape-hatch tường-minh** cho sweep/cost. (Fable down hiện tại: inherit = Opus = bằng cũ; khi Fable về: role-less → Fable lead thay vì pin Opus — đúng intent H6.2.)
- **H6.1 coexist T4:** T4 keyword=quyền vẫn áp cho **mode-OFF** (chống 515K-token false-trigger); H6.1 auto-HMW chỉ khi **mode-ON** (marker = standing consent). KHÔNG mâu thuẫn.
- **Trivial-solo mở rộng:** SE thêm "governance-authoring single-writer → solo" (vd adap-apply NÀY — sub không viết governance thay lead được).
- **SKIP/n-a:** H6.7a cross-project-exclusion = SE **không có** vai cross-project (monitor audit SE-only, đã ngoài workflow) → exclusion = n-a-vì-không-có, KHÔNG behind.
## 5. honest-caveat
- **H6.1 = floor HÀNH-VI của lead, KHÔNG automation cứng** (đừng claim "100% tự-động") — lead theo nếp tự-nhận-diện substantive. **Verified-pending-restart** (command no hot-reload → session NÀY vẫn body cũ; nhưng em-main đã theo tinh-thần H6.1 trong session này: adap-apply = governance-authoring → SOLO đúng, KHÔNG fan-out).
- **"Auto-HMW" ≠ "workflow mọi task"** — trivial + governance-single-writer vẫn solo (giữ chống token-nổ). KHÔNG slide sang native-ultracode.
- **H6.2 inherit = theo lead hiện-tại:** lead đang fallback Opus (H5) → inherit = Opus (top-tier khả-dụng), KHÔNG phải "hạ model". Khi Fable về → inherit tự lên Fable.
- **H6.7 KHÔNG mới-build** — đã là floor SE từ S49; adopt = re-confirm + document (honest: không over-claim "vừa thêm").
- **Native `/effort ultracode` vẫn CẤM** (line 17 ultra-on) — H6 = HMW governed thay thế, đủ guard.