Agent skill

Design Iteration Loop

by modu-ai in modu-ai/moai-cowork

Runs a builder-and-evaluator cycle that scores a design draft on four dimensions and escalates when the score stalls.

Apache-2.0Auto-check passedAgent Workflows

Install Design Iteration Loop

skills CLI
$ npx skills add modu-ai/moai-cowork --skill design-iteration-loop -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install modu-ai/moai-cowork design-iteration-loop --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/modu-ai/moai-cowork.git skills-src && mkdir -p .claude/skills && cp -r skills-src/plugins/moai-designer/skills/design-iteration-loop .claude/skills/design-iteration-loop && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
design-iteration-loop
GitHub stars
305
Token cost
~2.9k tokens
SKILL.md length
1,199 words
Files
1
Skills in repo
12
Repo updated
First seen
Licence
Apache-2.0

At a glance

Runs a builder-and-evaluator cycle that scores a design draft on four dimensions and escalates when the score stalls.

  • Works in 4 steps: Evaluator analyzes the BRIEF document… → Evaluator produces the Sprint Contract… → Builder reviews the contract → …
  • Running repeated design-quality passes on a UI or brand deliverable
  • SKILL.md covers Quick Reference, Implementation Guide, Advanced Patterns and Works Well With
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

What it does

A repeating builder-evaluator cycle drives this workflow: a builder produces or revises the design, an evaluator scores it, and the pair repeats until the score clears a pass threshold or a maximum number of iterations is reached. Inside a MoAI-ADK project the loop reads those parameters, including the iteration cap and pass threshold, from a project config file; outside that setup it agrees criteria with you instead of inventing numbers.

Each pass is scored across four dimensions: design quality, originality, completeness against the brief, and functionality. The loop also tracks stagnation across iterations, defines an escalation path for when scoring stops improving, and includes a leniency check so the evaluator cannot quietly loosen its own bar.

When your agent uses it

  • Running repeated design-quality passes on a UI or brand deliverable
  • Scoring a draft against a brief before calling it done
  • Deciding whether another design iteration is worth running

Example prompts

  • “Score this homepage draft against the brief on all four dimensions.”
  • “Run another builder-evaluator pass since the last score was borderline.”
  • “Why did the last three iterations stop improving the design score?”

Workflow steps

4 steps, taken from the first numbered list in SKILL.md.

  1. Evaluator analyzes the BRIEF document and current iteration scope.
  2. Evaluator produces the Sprint Contract document
  3. Builder reviews the contract
  4. Contract is saved to design.gan_loop.sprint_contract.artifact_dir/sprint-N.json

What it can do on your machine

Read from SKILL.md and the folder at commit 3e31477. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are json).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Design Iteration Loop loads about 2.9k tokens when it runs. Until then it costs about 97 tokens; SKILL.md has 1,199 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~97
When it runs · the whole SKILL.md, loaded when a task matches
~2.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from modu-ai/moai-cowork at commit 3e31477, republished under its Apache-2.0 licence (© modu-ai). 1,199 words, ~2,893 tokens.

Download SKILL.mdSave it as .claude/skills/design-iteration-loop/SKILL.md (or your agent's skills folder).
name
design-iteration-loop
description
반복적 디자인 품질 개선을 위한 빌더-평가자 GAN 루프 워크플로. 스프린트 컨트랙트 협상, 4차원 평가(디자인 품질·오리지널리티·완결성·기능성), 정체 감지, 에스컬레이션 프로토콜을 구현합니다. design.yaml에서 파라미터를 읽습니다. Use for the Builder-Evaluator GAN loop: iterative design-quality improvement via Sprint Contract negotiation, 4-dimension scoring (Design Quality, Originality, Completeness, Functionality), stagnation detection, and escalation.
metadata.invocation-scope
workflow
metadata.version
1.1.3

MoAI-ADK 프로젝트에서는 .moai/config/sections/design.yaml과 기존 스프린트 산출물을 읽는다. Claude Cowork·ChatGPT Work 데스크톱에서는 사용자가 제공한 브리프와 실제 시안으로 같은 평가 항목을 점검할 수 있다. 설정 파일이나 검사 도구가 없으면 그 항목을 미검증으로 기록하고 점수나 PASS를 만들어 내지 않는다.

design-iteration-loop

Implements the Builder-Evaluator GAN loop for iterative design quality improvement. Absorbed from the retired v2.x design constitution Section 11 and Section 12 (per the design constitution absorption policy). Integrates Sprint Contract Protocol, 4-dimension scoring, stagnation detection, and Evaluator Leniency Prevention.

In a MoAI-ADK project, read loop parameters from .moai/config/sections/design.yaml; the values below describe the current project configuration and are not portable defaults. In a desktop conversation without that file, agree on criteria with the user and report observations without inventing thresholds.


Quick Reference

Loop Parameters (from design.yaml)
design.gan_loop:
  max_iterations: 5          # Maximum Builder-Evaluator cycles
  pass_threshold: 0.75       # Score >= this value to exit loop
  escalation_after: 3        # Escalate to user after N iterations without passing
  improvement_threshold: 0.05  # Minimum score delta per iteration
  strict_mode: false         # If true, each must-pass criterion must pass individually
  sprint_contract:
    enabled: true
    required_harness_levels: [thorough]
    optional_harness_levels: [standard]
    artifact_dir: ".moai/sprints"
    max_negotiation_rounds: 2
4-Dimension Evaluation
DimensionDescription
Design QualityVisual consistency, supplied brand token compliance, measured contrast
OriginalityBrand-specific expression against the supplied brief
CompletenessRequested BRIEF sections present, copy matches the agreed text
FunctionalityObserved responsive behavior and tested interactions

The current design.yaml does not define weights for these dimensions. Do not present 30/25/25/20 or any other split as configured. The ADK evaluator owns the overall score; cite its actual rubric and result. In a standalone desktop review, report each observed dimension and gaps without a synthetic overall score.

In the ADK loop, pass requires the evaluator's measured overall score to reach pass_threshold and every contracted must-pass criterion to pass. Strict mode adds the constitution's two-iteration minimum. A standalone desktop review without a configured evaluator does not issue this numeric PASS.


Implementation Guide

GAN Loop Execution Flow

Phase 1: Sprint Contract (when required by harness level)

Required when harness_level == thorough. Optional when harness_level == standard and user opts in. Skipped when harness_level == minimal.

Sprint Contract generation:

  1. Evaluator analyzes the BRIEF document and current iteration scope.
  2. Evaluator produces the Sprint Contract document:
    • acceptance_checklist: concrete, testable criteria for this iteration
    • priority_dimension: which of the 4 dimensions to focus on
    • test_scenarios: specific verification steps
    • pass_conditions: minimum score per criterion
  3. Builder reviews the contract:
    • Accept: proceed with implementation
    • Request adjustment: propose alternatives (max max_negotiation_rounds rounds)
  4. Contract is saved to design.gan_loop.sprint_contract.artifact_dir/sprint-N.json

Constraint: Evaluator must not score on criteria outside the Sprint Contract. Builder must not claim criteria as met without evidence.

Phase 2: Builder Execution

Builder implements based on:

  • Accepted Sprint Contract (if present)
  • BRIEF document
  • Copy JSON from design-copywriting
  • Design tokens from design-brand-system or design-workflow (Path A handler)

Builder outputs: code files, rendered previews (if Playwright available), implementation notes.

Phase 3: Evaluator Scoring

Evaluator scores against the 4 dimensions using the Evaluator Leniency Prevention mechanisms:

  1. Rubric Anchoring: Score each dimension against the rubric (0.25 increments) with explicit justification. Scores without rubric reference are invalid.
  2. Evidence-Only Verdicts: No PASS without concrete evidence (screenshot, test output, code reference).
  3. Anti-Pattern Cross-check: Check known anti-patterns before finalizing. Any detected anti-pattern caps the relevant dimension score at 0.50.
  4. Must-Pass Firewall: Copy integrity, mobile viewport, and WCAG AA are must-pass criteria. Failure in any must-pass = overall FAIL regardless of other scores.

Output: evaluation-report-N.json in sprint_contract.artifact_dir.

Phase 4: Loop Decision

if overall_score >= pass_threshold:
    EXIT LOOP → proceed to next phase
elif iteration >= max_iterations:
    ESCALATE → present failure report to user
elif stagnation_detected:
    ESCALATE → present stagnation options
else:
    ITERATE → pass feedback to Builder, increment N

Phase 5: Iteration Feedback

If looping back:

  1. Evaluator generates targeted feedback per failed criterion.
  2. Builder receives the feedback and previous Sprint Contract.
  3. Previously passed criteria carry forward (no regression allowed).
  4. New Sprint Contract is generated for failed criteria only.

Stagnation Detection

Stagnation is detected when the score improvement between consecutive iterations is below improvement_threshold for 2 or more iterations.

Tracking:

  • After each iteration, record {iteration: N, score: X} in the sprint artifact.
  • Calculate delta = score[N] - score[N-1].
  • If delta < improvement_threshold for the last 2 iterations, flag stagnation.

When stagnation is detected, present the findings through the available user question channel with three options:

  1. Continue with current approach (Evaluator tries a different dimension focus)
  2. Adjust criteria (user provides guidance or relaxes constraints)
  3. Abort loop (accept current output as-is)

The escalation trigger at escalation_after iterations applies independently: if 3 iterations pass without a PASS score, escalate regardless of stagnation state.


Show full SKILL.md (537 more words)Show less
Evaluator Leniency Prevention Mechanisms

The following 5 mechanisms prevent score inflation and must be applied on every evaluation:

Mechanism 1: Rubric Anchoring

Score descriptions for each dimension:

  • 0.25: Major defects, fails most criteria
  • 0.50: Partial compliance, notable issues remain
  • 0.75: Solid compliance, minor issues only
  • 1.00: Full compliance, no issues found

Always state which rubric level applies and why before assigning a numeric score.

Mechanism 2: Must-Pass Firewall

The following conditions cause immediate FAIL regardless of other scores:

  • Copy text differs from the original copy.json or BRIEF copy section
  • AI slop detected: purple gradient (#8B5CF6-#6D28D9) as primary visual element with generic white cards
  • Mobile viewport broken at 375px width (content overflow, unreadable text)
  • Any interactive element returns 404 or broken state
  • An agreed accessibility criterion fails in a tool result; when Lighthouse is used and the brief sets a threshold, report its measured score

Mechanism 3: Anti-Pattern Penalty

Known anti-patterns that cap dimension score at 0.50:

  • Generic icon set without brand customization (Originality capped)
  • Hard-coded spacing values outside the design token scale (Design Quality capped)
  • Missing alt attributes on non-decorative images (Functionality capped)
  • Section copy that does not match the contracted copy (Completeness capped)

Mechanism 4: Evidence Requirement

Each dimension score must cite specific evidence:

  • Design Quality: Reference supplied tokens and a measured contrast ratio where available
  • Originality: Describe what makes the design non-generic
  • Completeness: List each BRIEF section and its implementation status
  • Functionality: Reference actual test or browser observation; otherwise mark unverified

Mechanism 5: Regression Baseline

If a previous iteration passed a criterion, the current iteration must maintain that criterion. Regression from a previously passed criterion triggers an automatic score reduction in the relevant dimension.


Sprint Contract Structure

Sprint Contract document format (sprint-N.json):

json
{
  "sprint_id": "sprint-N",
  "iteration": N,
  "priority_dimension": "Design Quality | Originality | Completeness | Functionality",
  "acceptance_checklist": [
    {
      "id": "AC-01",
      "criterion": "Hero headline contrast ratio >= 4.5:1",
      "verification": "Check color pair with contrast calculator",
      "status": "pending | passed | failed"
    }
  ],
  "test_scenarios": [
    {
      "id": "TS-01",
      "description": "Mobile viewport renders without horizontal scroll",
      "tool": "Playwright | visual inspection",
      "command": "playwright test --viewport 375x667"
    }
  ],
  "pass_conditions": {
    "Design Quality": 0.75,
    "Originality": 0.70,
    "Completeness": 0.80,
    "Functionality": 0.75
  },
  "negotiation_history": [],
  "created_at": "ISO-8601"
}

Advanced Patterns

Strict Mode

When strict_mode: true in design.yaml:

  • Each contracted must-pass criterion must individually pass, as constitution §11 requires.
  • An overall score cannot compensate for a failed must-pass criterion.
  • Minimum 2 iterations required even if the first iteration achieves a passing weighted average.
  • Strict mode is recommended for client-facing deliverables.
Independent Re-evaluation

Every 5th project triggers an independent re-evaluation:

  • The same build is scored twice with independent prompts.
  • If scores diverge by more than 0.10, a calibration warning is logged.
  • Calibration results are stored in sprint_contract.artifact_dir/calibration-log.json.
Playwright Integration

When a browser or Playwright is available, the Evaluator may run the relevant checks:

  • Desktop screenshot (1280x720): full page
  • Mobile screenshot (375x667): full page
  • Interaction test: click all CTAs, verify no 404
  • Accessibility scan: record the tool and its findings; an automated scan alone does not establish full WCAG conformance

When testing tools are unavailable, record code observations and mark browser behavior, accessibility and interaction criteria unverified. Do not score an unobserved criterion as passed.


Works Well With

  • design-brand-system: Provides design tokens that Evaluator validates in Design Quality dimension
  • design-copywriting: Copy JSON is the reference for Completeness dimension
  • 자체 Evaluator: GAN 루프는 매 스코어링 패스마다 본 스킬의 4-dimension scoring으로 평가합니다. MoAI harness(moai)의 sync-auditor가 함께 설치된 환경에서는 해당 agent로 평가를 보강할 수 있습니다.
  • design-workflow: Extracted tokens (Path A) serve as the design reference baseline

Source: Absorbed from the retired v2.x design constitution per the design constitution absorption policy (Section 11 GAN Loop Contract, Section 12 Evaluator Leniency Prevention). REQ coverage: (internal provenance omitted) Version: 0.1.0

© modu-ai, Apache-2.0. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in plugins/moai-designer/skills/design-iteration-loop of modu-ai/moai-cowork.

Open the folder on GitHubat commit 3e31477

Compare with similar skills

Design Iteration Loop next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Design Iteration Loop compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Design Iteration Loop this skillmodu-ai/moai-cowork305—~2.9kAutomated safety check: PassApache-2.0
Design ReviewPrismer-AI/PrismerCloud1.6k—~1.3kAutomated safety check: NotesMIT
NelsonAspegio/nelson421—~11kAutomated safety check: WarnMIT
Agent Teams PlaybookKimYx0207/Kim_Service174—~2.7kAutomated safety check: PassMIT
Kicad Design Reviewoaslananka/kicad-mcp-pro119—~529Automated safety check: PassMIT
Long Horizon Promptingguanyang/open-agent-hub9731 repos~6.4kAutomated safety check: PassMIT

Similar skills

  • Design Review

    Prismer-AI/PrismerCloud

    Five-dimension design audit (frontend UI/UX · server data-model & flow · endpoint spec · daemon-runtime/SDK & local-cache-first · built-in skill/agent-role), executed by a NON-implementing agent.

    1.6k GitHub stars~1.3k tokensUpdated 7 days ago
    Media & CreativeAuto-check: notes
  • Nelson

    Aspegio/nelson

    Orchestrates multi-agent task execution using a Royal Navy squadron metaphor — from mission planning through parallel work coordination to stand-down.

    421 GitHub stars~11k tokensUpdated 3 mo ago
    Agent WorkflowsAuto-check: warnings
  • Agent Teams Playbook

    KimYx0207/Kim_Service

    Cross-runtime playbook for multi-agent collaboration, agent teams, swarm orchestration, parallel task distribution, capability discovery, and quality gates on Claude Code, Codex, OpenClaw, and Cursor.

    174 GitHub stars~2.7k tokensUpdated today
    Agent WorkflowsAuto-check passed
  • Kicad Design Review

    oaslananka/kicad-mcp-pro

    Comprehensive KiCad design review skill covering schematic, PCB, DFM, manufacturing, high-speed, and simulation review workflows.

    119 GitHub stars~529 tokensUpdated today
    Media & CreativeAuto-check passed
  • Long Horizon Prompting

    guanyang/open-agent-hub

    This skill should be used when writing, enhancing, or evaluating the launch prompt for a long-running autonomous agent or a parallel multi-agent orchestration attacking a hard problem: pseudo-formal…

    973 GitHub starsUsed in 1 repo~6.4k tokens
    Agent WorkflowsAuto-check passed
  • Team Coordination

    bybren-llc/safe-agentic-workflow

    Agent Teams orchestration patterns for multi-agent SAFe workflows.

    421 GitHub stars~1.7k tokensUpdated 2 mo ago
    Agent WorkflowsAuto-check passed

More from modu-ai/moai-cowork

All 12 skills in this repo
  • MoAI Project Initializer

    modu-ai/moai-cowork

    Starts a non-development project in MoAI-Cowork by interviewing you, scanning installed plugins and generating AGENTS.md, CLAUDE.md and custom agent and skill chains.

    305 GitHub stars~3.7k tokensUpdated today
    Auto-check passed
  • AI Slop Reviewer

    modu-ai/moai-cowork

    Detects mechanical patterns in AI-generated prose and rewrites them into natural sentences, for blogs, newsletters, copy, proposals, reports and emails.

    305 GitHub stars~1.9k tokensUpdated today
    Auto-check passed
  • Career Interview

    modu-ai/moai-cowork

    한국 취준생·재직 이직자를 위한 면접 준비·모의 면접·답변 코칭 스킬입니다. An agent skill from modu-ai/moai-cowork.

    305 GitHub stars~1.7k tokensUpdated today
    Auto-check passed
  • Career Portfolio

    modu-ai/moai-cowork

    한국 신입 취준생·재직자를 위한 분야별 포트폴리오 구성과 프로젝트 기술서 작성 스킬입니다. An agent skill from modu-ai/moai-cowork.

    305 GitHub stars~1.9k tokensUpdated today
    Auto-check passed
  • Career Resume

    modu-ai/moai-cowork

    한국 취준생·재직 이직자를 위한 자기소개서·이력서·경력기술서·영문 CV·링크드인 작성 스킬입니다. An agent skill from modu-ai/moai-cowork.

    305 GitHub stars~1.7k tokensUpdated today
    Auto-check passed
  • Career Transition

    modu-ai/moai-cowork

    이직·전직을 감정이 아닌 프로젝트로 설계하도록 돕는 커리어 전환 전략 스킬입니다. An agent skill from modu-ai/moai-cowork.

    305 GitHub stars~1.4k tokensUpdated today
    Auto-check passed

Questions about Design Iteration Loop

What does Design Iteration Loop do?

Runs a builder-and-evaluator cycle that scores a design draft on four dimensions and escalates when the score stalls. A repeating builder-evaluator cycle drives this workflow: a builder produces or revises the design, an evaluator scores it, and the pair repeats until the score clears a pass threshold or a maximum number of iterations is reached. Inside a MoAI-ADK project the loop reads those parameters, including the iteration cap and pass threshold, from a project config file; outside that setup it agrees criteria with you instead of inventing numbers.

When should I use Design Iteration Loop?

Design Iteration Loop fits situations like: running repeated design-quality passes on a UI or brand deliverable; scoring a draft against a brief before calling it done; deciding whether another design iteration is worth running.

How do I install Design Iteration Loop in Claude Code?

Run `npx skills add modu-ai/moai-cowork --skill design-iteration-loop -a claude-code`. Or copy the skill folder (plugins/moai-designer/skills/design-iteration-loop in modu-ai/moai-cowork) into .claude/skills/design-iteration-loop in your project. Claude Code loads it when a task matches its description.

How do I install Design Iteration Loop in Codex?

Run `npx skills add modu-ai/moai-cowork --skill design-iteration-loop -a codex`. Or copy the skill folder (plugins/moai-designer/skills/design-iteration-loop in modu-ai/moai-cowork) into .agents/skills/design-iteration-loop in your project. Codex loads it when a task matches its description.

Can I use Design Iteration Loop in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add modu-ai/moai-cowork --skill design-iteration-loop -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/design-iteration-loop, .gemini/skills/design-iteration-loop, .github/skills/design-iteration-loop and .opencode/skills/design-iteration-loop in your project.

What does Design Iteration Loop need to run?

SKILL.md names no scripts, command-line tools or credentials: Design Iteration Loop is instructions for the agent only.

Does Design Iteration Loop access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Design Iteration Loop safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Design Iteration Loop use?

Design Iteration Loop is published under the Apache-2.0 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Design Iteration Loop use?

About 2.9k tokens (SKILL.md is roughly 12k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Design Iteration Loop?

Skills that share tags, products or a category with Design Iteration Loop: Design Review (Prismer-AI/PrismerCloud, 1.6k stars), Nelson (Aspegio/nelson, 421 stars), Agent Teams Playbook (KimYx0207/Kim_Service, 174 stars) and Kicad Design Review (oaslananka/kicad-mcp-pro, 119 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Design Iteration Loop?

modu-ai (a GitHub organization) maintains it in modu-ai/moai-cowork, which has 305 GitHub stars. The repository holds 12 skills in this directory. The repository was last updated on October 6, 2026.

Source: modu-ai/moai-cowork on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.