- engine-doc canonical docs/governance/harness-11-engine.md (PHẦN A/B/C/D + 3-tier D5/D6/D7 + one-direction-lock D8 + CAVEAT honest) - scripts/governance-detectors.ps1 (C1 broken-pointer + C2/B3 staleness + C3 vocab-fork + C4 self-exclusion + C5 resolve, NO-API DÒ+FLAG-only, runtime-proven, FP-refined 59→27) - scripts/memory-archive-gate.ps1 (PHẦN A: hysteresis 0.85 + keep-floor 5 + 2-strike + A7 NO-API L1-eval) + budget.json archive_gate - B1 ×11 count→canonical-pointer (root CLAUDE.md, ef-core/dep-audit SKILL, skills/README, docs/CLAUDE.md) — drift mig53→55/test306→339/gotcha68→69 RESOLVED + ef-core +Mig 54/55 rows - cadence-wire D1 session-start §2.1.3 + D2 session-end §L.b(c) + agents/README Upgrade S75 - run-trace TRACKED: audit wf_7fdc3bd5-930 / implement wf_c5e5844e-7c1 / review wf_d7ca1ff8-942 (REVIEW PASS, completeness-gate ĐẠT) - check-email AI_INFRA harness-11 (verify whole-file 318ff9f6 + body b2a2fc1c) + adap-report + outbox report (body 7fa1b53a) - 0 production code; state THẬT giữ nguyên (Mig 55 · 88 bảng · 339 test · gotcha 69 · menu 54 · bundle BYF5vIMJ/CB-tiRxd) Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
Skill Library — SOLUTION_ERP
Skill này là tài liệu chuyên biệt để Claude (và developer khác) dùng khi cần deep-dive 1 domain area. Claude tự động invoke qua Skill tool dựa trên semantic matching với description trong từng SKILL.md.
Skills hiện có
Domain skills (logic nghiệp vụ)
| Skill | Mục đích | Trigger ví dụ | Trạng thái |
|---|---|---|---|
contract-workflow |
State machine 9 phase + versioned workflow per ContractType + role × phase guard + SLA + auto-gen mã HĐ RG-001 | "approve contract", "chuyển phase", "versioned workflow", "HĐ cũ giữ cũ" | ✅ Tier 3 + Phase 6 cross-ref PE workflow |
form-engine |
Render template docx/xlsx + FieldSpec JSON + DynamicForm + PDF export LibreOffice | "export contract as word", "điền form", "render template", "PDF export" | ✅ Active |
permission-matrix |
Role × MenuKey × CRUD + seed + 3-layer resolution + inherit Contracts/Workflows/PurchaseEvaluations | "permission denied", "gán role", "menu không hiện", "inherit permission" | ✅ Active (Phase 6 +Pe_/PeWf_) |
Ops/infra skills (devops + security + schema)
| Skill | Mục đích | Trigger ví dụ | Trạng thái |
|---|---|---|---|
dependency-audit-erp |
Scan CVE NuGet + npm 2 FE, respect pin constraint (MediatR 12.4.1, Swashbuckle 6.9.0) | "npm audit", "dotnet vulnerable", "deps scan", "nâng cấp package" | ✅ New Tier 3 |
ef-core-migration |
Tạo/revert EF Core 10 migration, 3-file rule, DesignTimeDbContextFactory, migration history (mới nhất Mig 55; số → docs/STATUS.md) |
"thêm migration", "EF migration", "schema update", "snapshot lỗi" | ✅ Updated S74 (Mig 55 PE CcmNote) |
iis-deploy-runbook |
3 IIS site + win-acme cert + gitea-runner + LibreOffice + debug 500/502/SignalR prod + G-084 IPv4/IPv6 hardening | "prod 500", "IIS fail", "cert hết hạn", "restart app pool", "deploy IIS", "port hijack" | ✅ Updated (G-084) |
Format chuẩn 1 skill
Mỗi skill là 1 folder với ít nhất SKILL.md + optional examples/ + references/:
.claude/skills/<skill-name>/
├── SKILL.md ← Entry point: description, when-to-use, workflow
├── examples/ ← Code snippets mẫu (optional)
│ └── *.cs | *.tsx
└── references/ ← Link đến file code thật, docs (optional)
Frontmatter SKILL.md (BẮT BUỘC when-to-use để skill auto-trigger):
---
name: skill-name-kebab-case
description: 1-3 câu mô tả skill làm gì + stack specificity (để embedding match chính xác)
when-to-use:
- "trigger phrase 1"
- "trigger phrase 2"
- "keyword tiếng Việt"
---
# Skill Name
## Context
...
## Workflow / Commands
...
## Pitfalls
...
## Code pointers
- `path/to/file.cs`
Tạo skill mới — checklist
- Tạo folder
.claude/skills/<kebab-case-name>/ - Viết
SKILL.mdvới frontmatter + sections: Context / Workflow / Code pointers / Common pitfalls - Add row vào bảng "Skills hiện có" phía trên
- Update
docs/CLAUDE.md(dòng skill count) - Commit
[CLAUDE] Skill: add <name>
Nguyên tắc design skill
PROJECT-SPECIFIC, không clone generic:
- Skill user-level global đã có sẵn (
code-reviewer,sql-database-assistant,focused-fix, ...) - Skill project-level phải encode kiến thức SOLUTION_ERP-only mà generic không có:
- Commit convention
[CLAUDE] <scope>: ... - Path pattern
src/Backend/SolutionErp.*/... - Pin constraint (MediatR 12.4.1, Swashbuckle 6.9.0, TypeScript 6 erasableSyntaxOnly)
- Gotcha-referenced (dẫn chiếu
docs/gotchas.md#N) - Workflow Vietnamese-first
- Commit convention
Keep it actionable:
- Commands copy-pastable (không pseudocode)
- Paths đầy đủ (không
src/...) - Version pinned (không "latest")
- Dẫn chiếu gotcha/migration # cụ thể
Related
docs/CLAUDE.md— quick rules + full stack contextdocs/gotchas.md— bẫy đã gặp (số hiện tại →docs/STATUS.md; latest #69 FE bundle-hash non-deterministic + deploy rebuild-FE-unconditional, S72; #68 IDE TS diagnostic giữa background-agent/workflow = snapshot dở-dang → chỉ tin build sạch sau-cùng, S69; #67 Tailwind v4 accent palette thiếu-stop vỡ-màu im-lặng; #66 ruleh1-h4{color}unlayered thắng utilitytext-white, S68)docs/changelog/migration-todos.md— roadmap 5 phase + Tier 3