Detects architecture boundary violations in the Parser/Renderer/Executor 3-layer model. Use when reviewing or implementing any code change.
Invoke this skill whenever you:
| Check | Allowed | Forbidden |
|---|---|---|
| Argument parsing | ✅ | |
| stdin detection | ✅ | |
| Exit code management | ✅ | |
| Direct YAML parsing | ❌ | |
| LLM API calls | ❌ | |
| Template expansion | ❌ |
| Check |
|---|
| Allowed |
|---|
| Forbidden |
|---|
| Read YAML file | ✅ | |
| Detect and report syntax errors | ✅ | |
Normalize model: string → model: { name: string } | ✅ | |
Promote prompt: "..." → steps: [{ prompt: "..." }] | ✅ | |
| Validate against JSON Schema | ✅ | |
Return ValidatedCommand | ✅ | |
| Call LLM API | ❌ | |
Expand {{variable}} templates | ❌ | |
| Write to stdout/file | ❌ | |
| Reference YAML from outside this layer | ❌ |
| Check | Allowed | Forbidden |
|---|---|---|
Accept ValidatedCommand + variable map as input | ✅ | |
Expand {{variable}} references | ✅ | |
| Resolve dependency graph for multi-step commands | ✅ | |
| Return expanded prompt string(s) | ✅ | |
| Any network call | ❌ | |
| Any file I/O | ❌ | |
| Calling the LLM API | ❌ | |
| Reading environment variables | ❌ | |
| Random number generation | ❌ |
| Check | Allowed | Forbidden |
|---|---|---|
| Initialize LLM API client | ✅ | |
| Call LLM API (including retries) | ✅ | |
| Handle streaming responses | ✅ | |
| Manage rate limits and errors | ✅ | |
| Dispatch multi-step steps | ✅ | |
| Convert and write output (text/json/markdown) | ✅ | |
Return ExecutionResult | ✅ | |
| Parsing YAML | ❌ | |
| Expanding templates directly (must use Renderer) | ❌ |
src/parser/, src/renderer/, src/executor/).CLI Layer calls Parser, which hands off to Renderer, which hands off to Executor). Imports must never skip layers or flow in reverse (e.g., Parser must not import from Executor).ValidatedCommand boundary — ensure Parser outputs it and Renderer/Executor consume it; raw YAML must not cross this boundary.fs, fetch, process.env, or Math.random call inside the Renderer is a violation.openai, fetch (to LLM endpoints), or SDK client usage in Parser or Renderer files.Note:
scripts/check-layers.shwill be added in a future iteration (Approach γ) to automate steps 2–6 above. Once available, run it as part of your pre-commit check:bash scripts/check-layers.sh