The workflow
multi-model.fabro
Model stylesheets
Themodel_stylesheet graph attribute contains CSS-like rules that assign models to nodes:
Selectors
| Selector | Syntax | Matches | Specificity |
|---|---|---|---|
| Universal | * | All nodes | 0 |
| Shape | box, tab, etc. | Nodes with that shape | 1 |
| Class | .classname | Nodes with class="classname" | 2 |
| ID | #nodeid | A specific node by ID | 3 |
How this workflow routes
| Node | Matches | Model | Why |
|---|---|---|---|
spec | * (universal) | Haiku | Simple generation task — fast and cheap |
implement | .coding (class) | Sonnet | Coding requires a capable model |
test | .coding (class) | Sonnet | Test writing also needs coding capability |
review | #review (ID) | Sonnet | Review needs careful analysis |
Assigning classes
Set theclass attribute on a node to target it with class selectors:
class="coding critical".
Properties
Stylesheets support four properties:| Property | Description |
|---|---|
model | Model ID or alias (e.g. claude-sonnet-4-5, opus, gemini-pro) |
provider | Provider name (optional — auto-inferred from the model catalog when omitted) |
reasoning_effort | low, medium, or high |
backend | api (default) or cli |
Why route models?
Not every task needs a frontier model:- Spec writing, classification, summarization — use a fast, cheap model (Haiku, Flash Lite)
- Code implementation, complex reasoning — use a capable model (Sonnet, Opus, GPT-5.2)
- Cross-critique — use a different provider so the reviewer brings fresh eyes
claude-haiku-4-5 to gemini-3-flash-preview in the stylesheet and the workflow behaves the same — just with a different model underneath.
Explicit overrides
A model set directly on a node attribute always beats the stylesheet:.coding says.
See Model Stylesheets for the full reference and Models for available model IDs.
What you’ve learned
- Model stylesheets use CSS-like rules to assign models to nodes
- Selectors match by universal (
*), shape, class (.name), or ID (#name) - Specificity determines which rule wins when multiple match
- Route cheap models to simple tasks and capable models to hard ones
Next
Ensemble
Fan out to multiple providers and synthesize their independent opinions.