MetaSpec Iteration Layers - Visual Guide

November 11, 2025 ยท View on GitHub

Quick Reference: When to use which layer and how they work together


๐ŸŽฏ Two Layers of Iteration

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                    MetaSpec Iteration System                    โ”‚
โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค
โ”‚                                                                 โ”‚
โ”‚  Layer 1: Evolution (Formal Change Management)                 โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚
โ”‚  โ”‚ Purpose: Modify specification with controlled process     โ”‚ โ”‚
โ”‚  โ”‚ Commands: /metaspec.proposal โ†’ apply โ†’ archive            โ”‚ โ”‚
โ”‚  โ”‚ Output: changes/[id]/proposal.md, spec-delta.md          โ”‚ โ”‚
โ”‚  โ”‚ Modifies: spec.md (after approval)                        โ”‚ โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚
โ”‚                                                                 โ”‚
โ”‚  Layer 2: Command Iteration (Daily Quality Checks)             โ”‚
โ”‚  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚
โ”‚  โ”‚ Purpose: Validate specification quality                   โ”‚ โ”‚
โ”‚  โ”‚ Commands: /metaspec.sds.checklist (update mode)           โ”‚ โ”‚
โ”‚  โ”‚ Output: checklists/comprehensive-quality.md               โ”‚ โ”‚
โ”‚  โ”‚ Modifies: NEVER modifies spec.md                          โ”‚ โ”‚
โ”‚  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚
โ”‚                                                                 โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ”„ Complete Workflow Diagram

โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
โ”‚                     User wants to change spec                   โ”‚
โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                            โ”‚
                            โ–ผ
                โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
                โ”‚ Is toolkit released?      โ”‚
                โ”‚ (v1.x.x or published)     โ”‚
                โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                            โ”‚
              โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚ YES                       โ”‚ NO
              โ–ผ                           โ–ผ
    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
    โ”‚ Use Evolution Layer  โ”‚    โ”‚ Check change type    โ”‚
    โ”‚                      โ”‚    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
    โ”‚ /metaspec.proposal   โ”‚               โ”‚
    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜     โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚                  โ”‚ Breaking/Major    โ”‚ Minor
              โ”‚                  โ–ผ                   โ–ผ
              โ”‚         โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”  โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
              โ”‚         โ”‚ Use Evolution    โ”‚  โ”‚ Direct Edit    โ”‚
              โ”‚         โ”‚                  โ”‚  โ”‚                โ”‚
              โ”‚         โ”‚ /metaspec.       โ”‚  โ”‚ vim spec.md    โ”‚
              โ”‚         โ”‚   proposal       โ”‚  โ”‚                โ”‚
              โ”‚         โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜  โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
              โ”‚                  โ”‚                     โ”‚
              โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                                 โ”‚
                                 โ–ผ
                    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
                    โ”‚ Execute change       โ”‚
                    โ”‚                      โ”‚
                    โ”‚ Evolution: apply     โ”‚
                    โ”‚ Direct: edit done    โ”‚
                    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                               โ”‚
                               โ–ผ
                    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
                    โ”‚ Validate Quality     โ”‚
                    โ”‚                      โ”‚
                    โ”‚ /metaspec.sds.       โ”‚
                    โ”‚   checklist          โ”‚
                    โ”‚   (update mode)      โ”‚
                    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                               โ”‚
                               โ–ผ
                    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
                    โ”‚ Quality OK?          โ”‚
                    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
                               โ”‚
                    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ผโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
                    โ”‚ YES               โ”‚ NO
                    โ–ผ                   โ–ผ
            โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”    โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
            โ”‚ Evolution:   โ”‚    โ”‚ Fix issues and   โ”‚
            โ”‚ archive      โ”‚    โ”‚ repeat           โ”‚
            โ”‚              โ”‚    โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
            โ”‚ Direct: Done โ”‚
            โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜

๐Ÿ“Š Layer Comparison Table

AspectEvolution LayerCommand Layer
PurposeModify spec.mdValidate spec.md
Modifies Specโœ… YES (after approval)โŒ NO (read-only)
WhenReleased OR Breaking/MajorAnytime (quality check)
WorkflowProposal โ†’ Apply โ†’ ArchiveGenerate โ†’ Update โ†’ Update
Outputchanges/[id]/proposal.mdchecklists/quality.md
OverheadHeavy (formal process)Light (immediate feedback)
Version Controlโœ… RequiredโŒ Not needed
Impact Analysisโœ… RequiredโŒ Not needed
Approvalโœ… RequiredโŒ Not needed

๐ŸŽฎ Usage Scenarios

Scenario 1: Draft Toolkit - Add Example (Minor)

# Toolkit: v0.2.0 (draft)
# Change: Add usage example

1. vim specs/domain/001-mcp/spec.md
   # Add example section

2. /metaspec.sds.checklist
   # AI detects existing checklist
   โ†’ Mode: update (default)
   โ†’ CHK010: โŒ โ†’ โœ… (Examples added)

3. Done! โœ…

Layer used: Command Layer only (no Evolution needed)


Scenario 2: Draft Toolkit - Add New Entity (Major)

# Toolkit: v0.2.0 (draft)
# Change: Add new "Notification" entity

1. /metaspec.proposal "Add Notification entity" --type sds
   โ†’ Creates changes/2025-11-05-add-notification/

2. Review proposal.md and approve

3. /metaspec.apply 2025-11-05-add-notification
   โ†’ Executes tasks, modifies spec.md

4. /metaspec.sds.checklist
   โ†’ Validates new entity quality
   โ†’ CHK001-CHK010: Check Notification entity

5. /metaspec.archive 2025-11-05-add-notification
   โ†’ Moves to archive, updates CHANGELOG

Done! โœ…

Layers used: Evolution Layer + Command Layer (validation)


Scenario 3: Released Toolkit - Fix Typo (Minor but Released)

# Toolkit: v1.0.0 (released)
# Change: Fix typo in description

1. /metaspec.proposal "Fix typo in entity description" --type sds
   โ†’ Even minor changes need Evolution for released toolkit

2. Review and approve

3. /metaspec.apply 2025-11-05-fix-typo
   โ†’ Version: v1.0.0 โ†’ v1.0.1 (PATCH)

4. /metaspec.sds.checklist
   โ†’ Validates fix

5. /metaspec.archive 2025-11-05-fix-typo

Done! โœ…

Layers used: Evolution Layer (required for released) + Command Layer


Scenario 4: Quality Check Only (No Changes)

# Toolkit: any version
# Purpose: Check spec quality

1. /metaspec.sds.checklist
   โ†’ Generates quality report
   โ†’ Identifies issues: CHK003 โŒ, CHK007 โš ๏ธ

2. User reviews issues

3. If fixes needed:
   โ†’ Draft: Direct edit โ†’ Re-run checklist
   โ†’ Released: /metaspec.proposal

Done! โœ…

Layer used: Command Layer only


๐Ÿšฆ Decision Matrix

Toolkit StatusChange TypeMethodExample
Draft (v0.x.x)Fix typoDirect editvim spec.md
Draft (v0.x.x)Add exampleDirect editvim spec.md
Draft (v0.x.x)Add optional fieldDirect editvim spec.md
Draft (v0.x.x)Add required fieldEvolution or Direct*Breaking โ†’ Evolution preferred
Draft (v0.x.x)Add new entityEvolutionMajor change โ†’ Evolution
Released (v1.x.x)Any changeEvolutionALWAYS Evolution

*Note: For draft toolkit, if near release (v0.9.x), use Evolution for breaking changes too.


๐Ÿ”‘ Key Principles

Principle 1: Command Layer Never Modifies

โœ… Checklist reads:
  - specs/domain/XXX/spec.md
  
โœ… Checklist writes:
  - checklists/comprehensive-quality.md
  
โŒ Checklist NEVER modifies:
  - spec.md

Principle 2: Evolution for Formal Changes

Use Evolution when:
  - Toolkit is released (v1.x.x)
  - Breaking changes
  - Major features
  - Need version control and impact analysis

Principle 3: Direct Edit for Fast Iteration

Use Direct Edit when:
  - Toolkit is draft (v0.x.x)
  - Minor, non-breaking changes
  - Fast iteration needed
  - THEN validate with checklist

๐ŸŽฏ No Conflict Between Layers

Q: Can they conflict?
A: No, they serve different purposes.

  • Evolution: MODIFY spec.md (formal process)
  • Command: VALIDATE spec.md (read-only)

They complement each other:

Evolution modifies โ†’ Command validates โ†’ Evolution archives

๐Ÿ“š Reference

For detailed decision guide, see:

  • docs/evolution-guide.md - Complete decision tree
  • memory/constitution.md - Principle #6: Iteration-Aware Design
  • src/metaspec/templates/meta/sds/commands/checklist.md.j2 - Command Layer
  • src/metaspec/templates/meta/evolution/commands/proposal.md.j2 - Evolution Layer

๐Ÿš€ Best Practices

  1. Always validate after modifying

    # After ANY modification (Evolution or direct)
    $ /metaspec.sds.checklist
    
  2. Use Evolution for released toolkits

    # If v1.x.x, ALWAYS use Evolution
    $ /metaspec.proposal "..."
    
  3. Fast iterate in draft phase

    # If v0.x.x, iterate quickly
    $ vim spec.md
    $ /metaspec.sds.checklist  # validate
    $ vim spec.md              # fix issues
    $ /metaspec.sds.checklist  # validate again
    
  4. Track iterations with checklist

    # Checklist automatically tracks:
    ## Iteration 1: [2025-11-03]
    ## Iteration 2: [2025-11-05]
    

โœ… Summary

Two layers, zero conflict, perfect synergy:

Evolution Layer (Modify) + Command Layer (Validate) = Robust Iteration

When to use what:

Released?
  YES โ†’ Evolution
  NO โ†’ Breaking/Major?
    YES โ†’ Evolution
    NO โ†’ Direct Edit + Checklist

Always validate:

After ANY change โ†’ /metaspec.sds.checklist (update mode)