Software Planning
Plan to prevent complexity before it exists. Use A Philosophy of Software
Design as the default lens: reduce change amplification, cognitive load, and
unknown unknowns before implementation starts.
Workflow
Phase 1: Purpose, Interface, and Ownership
- Inspect the current system first. Find the existing abstractions,
boundaries, conventions, and integration points before proposing changes.
- Frame the problem. State the purpose of the module or change clearly, and
make requirements, constraints, failure modes, and success criteria
explicit.
- Draft the high-level design: interfaces, module boundaries, and ownership.
- Write interface comments early so caller-facing contracts and guarantees are
explicit.
- Prefer deep modules and simple caller-facing interfaces.
- Use information hiding so each important design decision has one clear
owner.
- Compare viable alternatives when the choice materially affects complexity;
design it twice when useful.
- Ask for user review on the proposed purpose, interfaces, ownership, and
high-level design before refining internals.
Phase 2: Internals, Invariants, and Verification
- Refine the chosen design into internal structure and implementation
approach.
- Define invariants, state ownership, error behavior, and compatibility
expectations.
- Keep hub or orchestrator modules focused on wiring and composition.
- Define verification before coding: automated checks, regression coverage,
manual smoke checks, and residual risk.
- Define rollout and rollback expectations for risky changes. Call out blast
radius, failure detection, and recovery path.
- Bring the plan to the point where implementation can proceed without
reopening core design questions.
- Ask for user review on the complete plan before implementation begins.
Planning Principles
- Prefer deep modules with simple caller-facing interfaces.
- Hide information so each design decision has one owner.
- Centralize sequencing-sensitive state changes in one controlled place rather
than scattering partial updates across callers.
- Keep hub or orchestrator modules focused on wiring and composition.
- Keep abstraction levels clean within a module.
- Separate general-purpose mechanisms from special-purpose policy.
- Challenge temporal decomposition when it spreads knowledge across steps.
- Enforce invariants in module APIs, not caller convention.
Verification Planning
- Match verification depth to risk.
- Prefer the lowest effective automated check first.
- For bug fixes, plan a regression test that fails before the fix and passes
after it.
- Include manual smoke checks when automation is impractical.
- Record residual risk when anything important remains unverified.
Questions
Ask only when the answer changes the design:
- scale or load assumptions
- performance budgets
- external integration constraints
- expected future variation
- operational, security, or rollback requirements
Do not ask when the design would be the same either way.
Done When
- The chosen approach is explicit.
- Interfaces, module boundaries, and ownership are clear.
- Invariants and failure handling are named.
- Verification is defined.
- Rollout or rollback expectations are clear when risk warrants them.
- The user has reviewed the complete plan.
1---2name: software-planning3description: Plan non-trivial software changes before coding. Use for requirements framing, approach selection, API or module design, spec writing, verification planning, and rollout or rollback planning.4---56# Software Planning78Plan to prevent complexity before it exists. Use A Philosophy of Software9Design as the default lens: reduce change amplification, cognitive load, and10unknown unknowns before implementation starts.1112## Workflow1314### Phase 1: Purpose, Interface, and Ownership15161. Inspect the current system first. Find the existing abstractions,17 boundaries, conventions, and integration points before proposing changes.182. Frame the problem. State the purpose of the module or change clearly, and19 make requirements, constraints, failure modes, and success criteria20 explicit.213. Draft the high-level design: interfaces, module boundaries, and ownership.224. Write interface comments early so caller-facing contracts and guarantees are23 explicit.245. Prefer deep modules and simple caller-facing interfaces.256. Use information hiding so each important design decision has one clear26 owner.277. Compare viable alternatives when the choice materially affects complexity;28 design it twice when useful.298. Ask for user review on the proposed purpose, interfaces, ownership, and30 high-level design before refining internals.3132### Phase 2: Internals, Invariants, and Verification33341. Refine the chosen design into internal structure and implementation35 approach.362. Define invariants, state ownership, error behavior, and compatibility37 expectations.383. Keep hub or orchestrator modules focused on wiring and composition.394. Define verification before coding: automated checks, regression coverage,40 manual smoke checks, and residual risk.415. Define rollout and rollback expectations for risky changes. Call out blast42 radius, failure detection, and recovery path.436. Bring the plan to the point where implementation can proceed without44 reopening core design questions.457. Ask for user review on the complete plan before implementation begins.4647## Planning Principles4849- Prefer deep modules with simple caller-facing interfaces.50- Hide information so each design decision has one owner.51- Centralize sequencing-sensitive state changes in one controlled place rather52 than scattering partial updates across callers.53- Keep hub or orchestrator modules focused on wiring and composition.54- Keep abstraction levels clean within a module.55- Separate general-purpose mechanisms from special-purpose policy.56- Challenge temporal decomposition when it spreads knowledge across steps.57- Enforce invariants in module APIs, not caller convention.5859## Verification Planning6061- Match verification depth to risk.62- Prefer the lowest effective automated check first.63- For bug fixes, plan a regression test that fails before the fix and passes64 after it.65- Include manual smoke checks when automation is impractical.66- Record residual risk when anything important remains unverified.6768## Questions6970Ask only when the answer changes the design:7172- scale or load assumptions73- performance budgets74- external integration constraints75- expected future variation76- operational, security, or rollback requirements7778Do not ask when the design would be the same either way.7980## Done When8182- The chosen approach is explicit.83- Interfaces, module boundaries, and ownership are clear.84- Invariants and failure handling are named.85- Verification is defined.86- Rollout or rollback expectations are clear when risk warrants them.87- The user has reviewed the complete plan.