This contract applies to every visual style. Style references control color, typography, material, corner radius, and decorative treatment. They never weaken geometry or composition quality.
Use "quality_profile": "showcase" for official samples and polished delivery
artifacts. The renderer and validator enforce all of these budgets:
| Metric | Showcase limit |
|---|---|
| Edge crossings | 0 |
| Bridge jumps | 0 |
| Bends on one edge | 2 maximum |
| Bends in the six-node reference topology | 8 maximum |
| Route length / direct Manhattan length | 1.35 maximum |
| Shortest route segment | 16px minimum |
| Node-to-node whitespace | 40px minimum |
| Node-to-container gutter | 20px minimum |
| Edge-label clearance from unrelated geometry | 4px minimum |
The six-node reference topology currently scores 100 with four total bends, zero crossings, zero bridges, a route-stretch maximum of 1.0, 50px minimum node spacing, and 20px minimum container gutter.
Styles may vary these properties freely within their own reference:
Styles must share these structural properties for a direct comparison:
Visual effects never create a second business connector. Pencil echoes, rail
casings, critical-path glow, and similar layers use
data-graph-role="decoration" with data-owner; exactly one ordinary
data-graph-role="edge" carries the source, target, route, and arrowhead.
Run both gates before delivery:
python3 scripts/validate_svg.py diagram.svg --check geometry
python3 scripts/validate_svg.py diagram.svg --check composition
scripts/validate-svg.sh runs both automatically. A successful render without
these gates is still a draft.
Dense legacy diagrams live under fixtures/stress/. They preserve routing
pressure cases and are not visual quality references. The public 12-style
showcase keeps a distinct engineering scene for every style. The internal
fixtures/quality-baseline/ set applies one shared Agent Runtime Architecture
topology to all 11 generator-backed styles; Style 8 remains the static,
AI-authored exception.
Apply visual-quality.md after geometry passes. Use text_policy: "strict" when labels must remain visible in full, inspect typography and palette in the layout report, and verify the raster at its intended reading size.