Repository navigation
feat(semantic): add P4 evaluator and public-set measurements - #101
Conversation
Add semantic off/shadow/on evaluator integration for all four public sets, per-scene metrics/cache/budget accounting, checked-in reports, host round-trip coverage, and P4 docs/changelog. The lane remains off by default; public-set repair and p95 gates fail and are reported honestly.
VerifiedOrganic
left a comment
There was a problem hiding this comment.
Changes requested. The evaluator currently computes semantic warning precision from plant recall and compares per-scene totals with per-call activation limits. Those measurement errors need correction before the checked-in gate interpretation is reliable. Required changes are inline. Reviewed 7840dee against base 54503f4. Static inspection only; no tests, builds, or project programs executed.
Score precision over warning instances with TP/FP plant matching (null for zero denominator), add per-call receipts to the semantic summary, compute p95/repair from actual dispatches, and refresh docs/results.
VerifiedOrganic
left a comment
There was a problem hiding this comment.
Changes requested. Warning-instance precision/null handling and successful-call token percentiles are fixed. The remaining per-call measurement finding is not fully resolved: repair rate uses candidate scenes as its denominator, and failed/time-out dispatches do not receive receipts and vanish from metrics. Required follow-ups are inline. Reviewed 0226931 against base 54503f4, including the latest diff. Static inspection only; tests and project programs were not executed.
Emit call receipts for failed/timed-out dispatches and compute repair rate over actual dispatches with a zero-call guard. Refresh P4 reports/docs to per-call p95 and shadow/on repair rates.
VerifiedOrganic
left a comment
There was a problem hiding this comment.
Approved. The remaining accounting findings are addressed: repair_rate is repair dispatches / all dispatches, repaired-scene rate is reported separately, and failed/time-out dispatches now contribute receipts with elapsed time and reserved input usage. Reports/docs were regenerated, and an offline metric fixture distinguishes call-level statistics from scene totals. The prior warning-instance precision and per-call percentile fixes remain intact. Reviewed df38fb7 against base 54503f4, including the latest follow-up diff. No further required changes found. Static inspection only; tests and project programs were not executed.
Summary
P4 of the 0.4 semantic continuity lane: evaluator integration for
--semantic off|shadow|on, live five-metric evaluation over the four public sets, the no-route host round-trip acceptance path, and documentation/changelog updates. The default remainssemantic_mode = off.What changed
evals/continuity_recall.pyaccepts--semanticand--semantic-judge-identityforrun,held-out,held-out-2, andheld-out-3.evals/semantic_eval.pyseeds each set once, runs shadow first, then on against the same projects (cache-backed), and reports:check_consistencyoutput (semantic_scene_summaries), with bounded/schema/profile updates.evals/results/semantic_p4_*.json.host_report_emits_in_on_mode_and_shadow_counts_without_findingstest: prepare request → host report → validated findings, with no judge route configured.Unreleased (0.4.0). No migration.Live evaluation
Judge config held constant throughout:
ollama:gemma4:31bviaai run OLLAMA_API_KEY -- .... The evaluator runs shadow first, then on against the same projects; the on pass reuses the validated cache. P95s are per actual dispatch receipt, including failed/timeout dispatches; scene totals are retained for cost.Why zero warnings, including info?
The judge returned zero contradiction verdicts on every set. All validated judgments were compatible or insufficient, and every confidence landed in the top bucket (>=0.85):
not_contradictionNothing was discarded downstream: there was no contradiction to promote, downgrade, or emit as info. Truncation/repair rates are a quality problem but are not the cause of the zero-warning result.
Activation gate fails: no semantic recall lift, warning precision is
null(zero denominator), evidence validity is vacuous, and repair rates (19-50%) exceed <=10%. Per-call prompt/output/latency ceilings pass; control warnings did not rise. Default remains off.Cost: no provider price is configured, so no dollar figure was fabricated. Held-out-4 was not accessed.
Gates
-D warnings, and fmt: pass (p4_final2run; clippy allow for the per-call helper only).semantic_eval_self_test), CLI self-test, and P3 host/cache tests: pass.