mirror of
https://github.com/catlog22/Claude-Code-Workflow.git
synced 2026-03-30 20:21:09 +08:00
Convert team-interactive-craft, team-motion-design, team-visual-a11y, team-ui-polish from Claude agent format to Codex v4 API (spawn_agent, wait_agent, close_agent, request_user_input). Each skill includes SKILL.md with Delegation Lock + v4 Coordination, coordinator with Scope Lock, worker roles with preserved domain content, and specs. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
5.4 KiB
5.4 KiB
role, prefix, inner_loop, message_types
| role | prefix | inner_loop | message_types | ||||
|---|---|---|---|---|---|---|---|
| verifier | VERIFY | false |
|
Verification & Regression Check
Before/after comparison verification. Re-scan fixed code against same 8 dimensions, calculate improvement, detect regressions. Acts as Critic in the optimizer<->verifier Generator-Critic loop.
Phase 2: Context & Artifact Loading
| Input | Source | Required |
|---|---|---|
| Original scan report | /scan/scan-report.md | Yes |
| Fix log | /optimization/fix-log.md | Yes |
| .msg/meta.json | /wisdom/.msg/meta.json | Yes |
| Anti-patterns catalog | specs/anti-patterns.md | Yes |
| Design standards | specs/design-standards.md | Yes |
| Scoring guide | specs/scoring-guide.md | Yes |
- Extract session path from task description
- Read original scan report: parse before-scores per dimension and issue inventory
- Read fix log: parse all fixes applied and files modified
- Read specs for scoring reference
Phase 3: Verification
Step 1: Re-scan Fixed Code
Apply the same 8-dimension scan as the scanner role (reference roles/scanner/role.md Phase 3) to the current state of files. Use identical checklist items and scoring criteria.
If Chrome DevTools available:
- Take screenshots at same 3 viewports (mobile 375px, tablet 768px, desktop 1440px)
- Save to
<session>/evidence/after-mobile.png,after-tablet.png,after-desktop.png
Step 2: Calculate Score Delta
For each dimension, compare before and after:
| Dimension | Before | After | Delta | Status |
|---|---|---|---|---|
| 1. Anti-Patterns | X/4 | Y/4 | +/-N | improved/same/regressed |
| 2. Color Quality | X/4 | Y/4 | +/-N | improved/same/regressed |
| 3. Typography | X/4 | Y/4 | +/-N | improved/same/regressed |
| 4. Spacing/Layout | X/4 | Y/4 | +/-N | improved/same/regressed |
| 5. Motion | X/4 | Y/4 | +/-N | improved/same/regressed |
| 6. Interaction States | X/4 | Y/4 | +/-N | improved/same/regressed |
| 7. Visual Hierarchy | X/4 | Y/4 | +/-N | improved/same/regressed |
| 8. Responsive | X/4 | Y/4 | +/-N | improved/same/regressed |
| Total | X/32 | Y/32 | +/-N |
Step 3: Regression Detection
Check for NEW issues not present in original scan report:
| Check | Method |
|---|---|
| New issues introduced | Compare current issue inventory against original. Any issue not in original = regression |
| Score dropped | Any dimension score lower than before = regression |
| Positive findings broken | Items from original "Positive Findings" no longer hold |
| Build broken | Modified files have syntax errors or lint failures |
Classify regressions:
- Critical: Score dropped in any dimension, WCAG AA violation introduced, build broken
- Non-critical: New minor issues introduced but overall score improved
Step 4: Determine Signal
| Condition | Signal |
|---|---|
| No regressions AND total score >= before score | verify_passed |
| Non-critical regressions AND total score improved | verify_failed (fixable) |
| Critical regressions OR total score dropped | fix_required (urgent) |
Phase 4: Generate Verification Report
Output: <session>/verification/verify-report.md
# Verification Report
## Verdict: <PASSED | FAILED | FIX REQUIRED>
## Score Comparison
| Dimension | Before | After | Delta |
|-----------|--------|-------|-------|
| 1. Anti-Patterns | X/4 | Y/4 | +N |
| 2. Color Quality | X/4 | Y/4 | +N |
| 3. Typography | X/4 | Y/4 | +N |
| 4. Spacing/Layout | X/4 | Y/4 | +N |
| 5. Motion | X/4 | Y/4 | +N |
| 6. Interaction States | X/4 | Y/4 | +N |
| 7. Visual Hierarchy | X/4 | Y/4 | +N |
| 8. Responsive | X/4 | Y/4 | +N |
| **Total** | **X/32** | **Y/32** | **+N** |
## Before Rating: <rating-band> -> After Rating: <rating-band>
## Regressions Found
<list of regressions with location, severity, description>
<or "None" if clean>
## Remaining Issues
<issues from original scan that were NOT fixed>
## Improvements
<per-dimension improvement details>
## Screenshots
- Before: <session>/evidence/before-*.png
- After: <session>/evidence/after-*.png
<or "Chrome DevTools not available" if no screenshots>
## Metadata
- Original scan: <session>/scan/scan-report.md
- Fix log: <session>/optimization/fix-log.md
- GC round: <round number>
- Timestamp: <ISO timestamp>
After writing the report, send signal-appropriate message:
If verify_passed:
mcp__ccw-tools__team_msg(session_id, role="verifier", type="verify_passed", content="Verification passed. Score: before X/32 -> after Y/32 (+N). No regressions.")
report_agent_job_result({ result: "[verifier] VERIFY-001 passed. Score: X/32 -> Y/32 (+N). No regressions. Report: <session>/verification/verify-report.md" })
If verify_failed:
mcp__ccw-tools__team_msg(session_id, role="verifier", type="verify_failed", content="Verification failed. N non-critical regressions found. Score: X/32 -> Y/32.")
report_agent_job_result({ result: "[verifier] VERIFY-001 failed. N regressions (non-critical). Score: X/32 -> Y/32. Report: <session>/verification/verify-report.md" })
If fix_required:
mcp__ccw-tools__team_msg(session_id, role="verifier", type="fix_required", content="Fix required. N critical regressions. Score dropped: X/32 -> Y/32.")
report_agent_job_result({ result: "[verifier] VERIFY-001 fix_required. N critical regressions. Score: X/32 -> Y/32 (DROPPED). Report: <session>/verification/verify-report.md" })