Repository navigation
Description
Background
Feedback from a real production debugging session, after Verfix correctly captured every artifact but the user still had to diagnose two failures by hand:
Net take: Verfix did the capture work correctly (screenshots, DOM snapshots, console/network logs were all there and accurate) — the gap is entirely in synthesis. It hands you raw forensic material and a generic fix_hint template, but doesn't connect the dots itself. Both issues here were "the evidence was in the trace the whole time," not "the evidence was missing."
Concretely: a selector_not_found whose real cause was an open onboarding dialog (the templated fix_hint said "fix the selector"), and an early Failed to fetch console error that was never connected to a selector failure several steps later. Diagnosing each cost multiple manual round-trips over raw artifacts.
Architecture
Real-world failure causes are open-ended — we can't enumerate them. So coverage cannot come from classifiers. The design is two layers, weighted toward the first:
Layer 1 — universal evidence surface (the coverage mechanism). Cause-agnostic, so it works for failures nobody predicted:
- Facts, not diagnoses, in the failure JSON: what was observably true at failure time (URL, open dialogs/overlays with accessible names, visible-element summary, prior console-error/failed-request counts). Facts have no false positives.
- Queries over the recorded run:
show --timeline(interleaved steps/console/network) andshow --dom(query the saved snapshot) — replacing the throwaway scripts users currently write. - A taught process: a diagnosis playbook in the generated
.verfix/INSTRUCTIONS.md, so the reader of a failure always knows the next question to ask and can answer it in one command.
Layer 2 — deterministic analyzers (accelerators, not coverage). A registry of pure functions over the captured evidence that emit typed, hypothesis-language findings[] for the handful of causes that recur constantly. Precision over recall: silent when unsure, capped, no LLM anywhere ("deterministic first"). When no analyzer matches, Layer 1 keeps diagnosis cheap.
The JSON output contract is stable and agent-facing — everything here is additive (new fields only).
Work items
Layer 1 (independent of each other):
- feat(workers): report cause-agnostic failure-time facts (page state, prior anomalies) in failure JSON #55 failure-time facts in failure JSON
- feat(cli):
verfix show --timeline— interleaved steps/console/network view of a run #56verfix show --timeline - feat(cli):
verfix show --dom <selector>— query the saved failure-time DOM snapshot #57verfix show --dom <selector>
Layer 2 (#58 first; #59/#60 build on it, #59 also needs #55):
- feat(workers): deterministic failure-analyzer pipeline with additive
findings[]in failure JSON #58 analyzer pipeline +findings[]contract (refactors the existing stale-session hint in as analyzer feat(cli): add runtime bootstrap flow verfix init #1) - feat(workers): blocking-overlay analyzer — flag open modals/overlays on selector failures #59 blocking-overlay analyzer
- feat(workers): prior-console-errors analyzer — correlate earlier console errors with a later failure #60 prior-console-errors analyzer
Last (documents the above — written once they exist):
- docs(cli): failure-diagnosis playbook in generated .verfix/INSTRUCTIONS.md #61 diagnosis playbook in
.verfix/INSTRUCTIONS.md
Success test
Take a failure cause none of these issues anticipates. Analyzers say nothing (correctly) — but the failure JSON still reports what was on screen and what misbehaved earlier, --timeline shows the sequence, and the playbook says how to look. If that holds, synthesis coverage is universal even though the analyzer taxonomy never will be.
Activity
jyotir-aditya commentedon Jul 11, 2026
All seven work items shipped: #56/#57 (evidence queries, PRs #78/#79), #58 (analyzer pipeline + findings[], #75), #60 (prior-console-errors, #81), #55 (failure-time page_state facts, #84), #59 (blocking-overlay analyzer, #86), #61 (diagnosis playbook, #85).
The success test from this issue's design holds: for a failure cause no analyzer anticipates, the failure JSON still reports page_state facts (URL, open dialogs, prior anomaly counts), show --timeline/--dom answer the follow-up questions, and the generated playbook teaches the escalation order. Analyzer additions from here are accelerators, not coverage — and the next gate before growing that taxonomy should be the loop-closure benchmark (#66), which measures whether any of this actually reduces agent fix cycles.