Install
openclaw skills install deep-planning-skillUse for complex architecture, algorithm, system-design, logic, or research-planning problems where ordinary linear planning is likely to be brittle, bloated, or trapped in local assumptions. Deep Planning creates a baseline plan, abstracts the problem into domain-neutral structure, spawns a blank-context domain-questioning subagent, translates useful cross-domain mechanisms back into the original domain, compares standard/novel/hybrid plans, and emits a self-contained execution blueprint. Do not use for routine coding, simple refactors, factual lookup, straightforward API usage, or tactical bug fixes.
openclaw skills install deep-planning-skillDeep Planning is a high-latency System 2 planning routine. Use it to produce an architecture, algorithm, research, or execution blueprint before downstream implementation or deep research begins.
The purpose is not to write metaphorical prose. The purpose is to use a blank-context, domain-shifted question-asking subagent to expose overlooked mechanisms, then translate only the useful mechanisms back into a literal plan.
The core mechanism is asymmetrical expertise:
Use this skill when the user explicitly asks for any of the following:
deep planrun deep planning/deep-planplan a novel architecturegenerate a lateral research planrun the metaphorical solver loopfind similar math in other fieldsuse a metaphorical sub-agentuse lateral planninguse a blank-context question askerIf the user says /deep-plan, treat that as an explicit request to run this skill.
Use Deep Planning when at least one condition is true:
Do not use Deep Planning for:
For tactical execution, use the normal coding, research, or tool-use loop instead.
The main agent should perform these roles itself:
Only the Domain Questioner must be a spawned blank-context subagent.
The Domain Questioner must be isolated because its ignorance of the original problem is the actual planning mechanism. If it sees the original domain, it will collapse back into ordinary advice and stop asking useful domain-native questions.
The Domain Questioner must not see:
The Domain Questioner sees only a literal problem from its assigned metaphor domain.
This blindness is mandatory. Do not weaken it.
Spawn a real subagent for the Domain Questioner. The subagent should receive only:
Do not give the subagent tools, repo access, file access, web access, or project context unless the selected domain absolutely requires external reference. For normal Deep Planning, the Domain Questioner should be tool-free.
If the environment cannot spawn subagents, simulate the Domain Questioner in a clearly separated internal section. Still obey the context-separation rule as much as possible, but treat the result as lower-confidence because true context isolation is unavailable.
Do not claim true blank-context interrogation occurred if it did not.
Baseline Plan: the best ordinary plan in the original domain before lateral reasoning.
Domain Questioner: the blank-context subagent that interrogates the domain-native problem from inside a selected external field.
Homologous Field: a field that shares the same structural topology or mathematics as the original problem.
Domain-Native Problem Statement: a rewritten problem that sounds like a literal problem in the selected field, with no source-domain terminology.
Lateral Mechanism: a standard mechanism from the selected field that may transfer back into the original domain.
Metaphor Wash: removal of all metaphor language from the final output.
Hybrid Plan: a plan that keeps the stable parts of the baseline and grafts in only the useful lateral mechanism.
ExecPlan Hardening: conversion of the final strategy into a self-contained, executable blueprint with milestones, validation, recovery, and logs.
Follow the phases in order. Do not skip the baseline. Do not expose the raw metaphor trace in the final output unless the user explicitly asks for it.
Before running Deep Planning, decide whether the request deserves this expensive routine.
Run the skill if the user explicitly invoked it or if the task meets the usage criteria above.
If the task is tactical and does not need Deep Planning, do not run the skill. Use the normal execution loop instead.
When running the skill, state the final plan directly. Do not spend the final answer explaining that a skill was used.
Create the best ordinary plan in the original domain before invoking the domain-shifted loop.
Internally record:
Score the baseline using integer values from 1 to 5, where 5 is best unless the metric is explicitly a cost metric.
Required baseline metrics:
For cost-like metrics such as implementation effort and resource overhead, be explicit about whether a higher score means better/lower cost or worse/higher cost. Prefer a consistent convention: 5 means favorable.
This baseline is the plan the lateral loop must beat, simplify, or selectively improve.
Strip source-domain nouns from the problem.
Translate the blocker into a domain-neutral structural form.
Internally identify:
Then identify 2 to 4 homologous fields that share the same topology or mathematics.
Examples:
Select the field most likely to produce a concrete standard mechanism, not merely a colorful analogy.
Prefer fields with:
Convert the abstracted structure into a literal problem statement inside the selected field.
The statement must:
Do not ask the subagent to “think metaphorically.” Ask it to solve or interrogate what appears to be a real problem in its own domain.
Bad framing:
A coding agent is failing tool calls. Think of this like CNC machining.
Good framing:
A workshop runs long multi-stage jobs on expensive workpieces. Local failures occur at different stages. The operator often either restarts the whole job or continues unsafely without enough inspection. Design questions remain around when to retry, rework, inspect, pause, or scrap.
The main agent may keep a private mapping table, but the Domain Questioner must not see that table.
Spawn exactly one isolated blank-context Domain Questioner unless there is a specific reason to fan out multiple domains.
Use this system payload exactly, replacing bracketed placeholders:
Role: Senior Expert in [SELECTED_DOMAIN]
Context:
You are blind to software engineering, LLMs, coding agents, databases, UI, research planning, and the original problem domain. You only understand the literal mechanics, tools, constraints, mathematics, and established practices of [SELECTED_DOMAIN].
Objective:
A novice has presented a structural design problem in your field. Your job is to interrogate the design and identify standard mechanisms from [SELECTED_DOMAIN] that should solve, simplify, stabilize, or stress-test it.
Behavior:
- Prefer sharp domain-native questions over broad essays.
- Ask why standard mechanisms from your field are not being used.
- If the novice's design seems overcomplicated, identify the simpler standard mechanism.
- If a mechanism should normally solve the issue, state it plainly.
- If the novice claims your mechanism will not work, do not concede immediately.
- Demand a literal [SELECTED_DOMAIN] reason why it fails.
- Patch within [SELECTED_DOMAIN] before recommending a domain change.
- Stay inside [SELECTED_DOMAIN] unless a terminal boundary is reached.
- Do not translate your answer into software, AI, coding, research planning, or any external domain.
Required Output:
1. Primary domain-native question.
2. Standard mechanism you would try first.
3. Why that mechanism should work in [SELECTED_DOMAIN].
4. Exact conditions under which it would fail.
5. Local patches or refinements within [SELECTED_DOMAIN].
6. Signs the current domain is becoming inefficient or overcomplicated.
7. If pivot is necessary, name a narrower field and the exact bottleneck it specializes in.
Give the Domain Questioner only the domain-native problem statement.
Do not provide the original problem.
When the Domain Questioner returns questions and mechanisms, the main agent must translate them back into the original domain.
For each candidate mechanism, internally record:
Extract function, not imagery.
Examples:
Reject metaphor-only residue. Accept only implementable structures, policies, algorithms, validation gates, state machines, or research work packages.
If the translated mechanism is promising but creates secondary issues, do not pivot immediately.
Frame only the secondary issue back into the same selected domain and ask the same Domain Questioner to patch it within that domain.
Rules:
Pivot only when one or more is true:
If pivoting is needed, do not pass the whole original problem to the next subagent.
Slice the problem down to only:
Select a narrower domain specialized for that bottleneck.
Spawn a new blank-context Domain Questioner for the narrowed slice.
Repeat until:
Use recursion sparingly. Deep Planning should converge on a cleaner plan, not explore metaphors endlessly.
Compare three plans:
Score each with integer values.
Required metrics:
Use a consistent convention: 5 is favorable, 1 is poor.
Aggressively penalize cleverness that adds complexity without clearing the bottleneck.
Selection rules:
Do not choose the novel plan merely because it is more interesting.
Remove all metaphor language from the final answer.
The user or downstream worker agent should receive only literal output:
Do not expose internal metaphor text unless the user explicitly asks for it.
No valves, pipes, feed rates, pallets, fixtures, surgical triage, traffic lanes, water hammer, stress risers, or other metaphor residue should appear in the final handoff.
Convert the selected standard, novel, or hybrid strategy into a self-contained execution blueprint.
The blueprint must assume the downstream worker has:
The blueprint must include:
For coding plans, prefer red/green TDD where practical:
For research plans, use the analogous evidence loop:
For architecture plans, use the analogous design-validation loop:
Before finalizing, remove anything that does not directly support:
Apply YAGNI and DRY pressure.
Ask internally:
If the lateral mechanism does not survive this pass, reject it and return the standard plan.
The final answer must be a clean blueprint suitable for a coding agent, research agent, or architecture agent.
It must be self-contained. It must not rely on the reader having access to the conversation that produced it.
Do not include the raw metaphor trace by default.
Use the template below unless the user explicitly asks for a different format.
State the literal original-domain objective.
List explicit assumptions made while planning.
Summarize the ordinary original-domain solution.
Describe the extracted mechanism in literal original-domain terms only.
Do not include metaphor-language residue.
State whether the selected plan is:
Explain why in practical terms.
Describe the selected structure.
For coding tasks, include module boundaries, state ownership, data flow, and integration points.
For research tasks, include research questions, hypothesis structure, source classes, evidence tables, and synthesis path.
For algorithm tasks, include inputs, outputs, invariants, complexity expectations, and failure cases.
List concrete modules, files, systems, experiments, sections, or work packages as applicable.
For each component or work package, include:
Define persistent state, transient state, data flow, control state, or conceptual dependencies.
If the task is research-oriented, define the evidence model instead:
Describe the operational sequence.
Include normal path, retry path, validation path, and terminal failure path.
Define:
State how the downstream worker must execute the plan.
Include:
For each milestone, include:
Map every success criterion to a concrete test, command, artifact, citation, experiment, or review step.
Use a table when helpful:
| Success Criterion | Validation Method | Expected Result | Failure Response |
|---|---|---|---|
| ... | ... | ... | ... |
If validation fails:
Include an initially empty progress log for downstream execution.
Example:
| Time | Milestone | Action | Result | Next Step |
|---|---|---|---|---|
| TBD | TBD | TBD | TBD | TBD |
Record architectural, algorithmic, or research decisions.
Example:
| Decision | Rationale | Alternatives Rejected | Date/Context |
|---|---|---|---|
| TBD | TBD | TBD | TBD |
Define what the downstream worker must report when finished.
For coding tasks, require:
For research tasks, require:
For architecture tasks, require:
Briefly list rejected approaches and why they were rejected.
Include only information useful to the downstream coding, research, or architecture agent.
Do not include metaphor details unless explicitly requested.
If the user explicitly asks to see the Deep Planning trace, provide a cleaned trace using this format:
Even in the trace, do not expose private chain-of-thought. Summarize the reasoning and artifacts only.
A valid Deep Planning output must satisfy all of the following:
If the output fails any of these, revise before handing it off.