@blazediff/agent 0.11.1 → 0.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -14,7 +14,7 @@ Visual regression testing your coding agent can judge. Discovers routes, screens
14
14
  - Source-walking route discovery for Next.js / Vite / Remix (BFS fallback)
15
15
  - Heuristic verdict: `regression-likely | intentional-likely | noise-likely | ambiguous`
16
16
  - LangGraph pipeline with per-entry subgraphs, suspendable via `interrupt()` and resumable from an on-disk checkpoint
17
- - Region-tile handoff to host agents (10 to 100x smaller than full PNGs)
17
+ - Region-tile handoff to coding agents (10 to 100x smaller than full PNGs)
18
18
  - Auto-masking via `data-blazediff-agent-mask` attribute
19
19
  - Auth-protected route capture via a codegen-recorded login harness; credentials live in env vars, never in LLM context
20
20
 
@@ -28,7 +28,7 @@ npm install --save-dev @blazediff/agent
28
28
 
29
29
  ```bash
30
30
  blazediff-agent onboard # interactive: config + chromium + playbook + baselines
31
- blazediff-agent check --judge host # CI: re-capture, diff, judge
31
+ blazediff-agent check --judge agent # CI: re-capture, diff, judge
32
32
  blazediff-agent rewrite home # accept an intentional change
33
33
  ```
34
34
 
@@ -46,7 +46,7 @@ no capture) — a scriptable config + chromium step.
46
46
  <tr><td><code>onboard</code></td><td>Interactive setup: write <code>.blazediff/config.json</code>, install Chromium, install the playbook for your stack (Claude Code / Codex / Cursor, or <code>local</code> for a Moondream + Qwen judge), and optionally capture baselines</td></tr>
47
47
  <tr><td><code>discover</code></td><td>BFS-crawl routes from <code>baseUrl</code></td></tr>
48
48
  <tr><td><code>capture --stdin</code></td><td>Screenshot routes from stdin JSON, write baselines/actuals</td></tr>
49
- <tr><td><code>check</code></td><td>Re-capture, diff against baseline, emit <code>CheckReport</code>. Judge backend defaults to <code>config.judge</code> (set by <code>onboard</code>), overridable with <code>--judge host|none|local</code>. <code>--judge host</code> suspends on the first ambiguous entry (<code>--apply-judgments</code> resumes once verdicts are written); <code>--judge local</code> judges inline with local models (Moondream describes, Qwen classifies) — no host round-trip.</td></tr>
49
+ <tr><td><code>check</code></td><td>Re-capture, diff against baseline, emit <code>CheckReport</code>. Judge backend defaults to <code>config.judge</code> (set by <code>onboard</code>), overridable with <code>--judge agent|none|local</code>. <code>--judge agent</code> suspends on the first ambiguous entry (<code>--apply-judgments</code> resumes once verdicts are written); <code>--judge local</code> judges inline with local models (Moondream describes, Qwen classifies) — no agent round-trip; <code>--model</code> picks which Moondream.</td></tr>
50
50
  <tr><td><code>rewrite &lt;id...&gt;</code></td><td>Re-baseline existing entries (also <code>--failed</code> / <code>--all</code>). Cleans stale <code>actual/</code>, <code>judgments/</code>, <code>report.json</code>, <code>checkpoints/</code> for the rewritten ids.</td></tr>
51
51
  <tr><td><code>diff &lt;id&gt;</code></td><td>Re-diff one entry without re-screenshotting</td></tr>
52
52
  <tr><td><code>manifest</code></td><td>Inspect / list manifest entries</td></tr>
@@ -65,7 +65,7 @@ Pass `--cwd <abs-path>` to target a sub-package in a monorepo.
65
65
  ```bash
66
66
  blazediff-agent onboard --stack codex # explicit
67
67
  blazediff-agent onboard --stack all # claude + codex + cursor
68
- blazediff-agent onboard --stack local # local judge, no host agent (Moondream + Qwen)
68
+ blazediff-agent onboard --stack local # local judge, no coding agent (Moondream + Qwen)
69
69
  blazediff-agent onboard --no-browsers --no-capture # config + playbook only
70
70
  ```
71
71
 
@@ -73,7 +73,7 @@ Other flags: `--url <baseUrl>` (external/running server), `--dev-command <cmd>`
73
73
  `--port <n>` / `--dev-script <name>` (override detection), `--yes` (accept prompts),
74
74
  `--force` (rewrite config + playbook).
75
75
 
76
- For coding-agent stacks, writes the playbook and sets `config.judge: "host"`:
76
+ For coding-agent stacks, writes the playbook and sets `config.judge: "agent"`:
77
77
  - Claude Code → `<project>/.claude/skills/blazediff/SKILL.md`
78
78
  - Codex → `~/.codex/skills/blazediff/SKILL.md`
79
79
  - Cursor → `<project>/.cursor/rules/blazediff.mdc`
@@ -84,6 +84,20 @@ Qwen3.5-0.8B classifies it using that description plus the deterministic
84
84
  `interpret` summary (both via the optional peer dependency
85
85
  `@huggingface/transformers`; install it with `npm i @huggingface/transformers`).
86
86
  Each model loads once on the first judgment and is reused for the rest of the run.
87
+
88
+ `--model` picks the model the local judge reads regions with. It applies only to
89
+ `--judge local`; passing it to another backend is an error.
90
+
91
+ | `--model` | Reader | Notes |
92
+ | --- | --- | --- |
93
+ | `moondream-2-2b-onnx` (default) | in-process ONNX | Runs anywhere, no setup. ~11s per region read. |
94
+ | `moondream-3-9b-mlx` | [Moondream Station](https://docs.moondream.ai/station/) | Apple Silicon only, ~2s per read, needs ~16GB RAM. |
95
+
96
+ The MLX model needs no setup either: the judge installs Station if missing (via
97
+ `uv`), launches it, selects the model, warms it, and stops it on exit — or
98
+ attaches to a Station you already have running and leaves that one alone.
99
+ Station reaches the GPU, which onnxruntime-node cannot for this model. Qwen still
100
+ classifies in-process, and the prompts and region diffing are shared.
87
101
  `local` cannot be combined with the coding-agent stacks.
88
102
 
89
103
  ## Masking
@@ -99,7 +113,7 @@ For third-party embeds you can't annotate, use a per-entry `manifest.entries[].m
99
113
 
100
114
  ## Judging
101
115
 
102
- Every non-match routes through the configured judge. With `--judge host` the judge node `interrupt()`s the LangGraph pipeline, writes a `JudgmentRequest` (region tiles + locator thumbnail) to `.blazediff/judgments/<id>/`, and the suspended graph is checkpointed to `.blazediff/checkpoints/`. The host agent reads the tiles, writes `verdict.json`, and `check --apply-judgments` resumes the same graph with the verdicts. No re-capture, no re-diff.
116
+ Every non-match routes through the configured judge. With `--judge agent` the judge node `interrupt()`s the LangGraph pipeline, writes a `JudgmentRequest` (region tiles + locator thumbnail) to `.blazediff/judgments/<id>/`, and the suspended graph is checkpointed to `.blazediff/checkpoints/`. The coding agent reads the tiles, writes `verdict.json`, and `check --apply-judgments` resumes the same graph with the verdicts. No re-capture, no re-diff.
103
117
 
104
118
  ## Configuration
105
119