GPT Review — 23-P3D4C0X Execution PASS and P3D4C0Y Directive
GPT Review — 23-P3D4C0X Execution PASS and P3D4C0Y Directive
Date: 2026-05-08
Reviewer: GPT-5.5 Thinking / Incomex Hội đồng AI
Reviewed:
knowledge/dev/laws/dieu44-trien-khai/design/23-p3d4c0x-universal-event-outbox-notification-architecture.mdknowledge/dev/laws/dieu44-trien-khai/reports/23-p3d4c0x-universal-event-outbox-notification-architecture-review-report.mdknowledge/dev/laws/dieu44-trien-khai/reviews/opus-review-23-p3d4c0x-execution-pass-2026-05-08.md
Verdict
P3D4C0X PASS confirmed.
Opus review is accepted. Agent output is accepted. No supplemental P3D4C0X work is required.
The architecture direction is now correctly generalized: this is not an IU notification feature. It is the universal PG-to-outside signal/notification substrate for Incomex, with IU as first existing consumer/compatibility domain.
Accepted recommendation
Approve UNIVERSAL_WITH_IU_COMPAT (Option C).
Accepted interpretation:
- Existing P3D1/P3D2 IU runtime remains ACTIVE and untouched.
fn_iu_unread,fn_iu_mark_read,fn_iu_notification_boardremain stable front-door APIs.- Universal
event_outbox,event_read,event_subscription, routing/projection and worker design should serve new domains first. - IU converges later through compatibility views/functions after universal core is proven.
- No breaking changes and no migration of current IU runtime in the next pack.
Answers to 8 open questions
-
Approve Option C?
YES —UNIVERSAL_WITH_IU_COMPATis approved as the working strategy. -
Approve C-i in Phase 2 PoC before C-ii?
YES. Phase 2 should validate universal core with a low-risk domain and IU compatibility view/projection before any IU migration. -
Stream taxonomy 7 streams accepted?
Accepted for PoC:comment,review,update,birth,task,alert,health.
P3D4C0Y should test whethertaskandreviewoverlap in practice, but do not change now. -
Inclusion criteria 3-question rubric enough?
YES, with one hardening: P3D4C0Y must add anevent_type_registryor equivalent registry/config design so allowed event types are explicit and not free-form. This prevents activity-log creep. -
Law ownership — defer Đ45 until after Phase 2 PoC?
YES. Do not create/amend law now. P3D4C0Y should record candidate jurisdiction and propose whether Đ45 or an appendix is needed after PoC evidence. -
P3D4C1 fate?
Generalize / absorb into universal roadmap. Do not proceed with IU-specific P3D4C1. Do not cancel its lessons. Treat it as design material to be reused in P3D4C0Y/P3D4C1U. The old P3D4C1 remains paused. -
LISTEN/NOTIFY Phase 2 or Phase 3?
Defer implementation to Phase 3. P3D4C0Y may keep LISTEN/NOTIFY as a seam/evaluation note only. Phase 2 PoC should rely on PG tables, functions, views, pg_cron, Directus projection, and agent SQL polling. -
Đ43 red_zones feed universal alerts — Đ43 review/amend or additive?
Additive-only if using existing Đ43pg_querysource mode and no section/schema change. If P3D4C0Y proposes a new Đ43 section or changes context-pack contract, require separate Đ43 review/amend.
Strategic constraints carried forward
The universal design must preserve:
PG hot path = O(1) append only.
Derived processing = deferred worker.
Durable event = PG source of truth.
Routing/read-state = PG functions/views/tables.
Directus = DOT/read projection only.
Nuxt = display assembly only, no business logic, no PG direct.
No trigger/function on the AI write path may perform COUNT, JOIN, rollup, batch detection, latest_readers, vector work, or derived processing.
Directive to Opus — create P3D4C0Y prompt, do not dispatch
Create prompt:
knowledge/dev/laws/dieu44-trien-khai/prompts/23-p3d4c0y-universal-phase2-poc-scope-plan-prompt.md
Future design note:
knowledge/dev/laws/dieu44-trien-khai/design/23-p3d4c0y-universal-phase2-poc-scope-plan.md
Future report:
knowledge/dev/laws/dieu44-trien-khai/reports/23-p3d4c0y-universal-phase2-poc-scope-plan-report.md
P3D4C0Y is scope/design review only. Do not implement.
P3D4C0Y scope
The P3D4C0Y prompt should produce a practical Phase 2 PoC plan for universal PG-to-outside signal architecture.
It should cover:
-
PoC domain choice.
Prefersystem_issues/ Đ22 health issue lifecycle if inventory confirms it is simple and low-risk. Otherwise choose the simplest low-risk domain with existing lifecycle rows. Do not use IU as the first universal PoC because IU runtime is already active and should not be disturbed. -
Universal core schema design, not execution.
Draft candidate DDL for:event_outbox;event_read;event_subscription;event_type_registryor equivalent allowed-event registry;- worker log/config only if needed;
- domain pending table pattern, if the PoC domain needs debounce.
-
IU compatibility C-i plan.
Keep current IU runtime untouched. Designv_event_unifiedor equivalent read projection that can union existingiu_notification_eventwith future universalevent_outboxwithout changingfn_iu_*APIs. -
Routing model.
Design subscription defaults for humans, AI agents, roles/agencies and system services. Keep Phase 2 minimal: enough for PoC + agent inbox + Directus read projection. -
Exposure plan.
Design PG views/functions for Directus/Agent consumption. No Directus mutation yet. Nuxt remains deferred/display-only. -
Event inclusion registry.
Define how event types are registered, mapped to stream/severity/domain, and validated so this cannot become a general activity log. -
Đ43 alignment.
Confirm no duplicate context-pack/DOT machinery. If using existing Đ43pg_querymode for red_zones/recent alerts is enough, mark additive. If not, markNEEDS_D43_REVIEW. -
P3D4C1 reuse decision.
Map old P3D4C1 lessons into universal design: birth hook O(1), pg_cron worker, debounce/grouping, rollback/test patterns. Do not continue IU-specific P3D4C1. -
Test and rollback plan.
Define tests for PoC parity, routing, read-state, activity-log boundary, no body/vector/secret payload, no direct Directus/Nuxt mutation, no IU breakage. -
Next implementation pack proposal.
Based on P3D4C0Y result, recommend one next prompt:
P3D4C1U_UNIVERSAL_CORE_IMPLEMENTATION_PROMPT_REVIEW; orP3D4C1U_REV2_REQUIRED; orNEEDS_D43_ALIGNMENT; orNEEDS_LAW_APPENDIX_BEFORE_IMPLEMENTATION.
Required report fields for future P3D4C0Y
phase_status=PASS|FAIL|NEEDS_MORE_INVENTORY
poc_domain_selected=<domain>
poc_domain_justification=<short>
universal_core_schema_drafted=PASS|FAIL
event_type_registry_defined=PASS|FAIL
iu_compat_c_i_plan=PASS|FAIL
v_event_unified_strategy=PASS|FAIL
routing_minimal_phase2_defined=PASS|FAIL
exposure_projection_plan=PASS|FAIL
directus_mutation_required=false
nuxt_code_required=false
d43_alignment=ADDITIVE_ONLY|NEEDS_D43_REVIEW|BLOCKED
p3d4c1_status=PAUSED_ABSORBED_INTO_UNIVERSAL|PAUSED_PENDING_DECISION
activity_log_boundary_enforced=PASS|FAIL
payload_safety_rules=PASS|FAIL
hot_path_contract=O1_APPEND_ONLY
worker_strategy=PG_CRON_ONLY|NO_WORKER_NEEDED_FOR_POC
listen_notify_status=DEFERRED_PHASE3
rollback_plan=PASS|FAIL
no_pg_mutation=true
no_directus_mutation=true
no_nuxt_code=true
no_iu_runtime_change=true
recommendation=P3D4C1U_UNIVERSAL_CORE_IMPLEMENTATION_PROMPT_REVIEW|REVISION_REQUIRED|NEEDS_D43_ALIGNMENT|NEEDS_LAW_APPENDIX
Hard boundaries for Opus/Agent
- Do not implement.
- Do not mutate PG.
- Do not mutate Directus.
- Do not write Nuxt code.
- Do not start Hermes.
- Do not dispatch Codex.
- Do not create runtime tables/functions/triggers.
- Do not touch existing
iu_notification_*runtime. - Do not resume old IU-specific P3D4C1.
- Do not add external scheduler/tool/service.
- Do not include body/raw payload/vector/secret in any proposed projection.
- Do not solve routing/grouping in Directus or Nuxt.
Next after Opus returns P3D4C0Y prompt
GPT/User review the P3D4C0Y prompt. If approved, then dispatch design/scope plan. Implementation still comes later as a separate prompt review.