KB-4294

D36 NVSZ Birth Pipeline Audit + QT Classification — 00 Summary (PASS)

10 min read Revision 1
d36nvszbirth-pipelineauditqt-001qt-002classification2026-05-25read-only

D36 NVSZ Birth Pipeline Audit + QT Classification — 00 Summary

Outcome: D36_NVSZ_BIRTH_PIPELINE_AUDIT_AND_QT_CLASSIFICATION_PASS Date: 2026-05-25 Mode: READ-ONLY — zero production mutation (no DDL, no DML, no migration, no rollback, no MARK/CUT, no Qdrant write). Channel: Live directus PG database, queried via VPS MCP tool (read-only role, AST-validated, statement_timeout 5s).

TL;DR verdict

NVSZ Macro A objects (SPE-NVS, COL-IUS-001, COL-IUS-002, plus the underlying iu_core.iu_staging_record and iu_core.iu_staging_payload tables) are TECHNICALLY VALID auto-birth via the standard collection_registry / entity_species trigger chain, but the macro was executed in governance-order nonconforming fashion (substrate applied before the Birth Execution Plan).

Classification (per ops/processes/birth-process-v1.md + design/12c-iu0-pack2a-birth-process-classification.md):

Object Birth path used QT class Verdict
SPE-NVS row in entity_species trigger trg_birth_entity_speciesfn_birth_registry_auto('code') Catalog auto-birth (Case 3) VALID
COL-IUS-001 (iu_staging_record) row in collection_registry trigger trg_birth_collection_registryfn_birth_registry_auto('code') Catalog auto-birth (Case 3) VALID with SUSPECT: provenance flag
COL-IUS-002 (iu_staging_payload) row in collection_registry same trigger chain Catalog auto-birth (Case 3) VALID with SUSPECT: provenance flag
iu_core.iu_staging_record table DDL via migration n/a — physical object, registered via COL-IUS-001 VALID (catalog covers it)
iu_core.iu_staging_payload table DDL via migration n/a — physical object, registered via COL-IUS-002 VALID (catalog covers it)
3 proof rows in iu_staging_record + 4 rows in iu_staging_payload direct DML by macro proof Data inside staging table — no birth_registry required because staging-tier data is by design non-governed-entity-level (no species mapping for staging-record content) VALID per D36 design

No QT-001 or QT-002 violation. No orphan or half-born object. No rollback needed.

Birth Gate WARNING triage (SUSPECT:D36-Macro-A)

The SUSPECT: prefix on collection_registry._dot_origin for COL-IUS-001/002 is produced by fn_validate_dot_origin (BEFORE INSERT trigger on collection_registry). The function checks whether the leading DOT code (before the first |) exists in the dot_tools table; if not, it prepends SUSPECT:. D36-Macro-A is a macro label, not a registered DOT tool codedot_tools has 309 rows but none named D36-Macro-A. The function never blocks the INSERT; it only annotates.

This pattern is historically accepted: prior SUSPECT-prefixed entries include DOT-IU-CUTTER, DOT-IU-CUTTER-VERIFY, DOT-TAC-LABEL-FORMAT-VERIFY, DOT-TAC-LABEL-FACET-VERIFY, DOT-TAC-LABEL-VERIFY, DOT-TAC-VECTOR-VERIFY, tbl_event_outbox, table_registry::21. The mechanism is a soft governance warning + audit trail, not a defect. TD-411 (a known TODO in the function body) tracks moving the whitelist to a dot_origin_whitelist table.

Triage outcome: ACCEPTED PATTERN. Documentation reconciliation only. Optional follow-up: register D36-Macro-A (and other macro labels) into dot_tools or land TD-411 dot_origin_whitelist.

Auto-birth pipeline — confirmed LIVE

Auto-birth from catalog INSERT exists and is wired:

  • collection_registry has 8 functional triggers (excluding RI constraints), including birth_trigger_collection_registry + trg_birth_collection_registry (duplicate-pair on AFTER INSERT) calling fn_birth_registry_auto('code'); trg_before_birth_gate_collection_registry (BEFORE INSERT → fn_birth_gate); trg_auto_code_collection_registry (auto-codes COL-NNN); trg_desc_guard_collection_registry; trg_desc_provenance_collection_registry; trg_validate_dot_origin_collection_registry; trg_collection_onboarding_soft_gate.
  • entity_species has analogous chain: trg_birth_entity_species + birth_trigger_entity_speciesfn_birth_registry_auto('code'); trg_desc_guard_entity_species; trg_desc_provenance_entity_species; trg_refresh_orphan_species; trg_refresh_species_count.
  • species_collection_map also has birth_trigger_species_collection_mapfn_birth_registry_auto() (no code arg → synthetic key).
  • birth_registry itself has trg_birth_auto_certify, trg_birth_change_flag_matrix.

This is the QT-001-style auto-backfill described in birth-process-v1.md — implemented via trigger chain, fired automatically on catalog INSERT, idempotent (ON CONFLICT DO NOTHING).

NVSZ governance row inventory

Registry Row State
entity_species SPE-NVS (id 51, prefix IUS, level 1, governed, vector_eligible=false in kg_metadata) PRESENT
collection_registry COL-IUS-001 (id 190, iu_staging_record, GRP-GOVERNANCE, governed, species SPE-NVS, birth_identity_source migration_seed, coverage_status BIRTH_REQUIRED) PRESENT, _dot_origin=SUSPECT:D36-Macro-A
collection_registry COL-IUS-002 (id 191, iu_staging_payload, same shape as 001) PRESENT, _dot_origin=SUSPECT:D36-Macro-A
species_collection_map (SPE-NVS, iu_staging_record, is_primary=true) id 172 PRESENT
species_collection_map (SPE-NVS, iu_staging_payload, is_primary=false) id 173 PRESENT
collection_registry_vector_policy sidecar row for id 190 (vector_eligible=false, semantic_search_eligible=false, reason "D36 Rule N1 — No-Vector Staging Zone…") PRESENT
collection_registry_vector_policy sidecar row for id 191 (same) PRESENT
birth_registry SPE-NVS (collection_name=entity_species, species_code=species, dot_origin D36-Macro-A — clean, no SUSPECT prefix because entity_species has no trg_validate_dot_origin), status born, certified=false PRESENT
birth_registry COL-IUS-001 (collection_name=collection_registry, dot_origin SUSPECT:D36-Macro-A), status born, certified=false PRESENT
birth_registry COL-IUS-002 (collection_name=collection_registry, dot_origin SUSPECT:D36-Macro-A), status born, certified=false PRESENT
tac_birth_gate_config 3 new D36 gates: iu_core.no_vector_staging_excluded (block, enabled), iu_core.staging_cleanup_enabled (block, disabled), iu_core.staging_writes_enabled (block, disabled) PRESENT
dot_tools D36-Macro-A ABSENT (cause of SUSPECT prefix; 309 rows total, none named D36-Macro-A)

No orphan, no half-born object, no missing mandatory row.

Pass criteria check

Criterion Result
QT-001/QT-002 definitions confirmed from KB + live evidence PASS — ops/processes/birth-process-v1.md (re-read full) + fn_birth_registry_auto source inspected live
NVSZ Macro A objects classified PASS — Case 3 (Catalog Auto-Birth), per Pack 2A doc
Auto-birth behavior verified live PASS — 28 triggers inventoried on the 4 governance tables; fn_birth_registry_auto definition retrieved
All NVSZ birth/governance rows accounted for PASS — 11 expected rows present, 0 missing, 0 orphan
Birth Gate SUSPECT: warning triaged PASS — annotation, not block; accepted historical pattern; TD-411 tracks the canonical fix
Clear next action recommended PASS — documentation reconciliation now, optional dot_tools row for macro labels, full TD-411 follow-up
KB reports uploaded + verified (this report set)
No production mutation occurred PASS — read-only role, AST-validated SELECT only

Next action recommendation

No fix needed for substrate or birth records. Recommended: documentation reconciliation (this audit package), plus optionally:

  1. Add a single dot_tools row for D36-Macro-A (or, more cleanly, macro labels as a family) to clear the SUSPECT prefix on COL-IUS-001/002 — this is a 1-row INSERT + an UPDATE to strip the prefix on the 2 rows; separate fix phase, not part of this audit.
  2. Land TD-411: move the validate-dot-origin whitelist into a dot_origin_whitelist table so future macros register their label declaratively.
  3. Adopt the rule established by [[feedback-birth-execution-plan-hard-gate-precedes-apply]] for Macro B onward: Birth Execution Plan BEFORE any CREATE TABLE/VIEW/FUNCTION when the Collection Birth Hard Gate is invoked.

Reports

  • 01-qt001-qt002-definition.md — Live + KB-confirmed definitions
  • 02-live-birth-pipeline-survey.md — All triggers, functions, gate config
  • 03-nvsz-object-birth-state.md — Per-object birth + registry state
  • 04-classification-verdict.md — QT classification with justification
  • 05-birth-gate-warning-triage.md — SUSPECT prefix root cause + accepted-pattern evidence
  • 06-fix-or-reconcile-plan.md — Doc reconcile + optional 2-step SUSPECT cleanup
  • 07-carry-forward.md — TD-411, Macro B governance-order rule, dot_tools macro-label policy
Back to Knowledge Hub knowledge/dev/laws/dieu44-trien-khai/v0.6-d36-nvsz-birth-pipeline-audit-qt-classification/00-summary.md