Validation Gate (Read-Only, 3 Checks)
Every report passes all 3 checks before delivery. Any failure blocks delivery per HC#8. Fail-open is NOT applied since the skill is read-only.
V1: Format-String Completeness
Check: every measure placement, date pill, and text object identified in Phase 1 has a resolved format string in Phase 2 (or sentinel "unscanned" with rationale).
Required per placement:
placement_id(unique per placement across worksheets and DS).element_type(measure_placement,date_pill, ortext_object).worksheet_nameanddata_source_name(orworkbook_scopefor text elements).format_string(extracted from XML) OR sentinel"unscanned"withreasonpopulated.
Fail action. Re-derive the format string from the target worksheet's XML. If a second run still fails, refuse delivery per HC#8 or flag UNSCANNED. Never leave the format_string blank.
V2: Drift-Catalog Match
Check: every finding cites one of the 7 catalog rule IDs (F-CURRENCY-01 through F-NEGATIVE-07) with the two-or-more differing format strings that fired the rule.
Verification steps:
- Every finding has a
rule_idfrom the locked 7-drift catalog. - Every finding has a
differing_format_stringslist with at least 2 entries. - Every finding cites the specific worksheets or elements where the drift occurred.
- Cross-DS Info-by-default rule is applied correctly per HC#12.
Fail action. Re-run the drift detection against the baseline. If a second run still fails, refuse delivery per HC#8.
V3: Handoff Completeness
Check: every field in format_drift_report/1 populated per skill-expertise/handoff_schema.md.
Verification steps:
- Every required field present with a non-blank value or sentinel.
findings_by_drift_typepopulated with all 7 drift-type counters (some may be 0).unscanned_placementslist populated when any placement was UNSCANNED (empty list otherwise).- Baseline format strings per drift type per DS populated for reproducibility.
Fail action. Identify the missing field, populate with the correct value or sentinel, and re-run V3. If a second run still fails, refuse delivery per HC#8.
Gate Execution Order
- V1 (format-string completeness) first. Cheapest to run; catches most failures.
- V2 (drift-catalog match) next. Validates the drift-detection logic ran correctly.
- V3 (handoff completeness) last. Depends on V1 and V2 to have complete data.
What V-Gate Does NOT Check
- Whether the format strings represent locale-appropriate conventions (route to
i18n-scanner). - Whether the underlying data has quality issues (route to
data-quality-review). - Whether the chart type itself is right for the question (route to
chart-swap-advisor).
Refuse to Fabricate
If the V-gate cannot pass after one retry, refuse delivery and diagnose. Never fake a V-gate pass. Never invent a baseline format string; use the first-seen format string per HC#11.