一键导入
visual-review-pipeline
Automated visual review pipeline — Playwright screenshots, self-analysis, fix loop, escalation. Used by Aphrodite for UI verification.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Automated visual review pipeline — Playwright screenshots, self-analysis, fix loop, escalation. Used by Aphrodite for UI verification.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | visual-review-pipeline |
| description | Automated visual review pipeline — Playwright screenshots, self-analysis, fix loop, escalation. Used by Aphrodite for UI verification. |
| applyTo | agents/{aphrodite,zeus}.agent.md |
Automated visual review: Aphrodite captures screenshots via Playwright MCP → Self-analyzes for visual issues → Addresses findings in a loop.
This pipeline establishes a formal workflow for detecting and resolving visual regressions and design issues. It enforces structured JSON output, iteration limits, and escalation criteria to prevent infinite fix loops.
Aphrodite implements UI
↓
Playwright screenshot (browser/screenshotPage)
↓
Aphrodite self-analyzes (layout, contrast, responsive, accessibility)
↓
├─ verdict: pass → proceed to Themis review
├─ verdict: fail + iteration < 3 → fix → re-capture
└─ verdict: fail + iteration = 3 → Zeus escalation
Aphrodite uses Playwright MCP to capture screenshots.
browser/screenshotPagescreenshot-iteration-N-component.pngAphrodite self-analyzes screenshots visually.
pass_if_fixed IDsAphrodite addresses each finding from self-analysis.
Repeat Steps 1-3 for up to 3 iterations.
pass_if_fixed issueZeus intervenes if issues persist after 3 iterations.
Aphrodite must return findings in this exact structure:
{
"verdict": "pass | fail | warn",
"iteration": 1,
"max_iterations": 3,
"issues": [
{
"id": "VIS-001",
"category": "layout",
"severity": "high",
"description": "Sidebar overflows on viewport width < 768px",
"screenshot_region": "left-panel at x:0,y:0 width:300px",
"recommendation": "Add responsive breakpoint to collapse sidebar below 768px"
}
],
"summary": "One-line summary of overall visual state",
"pass_if_fixed": ["VIS-001", "VIS-002"]
}
| Field | Type | Description |
|---|---|---|
verdict | enum | pass = no issues, fail = blocking, warn = non-blocking |
iteration | int | Current iteration number (1-3) |
max_iterations | int | Always 3 |
issues | array | List of visual issues found |
issues[].id | string | Unique ID in format VIS-NNN |
issues[].category | enum | Issue category (see Categories) |
issues[].severity | enum | Severity level (see Severity) |
issues[].description | string | Clear description of the issue |
issues[].screenshot_region | string | Bounding box or region reference |
issues[].recommendation | string | Suggested fix |
summary | string | One-line overall assessment |
pass_if_fixed | string[] | Issue IDs that must be resolved to pass |
| Category | Description | Examples |
|---|---|---|
layout | Positioning, alignment, overflow | Element misplaced, container overflow, z-index issues |
contrast | Color contrast, visibility | Text hard to read, low contrast ratio |
responsive | Mobile/tablet behavior | Elements break at specific breakpoints |
missing_element | Expected element not rendered | Button not visible, icon missing |
typography | Font, size, weight, spacing | Wrong font family, text truncation |
spacing | Margins, padding, gaps | Uneven spacing, cramped elements |
accessibility | ARIA, focus states, keyboard nav | Missing alt text, no focus ring |
| Level | Description | Action Required |
|---|---|---|
critical | Blocks user interaction or content | Must fix before merge |
high | Significant visual regression | Must fix before merge |
medium | Noticeable but not blocking | Fix in current sprint |
low | Minor polish item | Backlog, fix when convenient |
pass_if_fixed issueverdict is pass, stop iteratingIteration N:
- Compare pass_if_fixed list to previous iteration
- If any ID removed from pass_if_fixed → progress detected
- If pass_if_fixed unchanged → zero progress → escalate
Zeus must be invoked when:
pass_if_fixed issues resolved in an iterationEscalation format:
@zeus Visual review escalation: [component] failed after [N] iterations.
Remaining issues: [list of unresolved pass_if_fixed IDs]
Root cause: [backend | architectural | conflicting]
browser/screenshotPage for full-page capturesbrowser/snapshot for accessibility tree context⚠️ Playwright MCP unavailable — visual review skipped.
Install Playwright MCP server to enable visual review pipeline.
For UI implementation review, Aphrodite self-reviews.
IMPL- artifacts. Escalation decisions documented in _notes/.01-active-context.md. Architectural visual decisions recorded as _notes/NOTE000X-*.md.1. Aphrodite captures screenshot of LoginButton
→ screenshot-iteration-1-login-button.png
2. Self-analysis returns:
{
"verdict": "fail", "iteration": 1,
"issues": [{
"id": "VIS-001", "category": "contrast", "severity": "high",
"description": "White text on light blue bg, contrast ratio 2.1:1",
"recommendation": "Darken background to #1a56db"
}],
"pass_if_fixed": ["VIS-001"]
}
3. Fix contrast, re-capture → screenshot-iteration-2-login-button.png
4. Re-analysis: { "verdict": "pass", "iteration": 2, "issues": [],
"summary": "All visual issues resolved", "pass_if_fixed": [] }
5. Pipeline complete — 2 iterations, all issues fixed.
Tool-agnostic search — query construction, tool selection, source trust hierarchy.
Auto-continue through todos with idle detection and safety gates. Use for multi-step orchestration.
Level 2 — Pantheon-native context compression with priority scoring, semantic summarization, downstream-aware compression, budget allocation, and cross-references
Multi-agent orchestration with model routing, category delegation, and sprint management. Use for coordinating Pantheon agents.
MCP security hardening — credential leakage prevention, input sanitization, and tool access control. Use for reviewing agent MCP configurations.
Load prompts from external files with path expansion. Use for version-controlled prompts outside config.