Context
ValidateScreenshotWithLLM() was added to lvt/testing (commit 03fb143) — it captures screenshots via chromedp and sends them to Claude for visual analysis. Currently runs only with explicit LVT_VISUAL_CHECK=true on local machines.
Proposal
Add optional CI integration:
- Run as a separate GitHub Actions job (not blocking)
- Only on PRs that modify
*.tmpl files
- Use
claude-haiku-4-5 for cost efficiency (~$0.01/screenshot)
- Report findings as PR comment, not as check failure
- Store
ANTHROPIC_API_KEY as GitHub secret
Current State
- Helper:
lvt/testing/visual.go
- Usage:
e2etest.ValidateScreenshotWithLLM(t, ctx, "page description")
- Gating:
LVT_VISUAL_CHECK=true + ANTHROPIC_API_KEY
- Model:
claude-haiku-4-5
Created from PR review follow-up.
Context
ValidateScreenshotWithLLM()was added tolvt/testing(commit 03fb143) — it captures screenshots via chromedp and sends them to Claude for visual analysis. Currently runs only with explicitLVT_VISUAL_CHECK=trueon local machines.Proposal
Add optional CI integration:
*.tmplfilesclaude-haiku-4-5for cost efficiency (~$0.01/screenshot)ANTHROPIC_API_KEYas GitHub secretCurrent State
lvt/testing/visual.goe2etest.ValidateScreenshotWithLLM(t, ctx, "page description")LVT_VISUAL_CHECK=true+ANTHROPIC_API_KEYclaude-haiku-4-5Created from PR review follow-up.