Rtl p6 design review policy

From babyworm/rtl-agent-team · View interactive version

Rtl p6 design review policy is an AI agent skill from the GitHub repository babyworm/rtl-agent-team. Internal reference: rtl p6 design review policy (agent-loaded; do not invoke).

How to use this skill

Skill file

Phase 6 Design Review Policy

Why Phase 6 Exists

Phase 4/5 gate reviews focus on spec compliance and functional correctness.

Phase 6 goes deeper:

Why 2-round consistency checks?

Wave 1 and Wave 2 agents run independently — each produces its own scoring, terminology,

and severity labels. Without consistency enforcement, the same issue may be rated HIGH in

one document and MEDIUM in another, or identical concepts named differently across documents.

Why decision rationale in design notes?

A design note that only describes WHAT was built is half the story. Future engineers need:

Execution Rules

Design Note Requirements

Mandatory content per module (all 10 items):

  1. Purpose & Context: What does this module do? Where in the hierarchy?
  2. Decision Rationale (WHY): Why this approach? Trade-offs evaluated? Constraints? Alternatives rejected?
  3. Module Connections (HOW): Data flow, control dependencies, shared resources, timing
  4. I/O Table: Verified against actual RTL ports (port name, width, direction, description)
  5. Internal Structure: D2 block diagram showing sub-modules, registers, muxes
  6. Algorithm Description: Key equations/transforms
  7. FSM Diagrams: Mermaid state diagram for every FSM (NOT ASCII art)
  8. Timing Diagrams: Key timing waveforms (handshake, pipeline stages)
  9. Edge Cases & Gotchas: Corner cases, what can go wrong
  10. What-If Considerations: What changes if requirements shift

System-level sections: Architecture overview (D2), data/control flow, clock/reset architecture, mode operations, verification summary

Document Splitting Rules:

| Total Lines | Strategy | File Structure |

|-------------|----------|----------------|

| <= 300 | Single file | design-note.md |

| 300 - 800 | 2-3 files | design-note-overview.md + design-note-{topic}.md + design-note-appendix.md |

| > 800 | Per-module files | design-note-overview.md + design-note-{module}.md per module + design-note-appendix.md |

Consistency Check Protocol

CC1 — After Wave 1 (Code Review + Design Review)

| Check Item | What to Compare | Fix Action |

|------------|----------------|------------|

| Scoring scale | Both use 1-10 with same anchor points | Normalize to shared scale |

| Severity labels | HIGH/MEDIUM/LOW applied consistently | Re-rate using shared criteria |

| Terminology | Same concepts named identically | Adopt canonical terms |

| Finding overlap | Same issue in both reviews | Add cross-references |

| Module names | Consistent module naming | Standardize to rtl/ directory names |

CC2 — After Wave 2 (All 4+ Deliverables)

| Check Item | What to Compare | Fix Action |

|------------|----------------|------------|

| Narrative coherence | Story told consistently across docs | Align narrative arc |

| Traceability | Every improvement traces to a finding | Add missing traces |

| Completeness | Design note covers all reviewed modules | Add missing modules |

| Terminology | All docs use same terms | Global terminology pass |

| No contradictions | No conflicting statements | Resolve conflicts |

| Diagram consistency | D2/Mermaid match textual descriptions | Update mismatched diagrams |

CC log format (appended to each corrected document):

## Consistency Check {N} Log
- Date: YYYY-MM-DD
- Items checked: {count}
- Inconsistencies found: {count}
- Corrections applied: {list}

PDF Generation

Usage:

cd reviews/phase-6-review
make pdf        # Generate design-note.pdf
make clean      # Remove generated files
make check-deps # Verify required tools

Required tools:

| Tool | Package | Purpose |

|------|---------|---------|

| pandoc | sudo apt install pandoc | Markdown to LaTeX |

| xelatex | sudo apt install texlive-xetex texlive-fonts-recommended | LaTeX to PDF |

| d2 | curl -fsSL https://d2lang.com/install.sh \| sh -s -- | D2 block diagrams (optional) |

| mmdc | npm install -g @mermaid-js/mermaid-cli | Mermaid diagrams (optional) |

Pipeline: Discover design-note*.md → extract D2/Mermaid → render PNGs → replace blocks → combine → pandoc + xelatex → PDF with TOC

Phase 7 Exploration: For free exploration mode, see rtl-p7-exploration-policy.

Escalation & Stop Conditions

Final Checklist

Use this skill with your AI agent: Open on Skill Issue to copy, download, or add to your library. Works with Claude, ChatGPT, Gemini, Cursor, Windsurf and more.