@rse/ase 0.9.6 → 0.9.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (58) hide show
  1. package/dst/ase-getopt.js +11 -1
  2. package/dst/ase-markdown.js +235 -0
  3. package/dst/ase-service.js +2 -0
  4. package/dst/ase-task.js +22 -20
  5. package/package.json +6 -6
  6. package/plugin/.claude-plugin/plugin.json +1 -1
  7. package/plugin/.github/plugin/plugin.json +1 -1
  8. package/plugin/agents/ase-docs-proofread.md +2 -2
  9. package/plugin/meta/ase-constitution.md +7 -0
  10. package/plugin/meta/ase-control.md +24 -3
  11. package/plugin/meta/ase-format-task.md +14 -14
  12. package/plugin/meta/ase-getopt.md +2 -1
  13. package/plugin/meta/ase-skill.md +28 -9
  14. package/plugin/package.json +3 -3
  15. package/plugin/skills/ase-arch-analyze/SKILL.md +88 -89
  16. package/plugin/skills/ase-arch-discover/SKILL.md +18 -9
  17. package/plugin/skills/ase-code-analyze/SKILL.md +6 -5
  18. package/plugin/skills/ase-code-craft/SKILL.md +47 -40
  19. package/plugin/skills/ase-code-craft/help.md +2 -2
  20. package/plugin/skills/ase-code-explain/SKILL.md +1 -1
  21. package/plugin/skills/ase-code-insight/SKILL.md +1 -1
  22. package/plugin/skills/ase-code-lint/SKILL.md +16 -8
  23. package/plugin/skills/ase-code-refactor/SKILL.md +47 -40
  24. package/plugin/skills/ase-code-refactor/help.md +2 -2
  25. package/plugin/skills/ase-code-resolve/SKILL.md +48 -40
  26. package/plugin/skills/ase-code-resolve/help.md +2 -2
  27. package/plugin/skills/ase-docs-distill/SKILL.md +1 -1
  28. package/plugin/skills/ase-docs-distill/help.md +3 -3
  29. package/plugin/skills/ase-docs-proofread/SKILL.md +22 -13
  30. package/plugin/skills/ase-meta-brainstorm/SKILL.md +25 -6
  31. package/plugin/skills/ase-meta-brainstorm/help.md +6 -10
  32. package/plugin/skills/ase-meta-diff/SKILL.md +5 -4
  33. package/plugin/skills/ase-meta-diff/help.md +10 -11
  34. package/plugin/skills/ase-meta-evaluate/SKILL.md +10 -9
  35. package/plugin/skills/ase-meta-quorum/SKILL.md +15 -5
  36. package/plugin/skills/ase-meta-review/SKILL.md +3 -3
  37. package/plugin/skills/ase-meta-review/help.md +3 -3
  38. package/plugin/skills/ase-meta-search/SKILL.md +9 -8
  39. package/plugin/skills/ase-meta-steelman/SKILL.md +1 -1
  40. package/plugin/skills/ase-meta-why/SKILL.md +16 -10
  41. package/plugin/skills/ase-task-condense/SKILL.md +32 -17
  42. package/plugin/skills/ase-task-condense/help.md +1 -1
  43. package/plugin/skills/ase-task-delete/SKILL.md +6 -3
  44. package/plugin/skills/ase-task-edit/SKILL.md +58 -36
  45. package/plugin/skills/ase-task-edit/help.md +3 -3
  46. package/plugin/skills/ase-task-grill/SKILL.md +59 -24
  47. package/plugin/skills/ase-task-id/SKILL.md +11 -2
  48. package/plugin/skills/ase-task-implement/SKILL.md +38 -17
  49. package/plugin/skills/ase-task-implement/help.md +1 -1
  50. package/plugin/skills/ase-task-list/SKILL.md +1 -1
  51. package/plugin/skills/ase-task-preflight/SKILL.md +42 -22
  52. package/plugin/skills/ase-task-preflight/help.md +1 -1
  53. package/plugin/skills/ase-task-reboot/SKILL.md +31 -22
  54. package/plugin/skills/ase-task-rename/SKILL.md +5 -3
  55. package/plugin/skills/ase-task-view/SKILL.md +19 -8
  56. package/plugin/skills/ase-task-view/help.md +24 -5
  57. package/dst/ase-bash.js +0 -618
  58. package/dst/ase-hello.js +0 -24
@@ -17,24 +17,23 @@ The `ase-meta-diff` skill turns a raw Git diff into a *concise*,
17
17
  *human-readable* narrative of what changed and why, *grouped by
18
18
  intent* (such as *Feature*, *Improvement*, *Bugfix*, *Update*,
19
19
  *Cleanup*, or *Refactor*) rather than by file. It inspects the
20
- *staged* changes (`git diff --cached HEAD`). The result is a short
21
- bullet list, one bullet per intent group, each naming the affected
22
- files with their per-file `[+N/-M]` line counts - giving you the
23
- essence of the changes at a glance.
20
+ *staged* changes (`git diff --cached HEAD`). The result is a compact
21
+ table, one row per intent group, each naming the affected files
22
+ with their per-file `[+N/-M]` line counts - giving you the essence
23
+ of the changes at a glance.
24
24
 
25
25
  With `--coherence`, the skill additionally *reconstructs the single
26
26
  intended change* the diff is trying to accomplish - phrased as one crisp
27
27
  *thesis* sentence - and then walks *every* hunk to *flag those that do
28
28
  not serve it*: **scope creep** (an unrelated feature or drive-by refactor
29
- riding along), **stray debug** (leftover prints, commented-out code, or
30
- disabled tests), and **ripple** (mechanical fallout edits forced by the
31
- core change). It emits an overall **COHERENT** / **INCOHERENT** verdict
29
+ riding along) and **stray debug** (leftover prints, commented-out code, or
30
+ disabled tests). It emits an overall **COHERENT** / **INCOHERENT** verdict
32
31
  plus a table of the flagged hunks with what to do with each - keeping the
33
32
  diff to a *single logical and coherent change* before it is committed.
34
33
 
35
34
  With `--risk`, the skill additionally *scores* the same diff against a
36
35
  four-axis **coupling-criticality-coverage-reversibility** rubric and
37
- emits a *graded risk report* - one bullet per axis (each scored *1*-*5*
36
+ emits a *graded risk report* - one table row per axis (each scored *1*-*5*
38
37
  with a one-line evidence justification drawn from the actual hunks), an
39
38
  overall risk band (**LOW**, **MODERATE**, **HIGH**, or **CRITICAL**),
40
39
  and one actionable *mitigation* per high-risk axis. The axes combine
@@ -57,9 +56,9 @@ giving a visual sense of *what a diff endangers* before a deeper review.
57
56
  `--coherence`, `-c`:
58
57
  In addition to the intent-grouped summary, reconstruct the diff's
59
58
  *single intended change* as one crisp *thesis* sentence and flag
60
- *every* hunk that does *not* serve it - *scope creep*, *stray debug*,
61
- or *ripple* fallout - then emit an overall **COHERENT** /
62
- **INCOHERENT** verdict with a table of the flagged hunks.
59
+ *every* hunk that does *not* serve it - *scope creep* or *stray
60
+ debug* - then emit an overall **COHERENT** / **INCOHERENT** verdict
61
+ with a table of the flagged hunks.
63
62
 
64
63
  `--risk`, `-r`:
65
64
  In addition to the intent-grouped summary, score the diff against
@@ -193,15 +193,16 @@ multi-*criteria* decision matrix.
193
193
 
194
194
  - Determine rating distance percentage <percentage/> between
195
195
  <alternative-K/> and <alternative-X/> from their *raw,
196
- unrounded* ratings by calculating: <percentage/> = <distance/> /
197
- abs(<rating-K/>). Do not output anything.
198
-
199
- - If <rating-K/> is exactly zero, skip the division entirely
200
- and treat <percentage/> as if it were equal to <distance/>
201
- (so a true zero tie with <distance/> = 0 falls into the
202
- *MULTIPLE BEST* branch below, and a non-zero gap with zero
203
- best falls into the *small distance* branch below).
204
- Do not output anything.
196
+ unrounded* ratings as follows. If <rating-K/> is exactly zero,
197
+ skip the division entirely and treat <percentage/> as if it
198
+ were equal to <distance/> (so a true zero tie with <distance/>
199
+ = 0 falls into the *MULTIPLE BEST* branch below, while a non-zero
200
+ gap with zero best is routed by the magnitude of <distance/>
201
+ through the same thresholds as <percentage/> otherwise). Do not
202
+ output anything.
203
+
204
+ - Otherwise (<rating-K/> is non-zero), calculate: <percentage/> =
205
+ <distance/> / abs(<rating-K/>). Do not output anything.
205
206
 
206
207
  - By construction, <rating-K/> is the maximum rating across
207
208
  all alternatives, so <distance/> >= 0 always holds; using
@@ -62,9 +62,19 @@ by querying *multiple* AIs for an *optimal consensus*.
62
62
 
63
63
  The user-selectable foreign models are restricted by the
64
64
  `--models`/`-m` option, parsed into <getopt-option-models/>
65
- as a comma-separated list of model tokens. The default is
66
- the single token `all`. If <getopt-option-models/> contains
67
- the token `all`, you *MUST* treat it as the full list
65
+ as a comma-separated list of model tokens. The getopt parser
66
+ validates only the *first* token, so you *MUST* validate each
67
+ remaining token yourself against the allowed set `all`, `chatgpt`,
68
+ `gemini`, `deepseek`, `grok`, `glm`, `qwen`. If any token is *not*
69
+ in this set, only output the following <template/> and then
70
+ immediately *STOP* processing the entire current skill:
71
+
72
+ <template>
73
+ ⧉ **ASE**: ✪ skill: **ase-meta-quorum**, ▶ ERROR: invalid `--models` token: **<token/>**
74
+ </template>
75
+
76
+ The default is the single token `all`. If <getopt-option-models/>
77
+ contains the token `all`, you *MUST* treat it as the full list
68
78
  `chatgpt,gemini,deepseek,grok,glm,qwen` (all models). Anthropic
69
79
  Claude (yourself) is *always* included, independent of this option.
70
80
 
@@ -142,8 +152,8 @@ by querying *multiple* AIs for an *optimal consensus*.
142
152
  5. <step id="STEP 5: Show Results">
143
153
 
144
154
  Finally show the summary, the consensus and the complete and
145
- unmodified responses of yourself and each of the MCP servers, based
146
- on the following output <template/>:
155
+ unmodified responses of yourself and each of the queried foreign
156
+ AIs, based on the following output <template/>:
147
157
 
148
158
  <template>
149
159
  **QUESTION**:
@@ -107,8 +107,8 @@ explicitly requested by this procedure via outputs based on a <template/>!
107
107
  <verdict/> to `REJECT - DEMANDS CHANGES` if *any* finding in
108
108
  <findings/> has a `severity` field of `HIGH`; otherwise set
109
109
  <verdict/> to `APPROVE`. The verdict is derived *before* the
110
- severity floor below, so a suppressed `HIGH` finding still drives the
111
- verdict.
110
+ severity floor below, so the floor only affects which findings are
111
+ *rendered*, never the verdict.
112
112
 
113
113
  Then *apply the severity floor* selected via <getopt-option-severity/>
114
114
  (default `LOW`): define the ordinal rank `LOW`=1, `MEDIUM`=2,
@@ -135,7 +135,7 @@ explicitly requested by this procedure via outputs based on a <template/>!
135
135
 
136
136
  </template>
137
137
 
138
- You *MUST* *NOT* output anything else in this STEP 3.
138
+ You *MUST* *NOT* output anything else in this STEP 3.1.
139
139
 
140
140
  2. <if condition="<findings/> is empty">
141
141
  Only output the following <template/> and then *SKIP* the
@@ -59,9 +59,9 @@ before it is committed.
59
59
  Set the *severity floor* (default `LOW`): findings below the chosen
60
60
  threshold are silently suppressed, ordered `LOW` < `MEDIUM` <
61
61
  `HIGH`. The default `LOW` keeps all findings; `ACCEPTED` findings are
62
- never suppressed. The floor only affects the rendered findings table;
63
- the overall *verdict* is still derived from all findings, so a
64
- suppressed `HIGH` finding still yields a *REJECT* verdict.
62
+ never suppressed. The floor only affects the rendered findings table,
63
+ not the overall *verdict*, which is always derived from all findings
64
+ before the floor is applied.
65
65
 
66
66
  ## ARGUMENTS
67
67
 
@@ -41,8 +41,8 @@ Your objective is to *search* the *Internet*/*Web* for the following query:
41
41
  <define name="agent">
42
42
  ```text
43
43
  Agent(
44
- name: "ase-meta-search",
45
- description: "Query Web Search Service",
44
+ name: "ase-meta-search-<arg1/>",
45
+ description: "Query Web Search Service: <arg1/>",
46
46
  subagent_type: "ase:ase-meta-search",
47
47
  prompt: <content/>
48
48
  )
@@ -53,8 +53,9 @@ Your objective is to *search* the *Internet*/*Web* for the following query:
53
53
  *backend tokens*. The getopt parser validates only the *first*
54
54
  token, so you *MUST* validate each remaining token yourself against
55
55
  the allowed set `all`, `perplexity`, `brave`, `exa`, `websearch`. If
56
- any token is *not* in this set, only output the following <template/>
57
- and then immediately *STOP* processing the entire current skill:
56
+ any token is *not* in this set, bind <token/> to that offending
57
+ token, then only output the following <template/> and then
58
+ immediately *STOP* processing the entire current skill:
58
59
 
59
60
  <template>
60
61
  ⧉ **ASE**: ✪ skill: **ase-meta-search**, ▶ ERROR: invalid `--services` token: **<token/>**
@@ -66,7 +67,7 @@ Your objective is to *search* the *Internet*/*Web* for the following query:
66
67
  If the `perplexity` backend is *selected* and the MCP tool
67
68
  `perplexity_search` from the MCP server `search-perplexity` is available:
68
69
 
69
- <expand name="agent">
70
+ <expand name="agent" arg1="perplexity">
70
71
  Call the MCP tool `perplexity_search(query: "<query/>")`
71
72
  from the MCP server `search-perplexity`.
72
73
  </expand>
@@ -74,7 +75,7 @@ Your objective is to *search* the *Internet*/*Web* for the following query:
74
75
  If the `brave` backend is *selected* and the MCP tool
75
76
  `brave_web_search` from the MCP server `search-brave` is available:
76
77
 
77
- <expand name="agent">
78
+ <expand name="agent" arg1="brave">
78
79
  Call the MCP tool `brave_web_search(query: "<query/>")`
79
80
  from the MCP server `search-brave`.
80
81
  </expand>
@@ -82,14 +83,14 @@ Your objective is to *search* the *Internet*/*Web* for the following query:
82
83
  If the `exa` backend is *selected* and the MCP tool
83
84
  `web_search_exa` from the MCP server `search-exa` is available:
84
85
 
85
- <expand name="agent">
86
+ <expand name="agent" arg1="exa">
86
87
  Call the MCP tool `web_search_exa(query: "<query/>")`
87
88
  from the MCP server `search-exa`.
88
89
  </expand>
89
90
 
90
91
  If the `websearch` backend is *selected*:
91
92
 
92
- <expand name="agent">
93
+ <expand name="agent" arg1="websearch">
93
94
  Call the tool `WebSearch(query: "<query/>")`.
94
95
  </expand>
95
96
 
@@ -197,7 +197,7 @@ to <getopt-option-count/>; if <getopt-option-count/> is *non-numeric* or
197
197
  Carry the result forward to the next round: set
198
198
  <thesis><fortification/></thesis> (the fortification becomes the
199
199
  thesis to be strengthened next), set <i/> to <i/> + 1 (increment the
200
- round counter), and then *CONTINUE* the *LOOP* at **STEP 1**!
200
+ round counter), and then *REPEAT* the operation at **STEP 1**!
201
201
  </if>
202
202
 
203
203
  <if condition="<i/> is greater than or equal to <rounds/>">
@@ -106,13 +106,15 @@ addressing surface-level symptoms.
106
106
 
107
107
  Ask <question/> and surface up to <width/> *distinct*,
108
108
  *non-overlapping* candidate sub-causes, each documented in <answer-k/>.
109
+ Let <count/> be the number of candidates you actually surfaced
110
+ (at least one, at most <width/>).
109
111
  Don't stop at symptoms, keep digging for systemic issues.
110
112
  Explore *different* candidates -- technical, domain-specific,
111
113
  process-related, or organizational causes -- and avoid restating
112
114
  the same cause in different words.
113
115
 
114
116
  Start with <k>1</k> (set candidate counter to one).
115
- <while condition="<k/> is less than or equal to <width/>">
117
+ <while condition="<k/> is less than or equal to <count/>">
116
118
  <template>
117
119
  <ase-tpl-bullet-secondary/> **WHY <n/>.<k/>**: <answer-k/>
118
120
  </template>
@@ -150,15 +152,19 @@ addressing surface-level symptoms.
150
152
  whole chain up to the original <problem/>).
151
153
 
152
154
  When <width/> is *greater than 1* and this backward validation *fails* at
153
- some level -- i.e. the chosen sub-cause does *not* adequately explain the
154
- fact above it -- *backtrack*: discard the chosen sub-cause from that level
155
- downward, pick the next-best candidate from that level's <fallbacks/>, set
156
- <question/> to it, and re-run the STEP 2 widened descent from there. Repeat
157
- until a chain survives backward validation or that level's <fallbacks/> are
158
- exhausted (then report the strongest chain found and note that no candidate
159
- fully validated). This is the payoff of <width/> *greater than 1*: the
160
- enumerated alternatives let the analysis *recover* from a wrong turn instead
161
- of committing to a mis-rooted chain.
155
+ some level <m/> -- i.e. the chosen sub-cause does *not* adequately explain
156
+ the fact above it -- *backtrack*: discard the chosen sub-cause (and every
157
+ chosen sub-cause below it) from level <m/> downward, pick the next-best
158
+ candidate from level <m/>'s <fallbacks/>, and resume the STEP 2 widened
159
+ descent: set <n/> to <m/> (reset the iteration counter to the failed level),
160
+ set <question/> to the picked candidate, and re-enter STEP 2's
161
+ <while condition="<n/> is less than or equal to <depth/>"/> loop at that
162
+ level -- so the original <depth/> budget is honored from <m/> downward.
163
+ Repeat until a chain survives backward validation or level <m/>'s
164
+ <fallbacks/> are exhausted (then report the strongest chain found and note
165
+ that no candidate fully validated). This is the payoff of <width/> *greater
166
+ than 1*: the enumerated alternatives let the analysis *recover* from a wrong
167
+ turn instead of committing to a mis-rooted chain.
162
168
 
163
169
  Propose a solution that addresses and solves the validated root-cause.
164
170
  For the proposed solution, optionally directly propose corresponding source code changes.
@@ -65,7 +65,7 @@ explicitly requested by this procedure via outputs based on a <template/>!
65
65
  </template>
66
66
  </if>
67
67
 
68
- 2. else <if condition="<instruction/> is NOT empty">
68
+ 2. <elseif condition="<instruction/> is NOT empty">
69
69
  The argument is neither empty nor a valid task id. As this
70
70
  skill only accepts an optional `[<id>]` argument and *never*
71
71
  a free-text instruction, only output the following <template/>
@@ -74,7 +74,7 @@ explicitly requested by this procedure via outputs based on a <template/>!
74
74
  <template>
75
75
  ⧉ **ASE**: ☻ skill: **ase-task-condense**, ▶ ERROR: expected single `[<id>]` argument
76
76
  </template>
77
- </if>
77
+ </elseif>
78
78
 
79
79
  2. **Determine Operation:**
80
80
 
@@ -114,9 +114,9 @@ explicitly requested by this procedure via outputs based on a <template/>!
114
114
  and unchanged*. Honor the following ruleset *strictly*:
115
115
 
116
116
  1. *Preserve-exactly (never alter)*: the plan <format/>
117
- structure (the headings `#`/`##`, the `※`/`◉`/`✪` markers,
118
- all three `## ※ CONTEXT`, `## ※ CHANGES`, and `##
119
- VERIFICATION` sections, the `created:`/`modified:` line, and
117
+ structure (the headings `#`/`##`, all three `## CONTEXT`,
118
+ `## CHANGES`, and `## VERIFICATION` sections, the
119
+ `Created:`/`Modified:` lines, and
120
120
  the `- **<aspect/>**:` bullet labels), all *code spans* and
121
121
  code blocks, technical terms, file paths, identifiers,
122
122
  numbers, severities (`LOW`/`MEDIUM`/`HIGH`/`ACCEPTED`), and
@@ -223,13 +223,15 @@ explicitly requested by this procedure via outputs based on a <template/>!
223
223
  </template>
224
224
 
225
225
  - If <result/> is `EDIT`:
226
- Set <args></args> (empty).
226
+ Set <args></args> (set args to empty).
227
+ <if condition="the condensed plan was saved via `ase_task_save` in step 3">
228
+ Set <args>--int-reuse-task</args>.
229
+ </if>
227
230
  <if condition="<getopt-option-next/> is not equal `none`">
228
- Set <args>--next <getopt-option-next/></args> (forward
229
- remaining list tokens to the downstream skill).
231
+ Set <args><args/> --next <getopt-option-next/></args>
230
232
  </if>
231
233
  Only output the following <template/> and then call the
232
- tool `Skill(skill: "ase:ase-task-edit", args: <args/>)`
234
+ tool `Skill(skill: "ase:ase-task-edit", args: "<args/>")`
233
235
  to invoke the `ase:ase-task-edit` skill in order to *edit*
234
236
  the condensed plan. Immediately stop processing the current
235
237
  skill once the `Skill` tool was used.
@@ -239,13 +241,15 @@ explicitly requested by this procedure via outputs based on a <template/>!
239
241
  </template>
240
242
 
241
243
  - If <result/> is `IMPLEMENT`:
242
- Set <args></args> (empty).
244
+ Set <args></args> (set args to empty).
245
+ <if condition="the condensed plan was saved via `ase_task_save` in step 3">
246
+ Set <args>--int-reuse-task</args>.
247
+ </if>
243
248
  <if condition="<getopt-option-next/> is not equal `none`">
244
- Set <args>--next <getopt-option-next/></args> (forward
245
- remaining list tokens to the downstream skill).
249
+ Set <args><args/> --next <getopt-option-next/></args>
246
250
  </if>
247
251
  Only output the following <template/> and then call the
248
- `Skill(skill: "ase:ase-task-implement", args: <args/>)` tool
252
+ `Skill(skill: "ase:ase-task-implement", args: "<args/>")` tool
249
253
  to *apply* the plan.
250
254
 
251
255
  <template>
@@ -253,15 +257,26 @@ explicitly requested by this procedure via outputs based on a <template/>!
253
257
  </template>
254
258
 
255
259
  - If <result/> is `PREFLIGHT`:
256
- Set <args></args> (empty).
260
+ Set <args></args> (set args to empty).
261
+ <if condition="the condensed plan was saved via `ase_task_save` in step 3">
262
+ Set <args>--int-reuse-task</args>.
263
+ </if>
257
264
  <if condition="<getopt-option-next/> is not equal `none`">
258
- Set <args>--next <getopt-option-next/></args> (forward
259
- remaining list tokens to the downstream skill).
265
+ Set <args><args/> --next <getopt-option-next/></args>
260
266
  </if>
261
267
  Only output the following <template/> and then call the
262
- `Skill(skill: "ase:ase-task-preflight", args: <args/>)` tool
268
+ `Skill(skill: "ase:ase-task-preflight", args: "<args/>")` tool
263
269
  to *apply* the plan.
264
270
 
265
271
  <template>
266
272
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ✪ plan: **<words/>** words, ▶ status: **plan condensed -- hand-off to pre-flight**
267
273
  </template>
274
+
275
+ - If <result/> matches `OTHER: <text/>` or is any other
276
+ unrecognized value:
277
+ Treat it as `DONE` (the condensed plan is already saved):
278
+ only output the following <template/> and then *STOP*.
279
+
280
+ <template>
281
+ ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ✪ plan: **<words/>** words, ▶ status: **plan condensed -- done**
282
+ </template>
@@ -30,7 +30,7 @@ telegrapher-like even under the `writer` persona.
30
30
 
31
31
  The plan is saved *only* when condensing actually makes it smaller; if no
32
32
  further reduction is possible, the plan is left untouched (including its
33
- `✎ modified:` timestamp) and reported as *already condensed*.
33
+ `⚙ Modified:` timestamp) and reported as *already condensed*.
34
34
 
35
35
  After condensing, the user is asked whether to stop or hand off to
36
36
  `ase-task-edit`, `ase-task-implement`, or `ase-task-preflight`, unless
@@ -35,6 +35,7 @@ explicitly requested by this procedure via outputs based on a <template/>!
35
35
  1. Set <id>$ARGUMENTS</id> initially, with any leading and trailing
36
36
  whitespace stripped.
37
37
  Inherit the always existing <ase-task-id/> from the current context.
38
+ Inherit the always existing <ase-session-id/> from the current context.
38
39
  Do not output anything.
39
40
 
40
41
  2. <if condition="<id/> is empty">
@@ -59,20 +60,22 @@ explicitly requested by this procedure via outputs based on a <template/>!
59
60
  output anything related to this MCP tool call.
60
61
 
61
62
  - If <text/> starts with `ERROR:` or `WARNING:`:
62
- Only output the following <template/>:
63
+ Set <deleted>false</deleted> and only output the following
64
+ <template/>:
63
65
 
64
66
  <template>
65
67
  ⧉ **ASE**: ◉ task: **<id/>**, ▶ status: **<text/>**
66
68
  </template>
67
69
 
68
70
  - If <text/> starts NOT with `ERROR:` and NOT with `WARNING:`:
69
- Only output the following <template/>:
71
+ Set <deleted>true</deleted> and only output the following
72
+ <template/>:
70
73
 
71
74
  <template>
72
75
  ⧉ **ASE**: ◉ task: **<id/>**, ▶ status: **task deleted**
73
76
  </template>
74
77
 
75
- 2. <if condition="<id/> is equal <ase-task-id/> AND <ase-task-id/> is not equal 'default'">
78
+ 2. <if condition="<deleted/> is equal 'true' AND <id/> is equal <ase-task-id/> AND <ase-task-id/> is not equal 'default'">
76
79
  Set <ase-task-id>default</ase-task-id>. Call the `ase_task_id(id:
77
80
  "<ase-task-id/>", session: "<ase-session-id/>")` tool from the `ase`
78
81
  MCP server to switch the task to the default task. Only output
@@ -23,7 +23,7 @@ Iteratively Edit a Task Plan
23
23
 
24
24
  <expand name="getopt"
25
25
  arg1="ase-task-edit"
26
- arg2="--plan|-p=(none|OVERWRITE|REFINE|PRESERVE) --dry|-d --next|-n=(none|DONE|GRILL|PREFLIGHT|IMPLEMENT)...">
26
+ arg2="--plan|-p=(none|OVERWRITE|REFINE|PRESERVE) --dry|-d --next|-n=(none|DONE|GRILL|PREFLIGHT|IMPLEMENT)... --int-reuse-task">
27
27
  $ARGUMENTS
28
28
  </expand>
29
29
 
@@ -67,13 +67,13 @@ the <instruction/> and all decisions you derived from the
67
67
 
68
68
  If a `CHANGELOG.md` file exists in the project (or in any
69
69
  affected sub-package), the plan *MUST* include, as part of
70
- its `##CHANGES` section, an explicit bullet point
70
+ its `## CHANGES` section, an explicit bullet point
71
71
  describing the addition of a corresponding new entry to
72
72
  that `CHANGELOG.md` file, aligned with its existing style
73
73
  and conventions.
74
74
 
75
75
  <if condition="<getopt-option-dry/> is equal `true`">
76
- You *MUST* completely omit the `##VERIFICATION` section
76
+ You *MUST* completely omit the `## VERIFICATION` section
77
77
  (including its heading and all of its bullet points) from
78
78
  <content/>.
79
79
  </if>
@@ -111,7 +111,7 @@ Set <content-dirty>true</content-dirty>.
111
111
  </template>
112
112
  </if>
113
113
 
114
- 2. else <if condition="
114
+ 2. <elseif condition="
115
115
  <instruction/> has the format `<id/>: <text/>` where
116
116
  <id/> matches the regexp `^[a-zA-Z][a-zA-Z0-9_-]*$` and
117
117
  <text/> is *empty*
@@ -126,9 +126,9 @@ Set <content-dirty>true</content-dirty>.
126
126
  <template>
127
127
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ▶ status: **task given**
128
128
  </template>
129
- </if>
129
+ </elseif>
130
130
 
131
- 3. else <if condition="
131
+ 3. <elseif condition="
132
132
  <instruction/> has the format `<id/>: <text/>` where
133
133
  <id/> matches the regexp `^[a-zA-Z][a-zA-Z0-9_-]*$` and
134
134
  <text/> is *not empty*
@@ -144,9 +144,9 @@ Set <content-dirty>true</content-dirty>.
144
144
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ▶ status: **task given**
145
145
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ⇌ instruction: **<instruction/>**, ▶ status: **instruction given**
146
146
  </template>
147
- </if>
147
+ </elseif>
148
148
 
149
- 4. else <if condition="
149
+ 4. <elseif condition="
150
150
  <instruction/> is not empty
151
151
  ">
152
152
  Only output the following <template/>:
@@ -155,9 +155,9 @@ Set <content-dirty>true</content-dirty>.
155
155
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ▶ status: **task inherited**
156
156
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ⇌ instruction: **<instruction/>**, ▶ status: **instruction given**
157
157
  </template>
158
- </if>
158
+ </elseif>
159
159
 
160
- 5. else <if condition="
160
+ 5. <elseif condition="
161
161
  <instruction/> is empty
162
162
  ">
163
163
  Only output the following <template/>:
@@ -165,14 +165,26 @@ Set <content-dirty>true</content-dirty>.
165
165
  <template>
166
166
  ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ▶ status: **task inherited**
167
167
  </template>
168
- </if>
168
+ </elseif>
169
169
 
170
170
  2. **Determine Plan:**
171
171
 
172
- 1. Call the `ase_task_load(id: "<ase-task-id/>")` tool of the `ase` MCP
173
- server to load any existing plan content and set <text/> to
174
- the `text` output field of this `ase_task_load` tool call.
175
- Do not output anything related to this MCP tool call.
172
+ 1. Determine any existing plan content:
173
+
174
+ <if condition="<getopt-option-int-reuse-task/> is equal `true`">
175
+ Set <text/> to the `text` argument of the most recent
176
+ `ase_task_save(id: '<ase-task-id/>', ...)` tool call,
177
+ *without* calling `ase_task_load` again. Set <status>plan
178
+ reused</status>. Do not output anything.
179
+ </if>
180
+ <else>
181
+ Call the `ase_task_load(id: "<ase-task-id/>")` tool of the
182
+ `ase` MCP server to load any existing plan content and set
183
+ <text/> to the `text` output field of this `ase_task_load`
184
+ tool call. Do not output anything related to this MCP tool
185
+ call. Set <status>plan loaded</status>.
186
+ </else>
187
+
176
188
  Set <content-dirty>false</content-dirty>.
177
189
 
178
190
  - If <text/> starts with `ERROR:`:
@@ -187,7 +199,7 @@ Set <content-dirty>true</content-dirty>.
187
199
  Only output the following <template/>:
188
200
 
189
201
  <template>
190
- ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ✪ plan: **<words/>** words, ▶ status: **plan loaded**
202
+ ⧉ **ASE**: ◉ task: **<ase-task-id/>**, ✪ plan: **<words/>** words, ▶ status: **<status/>**
191
203
  </template>
192
204
 
193
205
  2. <if condition="<content/> is empty AND <instruction/> is empty">
@@ -271,7 +283,7 @@ Set <content-dirty>true</content-dirty>.
271
283
  </template>
272
284
  </if>
273
285
 
274
- 4. <if condition="<content/> does not contain '#TASK' AND <instruction/> is empty">
286
+ 4. <if condition="<content/> does not contain '# TASK' AND <instruction/> is empty">
275
287
  Set <instruction><content/></instruction> (set instruction to content).
276
288
  Set <content></content> (set content to empty).
277
289
  Set <content-dirty>true</content-dirty>.
@@ -296,12 +308,12 @@ Set <content-dirty>true</content-dirty>.
296
308
  `PREFLIGHT`, or declines/cancels in the dialog of step 3.4:
297
309
 
298
310
  1. *Update timestamp*:
299
- <if condition="<content/> contains '✎ modified:' AND <content-dirty/> is 'true'">
311
+ <if condition="<content/> contains '⚙ Modified:' AND <content-dirty/> is 'true'">
300
312
  Update <timestamp-modified/> with the current time in
301
313
  ISO-style format, which has to be determined by calling the
302
314
  `ase_timestamp(format: "yyyy-LL-dd HH:mm")` tool of the `ase`
303
315
  MCP server and use the `text` field of its response. Update
304
- <content/> with the new `✎ modified: **<timestamp-modified/>**`.
316
+ <content/> with the new `Modified: <timestamp-modified/>`.
305
317
  Do not output anything.
306
318
  </if>
307
319
 
@@ -318,11 +330,12 @@ Set <content-dirty>true</content-dirty>.
318
330
  </template>
319
331
  </if>
320
332
 
321
- 3. *Render plan*: Only output the following <template/>, so the user
333
+ 3. *Render plan*: Treat <content/> as *verbatim* Markdown.
334
+ Only output the following <template/>, so the user
322
335
  can read the plan and react to it. If <content/> is longer
323
- than 90 lines and a `※ IMPLEMENTATION DRAFT` section (from the
336
+ than 90 lines and a `## IMPLEMENTATION DRAFT` section (from the
324
337
  companion skill `ase-task-preflight`) exists, replace the entire
325
- content of the `※ IMPLEMENTATION DRAFT` section with `[...]`.
338
+ content of the `## IMPLEMENTATION DRAFT` section with `[...]`.
326
339
  Else, do *not* truncate, summarize, or partially show the plan.
327
340
  Use the following <template/>:
328
341
 
@@ -349,8 +362,8 @@ Set <content-dirty>true</content-dirty>.
349
362
  Set <instruction></instruction> (clear the instruction, as
350
363
  any instruction carried in via the arguments was already
351
364
  applied to the plan in step 2 before this loop), so that a
352
- pre-selected `REFINE` correctly asks the user for a *fresh*
353
- refinement instruction below.
365
+ later `OTHER: <text/>` refinement correctly starts from a
366
+ *fresh* refinement instruction below.
354
367
 
355
368
  - else:
356
369
  Only output the following <template/> and then immediately
@@ -384,13 +397,16 @@ Set <content-dirty>true</content-dirty>.
384
397
 
385
398
  - If <result/> is `GRILL`:
386
399
 
387
- *Break* out of the *loop*. Set <args></args> (empty).
400
+ *Break* out of the *loop*.
401
+ Set <args></args> (set args to empty).
402
+ <if condition="the plan was saved via `ase_task_save` in step 3.2">
403
+ Set <args>--int-reuse-task</args>.
404
+ </if>
388
405
  <if condition="<getopt-option-next/> is not equal `none`">
389
- Set <args>--next <getopt-option-next/></args> (forward
390
- remaining list tokens to the downstream skill).
406
+ Set <args><args/> --next <getopt-option-next/></args>
391
407
  </if>
392
408
  Only output the following <template/> and then call the
393
- `Skill(skill: "ase:ase-task-grill", args: <args/>)` tool
409
+ `Skill(skill: "ase:ase-task-grill", args: "<args/>")` tool
394
410
  to *grill* the finalized plan.
395
411
 
396
412
  <template>
@@ -399,13 +415,16 @@ Set <content-dirty>true</content-dirty>.
399
415
 
400
416
  - If <result/> is `PREFLIGHT`:
401
417
 
402
- *Break* out of the *loop*. Set <args></args> (empty).
418
+ *Break* out of the *loop*.
419
+ Set <args></args> (set args to empty).
420
+ <if condition="the plan was saved via `ase_task_save` in step 3.2">
421
+ Set <args>--int-reuse-task</args>.
422
+ </if>
403
423
  <if condition="<getopt-option-next/> is not equal `none`">
404
- Set <args>--next <getopt-option-next/></args> (forward
405
- remaining list tokens to the downstream skill).
424
+ Set <args><args/> --next <getopt-option-next/></args>
406
425
  </if>
407
426
  Only output the following <template/> and then call the
408
- `Skill(skill: "ase:ase-task-preflight", args: <args/>)` tool
427
+ `Skill(skill: "ase:ase-task-preflight", args: "<args/>")` tool
409
428
  to *apply* the finalized plan.
410
429
 
411
430
  <template>
@@ -414,13 +433,16 @@ Set <content-dirty>true</content-dirty>.
414
433
 
415
434
  - If <result/> is `IMPLEMENT`:
416
435
 
417
- *Break* out of the *loop*. Set <args></args> (empty).
436
+ *Break* out of the *loop*.
437
+ Set <args></args> (set args to empty).
438
+ <if condition="the plan was saved via `ase_task_save` in step 3.2">
439
+ Set <args>--int-reuse-task</args>.
440
+ </if>
418
441
  <if condition="<getopt-option-next/> is not equal `none`">
419
- Set <args>--next <getopt-option-next/></args> (forward
420
- remaining list tokens to the downstream skill).
442
+ Set <args><args/> --next <getopt-option-next/></args>
421
443
  </if>
422
444
  Only output the following <template/> and then call the
423
- `Skill(skill: "ase:ase-task-implement", args: <args/>)` tool
445
+ `Skill(skill: "ase:ase-task-implement", args: "<args/>")` tool
424
446
  to *apply* the finalized plan.
425
447
 
426
448
  <template>