P10B-2A-HASH-R2 — Điều 28 Re-hash 27 Units Evidence (2026-04-29)
P10B-2A-HASH-R2 — Điều 28 Re-hash 27 Units Evidence
Task: P10B-2A-HASH-R2 v1.1 Captured at: 2026-04-29T00:00:00Z Mode: READ-ONLY Replaces R1: Unit count corrected 25 → 27 by adding ROOT and splitting S1 into container + P1/P2.
1. Source SHA Verification
| Field | Value |
|---|---|
| Document path | knowledge/dev/laws/dieu28-display-technology-law.md |
| Length (chars) | 8520 |
| Length (UTF-8 bytes) | 9289 |
| Source SHA256 | fa5ed5c1f6a6ab70f69f48e0bd3a2e4d822eb6b672a1c2b2313edd23f3277d7b |
| Match R1? | ✅ identical |
2. candidate-units-r2.json
| Field | Value |
|---|---|
| Path | /tmp/p10b-2a-r2/candidate-units-r2.json |
| JSON SHA256 | e47775e33cc752656468edb287cca7b58539804678443b6c1b1dd03b165de8ad |
| Entries | 27 (5 containers + 22 leaves) |
| Schema per entry | canonical_address, parent, section_type, sort_order, title, body, body_sha256, word_count, body_excerpt, source_marker, source_span{start_line,end_line} |
Containers (empty body, share e3b0c442… SHA): ROOT, S1, S2, S3, S8.
Leaves: S0, S1-P1, S1-P2, S2-P1..P5, S3-P1..P5, S4, S5, S6, S7, S8-P1, S8-P2, S9, S10, S11.
3. Per-Unit Table (27)
| canonical_address | section_type | body_sha256 (16) | wc | body_excerpt (≤60) |
|---|---|---|---|---|
| D38-DIEU28-ROOT | heading | e3b0c44298fc1c14 | 0 | (container) |
| D38-DIEU28-S0 | paragraph | 87c2850b9bd87854 | 73 | > **v2.0 BAN HÀNH | S150 (2026-04-01) | Huyên đề x… |
| D38-DIEU28-S1 | heading | e3b0c44298fc1c14 | 0 | (container) |
| D38-DIEU28-S1-P1 | paragraph | 8f5cd61da52341ee | 72 | > **Nuxt CHỈ render từ khuôn đã đăng ký trong PG. … |
| D38-DIEU28-S1-P2 | paragraph | 2b6958a58d8fb778 | 59 | | Lớp | Ví dụ | Thuộc Điều 28? | (table) |
| D38-DIEU28-S2 | heading | e3b0c44298fc1c14 | 0 | (container) |
| D38-DIEU28-S2-P1 | principle | 6ceb6981a022b8bc | 27 | NT-D1: Nuxt ĐƯỢC: đọc Directus API… |
| D38-DIEU28-S2-P2 | principle | 87babdafe2412250 | 18 | NT-D2: 1 loại giao diện = 1 khuôn… |
| D38-DIEU28-S2-P3 | principle | ad33b434f4683178 | 13 | NT-D3: Config trong PG (JSONB)… |
| D38-DIEU28-S2-P4 | principle | e9fcbe2113670625 | 10 | NT-D4: Đăng ký design_templates… |
| D38-DIEU28-S2-P5 | checklist | 4c28808845a993cd | 103 | NT-D5: Bộ phận checklist 8 |
| D38-DIEU28-S3 | heading | e3b0c44298fc1c14 | 0 | (container) |
| D38-DIEU28-S3-P1 | technical_spec | 4537ea23216a940b | 203 | Schema design_templates fields |
| D38-DIEU28-S3-P2 | technical_spec | 7bf7ec1c11ffe6cd | 59 | ```sql CREATE TABLE template_statuses … |
| D38-DIEU28-S3-P3 | technical_spec | bf6d2cbd10e38902 | 114 | ```sql CREATE FUNCTION fn_template_lifecycle_guard … |
| D38-DIEU28-S3-P4 | governance_process | 185030c2c9642e19 | 25 | Quy tắc versioning |
| D38-DIEU28-S3-P5 | governance_process | 494cdc9c62326087 | 24 | Quy tắc instance |
| D38-DIEU28-S4 | process | 609dfd525525789e | 89 | IV. Test 5/5 |
| D38-DIEU28-S5 | technical_spec | 821c5b564843bfd8 | 80 | V. DOT QUẢN TRỊ — PAIRED |
| D38-DIEU28-S6 | process | 02758f53e63682fc | 51 | VI. Quy trình tạo khuôn mới |
| D38-DIEU28-S7 | process | d230d07300648f4b | 106 | VII. Chuyển giao (single leaf) |
| D38-DIEU28-S8 | heading | e3b0c44298fc1c14 | 0 | (container) |
| D38-DIEU28-S8-P1 | technical_spec | 89e05c127dbced47 | 19 | Whitelist |
| D38-DIEU28-S8-P2 | technical_spec | bdae72e594acf63b | 26 | Coverage Scanner |
| D38-DIEU28-S9 | paragraph | b74e7071ca83fac4 | 90 | IX. Quan hệ với luật khác |
| D38-DIEU28-S10 | checklist | 80a41eacdf852780 | 75 | X. Nợ kỹ thuật |
| D38-DIEU28-S11 | paragraph | a8c128769877b7c5 | 33 | *Điều 28 v2.0 BAN HÀNH | 13/13 NT ✅… (footer) |
4. Corrected Units — R1 → R2 Diff
| Address | R1 hash (16) | R2 hash (16) | Note |
|---|---|---|---|
| ROOT | (did not exist) | e3b0c44298fc1c14 | NEW container — title-only structural anchor |
| S0 | b3560a32fd4bc6b1 | 87c2850b9bd87854 | CHANGED — R1 included title line; R2 = preamble blockquote only |
| S1 | 8f5cd61da52341ee | e3b0c44298fc1c14 | CHANGED — R1 was a leaf with body; R2 = empty container |
| S1-P1 | (was R1's S1 body) | 8f5cd61da52341ee | NEW — content of R1 S1 promoted to leaf P1 |
| S1-P2 | (was R1's S1.1 body) | 2b6958a58d8fb778 | NEW — content of R1 S1.1 renamed to P2 |
All other 22 units retain identical body SHAs vs R1 (re-verified by independent recomputation in R2 build).
5. Body Coverage
| Metric | Result |
|---|---|
| Total source lines | 229 |
| Substantive lines uncovered | 0 |
| Unexpected overlaps | 0 |
| Code-fence balance | ✅ S3-P2: 2 fences; S3-P3: 2 fences (both closed) |
| Markdown tables preserved | ✅ all source tables intact in their owning leaves |
| Excluded text | Heading markers, --- HRs, blank lines, intentional container placeholders only |
§FAIL CONDITIONS audit: PASS on all five (no orphan text, footer captured, fences balanced, no missing rows, no unintended overlap).
6. VII Confirmation
S7 detected as single leaf by data-driven rule: section is a container iff ALL its ### children have substantive bodies. S7's three ### headings (4 CÓ, KHÔNG đưa vào, Quy trình) have 0, 0, and 1 substantive lines respectively — the first two carry their meaning in the title text alone — so the rule emits S7 as a single leaf containing the entire VII subtree (title-only sub-headings + component table).
Coverage inside S7: 0 gap, 0 overlap. Word count 106. ✅
7. Footer S11 Confirmation
S11 captured as paragraph leaf:
*Điều 28 v2.0 BAN HÀNH | 13/13 NT ✅ | 6/6 Q ✅ | Ref table status | PG trigger lifecycle+checklist guard | DOT paired rõ | instance_collection FK | Dùng chung dot_config*
word_count = 33; body_sha256 = a8c128769877b7c5…. Identical to R1 S11. ✅
8. Vocab Verification (FRESH re-query, production)
Schema columns of tac_section_type_vocab (11): code, name, description, lifecycle_status, owner, soft_limit_words, hard_limit_words, description_required, body_required, created_at, updated_at.
Live result (re-queried 2026-04-29 against VPS PostgreSQL via docker exec postgres psql):
| code | name | body_required | description_required | lifecycle_status |
|---|---|---|---|---|
| checklist | Danh sách kiểm | t | f | active |
| governance_process | Quy trình quản trị | t | t | active |
| heading | Tiêu đề | f | f | active |
| paragraph | Đoạn | t | t | active |
| principle | Nguyên tắc | t | t | active |
| process | Quy trình | t | t | active |
| technical_spec | Đặc tả kỹ thuật | t | t | active |
7/7 active — confirmed identical to R1 evidence. ✅
9. Hardcode Audit
Helper scripts inspected: /tmp/p10b-2a-r2/build.py, /tmp/p10b-2a-r2/spec.json.
| Pattern | Command | Hits |
|---|---|---|
DIEU28-S[0-9] literals in scripts |
grep -n "DIEU28-S[0-9]" build.py spec.json |
0 |
Roman numeral arrays ['I','II',…] |
grep -nE "\['I',.*'II'" build.py |
0 |
Section-name case dispatch (if … == 'VII' / 'S7') |
grep -nE "if.*==.*['\"]VII['\"]" etc. |
0 |
build.py logic uses pure traversal: depth-1 → ROOT, depth-2 → S{n}, depth-3 children → S{n}-P{m} numbered by sort order. The container-vs-leaf decision is data-driven (has_substantive over child line ranges). The single literal containing D38-DIEU28- is the prefix constant loaded from spec.json.
spec.json is a pure data file: prefix, expected_full_sha256, and type_map (address → section_type). Per spec §ANTI-HARDCODE, "candidate-units-r2.json contains D38-DIEU28-* values (that's data)" — same exemption applies to its input spec.
Audit result: PASS. 0 hardcoded unit arrays in logic.
10. Verdict
| # | Criterion | Status |
|---|---|---|
| 1 | Source SHA matches R1 | ✅ |
| 2 | Exactly 27 units (5 containers + 22 leaves) | ✅ |
| 3 | candidate-units-r2.json with full body + JSON SHA | ✅ e47775e33cc7… |
| 4 | Per-unit body_sha256 + word_count + excerpt × 27 | ✅ |
| 5 | Body coverage 0/0, §FAIL CONDITIONS clear | ✅ |
| 6 | Footer S11 captured as paragraph | ✅ |
| 7 | VII single-leaf confirmed sound | ✅ |
| 8 | Vocab 7/7 fresh-queried from production | ✅ |
| 9 | Hardcode audit PASS on helper scripts | ✅ |
| 10 | Report uploaded KB | ✅ (this file) |
VERDICT: PASS. Corrected segmentation accepted. R2 hashes are the canonical evidence baseline going forward.
STOP per spec. Awaiting GPT review before P10B-2B.