Skip to content
Back to skills

Planner Rules

ASecurity

Task analysis and planning rules for /planner command. Load at /planner startup (step 0) or when /workflow enters Phase 1. Covers: task classification (7 types), S/M/L/XL complexity routing, code-researcher delegation (L/XL), plan documentation with full code examples.

  • 46 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added May 27, 2026
developmenttypescriptpythonrustgojavarefactoringapiperformancedocumentation

Works with

  • cli
  • api
  • mcp

Security analysis

A100/100

Pro scans all 15 files and shows the line behind each finding

Scanned May 27, 2026

npx -y skills add hex0xdeadbeef/claude-kit --skill planner-rules --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Planner Rules?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Planner Rules
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/hex0xdeadbeef-planner-rules/badge)](https://www.skillsdirectory.com/skills/hex0xdeadbeef-planner-rules)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: planner-rules
description: Task analysis and planning rules for /planner command. Load at /planner startup (step 0) or when /workflow enters Phase 1. Covers: task classification (7 types), S/M/L/XL complexity routing, code-researcher delegation (L/XL), plan documentation with full code examples.
disable-model-invocation: true
---

# Planner Rules

## Task Classification

Classify task type before any research:
- new_feature: add, create, implement, new endpoint → typical M-XL
- bug_fix: fix, bug, broken, not working → typical S-M
- refactoring: refactor, rewrite, extract, split → typical M-L
- config_change: config, parameter, environment variable → typical S
- documentation: documentation, README, describe → typical S
- performance: optimization, slow, N+1, cache → typical M-L
- integration: external service, API call, client → typical L-XL

## Complexity & Routing

| Complexity | Parts | Layers | Route | Sequential Thinking | Plan Review |
|------------|-------|--------|-------|---------------------|-------------|
| S | 1 | 1 | minimal | NOT needed | SKIP |
| M | 2-3 | 2 | standard | as needed | standard |
| L | 4-6 | 3+ | standard | RECOMMENDED | standard |
| XL | 7+ | 4+ | full | REQUIRED | standard |

## Auto-Escalation (re-routing)
- plan-review finds more Parts than expected → upgrade complexity
- coder finds hidden complexity (3+ adjustments) → upgrade + return to planner
- plan-review finds fewer Parts → downgrade complexity

## Instructions

### Step 1: Classify the task
Use Task Classification above to determine type (new_feature, bug_fix, etc.)
and Complexity & Routing table for S/M/L/XL classification.
Output: task type + complexity + route + ST requirement.

### Step 2: Load required references
- ALWAYS load: [MCP Tools](mcp-tools.md)
- Complexity L/XL: also load [Sequential Thinking Guide](sequential-thinking-guide.md)
- Complexity M+: also load [Data Flow](data-flow.md)
- For full classification details: [Task Analysis](task-analysis.md)

### Step 3: Research with appropriate tools
- S/M: use Grep/Glob directly for codebase research
- L/XL: delegate to code-researcher agent via Task tool for multi-package research

### Step 4: Document plan with full code examples
Write plan to `.claude/prompts/{feature}.md` using plan template.
CRITICAL: Code examples must be FULL (complete function bodies), not just signatures.
Form handoff payload for plan-review.

## Example

### Code completeness in plans

**Principle:** Full function body, error context propagated per ERROR_WRAP, explicit return types and values, no truncation.

**Bad — signature-only stub (any language):** Function declared without body (e.g. `func Get(id string) error` or `def get(id): ...`). Not actionable for the coder — no error path, no return shape.

**Good — see per-language reference shapes** in `.claude/skills/planner-rules/code-shapes/<LANGUAGE>.md` (resolved from `PROJECT-KNOWLEDGE.md → LANGUAGE`; falls back to `code-shapes/_default.md` pseudocode if LANGUAGE is unset or not one of go/python/typescript/rust/java).

**Why:** Incomplete examples are not actionable for the coder. Concrete shapes are language-specific; the four invariants (full body, ERROR_WRAP, explicit types, no truncation) are universal — see `code-shapes/INVARIANTS.md`.

For more examples, see [Examples](examples.md).

## Common Issues

### Plan has incomplete code examples
**Cause:** Planner shows function signature without body.
**Fix:** RULE: Full Examples — all code in plan must have complete function bodies, error handling, and context propagation.

### Sequential Thinking skipped for complex plan
**Cause:** Planner thinks plan is simple, but has 5+ parts.
**Fix:** ALWAYS use Sequential Thinking if Parts >= 5 or alternatives >= 3.

For all troubleshooting cases, see [Troubleshooting](troubleshooting.md).

## Core Deps (loaded at startup)
- [MCP Tools](mcp-tools.md) — Sequential Thinking, Context7 patterns and fallbacks
- [Sequential Thinking Guide](sequential-thinking-guide.md) — when/how to use ST (complexity L/XL only, SKIP for S/M)

## References
For detailed checks, read the supporting files in this skill directory:
- [Task Analysis](task-analysis.md) — full classification matrix, routing rules, preconditions, re-routing mechanism, examples
- [Data Flow](data-flow.md) — data origin/path analysis, layer placement rules (SKIP for S, LOAD for M+)
- [Examples](examples.md) — good vs bad code examples for plans
- [Checklist](checklist.md) — self-verification at each planner phase
- [Troubleshooting](troubleshooting.md) — common planner issues and fixes
- [code-researcher agent](../../agents/code-researcher.md) — available via Task tool for multi-package research (L/XL complexity, skip for S/M and --minimal)

Files in this skill

  • SKILL.md4.7 KB
  • checklist.md1.3 KB
  • code-shapes/INVARIANTS.md1.2 KB
  • code-shapes/_default.md816 B
  • code-shapes/go.md861 B
  • code-shapes/java.md971 B
  • code-shapes/python.md793 B
  • code-shapes/rust.md975 B
  • code-shapes/typescript.md897 B
  • data-flow.md2.5 KB
  • examples.md1.3 KB
  • mcp-tools.md1.8 KB
  • sequential-thinking-guide.md5.3 KB
  • task-analysis.md8.6 KB
  • troubleshooting.md1 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.