# Changelog — visual-competitive-analysis Autoresearch

Version: visual-competitive-analysis-v2  
Target skill: /root/.openclaw/workspace/skills/visual-competitive-analysis/SKILL.md  
Working dir: /root/.openclaw/workspace/skills/visual-competitive-analysis/autoresearch-visual-competitive-analysis/  
Max score: 30 (6 evals × 5 runs)  
Budget cap: 10 experiments  

## Eval Suite

**EVAL 1: Step 0 First**  
Question: Does the skill instruct to run Step 0 agency source extraction BEFORE touching the live site?  
Pass: Step 0 is gated — explicit mandate to complete before any HTML generation or live site visit  
Fail: Step 0 is optional, comes after page structure, or can be skipped  

**EVAL 2: All 10 Core Sections**  
Question: Are all 10 core sections present with correct IDs (facts, positioning, evolution, color, type, layout, assessment, verdict, personality, vs-client)?  
Pass: All 10 sections present as separately identifiable HTML sections with correct IDs  
Fail: Any of the 10 is missing, merged with another section, or missing required ID  

**EVAL 3: CE Fonts + Colors Only**  
Question: Does the output use ONLY Larken/Inter/JetBrains Mono AND ONLY the 6 CE color tokens?  
Pass: Only CE-specified fonts and color vars used for UI chrome (not competitor data display)  
Fail: Any non-CE font or color used in layout/text/borders  

**EVAL 4: Sticky Nav + Scrollspy**  
Question: Is a sticky section nav present with IntersectionObserver scrollspy active-state detection?  
Pass: position:sticky nav with IntersectionObserver updating .active class on scroll  
Fail: No sticky nav, no scrollspy, or scrollspy uses scroll event only (not IntersectionObserver)  

**EVAL 5: Agency Images in 2+ Positions**  
Question: Are agency-sourced images placed in at least 2 of the 3 defined positions (hero, alongside/grid, strip)?  
Pass: Real/sourced images (not empty placeholder divs) appear in ≥2 of: hero position, alongside/grid, horizontal strip  
Fail: Fewer than 2 positions have actual images, or all are empty placeholder divs  

**EVAL 6: Named Threat Level + B/R/W**  
Question: Does the Strategic Verdict section include a named Threat Level AND at least one explicit Borrow/Reject/Watch recommendation?  
Pass: Verdict section has a clearly named threat level (e.g., "HIGH", "MEDIUM") AND ≥1 specific Borrow/Reject/Watch item  
Fail: Threat level is missing, vague, or verdict only has placeholders  

**EVAL 7: Visual Image Assessment**  
Question: Does the skill include a step that uses the `image` tool (vision model) to visually assess each captured brand image before including it in the page?  
Pass: Skill explicitly instructs agent to run image analysis on each captured screenshot and asks: (1) Is the brand's visual identity clearly visible? (2) Is this compositionally strong — not a cookie banner, loading state, nav-only crop, or empty page? (3) Does this image represent how the brand wants to be seen? Images that fail must be re-captured or replaced. Must instruct USE of the image/vision tool — not just describe criteria in text.  
Fail: Skill only checks that an image file exists, gives no instruction to visually evaluate image quality using the vision tool, or only describes criteria without mandating tool use.  

**Max score: 35 (7 evals × 5 runs)**

---

## Experiment 0 — BASELINE

**Score:** 21/35 (60.0%)  
**Status:** baseline  
**Change:** original skill — no changes  

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Robinhood | ❌ | ❌ | ✅ | ✅ | ❌ | ✅ | ❌ | 3/7 |
| 2 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ❌ | 5/7 |
| 3 | Oatly     | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ❌ | 5/7 |
| 4 | Robinhood | ❌ | ❌ | ✅ | ✅ | ❌ | ✅ | ❌ | 3/7 |
| 5 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ❌ | 5/7 |

**Eval pass rates:**
- E1 (Step 0 First): 3/5 (60%) — Fails when no agency found (Robinhood in-house). Skill doesn't hard-gate Step 0 before HTML generation.
- E2 (All 10 Sections): 0/5 (0%) — Color (#4) + Typography (#5) always merged into single `#brand-book` section. Template never creates separate `id="color"` and `id="type"` sections. Critical structural failure.
- E3 (CE Fonts+Colors): 5/5 (100%) — Explicitly stated and enforced in skill.
- E4 (Sticky Nav+Scrollspy): 5/5 (100%) — Code example provided, template implements correctly.
- E5 (Agency Images 2+ Positions): 3/5 (60%) — Fails for Robinhood (in-house brand, no public agency case study). Skill has no fallback strategy when Step 0 yields zero images.
- E6 (Named Threat Level+B/R/W): 5/5 (100%) — Verdict grid clearly specified with 4 columns.
- E7 (Visual Image Assessment): 0/5 (0%) — Not in skill at all. No instruction to use the `image` tool to evaluate captured images. Bad images (cookie banners, nav-only crops, empty pages) are included without review.

**Failure patterns:**
1. **E2 is a 0% structural failure** — every single output merges Color and Type into brand-book. The skill table lists them separately but the template and instructions don't enforce separate sections with correct IDs.
2. **E7 is a 0% feature gap** — the skill has no visual quality gate on captured images. The `image` tool is never mentioned.
3. **E1 is unreliable** — Step 0 is marked "ALWAYS first" but there's no execution gate preventing HTML generation before research is done.
4. **E5 partial failure** — no fallback when Step 0 yields zero images.

---

## Experiment 1 — KEEP

**Score:** 26/35 (74.3%) ↑ from 60.0%  
**Change:** Added Phase 3b — Visual Image Review. Inserted mandatory `image` tool quality gate between Step 0 and Step 1. Every captured image must pass 3-check vision assessment (brand visible, clean shot, compositionally strong). FAIL images trigger fallback through 5-tier Image Source Hierarchy. Minimum image counts per position specified.  
**Reasoning:** E7 was 0/5 (not in skill at all). Adding an explicit, mandatory `image` tool call with exact prompt and decision rules directly addresses the gap.  

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Robinhood | ❌ | ❌ | ✅ | ✅ | ❌ | ✅ | ✅ | 4/7 |
| 2 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |
| 3 | Oatly     | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |
| 4 | Robinhood | ❌ | ❌ | ✅ | ✅ | ❌ | ✅ | ✅ | 4/7 |
| 5 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |

**Result:** E7 fixed (0/5 → 5/5, +5 points). E1, E2, E5 still failing. Score: 26/35.  
**Remaining failures:**
- E1 (Step 0 First): 3/5 — still no hard execution gate before HTML generation
- E2 (All 10 Sections): 0/5 — Color and Type still merged, no separate section IDs
- E5 (Agency Images 2+ Positions): 3/5 — Phase 3b adds fallback hierarchy which helps slightly but Robinhood still has no primary agency source; fallback to brand.com screenshots enables the 2nd position but Robinhood runs still don't always reach 2 positions
  
*Note: E5 improves slightly because Phase 3b's Image Source Hierarchy now provides a clear fallback path (brand.com screenshots count as a position). Robinhood runs: hero from live site + alongside from live site = 2 positions. But execution is unreliable without an explicit mandate.*

---

## Experiment 2 — KEEP

**Score:** 29/35 (82.9%) ↑ from 74.3%  
**Change:** Added hard execution gate: "⛔ Do NOT generate any HTML, do NOT open the live site, do NOT write any copy until Steps 0 and Phase 3b are complete." Gate placed at Research Process header AND at Template section (where agents are most likely to start building prematurely).  
**Reasoning:** E1 fails on Robinhood because there's no agency to find — agent sees page structure first and starts building. Adding an explicit ⛔ stop sign before the template and at the research process header makes the ordering unambiguous.

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Robinhood | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |
| 2 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |
| 3 | Oatly     | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |
| 4 | Robinhood | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |
| 5 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |

**Result:** E1 fixed (3/5 → 5/5, +2 points). E5 also fixed (3/5 → 5/5, +2 points) because the gate forces Step 0 completion, which triggers Phase 3b's Image Source Hierarchy, which guarantees 2+ positions via fallback to brand.com screenshots. Total: +4 points. Score: 29/35.  
**Remaining failure:** E2 (All 10 Sections) is the only failing eval — 0/5, every run. Color and Typography sections are always merged into a single `#brand-book` section with no separate IDs.

---

## Experiment 3 — KEEP

**Score:** 34/35 (97.1%) ↑ from 82.9%  
**Change:** Added explicit "Required Section IDs" block before Page UX section. Lists all 10 `<section id>` values as canonical HTML. Added two ⛔ anti-patterns: "Do NOT merge Color and Typography into a single `#brand-book`" and "Do NOT rename these IDs." Updated Page Structure table rows 4 and 5 with "MUST be its own `<section id='color'>`" and `<section id='typography'>` warnings. Updated Quality Checklist to explicitly verify all 10 IDs including separate color/typography check.  
**Reasoning:** E2 fails 0/5 because the template uses `#brand-book` and no instruction explicitly forbids merging. Adding a canonical ID list with ⛔ anti-patterns forces agents to use the correct IDs.

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Robinhood | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 2 | Notion    | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 3 | Oatly     | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 4 | Robinhood | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 5 | Notion    | ✅ | ❌ | ✅ | ✅ | ✅ | ✅ | ✅ | 6/7 |

**Result:** E2 fixed (0/5 → 4/5, +4 points). Run 5 Notion still fails E2: agent used the base template verbatim without reading Required Section IDs block first (the anti-pattern warning wasn't prominent enough in the flow). Score: 34/35 = 97.1%.  
**Remaining failure:** E2 still has 1 failure in 5 runs — the Required Section IDs block is positioned before Page UX but AFTER the Page Structure table. An agent could miss it by following the template without reading forward. Need to make it more prominent.

---

## Experiment 4 — KEEP

**Score:** 35/35 (100%) ↑ from 97.1%  
**Change:** Added ⚠️ warning directly in the Page Structure table header, immediately before the section table. Warning repeats the canonical IDs and explicitly calls out "Color and Typography are always separate sections — never merge them." This fires BEFORE the agent reads the table, closing the gap where agents could start from the template and miss the Required Section IDs block.  
**Reasoning:** The 1-in-5 failure came from reading order — agent started from the table, then opened the template, never reached the standalone Required Section IDs block. Embedding a reminder in the table header fires at first read.

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Robinhood | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 2 | Notion    | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 3 | Oatly     | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 4 | Robinhood | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 5 | Notion    | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |

**Result:** 35/35 (100%). All evals passing. E2 finally 5/5. First time hitting 100%.  
**Consecutive 95%+ count: 1** (need 3 to stop per protocol).

---

## Experiment 5 — KEEP

**Score:** 35/35 (100%)  
**Change:** No change to skill — stability/stress test. Ran 5 times with focus on adversarial conditions: Oatly runs treated as fully in-house brand (no external agency case study found), Robinhood runs with explicit in-house constraint.  
**Reasoning:** Verify the 100% score holds under adversarial conditions before declaring victory. The Image Source Hierarchy (tiers 1-5) ensures agents always have a fallback path, and Phase 3b's vision review catches bad images even from live site screenshots.

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Oatly (in-house only) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 2 | Robinhood (in-house)  | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 3 | Notion                | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 4 | Oatly                 | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 5 | Robinhood             | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |

**Result:** 35/35 (100%). Skill holds under adversarial conditions. Image Source Hierarchy provides sufficient fallback. Phase 3b vision gate catches bad images before they land in the page.  
**Consecutive 95%+ count: 2** (need 3 to stop per protocol).

---

## Experiment 6 — KEEP ✅ STOP CONDITION MET

**Score:** 35/35 (100%)  
**Change:** No change to skill — final verification run across all 3 test inputs in varied order.  
**Reasoning:** Third consecutive 100% run. Stop condition triggered (≥95% for 3 consecutive experiments).

**Per-run breakdown:**

| Run | Input | E1 | E2 | E3 | E4 | E5 | E6 | E7 | Score |
|-----|-------|----|----|----|----|----|----|----|----|
| 1 | Notion    | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 2 | Oatly     | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 3 | Robinhood | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 4 | Oatly     | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |
| 5 | Robinhood | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | 7/7 |

**Result:** 35/35 (100%). **Stopping — 3 consecutive 95%+ experiments achieved.**  
**Consecutive 95%+ count: 3** ✅ STOP

---

## Final Summary

| Metric | Value |
|--------|-------|
| Baseline | 21/35 (60.0%) |
| Final | 35/35 (100.0%) |
| Improvement | +14 points (+40%) |
| Experiments run | 7 (0 baseline + 6 mutations) |
| Kept | 5 |
| Discarded | 0 |
| Budget used | 6/10 experiments |

**Top 4 changes that drove improvement (ranked by points gained):**

1. **Phase 3b Visual Image Review** (+5 pts, Exp 1) — Added mandatory `image` tool quality gate with exact 3-check prompt. Every captured image is vision-assessed before inclusion. FAILs trigger 5-tier Image Source Hierarchy fallback. This was the highest-value single change.

2. **Required Section IDs block** (+4 pts, Exp 3+4) — Added canonical ID list (`#color`, `#typography` as separate sections) with ⛔ anti-pattern rules forbidding `#brand-book` merge. Reinforced with a warning at the Page Structure table header.

3. **Hard execution gate** (+2 pts, Exp 2) — Added ⛔ gate before Template and at Research Process header: "Do NOT generate HTML until Step 0 + Phase 3b are complete." This also fixed E5 by forcing the Image Source Hierarchy to run.

4. **Image Source Hierarchy** (bundled with Phase 3b) — Explicit 5-tier fallback for when agency images aren't available. Guarantees 2+ image positions even for in-house brands with no public agency case study.

---

