KB-72E8

S186 GPT Context Reset — Điều 38 Information Unit First

4 min read Revision 1
s186dieu38context-resetinformation-unittext-as-codesql-first

S186 GPT Context Reset — Điều 38 Information Unit First

Date: 2026-04-28

Correction / Re-anchor

The current work is not primarily an agent-permission project. It is the production implementation path for Điều 38 Text as Code, specifically the doctrine that miếng thông tin / information unit is the center.

TAC / Gate A/B/C / G8/G11 are implementation gates for the broader goal: SQL-izing formerly NoSQL/text-only knowledge into PostgreSQL-governed units, metadata, components, BOM, publications, review/change-set, and traceability.

Core problem being solved

Previous KB approach stored large text documents. As information grew and edits became complex, details could no longer connect reliably because they remained plain text. Điều 38 is prioritized to move from document-centric KB to PG-governed information units.

Correct overall goal

Build a PostgreSQL-first Text-as-Code substrate where every governance/knowledge object can be decomposed into managed units:

  • text units / information units;
  • segmentation rules;
  • metadata profiles;
  • component catalog;
  • BOM / publication assembly;
  • lifecycle vocab/config;
  • review and change-set approval;
  • checker/DOT validation;
  • Directus surface and role-governed access.

Documents re-read / re-anchored

  • knowledge/dev/laws/dieu38-trien-khai/HOW-TO-READ.md
  • knowledge/dev/laws/dieu38-trien-khai/LSL-01-information-unit-first.md
  • knowledge/dev/laws/luat-sua-luat/LSL-01-v0.4-patch-note.md
  • knowledge/dev/laws/luat-sua-luat/OR-kieu-c-doctrine-amendment-note.md
  • knowledge/dev/laws/dieu38-appendix-01-objectives.md
  • knowledge/dev/laws/dieu38-trien-khai/C1-text-unit-operating-model.md
  • knowledge/dev/laws/dieu38-trien-khai/C1A-segmentation-operating-model.md
  • knowledge/dev/laws/dieu38-trien-khai/C2-metadata-governance-operating-model.md
  • knowledge/dev/laws/dieu38-trien-khai/C3-component-bom-operating-model.md
  • knowledge/dev/laws/dieu38-trien-khai/P5-schema-draft-v0-2.md
  • knowledge/dev/laws/dieu38-trien-khai/P5b-component-bom-schema-draft-v0-2.md
  • knowledge/dev/laws/dieu38-trien-khai/P6-checker-dot-design-v0-2.md
  • knowledge/dev/laws/dieu38-trien-khai/P8-implementation-design-plan-v0-1.md
  • knowledge/dev/laws/dieu38-trien-khai/P9-production-ddl-collection-gate-design.md
  • knowledge/dev/laws/dieu38-trien-khai/index.md

Working mental model

Large KB document = old monolith.

Điều 38 target = split monolith into atoms and assemblies:

  1. Atom: text/information unit.
  2. Identity and birth: unit/component born through Birth Gate.
  3. Shape: segmentation and metadata profile.
  4. Assembly: component + BOM + publication.
  5. Change: unit-level review + change-set approval.
  6. Control: checker/DOT rules validate invariants.
  7. Warehouse: PostgreSQL is SSOT; Directus is gateway/surface.
  8. Operations: production gates deploy schema, collections, seed, roles, and approvals.

Current status remains

Production Gate A DDL is PASS, but DROP guard repair is/was in-flight. Gate B/C/G8B/G11 remain blocked until repair PASS review.

Guardrail for future GPT responses

When discussing S186/P9, avoid reducing the work to "agent control". Always frame it as Điều 38 Text-as-Code implementation for SQL-governed information units, where agent/TAC gates are the operational deployment path.