KB-17E1

08 — Static Literal & Live-Count Refactor

3 min read Revision 1

08 — Static Literal & Live-Count Refactor

The AX-PXT actionability ledger mixes live TRIG branches (from v_ax_process_trigger_crosscheck) with static-literal PROC branches. This phase makes the literals measurable and provides a live ledger.

v_rp_static_literal_live_mismatch (detector)

gap_code literal live live_source status
PROC:official_rp 0 0 axis_assignment official AX-PROCESS LITERAL_MATCHES_LIVE
PROC:new_candidates 6 6 wf_process_candidate PROCESS_CANDIDATE LITERAL_MATCHES_LIVE
PROC:jobcut_verified 1 1 job_queue cut.% exists LITERAL_MATCHES_LIVE
PROC:residual_reconcile 8 2 residual_v4 AWAITING_OWNER_RECONCILE STALE_LITERAL
PROC:owner_gated_runtime 11 NULL (11 docker runtime services) STATIC_NO_LIVE_SOURCE

1 STALE_LITERAL (residual 8 vs live 2) and 1 STATIC_NO_LIVE_SOURCE (owner_gated 11 — no clean SQL source; operator-confirmed constant).

Note on the prior "TRIG:job_queue 8 vs live 13" concern: not reproduced. Live job_queue distinct kinds = 8, equal to the crosscheck value the TRIG branch already uses (live). The only genuinely stale literal is PROC:residual_reconcile.

v_process_trigger_actionability_ledger_live

Same 12-row shape as the prod ledger, but PROC counts are live-derived with a count_provenance column:

  • official_rp → live_axis_assignment (0)
  • residual_reconcile → live_residual_v4 (2, was 8)
  • new_candidates → live_wf_process_candidate (6)
  • jobcut_verified → live_job_queue (1)
  • owner_gated_runtime → static_no_live_sql_source (11, explicitly flagged)
  • TRIG:* → live_crosscheck

Disposition

  • Prod v_process_trigger_actionability_ledger is untouched (no clobber). The live variant + detector are additive.
  • The UI _current count surfaces should consume the live ledger or render a loud STALE badge where status='STALE_LITERAL'.
  • The residual stale literal also drives one of the 2 invariant FAILs (Phase 6): the grouped substrate (23) doesn't match the headline (8) — the genuine fix is to scope the residual grouping to AWAITING_OWNER and align the headline to live. That is the next safe-engineering step.
Back to Knowledge Hub knowledge/dev/reports/architecture/rp-contract-canonical-registry-driven-fullpop-nohardcode-closeout-2026-06-05/08-static-literal-live-refactor.md