rse/ase / plugin/skills/ase-task-edit
ase-task-edit
UnverifiedIteratively edit and refine a named plan for a task through a conversational loop. A new plan is optionally composed along the chosen one of several proposed crafting, refactoring, resolution, or specification approaches. Each round, the current plan is shown and the user is asked whether to keep refining, mark the plan as done, or proceed to the implementation or draft. Use when the user wants to plan a task purely through chat-driven refinement, or wants a plan to "craft" a new feature, "refactor" the code base, or "resolve" a problem (also from a bare analyzer issue id like "P1").
@${CLAUDE_SKILL_DIR}/../../meta/ase-control.md @${CLAUDE_SKILL_DIR}/../../meta/ase-skill.md @${CLAUDE_SKILL_DIR}/../../meta/ase-dialog.md @${CLAUDE_SKILL_DIR}/../../meta/ase-getopt.md
$ARGUMENTS
@${CLAUDE_SKILL_DIR}/../../meta/ase-format-task.md @${CLAUDE_SKILL_DIR}/../../meta/ase-format-meta.md @${CLAUDE_SKILL_DIR}/../../meta/ase-common-task.md @${CLAUDE_SKILL_DIR}/../../meta/ase-common-grill.md @${CLAUDE_SKILL_DIR}/../../meta/ase-common-approach.md @${CLAUDE_SKILL_DIR}/../../meta/ase-common-ground.md @${CLAUDE_SKILL_DIR}/../../meta/ase-tenets.md
Procedure
Set true.
-
If is
craft,refactor,resolve, orspecify: Set toCRAFTING,REFACTORING,RESOLVING, orSPECIFYINGcorrespondingly, and set true. -
Else if is not empty (
autowith a retrieved analyzer issue): Set toRESOLVING, as the refinement fixes a reported problem, and set true. -
Else (
auto): Set to the value of theKind:frontmatter key of (or, if it is absent or invalid, infer it from the plan content, defaulting toCRAFTING), and set false.
You MUST then first forget all previous internalized tenets and then freshly internalize and strictly honor the GENERIC TENETS and the TENETS of the ASE Tenets in the following refinement of the plan. Do not output anything.
Treat the as a refinement instruction for the plan, and update in-place by applying the requested to the plan, preferring the grounding facts (if any) over the world knowledge of the model.
When refining the plan this way, preserve the overall structure of the plan and only modify what the user actually requested. Do not rewrite unrelated sections of the plan.
Attachment blocks of the "backmatter" are never dropped by a
refinement, unless the explicitly asks for it. Their
Data payloads are elided to [elided: <n/> lines] markers, which
you MUST keep verbatim, as ase_task_save restores them. Only if
the requires reading or changing the payload of an
attachment, fetch it via the ase_task_attachment(id: "<ase-task-id/>", type: "<type/>") tool of the ase MCP server (with
being the value of its Type key), and replace its marker with
the complete changed payload as a |4+ (or |4-) literal block
scalar according to the plan . Remember every attachment block whose content the
applied changed as touched, so its Modified key is
refreshed together with the frontmatter in step 3.1. An attachment the
did not change stays verbatim -- an implementation
draft attachment (Type key value text/x-diff; charset=utf-8; kind="draft", from ase-task-implement --draft) hence
turns stale through a "body" change by its Modified key falling
behind the frontmatter, which step 3.3 reports.
Set true.
Determine the kind of change of the new plan:
-
If is
craft,refactor,resolve, orspecify: Set toCRAFTING,REFACTORING,RESOLVING, orSPECIFYINGcorrespondingly. -
Else if is not empty (
autowith a retrieved analyzer issue): Set toRESOLVING, as the plan fixes a reported problem. -
Else (
auto): Infer the from the : set toSPECIFYINGif the plan predominantly creates or revises the statements of theSPECartifacts, set toRESOLVINGif it predominantly fixes a defect, set toREFACTORINGif it predominantly re-structures existing artifacts without changing their observable behavior, and set toCRAFTINGotherwise (also the default if the inference stays inconclusive).
Set to specification, resolution, refactoring,
or crafting for the SPECIFYING, RESOLVING,
REFACTORING, or CRAFTING correspondingly. You MUST then first
forget all previous internalized tenets and then freshly internalize
and strictly honor the GENERIC TENETS and the
TENETS of the ASE Tenets in the following composition of the
plan. Do not output anything.
Investigate and figure out details related to the problem of the and report them with the following :
PROBLEM DETAILS: ● [...] ● [...] ● [...]
Hints:
-
Give a short one-sentence of the problem plus a short excerpt of the affected code .
-
Give a short one-sentence of the problem plus precise but brief code processing information to understand the problem. Try to keep the number of bullet points (●) in the range of 1-4.
-
In case of a complex context situation with complex structure (layout, components, dependencies, etc.), complex control flow (branching, concurrency, etc.), complex state machine (states, transitions, etc.), complex data flow (actors, messages, etc.), or complex data structure (classes, entities, relationships, etc.), visualize it with an optional diagram by building a Mermaid specification (e.g.
flowchart TB,stateDiagram-v2,sequenceDiagram,classDiagram, orerDiagram, depending on intent) and rendering it according to the Diagrams rule of the skill conventions. Omit entirely for simple or purely local situations.
Set GRILLING. Do not output anything.
If is STOP, only output the following
and then immediately STOP processing the entire current skill:
Call the ase_timestamp(format: "yyyy-LL-dd HH:mm") tool of the
ase MCP server and use the text field of its response
for fresh and
information. Then insert the current ,
, and information -- except
for the OVERWRITE under a focus above, which keeps the Created: key.
Set true.
-
Determine Task and Instruction:
-
Set initially. Set (empty), false, false, (empty), and task inherited. Inherit the always existing from the current context. Inherit the always existing from the current context. Do not output anything.
Set false. The band of
--interactiveis drawn by the function hooks module of the plugin, which provides themcp__ase__ase_task_bandtool in an interactive terminal only. Load the schema of this tool (if deferred, viaToolSearchwith the queryselect:mcp__ase__ase_task_band). If this tool does not exist, only output the following and then immediately STOP processing the entire current skill: -
Resolve a potential analyzer issue:
The may be a bare issue identifier (like
P1,T1, or<prefix>-P1) previously produced byase-code-analyzeorase-arch-analyze. Call thease_kv_get(key: "ase-issue-<candidate/>")tool of theaseMCP server to retrieve the persisted problem description. If the returnedtextis non-empty:-
Set and .
-
If is given, set and task given, and call the
ase_task_id(id: "<ase-task-id/>", session: "<ase-session-id/>")tool from theaseMCP server to switch the task. -
Only output the following :
Otherwise, keep unchanged, so it is treated as a task id resp. as an instruction below. Do not output anything.
-
-
React on task and/or instruction:
-
Set (set task id to instruction) and (set instruction empty), call the
ase_task_id(id: "<ase-task-id/>", session: "<ase-session-id/>")tool from theaseMCP server to switch the task, and then only output the following : -
Set (set instruction to empty) and (set task id to id) and call the
ase_task_id(id: "<ase-task-id/>", session: "<ase-session-id/>")tool from theaseMCP server to switch the task, and then only output the following : -
Set (set instruction to text) and (set task id to id) and call the
ase_task_id(id: "<ase-task-id/>", session: "<ase-session-id/>")tool from theaseMCP server to switch the task, and then only output the following : -
Only output the following , where is
task givenif step 1.2 switched the task: -
Only output the following :
-
-
-
Determine Plan:
-
Determine any existing plan content:
Set to the
textargument of the most recentase_task_save(id: '<ase-task-id/>', ...)tool call -- this is the authoring form of the plan and MUST NOT be confused with thetextoutput field of that call -- without callingase_task_loadagain. Set (set the rendering-prepared plan to empty, as it is re-derived in step 3.2 or 3.3). Set to the content enclosed in the<task-plan-tag>delimiter line of thetextoutput field of thatase_task_savetool call (the entity tag of the plan as saved by it). Set plan reused. Do not output anything. Call thease_task_load(id: "<ase-task-id/>", variant: "both", tag: true)tool of theaseMCP server to load any existing plan content in both of its forms, with the payloads of all attachments elided to[elided: <n/> lines]markers (the default of itsattachmentsargument). From thetextoutput field of thisase_task_loadtool call, set to the content enclosed in the<task-plan-source>delimiter lines (the authoring form, the only form which is ever edited and persisted), set to the content enclosed in the<task-plan-render>delimiter lines (the rendering-prepared form, used for display only), and set to the content enclosed in the<task-plan-tag>delimiter line (the entity tag of the loaded plan, or empty if absent, as no plan exists yet). The delimiter lines themselves are never part of any form. Do not output anything related to this MCP tool call. Set plan loaded.Set false.
-
If starts with
ERROR:orWARNING:: Silently ignore the MCP error. Set to empty. Set to empty. Do not output anything. -
If starts NOT with
ERROR:and NOT withWARNING:: Set (set task content to text). Only output the following :
-
-
**No plan content yet. What is the task you want to plan?**Then set to the response of the user and only output the following :
-
Call the
ase_task_newid(title: "<title/>", proposal: "<proposal/>")tool from theaseMCP server, where is a brief title summarizing and is a task id derived from , which consists of two lower-case words concatenated with a-character, and set to theidfield of its response -- the tool derives the id according to the task id scheme of the project, so you MUST NEVER assemble it yourself. Then call thease_task_id(id: "<ase-task-id/>", session: "<ase-session-id/>")tool from theaseMCP server to switch the task, set (empty, as no plan exists yet under the new id) and true, and only output the following : -
Determine previous-plan handling:
-
If matches the regex
^(OVERWRITE|REFINE|PRESERVE)$: Honor the pre-selection of what to do with the previous plan. Set . -
If is equal to
none:In the following, you MUST NOT use your built-in tool! Instead, you MUST just show a custom dialog according to the expanded
custom-dialogdefinition. You MUST closely follow this definition:
Check the tool and dispatch accordingly:
-
If is
CANCELorPRESERVE:Only output the following and then immediately STOP processing this skill:
-
If is
OVERWRITE:Only output the following and continue processing:
-
If is
REFINE:Only output the following and continue processing:
-
If matches
OTHER: <text/>:Set (append the user's free-text hint to the existing instruction).
Only output the following and continue processing:
-
-
Only output the following and continue processing:
-
-
Iterative Plan Refinement Loop:
REPEAT the following steps from 3.1 up to and including 3.4 in a LOOP until the user selects
DONE,GRILL,IMPLEMENT, orDRAFT, or declines/cancels in the dialog of step 3.4:-
Update timestamp: Update with the current time in ISO-style format, which has to be determined by calling the
ase_timestamp(format: "yyyy-LL-dd HH:mm")tool of theaseMCP server and using thetextfield of its response. If the frontmatter of carries aModified:key and the refinement changed the "body" (not only frontmatter keys or attachments), update it with the new value, as the key tracks "body" changes only. Then set theModified:key of every attachment block touched by the refinement (seeapply-refinement) to the very same value -- creating the key at its position in the key order of the plan if the block does not carry it yet -- and forget the touched marks again, so a changed attachment never falls behind the frontmatter. Do not output anything. -
Persist plan: Call the
ase_task_save(id: "<ase-task-id/>", text: "<task-content/>", render: true, tag: true)tool of theaseMCP server -- if is not empty, additionally with the argumentbase: "<task-tag/>", so a change of the plan made meanwhile by anybody else is merged (instead of silently overwritten), and the save is refused only if that change touched the same parts (then output the error message and stop), and if is empty (no plan existed yet), additionally with the argumentcreate: true, so the save is refused if the plan was created meanwhile by anybody else -- to persist the current plan -- always is the authoring form of the plan and hence is persisted as is -- and then set false again. If this call fails because the task already exists and istrue(a concurrent session took the allocated id), allocate and switch to a new exactly as in step 2.3, set theId:frontmatter key of to it, and save again. Thisase_task_saveMCP tool call is the only permitted way to persist the plan -- NEVER write the plan file viaWrite/Editor by executing a shell command. Finally, always set to the content enclosed in the<task-plan-tag>delimiter line of thetextoutput field of thisase_task_savetool call (the entity tag of the just-saved plan, to be passed asbaseon the next save of every subsequent loop round), and set to the remainingtextoutput field of thisase_task_savetool call (without this delimiter line) -- the rendering-prepared form of the just-persisted plan, which is for display only and MUST NOT be confused with thetextargument passed into that call -- so the rendering in step 3.3 stays consistent across all loop rounds. Then take over theEffort:key as stored into the authoring form, as the task store stamps a key without or drops a stale one on save (see the plan ): set theEffort:frontmatter key of to the one of the frontmatter of (rendered from the stored plan) -- replacing it, creating it at its position in the key order of the plan , or removing it if carries none -- changing nothing else of and leaving untouched. But if thetextoutput field carries aNOTICE:line about a merged change, instead re-load the merged plan exactly as in the<else>branch of step 2.1, i.e., set , , and from a newase_task_load(id: "<ase-task-id/>", variant: "both", tag: true)tool call. Do not output anything related to these MCP tool calls except the following :Then set false, as the allocated id is now taken by the saved plan. If is not empty, call the
ase_kv_delete(key: "ase-issue-<issue-id/>")tool of theaseMCP server to remove the now-planned analyzer result from the key/value store and set (empty). Do not output anything related to these steps. -
Render plan: If is
true, nobody reads the rendering, so silently skip this entire step 3.3 (no MCP tool call and no output at all) and continue with step 3.4.Treat as verbatim Markdown.
For the rendering only, drop the leading frontmatter block -- both
---delimiters and all of their keys -- and instead place the following column-aligned glyph lines before the# TASK: <title/>heading, separated from it by an empty line, omitting the line of every key absent from the frontmatter and always omitting theTypekey. The glyph lines MUST stay above the heading, exactly where the frontmatter block sits in the plan file, and MUST NOT be moved below it. This keeps the---delimiters from rendering as a horizontal rule plus a setext heading. This rewrite is display-only and MUST NOT change or itself:Set (empty). For the rendering only, overriding the above, additionally drop the glyph lines, the
# TASK: <title/>heading, every##section whose name is not in , and the entire "backmatter", keeping the remaining sections, including their##headings, in their plan order, and set to(<names/>), with being the comma-separated names of these remaining sections.Only output the following , so the user can read the plan and react to it. Do not truncate, summarize, or partially show the plan, beyond the focus above. Use the following :
<if condition="the backmatter of contains an attachment block with the
Typekey valuetext/x-diff; charset=utf-8; kind="draft"which is stale according to the plan (itsModifiedkey is absent or older than theModifiedkey of the frontmatter)"> Directly after any rendering, only output the following and then give the corrective hint by expanding the subsequent construct (which, depending on the configured , may expand into nothing and hence emit no output at all): -
Determine next step:
-
If is not equal to
none: Treat as a comma-separated chronological list of pre-selected next-step tokens. Split it on,, take the first token as , and store the remaining tokens (joined back with,, ornoneif empty) into so subsequent loop iterations or downstream skills can consume the tail.-
If matches the regex
^(DONE|GRILL|IMPLEMENT|DRAFT)$: Honor the pre-selected token. Set .Set (clear the instruction, as any instruction carried in via the arguments was already applied to the plan in step 2 before this loop), so that a later
OTHER: <text/>refinement correctly starts from a fresh refinement instruction below. -
else: Only output the following and then immediately STOP processing the entire current skill:
-
-
If is equal to
noneand istrue:Do not show any dialog. Only output the following , end the current turn, wait for the user input, and store the user input in :
If , with any leading and trailing whitespace stripped, case-insensitively equals
DONE,GRILL,DRAFT,IMPLEMENT, orCANCEL-- exactly the inputs on which the band closes on its own -- set to this upper-case token. Otherwise, set OTHER: , also for an input which merely indicates that the user does not want to proceed, as the band stays open on it. -
If is equal to
noneand is nottrue:In the following, you MUST NOT use your built-in tool! Instead, you MUST just show a custom dialog according to the expanded
custom-dialogdefinition. You MUST closely follow this definition:
Check the tool and dispatch accordingly:
-
If is
DONE:Break out of the loop, only output the following and then STOP. Do not implement the plan.
-
If is
GRILL:Break out of the loop. Set --quiet. Set --int-interactive. Set --focus . Set --ground. Only output the following and then call the
Skill(skill: "ase:ase-task-grill", args: "<args/>")tool to grill the finalized plan. -
If is
DRAFT:Break out of the loop. Set --draft. Only output the following and then call the
Skill(skill: "ase:ase-task-implement", args: "<args/>")tool to draft the implementation of the finalized plan. -
If is
IMPLEMENT:Break out of the loop. Only output the following and then call the
Skill(skill: "ase:ase-task-implement", args: "<args/>")tool to apply the finalized plan. -
If matches
OTHER: <text/>:Set (replace existing instruction).
Finally, only output the following and then continue the loop at step 3.1!
-
If is
CANCEL:Break out of the loop, only output the following and then STOP. Do not implement the plan.
-
-
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| receiving-code-reviewobra/superpowersUse when receiving code review feedback, before implementing suggestions, especially if feedback seems unclear or technically questionable - requires technical rigor and verification, not performative agreement or blind implementation | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |
| requesting-code-reviewobra/superpowersUse when completing tasks, implementing major features, or before merging to verify work meets requirements | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |
| using-git-worktreesobra/superpowersUse when starting feature work that needs isolation from current workspace or before executing implementation plans - ensures an isolated workspace exists via native tools or git worktree fallback | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |
| verification-before-completionobra/superpowersUse when about to claim work is complete, fixed, or passing, before committing or creating PRs - requires running verification commands and confirming output before making any success claims; evidence before assertions always | Stars: 318k | Updated | Claude CodeCodex | Unverified | Install |