opencode-codeops 1.9.0 → 1.10.1
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.
- package/CHANGELOG.md +31 -0
- package/README.md +16 -0
- package/_shared/quality-profile.md +4 -0
- package/_shared/reasoning-effort.md +144 -0
- package/bin/lib/reasoning-effort.d.mts +98 -0
- package/bin/lib/reasoning-effort.mjs +383 -0
- package/package.json +1 -1
- package/plugin/index.ts +152 -0
- package/scripts/__pycache__/install_agents.cpython-312.pyc +0 -0
- package/scripts/codeops_effort.py +216 -0
- package/skills/exec-plan/SKILL.md +12 -0
- package/skills/exec-plan/execution-protocol.md +43 -3
- package/skills/grill-me/SKILL.md +10 -0
- package/skills/make-plan/SKILL.md +17 -0
- package/skills/make-plan/templates.md +2 -0
- package/skills/make-requirements/SKILL.md +10 -0
- package/skills/preflight/SKILL.md +10 -0
- package/skills/retro-requirements/SKILL.md +10 -0
- package/skills/setup-routing/SKILL.md +2 -0
- package/skills/setup-routing/routing.md +16 -1
- package/skills/upgrade-plan/SKILL.md +10 -0
|
@@ -0,0 +1,216 @@
|
|
|
1
|
+
#!/usr/bin/env python3
|
|
2
|
+
"""Record and clear the opt-in reasoning-effort level for a CodeOps session run.
|
|
3
|
+
|
|
4
|
+
The skills call this helper when a user passes `--auto-effort`. It writes one
|
|
5
|
+
small JSON file inside the session's CodeOps temp directory; the plugin reads
|
|
6
|
+
that file on every request and applies the level. The command fails closed:
|
|
7
|
+
an invalid level or a directory outside the CodeOps temp root exits with
|
|
8
|
+
status 2 and writes nothing.
|
|
9
|
+
"""
|
|
10
|
+
|
|
11
|
+
from __future__ import annotations
|
|
12
|
+
|
|
13
|
+
import argparse
|
|
14
|
+
import json
|
|
15
|
+
import os
|
|
16
|
+
import sys
|
|
17
|
+
import tempfile
|
|
18
|
+
from datetime import datetime, timezone
|
|
19
|
+
from pathlib import Path
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
#: The only levels a session flag may record.
|
|
23
|
+
EFFORT_LEVELS = ("low", "medium", "high", "max")
|
|
24
|
+
|
|
25
|
+
#: Name of the state file the plugin reads.
|
|
26
|
+
STATE_FILE_NAME = "reasoning-effort.json"
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
def codeops_tmp_root() -> Path:
|
|
30
|
+
"""Return the CodeOps-owned temp root for the active temp directory.
|
|
31
|
+
|
|
32
|
+
The root mirrors the layout `bin/lib/tmp-hygiene.mjs` owns, so the helper
|
|
33
|
+
and the plugin resolve the same per-session directory.
|
|
34
|
+
|
|
35
|
+
Returns:
|
|
36
|
+
Resolved path of the CodeOps temp root.
|
|
37
|
+
"""
|
|
38
|
+
return Path(tempfile.gettempdir()).resolve() / "opencode" / "codeops"
|
|
39
|
+
|
|
40
|
+
|
|
41
|
+
def resolve_session_dir(raw_dir: str) -> Path | None:
|
|
42
|
+
"""Validate a session directory argument against the CodeOps temp root.
|
|
43
|
+
|
|
44
|
+
A directory is accepted only when it exists, resolves strictly inside the
|
|
45
|
+
CodeOps temp root, and is not the root itself. Symlinks are resolved, so a
|
|
46
|
+
link that points outside the root is rejected.
|
|
47
|
+
|
|
48
|
+
Args:
|
|
49
|
+
raw_dir: The `--dir` argument as provided by the caller.
|
|
50
|
+
|
|
51
|
+
Returns:
|
|
52
|
+
The resolved session directory, or None when it is not acceptable.
|
|
53
|
+
"""
|
|
54
|
+
try:
|
|
55
|
+
resolved = Path(raw_dir).resolve(strict=True)
|
|
56
|
+
except (OSError, RuntimeError):
|
|
57
|
+
# RuntimeError covers a symlink loop on Python 3.12, which the
|
|
58
|
+
# filesystem reports as ELOOP rather than a plain OSError.
|
|
59
|
+
return None
|
|
60
|
+
root = codeops_tmp_root()
|
|
61
|
+
if resolved == root or root not in resolved.parents:
|
|
62
|
+
return None
|
|
63
|
+
if not resolved.is_dir():
|
|
64
|
+
return None
|
|
65
|
+
return resolved
|
|
66
|
+
|
|
67
|
+
|
|
68
|
+
def state_path(session_dir: Path) -> Path:
|
|
69
|
+
"""Return the state-file path inside a validated session directory.
|
|
70
|
+
|
|
71
|
+
Args:
|
|
72
|
+
session_dir: A directory accepted by `resolve_session_dir`.
|
|
73
|
+
|
|
74
|
+
Returns:
|
|
75
|
+
Path of the reasoning-effort state file.
|
|
76
|
+
"""
|
|
77
|
+
return session_dir / STATE_FILE_NAME
|
|
78
|
+
|
|
79
|
+
|
|
80
|
+
def set_level(session_dir: Path, level: str) -> int:
|
|
81
|
+
"""Write the session level atomically and report it.
|
|
82
|
+
|
|
83
|
+
The payload is written to a temporary file in the same directory and then
|
|
84
|
+
moved over the final name with `os.replace`, so a reader never observes a
|
|
85
|
+
partially written file.
|
|
86
|
+
|
|
87
|
+
Args:
|
|
88
|
+
session_dir: A validated session directory.
|
|
89
|
+
level: One of `EFFORT_LEVELS`.
|
|
90
|
+
|
|
91
|
+
Returns:
|
|
92
|
+
Process exit code 0.
|
|
93
|
+
"""
|
|
94
|
+
payload = {
|
|
95
|
+
"schema": 1,
|
|
96
|
+
"reasoning": level,
|
|
97
|
+
"setAt": datetime.now(timezone.utc).isoformat(timespec="seconds"),
|
|
98
|
+
}
|
|
99
|
+
path = state_path(session_dir)
|
|
100
|
+
descriptor, temporary_name = tempfile.mkstemp(
|
|
101
|
+
prefix=f"{STATE_FILE_NAME}.", suffix=".tmp", dir=session_dir
|
|
102
|
+
)
|
|
103
|
+
try:
|
|
104
|
+
with os.fdopen(descriptor, "w", encoding="utf-8") as handle:
|
|
105
|
+
json.dump(payload, handle, separators=(",", ":"), sort_keys=True)
|
|
106
|
+
handle.write("\n")
|
|
107
|
+
os.replace(temporary_name, path)
|
|
108
|
+
except OSError:
|
|
109
|
+
try:
|
|
110
|
+
os.unlink(temporary_name)
|
|
111
|
+
except OSError:
|
|
112
|
+
pass
|
|
113
|
+
print("Error: could not write the reasoning-effort state file.", file=sys.stderr)
|
|
114
|
+
return 2
|
|
115
|
+
print(f"Reasoning effort set: {level} for this session run.")
|
|
116
|
+
return 0
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
def clear_level(session_dir: Path) -> int:
|
|
120
|
+
"""Remove the session level when present and report the cleanup.
|
|
121
|
+
|
|
122
|
+
Args:
|
|
123
|
+
session_dir: A validated session directory.
|
|
124
|
+
|
|
125
|
+
Returns:
|
|
126
|
+
Process exit code 0.
|
|
127
|
+
"""
|
|
128
|
+
try:
|
|
129
|
+
state_path(session_dir).unlink()
|
|
130
|
+
except FileNotFoundError:
|
|
131
|
+
pass
|
|
132
|
+
except OSError:
|
|
133
|
+
print("Error: could not remove the reasoning-effort state file.", file=sys.stderr)
|
|
134
|
+
return 2
|
|
135
|
+
print("Reasoning effort cleared.")
|
|
136
|
+
return 0
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
def show_status(session_dir: Path) -> int:
|
|
140
|
+
"""Print the stored session level, or the empty-state message.
|
|
141
|
+
|
|
142
|
+
Args:
|
|
143
|
+
session_dir: A validated session directory.
|
|
144
|
+
|
|
145
|
+
Returns:
|
|
146
|
+
Process exit code 0.
|
|
147
|
+
"""
|
|
148
|
+
level = None
|
|
149
|
+
try:
|
|
150
|
+
payload = json.loads(state_path(session_dir).read_text(encoding="utf-8"))
|
|
151
|
+
if (
|
|
152
|
+
isinstance(payload, dict)
|
|
153
|
+
and payload.get("schema") == 1
|
|
154
|
+
and payload.get("reasoning") in EFFORT_LEVELS
|
|
155
|
+
):
|
|
156
|
+
level = payload["reasoning"]
|
|
157
|
+
except (OSError, json.JSONDecodeError):
|
|
158
|
+
level = None
|
|
159
|
+
if level is None:
|
|
160
|
+
print("No session reasoning effort set.")
|
|
161
|
+
else:
|
|
162
|
+
print(f"Session reasoning effort: {level}")
|
|
163
|
+
return 0
|
|
164
|
+
|
|
165
|
+
|
|
166
|
+
def parse_args() -> argparse.Namespace:
|
|
167
|
+
"""Parse the command-line arguments.
|
|
168
|
+
|
|
169
|
+
Returns:
|
|
170
|
+
The parsed argparse namespace.
|
|
171
|
+
"""
|
|
172
|
+
parser = argparse.ArgumentParser(description=__doc__)
|
|
173
|
+
sub = parser.add_subparsers(dest="command", required=True)
|
|
174
|
+
|
|
175
|
+
set_parser = sub.add_parser("set", help="record a session reasoning level")
|
|
176
|
+
set_parser.add_argument("--dir", required=True, help="session temp directory")
|
|
177
|
+
set_parser.add_argument("--reasoning", required=True, help="level to record")
|
|
178
|
+
|
|
179
|
+
clear_parser = sub.add_parser("clear", help="remove the session reasoning level")
|
|
180
|
+
clear_parser.add_argument("--dir", required=True, help="session temp directory")
|
|
181
|
+
|
|
182
|
+
status_parser = sub.add_parser("status", help="print the session reasoning level")
|
|
183
|
+
status_parser.add_argument("--dir", required=True, help="session temp directory")
|
|
184
|
+
|
|
185
|
+
return parser.parse_args()
|
|
186
|
+
|
|
187
|
+
|
|
188
|
+
def main() -> int:
|
|
189
|
+
"""Run the requested command.
|
|
190
|
+
|
|
191
|
+
Returns:
|
|
192
|
+
Process exit code: 0 on success, 2 on invalid input.
|
|
193
|
+
"""
|
|
194
|
+
args = parse_args()
|
|
195
|
+
session_dir = resolve_session_dir(args.dir)
|
|
196
|
+
if session_dir is None:
|
|
197
|
+
print(
|
|
198
|
+
"Error: --dir must be an existing session directory inside the CodeOps temp root.",
|
|
199
|
+
file=sys.stderr,
|
|
200
|
+
)
|
|
201
|
+
return 2
|
|
202
|
+
if args.command == "set":
|
|
203
|
+
if args.reasoning not in EFFORT_LEVELS:
|
|
204
|
+
print(
|
|
205
|
+
"Error: --reasoning must be one of: " + ", ".join(EFFORT_LEVELS) + ".",
|
|
206
|
+
file=sys.stderr,
|
|
207
|
+
)
|
|
208
|
+
return 2
|
|
209
|
+
return set_level(session_dir, args.reasoning)
|
|
210
|
+
if args.command == "clear":
|
|
211
|
+
return clear_level(session_dir)
|
|
212
|
+
return show_status(session_dir)
|
|
213
|
+
|
|
214
|
+
|
|
215
|
+
if __name__ == "__main__":
|
|
216
|
+
raise SystemExit(main())
|
|
@@ -36,6 +36,18 @@ do not report or implement optional additions raised during execution or review.
|
|
|
36
36
|
Exploration may create `SE-*` proposals, but only the user may choose `Keep` and authorize a plan
|
|
37
37
|
update.
|
|
38
38
|
|
|
39
|
+
## Auto-effort option
|
|
40
|
+
|
|
41
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
42
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
43
|
+
occurrences means each phase's `Reasoning:` level is printed as a suggestion only, more than one
|
|
44
|
+
or an invalid level is an argument error; announce
|
|
45
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
46
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. A bare
|
|
47
|
+
flag follows each phase's suggestion; `--auto-effort=<level>` forces that level for the whole run,
|
|
48
|
+
including every dispatch marker composed during it. The run clears the level before its final
|
|
49
|
+
summary.
|
|
50
|
+
|
|
39
51
|
Execute the implementation plan at `plans/$ARGUMENTS/99-execution-plan.md`. The first
|
|
40
52
|
argument is the feature name; an optional flag selects the commit mode.
|
|
41
53
|
|
|
@@ -70,6 +70,10 @@ scope baseline; missing mode context fails closed to strict scope.
|
|
|
70
70
|
When opt-in outcome metrics are enabled, record only a content-free execution-stage event through
|
|
71
71
|
`codeops_outcomes.py`; metrics never gate execution.
|
|
72
72
|
|
|
73
|
+
When the phase header carries `> **Reasoning**: <level> — <reason>`, record it as the phase's
|
|
74
|
+
advisory level for dispatch markers, inline reporting, and applied-level reporting. It is a
|
|
75
|
+
suggestion: no gate reads it, and its absence means "inherit".
|
|
76
|
+
|
|
73
77
|
**Spec-author dispatch (profile-gated).** Tasks marked `[spec-author]` dispatch the
|
|
74
78
|
spec-test-author agent — packet per `_shared/quality-profile.md` — BEFORE any implementation
|
|
75
79
|
task of that phase, and the red phase is confirmed from its report. A spec test that cannot be
|
|
@@ -300,12 +304,46 @@ receives nothing else and must not need anything else:
|
|
|
300
304
|
- the scope mode (`strict` or `explore`) and confirmed product scope baseline; missing or invalid
|
|
301
305
|
scope context fails closed to strict mode. Missing or invalid original-goal or smallest-design
|
|
302
306
|
context blocks dispatch;
|
|
303
|
-
- the target file paths and the project's verify command
|
|
307
|
+
- the target file paths and the project's verify command;
|
|
308
|
+
- the phase's reasoning marker line (`[codeops-effort: <level>]`), resolved from the run's forced
|
|
309
|
+
`--auto-effort=<level>` level, else the phase's `Reasoning:` suggestion; omitted when neither
|
|
310
|
+
exists.
|
|
304
311
|
|
|
305
312
|
Excerpting owned content into a packet is the intended retrieval mechanism, not restatement. The
|
|
306
313
|
quoted AR/ST/spec content is context for the executor's *understanding* — it must not surface as a
|
|
307
314
|
citation in shipped code (the executor carries the same doc-standard ban and self-check).
|
|
308
315
|
|
|
316
|
+
**Reasoning marker.** Every dispatched unit — executor, reviewer, auditor, spec-test author,
|
|
317
|
+
specialist, or scout — receives one standalone marker line in its packet:
|
|
318
|
+
|
|
319
|
+
```text
|
|
320
|
+
[codeops-effort: medium]
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
Place it immediately after the `[codeops-dispatch …]` header for quality agents, or as the first
|
|
324
|
+
line for packets without a header. When neither the forced run level nor the phase suggestion
|
|
325
|
+
exists, add no marker: routing policy still applies, otherwise the child inherits the parent
|
|
326
|
+
variant. The marker is packet context; it never appears in shipped code comments. The
|
|
327
|
+
complexity-gate design challenger is excluded because its independence contract forbids extra
|
|
328
|
+
packet shaping.
|
|
329
|
+
|
|
330
|
+
**Applied-level reporting.** For every dispatch, report the level and its source in the dispatch
|
|
331
|
+
commentary, for example `Dispatch: executor — reasoning: medium (phase suggestion)`,
|
|
332
|
+
`— reasoning: high (routing default)`, or `— inherited`. Reporting is observational; it never
|
|
333
|
+
gates a dispatch.
|
|
334
|
+
|
|
335
|
+
**Inline phases.** When a phase runs inline (the default):
|
|
336
|
+
|
|
337
|
+
1. Print `Suggested reasoning: <level> — <reason>` before the phase's first task when the phase
|
|
338
|
+
header carries the line.
|
|
339
|
+
2. Without `--auto-effort`, change nothing else — the session keeps its own variant.
|
|
340
|
+
3. With `--auto-effort`, set the session level for the phase through
|
|
341
|
+
`python3 "${CODEOPS_PLUGIN_ROOT}/scripts/codeops_effort.py" set --dir "$CODEOPS_TMPDIR" --reasoning <level>`
|
|
342
|
+
and update it when the next phase's suggestion differs; with `--auto-effort=<level>`, set that
|
|
343
|
+
level once and keep it for the whole run. A phase without a `Reasoning:` line leaves the
|
|
344
|
+
session level unchanged.
|
|
345
|
+
4. When `$CODEOPS_TMPDIR` is empty or the helper fails, print an advise-only note and continue.
|
|
346
|
+
|
|
309
347
|
**Division of labor.** The PARENT — never the executor — updates `99-execution-plan.md`
|
|
310
348
|
(two-stage marks), the Progress header, and the roadmap. The executor implements task-by-task,
|
|
311
349
|
runs verify per the Verify-output capture rule, and reports per task. Mark `[~]` as the executor
|
|
@@ -404,8 +442,10 @@ otherwise still `[~]` — with the progress counter and Last Updated stamp curre
|
|
|
404
442
|
2. **🚨 First: update `99-execution-plan.md`** with ALL completed tasks (before anything else).
|
|
405
443
|
3. Run the verify command (output captured per the Verify-output capture rule).
|
|
406
444
|
4. Handle the commit per the active commit mode (see [commit-modes.md](commit-modes.md)).
|
|
407
|
-
5.
|
|
408
|
-
|
|
445
|
+
5. If this run set a session level through `--auto-effort`, clear it before the summary:
|
|
446
|
+
`python3 "${CODEOPS_PLUGIN_ROOT}/scripts/codeops_effort.py" clear --dir "$CODEOPS_TMPDIR"`.
|
|
447
|
+
6. Report the session summary (must include `Execution Plan Updated: ✅`).
|
|
448
|
+
7. **Cleanup:** delete every temporary artifact this session created — verify logs under
|
|
409
449
|
`$CODEOPS_TMPDIR`, scratch directories, temporary diffs — per
|
|
410
450
|
`_shared/workspace-hygiene.md`, and report `Cleanup: done` or name what was kept and why.
|
|
411
451
|
|
package/skills/grill-me/SKILL.md
CHANGED
|
@@ -21,6 +21,16 @@ implementation work begins.
|
|
|
21
21
|
|
|
22
22
|
> **CodeOps Artifact Schema**: 1
|
|
23
23
|
|
|
24
|
+
## Auto-effort option
|
|
25
|
+
|
|
26
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
27
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
28
|
+
occurrences means this skill's recommended level (`high`) is printed as a suggestion only, more
|
|
29
|
+
than one or an invalid level is an argument error; announce
|
|
30
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
31
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. The
|
|
32
|
+
run clears the level before its final summary.
|
|
33
|
+
|
|
24
34
|
## Core Directive
|
|
25
35
|
|
|
26
36
|
> **Interview the user relentlessly about every aspect of the topic until you reach a shared understanding. Walk down each branch of the design tree, resolving dependencies between decisions one-by-one.**
|
|
@@ -24,6 +24,16 @@ If `$ARGUMENTS` contains exactly one exact standalone `--explore-scope` token be
|
|
|
24
24
|
do not report or plan optional additions. Exploration may propose `SE-*` items but
|
|
25
25
|
never accepts them; only the user may choose `Keep`.
|
|
26
26
|
|
|
27
|
+
## Auto-effort option
|
|
28
|
+
|
|
29
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
30
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
31
|
+
occurrences means this skill's recommended level (`high`) is printed as a suggestion only, more
|
|
32
|
+
than one or an invalid level is an argument error; announce
|
|
33
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
34
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. The
|
|
35
|
+
run clears the level before its final summary.
|
|
36
|
+
|
|
27
37
|
## Plan readiness proof
|
|
28
38
|
|
|
29
39
|
A plan is not ready merely because its documents exist. Before presenting it as executable,
|
|
@@ -106,6 +116,7 @@ Mini-plan shape:
|
|
|
106
116
|
|
|
107
117
|
> **Type**: Task (lightweight) · **Feature**: search · **CodeOps Artifact Schema**: 1
|
|
108
118
|
> **Progress**: 0/3 tasks (0%)
|
|
119
|
+
> **Reasoning**: medium — bounded UI change reusing existing patterns
|
|
109
120
|
|
|
110
121
|
## Objective
|
|
111
122
|
Debounce the search box to 300ms to cut redundant queries.
|
|
@@ -121,6 +132,12 @@ shared debounce subsystem.
|
|
|
121
132
|
**Verify**: [project verify command]
|
|
122
133
|
```
|
|
123
134
|
|
|
135
|
+
Every phase and every task mini-plan carries the same advisory
|
|
136
|
+
`> **Reasoning**: <level> — <reason>` line. Derive the level from the signals the plan already
|
|
137
|
+
records, using [../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Plan
|
|
138
|
+
suggestion derivation, and keep the reason a short plain-language phrase. The line is a
|
|
139
|
+
suggestion: no gate reads it, deleting it is valid, and its absence means "inherit".
|
|
140
|
+
|
|
124
141
|
Everything below is the **full feature** pipeline; skip it for tasks.
|
|
125
142
|
|
|
126
143
|
## Project configuration
|
|
@@ -458,6 +458,8 @@ task-size criteria in [quality-checklist.md](quality-checklist.md))
|
|
|
458
458
|
> committed, staged, unstaged, and untracked phase-start state)_
|
|
459
459
|
> **Lenses**: [add-on lenses — include this line only when the target repo carries a quality
|
|
460
460
|
> profile; informational: activation stays profile-driven]
|
|
461
|
+
> **Reasoning**: [advisory level — `low`, `medium`, `high`, or `max`, with a one-line reason;
|
|
462
|
+
> derivation in `../../_shared/reasoning-effort.md` §Plan suggestion derivation]
|
|
461
463
|
|
|
462
464
|
### Step 1.1: [Step Objective]
|
|
463
465
|
|
|
@@ -27,6 +27,16 @@ requirements decisions under that policy and propagate its downward-only context
|
|
|
27
27
|
invoked supported children; an unsupported child fails closed. This mode does not grant action permission or scope expansion. **Normal mode:** without the exact token, every material choice
|
|
28
28
|
still requires an explicit user decision; historical delegated records must not infer delegated authority.
|
|
29
29
|
|
|
30
|
+
## Auto-effort option
|
|
31
|
+
|
|
32
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
33
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
34
|
+
occurrences means this skill's recommended level (`high`) is printed as a suggestion only, more
|
|
35
|
+
than one or an invalid level is an argument error; announce
|
|
36
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
37
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. The
|
|
38
|
+
run clears the level before its final summary.
|
|
39
|
+
|
|
30
40
|
Transform a rough project idea into a structured, complete set of formal
|
|
31
41
|
**requirement documents (RDs)**. This skill is upstream of, and independent
|
|
32
42
|
from, the make-plan skill — neither requires the other.
|
|
@@ -33,6 +33,16 @@ If `$ARGUMENTS` contains exactly one exact standalone `--explore-scope` token be
|
|
|
33
33
|
do not report optional additions as findings or suggestions. Exploration records them
|
|
34
34
|
as separate `SE-*` proposals; finding resolution never chooses `Keep`.
|
|
35
35
|
|
|
36
|
+
## Auto-effort option
|
|
37
|
+
|
|
38
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
39
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
40
|
+
occurrences means this skill's recommended level (`high`, or `max` with `--thorough`) is printed
|
|
41
|
+
as a suggestion only, more than one or an invalid level is an argument error; announce
|
|
42
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
43
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. The
|
|
44
|
+
run clears the level before its final summary.
|
|
45
|
+
|
|
36
46
|
Run a rigorous quality audit of the artifact named in `$ARGUMENTS`, **grounded in the actual
|
|
37
47
|
codebase**. Find every issue, ambiguity, contradiction, gap, and risk; verify every claim and
|
|
38
48
|
assumption against the real code; present each finding with options + a recommendation; iterate
|
|
@@ -20,6 +20,16 @@ description: >-
|
|
|
20
20
|
|
|
21
21
|
> **CodeOps Artifact Schema**: 1
|
|
22
22
|
|
|
23
|
+
## Auto-effort option
|
|
24
|
+
|
|
25
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
26
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
27
|
+
occurrences means this skill's recommended level (`high`) is printed as a suggestion only, more
|
|
28
|
+
than one or an invalid level is an argument error; announce
|
|
29
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
30
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. The
|
|
31
|
+
run clears the level before its final summary.
|
|
32
|
+
|
|
23
33
|
Analyze an existing codebase — any language, any framework — and produce a
|
|
24
34
|
structured **reconstruction brief** that can be fed to the make-requirements
|
|
25
35
|
skill to generate formal requirement documents capable of rebuilding the entire
|
|
@@ -50,6 +50,8 @@ Present:
|
|
|
50
50
|
|
|
51
51
|
- detected domains and concrete evidence;
|
|
52
52
|
- phase tag → capability/effort policy;
|
|
53
|
+
- reasoning-effort defaults per role when risk signals justify them (see
|
|
54
|
+
[routing.md](routing.md) §Reasoning effort policy);
|
|
53
55
|
- required specialist reviewers;
|
|
54
56
|
- proposed concurrency limit;
|
|
55
57
|
- whether custom TOML agents add value over dynamic packets; and
|
|
@@ -27,7 +27,7 @@ CodeOps routing lives under the optional `routing` and `quality` fields in `code
|
|
|
27
27
|
|
|
28
28
|
Allowed effort values follow the active OpenCode release. Prefer `medium` for bounded reconnaissance, `high` for correctness/security review, and higher supported levels only for genuinely demanding semantic or architectural work.
|
|
29
29
|
|
|
30
|
-
An optional per-role `reasoning` field sets the provider reasoning-effort passthrough (`none`, `minimal`, `low`, `medium`, `high`, `xhigh`, `max`). Generated project specialists default to `max` through their brief or the embedded `reasoningEffort`; a routing value wins over the brief.
|
|
30
|
+
An optional per-role `reasoning` field sets the provider reasoning-effort passthrough (`none`, `minimal`, `low`, `medium`, `high`, `xhigh`, `max`). Generated project specialists default to `max` through their brief or the embedded `reasoningEffort`; a routing value wins over the brief and is embedded without provider-capability detection. At runtime the plugin applies a level only when the active model exposes a matching variant; an unsupported value leaves the request unchanged (see the policy below).
|
|
31
31
|
|
|
32
32
|
```json
|
|
33
33
|
"roles": {
|
|
@@ -35,6 +35,21 @@ An optional per-role `reasoning` field sets the provider reasoning-effort passth
|
|
|
35
35
|
}
|
|
36
36
|
```
|
|
37
37
|
|
|
38
|
+
## Reasoning effort policy
|
|
39
|
+
|
|
40
|
+
A role's `reasoning` entry is a project default, not the only source. The runtime resolution
|
|
41
|
+
order is `dispatch marker > session auto-effort > routing role default > inherit parent variant`
|
|
42
|
+
(see [../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md)). A dispatch marker
|
|
43
|
+
comes from an execution plan's per-phase suggestion; a session level comes from an explicit
|
|
44
|
+
`--auto-effort` run. Both override the routing default for their scope, and routing applies only
|
|
45
|
+
when a role entry exists — with no entry the child inherits the parent variant.
|
|
46
|
+
|
|
47
|
+
The suggestion vocabulary is `low`, `medium`, `high`, and `max`, while the routing field accepts
|
|
48
|
+
the wider provider enum (`none`, `minimal`, `low`, `medium`, `high`, `xhigh`, `max`). The deepseek
|
|
49
|
+
flash model exposes `low`/`medium`/`high`/`max`; prefer `low` for mechanical work, `medium` for
|
|
50
|
+
bounded implementation, `high` for planning and review, and `max` only for adversarial analysis.
|
|
51
|
+
An unsupported value is skipped at runtime, so a routing entry never produces a provider error.
|
|
52
|
+
|
|
38
53
|
Model pins are optional per role. When omitted, OpenCode resolves the model from the explicit spawn, project defaults, and parent session. A missing pin must never block the workflow.
|
|
39
54
|
|
|
40
55
|
Reviewer selection is driven by risk tags:
|
|
@@ -7,6 +7,16 @@ description: Upgrade an existing CodeOps requirements set, specification, plan,
|
|
|
7
7
|
|
|
8
8
|
The current CodeOps artifact schema is `1`. Historical Claude CodeOps `3.x` stamps describe the producing skill release, not this schema. Treat them as legacy input requiring assessment, not as numeric predecessors of schema 1.
|
|
9
9
|
|
|
10
|
+
## Auto-effort option
|
|
11
|
+
|
|
12
|
+
If `$ARGUMENTS` contains exactly one exact standalone `--auto-effort` or `--auto-effort=<level>`
|
|
13
|
+
token before the first `--` sentinel, remove it before resolving targets, paths, or modes; zero
|
|
14
|
+
occurrences means this skill's recommended level (`high`) is printed as a suggestion only, more
|
|
15
|
+
than one or an invalid level is an argument error; announce
|
|
16
|
+
`Auto-effort active — reasoning <level> applied for this run`; then read and apply
|
|
17
|
+
[../../_shared/reasoning-effort.md](../../_shared/reasoning-effort.md) §Auto-effort option. The
|
|
18
|
+
run clears the level before its final summary.
|
|
19
|
+
|
|
10
20
|
## Scope
|
|
11
21
|
|
|
12
22
|
Upgrade content and structure in place. Layout moves belong to `setup-codeops`. Never combine a layout migration and semantic/schema upgrade into one irreversible operation.
|