16 KiB
Tooling-Auditor Agent — Persistent Memory
Persistent diary cross-session. Auto-injected first ~200 lines at spawn (L1 HOT). Update BEFORE every stop. Tiered Memory v1: L1 HOT (hook hard-limit <17KB) · L2
archive/2026-06.mdverbatim on-demand · L3 RAGsearch_memory. Keep entry ≤ 1.5K chars. NEW agent 2026-06-07 (adopt AI_INFRA Harness 1 — H1 tooling-freshness; TÁCH khỏi harvest-curator H2 per anh-mandate "H1/H2 hay quên+nhầm → riêng-biệt"). Compacted S99 2026-07-02 (19.6KB→~9KB, 12 entry 06-xx → archive NGUYÊN VĂN) · S105 2026-07-07 (19.4→~16KB, S98-S100 →archive/2026-07.md) · S106 2026-07-07 (19.7→14.9KB, S102-S104 @start →archive/2026-07.md; byte-verified md5×3 @S107) · S107 2026-07-10 @end (17.8→16.2KB, S101+S105 @start → archive md5×2) · S109 2026-07-10 @start (17.2→~13KB, S105-end+S106-start → archive md5×2).
🎯 Role baseline
H1 tooling-freshness auditor SOLUTION_ERP-self. Read-only + propose-only (em main = single-writer; NGOẠI LỆ duy nhất: diary/archive của chính mình). Tools: Read/Grep/Glob/Bash + 4 RAG-read. NO store_memory. Audit 4-mặt mỗi session: skill · sub-role · plugin · docs — đầy-đủ + kịp-thời. @session-start báo state + diff-vs-last; @session-end chốt + new-alloc audit. 🔴 Final message = VERDICT trực tiếp, KHÔNG narrative memory-curation (#53 return-garble ×4).
🚫 Split boundary
- ✅ MINE: tooling/docs freshness (4-mặt) + roster-drift + skill/plugin new-alloc — SOLUTION_ERP-self
- ❌ NOT: harvest-memory/5-trục → harvest-curator (H2) · corpus/RAG/deploy → cicd-monitor · code/SQL audit → investigator-codebase · write/decide → em main
📋 Baseline state (re-ground 2026-07-02 S99 — VERIFY mỗi session, đừng tin số cũ)
- Roster: 12 sub (S107 +office-document 📄 Office WRITE, anh giao), 12/12
model: inherit(Harness-8 all-inherit, runtime-verified S98 — Fable 5 RESTORED, inherit-chain self-reportclaude-fable-5). 10 product/quality (investigator-codebase/api · implementer-backend/frontend · test-specialist · reviewer · cicd-monitor · frontend-designer · database-agent read-advisory · office-document Office S107 ✅ verified-runtime cùng-phiên [hot-reload agent-MỚI ăn thật — S27 lesson chỉ còn EDIT-agent/command]) + 2 monitor INFORM-only (tooling-auditor · harvest-curator). VALID_ROLES hmw.js = 10 product-only by-design. - Skills: 6 project (
.claude/skills/) + 23 standalone (~/.claude/skills/) + 16 command-file (S101 +fable-real/clone) (.claude/commands/— hmw = scriptworkflows/hmw.js, KHÔNG phải slash-command). - Plugins: 18 registered (15 enabled / 3 disabled: pr-review-toolkit · code-modernization · hookify) user-global
~/.claude/settings.json:17-35· marketplace 35 · settingsmodel: claude-fable-5[1m]+effortLevel: xhigh. - Docs canonical:
CLAUDE.md(root+docs) ·docs/STATUS.md(số canonical B1) ·docs/HANDOFF.md·.claude/agents/README.md·docs/governance/.
⚠️ Anti-patterns
❌ Tự sửa config/doc/enable-plugin (propose-only) · ❌ conflate plugin "enabled"="used" (installed≠enabled≠assigned≠used) · ❌ tick-checkbox no-evidence · ❌ đụng harvest-memory (harvest-curator) · ❌ G-015 overclaim "read-only enforced" (Bash residual = write-channel mở).
🧭 Method distilled (S50-S98 — chi tiết verbatim archive/2026-06.md)
- Ground-truth MỌI count từ disk:
settings.json enabledPlugins= authoritative plugin# ·skills/README.md≠ SKILL.md frontmatter (drift độc lập) · Migrations ởInfrastructure/Persistence/Migrations(KHÔNGInfrastructure/Migrations). - Test count: KHÔNG attr-count
[Fact]/[Theory](Theory expand runtime) — tin session-log/test-run/STATUS. - Bundle-hash: KHÔNG tin 1-source — triangulate (cicd-MEMORY = provenance giàu nhất Run#+sha+rotate); anh-cite chưa verify được → flag "unverified", KHÔNG copy.
- gotcha format: entry =
### N.KHÔNG#N— verify format trước khi claim missing. - commands/*.md + ultra-on.md = trong radar: roster-grep (S57 catch) + count-grep (S99 catch "(68)") — lớp file hay bị monthly-audit bỏ sót; index/README files cũng vậy (S50).
- Drift born-SAU-monthly-CÙNG-NGÀY = lớp riêng (S97/S98) — per-session monitor bù lớp monthly không thấy.
- system-reminder claudeMd header = pre-session snapshot → re-Read line thật trên disk, KHÔNG tin context-injection. Brief "chưa flush" cũng = snapshot lúc spawn → re-ground disk hiện tại (S58).
- Backlog/coords trong HANDOFF phải re-verify trước khi tin (stale-contradiction S57-resume).
- Model spawn-test: frontmatter no hot-reload — pin/inherit ăn SAU restart CLI; self-report nguyên văn = bằng chứng runtime (H4 S57bis · H8 S98).
- Tool-gotchas: Bash nuốt
$PS-inline →powershell -NoProfile -Commandescape\$· PSGet-Content -Raw+-TotalCountmutually exclusive → dùng Grep tool^model:. - Return-cut giữa emit (S58) = finding chính vẫn salvageable từ partial return; emit finding chính SỚM trong report.
📅 Recent activity (FIFO — older → archive/2026-06.md verbatim)
- 2026-06 (12 entry S50→S66 → archive): CREATED+first-run verified-runtime (S50 3-drift: plugin 15→18 · ef-core 31→43 · gotcha 49→57) · S51 new-alloc database-agent STRONG-FIT/codebase-agent SKIP · S57×2 (ultra-on+session-start roster catch; VALID_ROLES 9) · H4 demote spawn-test ×2 (pin ăn post-restart, demote-watch #1 OK) · post-S57bis count-drift top-5 · S58 return-cut-partial · S59×2 ALL-FRESH (bundle triangulate 4-src; SearchableSelect=code KHÔNG skill) · S63 H5 opus-collapse confirm + ef-residual · S66 H8 all-inherit flip (7 pin→inherit). →
archive/2026-06.md. - 2026-07-02 (3 entry S98/S99/S100 →
archive/2026-07.mdverbatim, compact S105): S98 Fable-restore-evidence + ef-core stuck-59 + post-audit-drift (archive giữ bản verbatim-superset pre-curate) · S99 F1 s98-flip-miss + F2 SendMessage-stale + F3 command-count-catch "(68)" · S100 ALL-PASS F1/F3 fixed-verified + methodgit log -- .claude/skills/last-touch shortcut. - 2026-07-03 (S101 @start →
archive/2026-07.mdverbatim, compact S107): ALL-4 PASS + 🔴 MODEL-DRIFT first-catch (inherit-chain data-point #4 DIVERGENT Opus, H5-fallback tự-kích) — lesson gốc “inherit-chain self-report = per-session availability probe, đừng tin last-session model claim”. - 2026-07-03 (S101 @closeout →
archive/2026-07.mdverbatim, compact S105): command 14→16 (+fable-real/clone H19 = COMMAND-tier ≠ skill, đừng conflate; 0 catalog-drift) · data-point #5 Opus DIVERGENT · new-alloc 0 · F-H19a LOW DEFER (note khi Fable-về) · F-H19b em-main fixed. - 2026-07-06 (S102/S103/S104 @start →
archive/2026-07.mdverbatim, compact S106): S102 ALL-PASS Fable-restore-2nd (data-point #6) + model-note-reconcile-3 propose · S103 ①②③ PASS, ④ FLAG-M-LOW model-note S102-Fable thiếu S103-O data-point (#7 divergent) · S104 = Mig-62 ship docs-lag (product commit778fc98chưa reconcile): D1-HIGH STATUS:14 Mig 61→62 + D2-skill ef-core header/row-lag + D3-MED closeout-blurb-missing + D4-LOW migration-todos-tick; ⚠️ table 89 GIỮ (18 AddColumn/0 CreateTable count-invariant); methodgit show --stat= xác-nhận-nhanh commit-scope (#8 divergent Opus). - 2026-07-07 (S105 @start →
archive/2026-07.mdverbatim, compact S107): ①②③ PASS ④ 2-flag LOW (skills/README:20 Mig-61-stale [fixed S105-end] + model-note 2-of-3 lag [FLAG-M closed S105-end]); Fable-về lần 3 flip-6 data-point #9; L1 compact S105 19.4→16KB md5-verified. - 2026-07-07 (S105 @closeout →
archive/2026-07.mdverbatim, compact S109): ALL-4 PASS 0-sót · 4 patch em-main LANDED verified · FLAG-M CLOSED 3/3 · 🔴 method-gotcha Grep-tool brace-glob{a,b}/**match 0-FILE → sweep VOID tưởng clean — re-run per-dir; phân-biệt "0-match" vs "0-file-searched". - 2026-07-07 (S106 @start →
archive/2026-07.mdverbatim, compact S109): ①②③ PASS ④ 2-FLAG (D-BUNDLE MED STATUS:27 live-pointer stale #484→#488 [pattern gốc] · D-MODEL LOW flip-note); flip-7 Opus data-point #10 · CADENCE-proposal born-here (adopted S107). Method: ĐỪNG tin brief-baseline HEAD — re-groundgit log+git show --statmỗi commit-mới · bundle-live triangulate cicd-MEMORY (2-source-cùng-doc cũng cross-check). - 2026-07-10 (S107 @start RE-REPORT — ALL-4 PASS, 0 flag mới; FABLE VỀ lần 4 = flip-8, data-point #11; self-compact-S106 byte-verified): HEAD
41f8061+ tree 7-M uncommitted = ĐÚNG brief-list S106 micro-session 7/7 file, 0 file lạ (em-main commit reconcile S107). Model: spawn self-reportclaude-fable-5(chuỗi …S105F→S106O→S107F, flip-8). ①SKILL PASS 6+23+16 identical, last-touch skills/0f16c00S105, README:20 fresh Mig62/S104. ②ROSTER PASS 11=11=11, 11/11^model: inheritgrep, README:3 gộp-pointer→canonical. ③PLUGIN PASS 18/15/3 + m35 + xhigh + fable[1m]:11 identical, 0 new-alloc. ④DOCS PASS: D-BUNDLE FIXED-verified (STATUS:27 hoistedChSNAJBK/Bn2w1znH#488 + lag-note) · D-MODEL FIXED-verified (STATUS:24 +S106-O flip-7 + 🔴 stamp "§Sub-agents = CANONICAL single-owner flip-chain, S106 gộp per anh-confirm"; 3 derived agents/README:3 + ss:37 + se:113 = pointer-only; residual-enumerate sweep agents/+commands/+docs/ = 0 stale [chỉ canonical :6/:24 + 1 session-log history]) · CADENCE-proposal S106 tao = ADOPTED (anh-confirm gộp 1-chain, chống churn 4-file/flip) · counts khớp Mig62/89/440/79/54 · ERD-debt carry (root:131 "32-61" + docs:70 "27-61", KHÔNG mới) · HANDOFF:5 S105 = expected micro-session. Self-compact-S106 verify (tự-kiểm): PASS byte-level — md5×3 identical HEAD-blob-L1 vs archive (S1021760f27a· S103a6c8c75f· S104e12e5377= moved-not-cut LOSSLESS), L1 14.9KB<17KB, FIFO :43 đúng, archive :13 compact-header FROZEN-additive; self-fix header :5 +compact-S106 note (sót lúc compact). Tag[s107-start, 4-mat, all-pass, flip-8-fable, self-compact-byte-verified, d-bundle-d-model-closed, cadence-adopted]. - 2026-07-10 (S107 @end CHỐT — ①③ PASS · ② PASS-DELTA roster 12 · ④ 1-FLAG D-BUNDLE lặp; new-alloc PASS; residual 0-sót): HEAD
86a34d5tree CLEAN (7-M S106 committed1eea51b). ② 11→12 +office-document 📄 OD1-OD10model: inherit:5, 3 commit1eea51b/21387cd/86a34d5— VERIFIED-RUNTIME CÙNG-PHIÊN (registry hot-reload agent-MỚI; S27 lesson thu-hẹp còn EDIT-agent/command). New-alloc 5-skill PASS ×3-chỗ: agent §SKILL:27-32 (docx/xlsx/pptx/pdf standalone + form-engine project, verify-present :52) · README matrix-row :165 · VALID_ROLES 10 (hmw.js:27 + README:208); skills/README no-agent-column by-design KHÔNG thiếu; budget.json:132 seeded 3323B. Residual-grep độc-lập 0-sót: live-claims đều 12/10 (README:3/:24/:217 · STATUS:24/:39 · ss:56 · se:83); hits còn = history-valid (README:12/:16 upgrade-log S66/S79 · ACTIVE-MARKS:15/:18 stamped-S79 FROZEN · README:247 S38-snapshot); STATUS:112 “11/11 có tools:” = point-in-time S100, OD có tools → invariant giữ (INFO). Wire =git show 21387cd --statđúng 14-file. 🔴 D-BUNDLE-LẶP (MED): STATUS:27 live-pointer kẹt #488ChSNAJBK/Bn2w1znHnhưng cicd:55/:73 = live thật #489BVyH-FY7/EDsZebvn(JS rotate-benign governance-only 0-fe-src, #69 two-mode, ship-proof LM-in-window + real-size; STATUS:39 đã carry đúng — chỉ :27 lag 1-run đúng pattern S106) → propose hoist :27 → #489 + prepend #488 prev-chain; cân-nhắc cadence :27 nếu benign-rotate lặp thường. Diary: :17 em-main flushed 12-sub ✓ · self-fix :18 14→16 cmd · compact S101@start→archive md512612234✓. Tag[s107-end, roster-12, new-alloc-pass, d-bundle-489-repeat, residual-0]. - 2026-07-10 (S108 @end CHỐT — ①②③ 0-đổi PASS · ④ PASS; marker-not-committed ✓; 1 propose LOW): HEAD
5d13b48CLEAN; 3 commit S108 scope-verified 0 skills/agents (roster 12 giữ, new-alloc 0, plugin 18/15/3). ④ +fable-real-runbook.md60,586B — engine:334 ĐÃ trỏ runbook+first-real-run (KHÔNG cần +pointer engine) · K.C:328 "10 vai +OD" đúng · adap-request + email8d14405f+ _index đều in-commit69957fd· hmw:30-34 comment-only per-session-probe (:35 logic giữ). Marker ON 261B +check-ignore→.gitignore:92 + ls-files 0-hit = KHÔNG committed. D-BUNDLE S107 CLOSED-verified: STATUS:27 hoisted #489BVyH-FY7/EDsZebvn; #490/#491 frozen-streak → :27 vẫn đúng. 🟡 Propose LOW:fable-real.md+ ss BƯỚC-0.5b = 0-hit runbook → +1 dòng pointer mỗi chỗ (entry-point thao tác). Tag[s108-end, marker-ignored, d-bundle-closed, runbook-ptr-propose]. - 2026-07-10 (S109 @start RE-REPORT — ALL-4 PASS, 0 flag; Fable streak-3 KHÔNG flip, data-point #12; self-compact-S109 md5×2): HEAD
a9c3f1dCLEAN; 2 commit post-5d13b48(557642fS108-closeout 7-file [2 monitor-memory APPEND + runbook-pointer ×2 = propose-LOW S108 APPLIED-verified ss:33 + fable-real:9] ·a9c3f1dHANDOFF-1-line sleep-recovery-PAUSED) — cả 2 = 0 skills/agents/settings → ①②③ identical S108-baseline. ①PASS 6+23+16, ef-core :3/:19 Mig-62 + skills/README:20 fresh, last-touch0f16c00S105. ②PASS 12=12=12 (README:3/:24 · STATUS:24), 12/12^model: inherit:5, VALID_ROLES 10 (hmw:22 + README:208), last-touch86a34d5S107. ③PASS 18/15/3 + m35 + fable[1m]:11 + xhigh:37, 0 new-alloc. ④PASS: STATUS:27 #489BVyH-FY7/EDsZebvnVẪN ĐÚNG (#490/#491 frozen-streak + 2 commit .md-only path-filter-skip → 0 run mới, D-BUNDLE KHÔNG tái) · HANDOFF:5 S108-fresh + resume-point sleep-PAUSED (scope 16-file/6-agent · 0 gist · resume Phase-1 lượt-A) NHẤT-QUÁN budget.json:4last_sleep_at=2026-07-02giữ-intentional (8d≥7 → sleep-check INFORM = expected, NEXT-anh(4) consent) · marker.claude/fable-real-mode.on261B EXISTS+gitignored:92 = HANDOFF "VẪN ON" TRUE · session-log S108 + runbook 60KB tồn tại · phiên-pause 0 STATUS-row = OK (0 task xong, resume-point ở HANDOFF đúng chỗ). ⚠️ Self-caught false-alarm: đoán marker-name.fable-real-active→ tưởng ABSENT — resolve tên THẬT từ fable-real:11/.gitignore:92 rồi mới kết luận (marker/filename LUÔN lấy từ source trước khi flag absence). Model: self-reportclaude-fable-5(…S107F→S108F→S109F). Tag[s109-start, all-pass, fable-streak-3, marker-name-lesson, self-compact-md5x2]. - 2026-07-11 (S110 @start RE-REPORT — ALL-4 PASS, 0 flag; Fable streak-4, data-point #13): HEAD
72a85bfCLEAN; 2 commit post-a9c3f1d(f5a5c3esleep-compress P1 10-file agent-memory-only [2 gist 2026-06 tooling/harvest distill-gen:1 + reviewer curate + budget last_sleep_at=07-10] ·72a85bfS109 closeout [STATUS +15 dòng + HANDOFF 1-line + session-log + cicd #492]) — cả 2 = 0 skills/agents/settings → ①②③ identical S109-baseline. ①PASS 6+23+16, last-touch0f16c00S105. ②PASS 12=12=12 (README:3 · STATUS:24), 12/12^model: inherit, last-touch86a34d5S107. ③PASS 18/15/3 + m35 + fable[1m]:11 + xhigh:37, 0 new-alloc. ④PASS: STATUS:6 + HANDOFF:5 fresh S109 · counts Mig62/89/440/79/54 khớp · STATUS:27BVyH-FY7/EDsZebvnVẪN ĐÚNG (frozen-streak ×3 #490→#492 per STATUS:40 — D-BUNDLE KHÔNG tái) · markers hmw.on 349B + fable-real.on 261B EXISTS = HANDOFF "VẪN ON" TRUE · In-Progress 3-row S109 done + PE-phân-quyền carry đúng chỗ. Method: grep pattern rộng trên STATUS mega-line nổ 115KB persisted-output → dùng Read offset/limit targeted dòng canonical (:14/:24/:27) thay grep cả file. Model: self-reportclaude-fable-5(…S108F→S109F→S110F streak-4). Re-spawn lần-2 cùng-phiên (em-main premise "+1-dòng=S109-end" SAI): git-diff = +1 dòng/monitor = CHÍNH entry @S110-start lần-1 (cả harvest-curator cùng pattern) → commit-worthy closeout KHÔNG stray; re-verify độc-lập lần-2 identical ALL-PASS 0-flag; same-session re-spawn ≠ data-point mới. Method: STATUS Read limit=42 vẫn nổ 25K-tok (mega-line :6/:14/:27 đều trong 42 dòng đầu) → đọc khúc ≤20 dòng. Tag[s110-start, all-pass, fable-streak-4, sleep-p1-done-baseline, respawn-x2-premise-fix].