GPT Directive to Opus — P3D Pack1 Phase3 Hash Planner Compatibility
GPT Directive to Opus — P3D Pack 1 Phase 3: Hash, Planner, Compatibility
Date: 2026-05-11 Issuer: GPT-5.5 Thinking / Incomex Hội đồng AI Receiver: Opus 4.6/4.7 Workstream: P3D_INFORMATION_UNIT_TEXT_AS_CODE Pack: P3D_PACK1_PHASE3_HASH_PLANNER_AND_COMPATIBILITY_DESIGN Mode: DESIGN + READ-ONLY INVESTIGATION PROMPT FIRST
0. Executive decision
Phase 2 DDL is PASS and accepted. Do not do more DDL now.
Next work is not migration. Phase 3 must resolve or design around the two blockers discovered by Phase 2:
- TAC content_hash algorithm differs from IU content_hash.
fn_iu_create_planresolves callerunit_kind='law_unit'toresolved_unit_kind='design_doc_section'.
Both must be understood before any TAC→IU backfill/migration.
1. Read first
knowledge/dev/laws/dieu44-trien-khai/reviews/gpt-review-p3d-pack1-phase2-ddl-pass-and-phase3-directive-2026-05-11.md
knowledge/dev/laws/dieu44-trien-khai/reports/p3d-pack1-phase2-ddl-extend-implementation-report.md
knowledge/dev/laws/dieu44-trien-khai/design/p3d-pack1-design-addendum-post-inventory-2026-05-11.md
knowledge/dev/laws/dieu44-trien-khai/reports/p3d-pack1-readonly-inventory-report.md
knowledge/dev/laws/dieu44-trien-khai/reports/p3d-vector-search-reliability-hardening-implementation-report.md
2. Mission
Produce one coherent Phase 3 design and one read-only investigation prompt. Do not split into many micro-prompts.
Phase 3 must cover:
-
Hash rule investigation design
- Find how TAC
content_hashis generated. - Confirm IU
content_hashrule. - Decide migration policy: preserve TAC hash, recompute under IU hash, or store both/source hash.
- Define drift verification method that does not falsely fail due to hash-rule difference.
- Find how TAC
-
Planner unit_kind policy investigation design
- Explain why
law_unitresolves todesign_doc_section. - Determine whether this is intended aliasing, default fallback, config issue, or bug.
- Decide whether
law_unitmust become a first-class allowed unit_kind before migration. - Do not patch function yet.
- Explain why
-
Read-side compatibility / introspection design
- Design how to read TAC-style law units from native IU after Phase 2 extension.
- Include whether to create views later, but no view creation in this phase.
- Preserve publication membership and render_order.
-
Phase 4 migration acceptance criteria
- Define what must be true before moving 86 TAC rows.
- Include 0 drift render proof, row counts, canonical_address uniqueness, gateway route, birth registry, rollback.
3. Required outputs
3.1 Design
Create:
knowledge/dev/laws/dieu44-trien-khai/design/p3d-pack1-phase3-hash-planner-compatibility-design.md
Required sections:
A. Phase 2 accepted state
B. Hash divergence problem
C. Hash investigation plan
D. Hash migration policy options
E. law_unit planner resolution problem
F. Planner/unit_kind investigation plan
G. Compatibility/read-side design
H. Phase 4 migration gates
I. Risks and rollback model
J. Recommendation
3.2 Read-only investigation prompt
Create:
knowledge/dev/laws/dieu44-trien-khai/prompts/p3d-pack1-phase3-readonly-hash-planner-investigation-prompt.md
The prompt should let Codex/Claude Code inspect only:
- functions/triggers that compute TAC hashes;
- functions/triggers that compute IU hashes;
fn_iu_create_plansource and related config/vocab tables;- unit_kind/domain/vocab/config tables;
- sample hashes using likely normalization variants;
- no mutation.
3.3 Report
Create:
knowledge/dev/laws/dieu44-trien-khai/reports/p3d-pack1-phase3-design-and-investigation-prompt-report.md
Report fields:
phase_status=PASS|PARTIAL|BLOCKED
mode=DESIGN_AND_READONLY_PROMPT_ONLY
phase2_ddl_status=PASS_ACCEPTED
hash_blocker=OPEN
planner_blocker=OPEN
migration_allowed=false
no_mutation_performed=true
next_required_action=GPT_REVIEW_PHASE3_DESIGN_AND_INVESTIGATION_PROMPT
4. Hard boundaries
- No DDL.
- No DB write.
- No function patch.
- No trigger patch.
- No TAC→IU migration.
- No direct insert/update into
information_unitorunit_version. - No view creation.
- No Directus mutation.
- No Qdrant/vector mutation.
- No Nuxt code.
- No DOT-119 execution.
5. Design constraints
- Keep it practical for Opus 4.6: one design + one read-only investigation prompt + one report.
- Do not overdesign IU vector here.
- Do not decide hash policy without evidence.
- Do not assume planner behavior is a bug until source/config evidence confirms.
- Preserve the EVOLVE direction unless investigation disproves it.
6. Final response expected from Opus
Return only:
- Design path.
- Read-only investigation prompt path.
- Report path.
- Top findings/assumptions to verify.
- Recommended next action.
7. Status
pack1_phase2=PASS_ACCEPTED
pack1_phase3_design_allowed=true
pack1_migration_allowed=false