oris-skills 2.0.0 → 2.1.0
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/.cursor-plugin/plugin.json +6 -1
- package/CHANGELOG.md +38 -0
- package/README.md +11 -10
- package/agents/oris-loop-doctor.md +1 -1
- package/agents/oris-loop-verifier.md +3 -0
- package/docs/architecture.md +4 -3
- package/docs/distribution.md +1 -1
- package/docs/maintainer-guide.md +2 -2
- package/docs/user-guide.md +9 -7
- package/package.json +2 -3
- package/references/clean-code-checklist.md +20 -107
- package/references/conventions.md +16 -2
- package/references/doc-policy.md +19 -3
- package/references/loop-contract.md +23 -16
- package/references/loop.schema.json +13 -0
- package/references/repo-map.md +3 -3
- package/references/repo-map.schema.json +37 -0
- package/scripts/flow/oris-flow-layout.mjs +1 -0
- package/scripts/flow/oris-flow-scan.mjs +195 -27
- package/scripts/install/generate-agent-adapters.mjs +19 -2
- package/scripts/install/install-user-skills.mjs +7 -1
- package/scripts/loop/oris-loop-bootstrap.mjs +7 -2
- package/scripts/loop/oris-loop-chat.mjs +32 -14
- package/scripts/loop/oris-loop-demo.mjs +11 -20
- package/scripts/loop/oris-loop-document.mjs +24 -7
- package/scripts/loop/oris-loop-dry-run.mjs +7 -3
- package/scripts/loop/oris-loop-fixtures.mjs +12 -11
- package/scripts/loop/oris-loop-run.mjs +80 -20
- package/scripts/loop/oris-loop-stop.mjs +48 -9
- package/scripts/loop/oris-loop-templates.mjs +10 -7
- package/scripts/loop/oris-loop-verify.mjs +1 -2
- package/scripts/oris-skills.mjs +2 -1
- package/scripts/tests/run-all-tests.mjs +0 -2
- package/scripts/tests/test-oris-flow-scan.mjs +66 -0
- package/scripts/tests/test-oris-loop-document.mjs +39 -3
- package/scripts/tests/test-oris-loop-run.mjs +28 -2
- package/scripts/tests/test-oris-loop-smoke.mjs +36 -3
- package/scripts/tests/test-oris-loop-stop.mjs +65 -4
- package/scripts/tests/test-routing-lifecycle.mjs +11 -9
- package/skills/oris-flow/SKILL.md +16 -3
- package/skills/oris-flow-architecture/SKILL.md +64 -0
- package/skills/oris-flow-change/SKILL.md +55 -0
- package/skills/oris-flow-criteria/SKILL.md +10 -4
- package/skills/oris-flow-discover/SKILL.md +10 -5
- package/skills/oris-flow-docs/SKILL.md +2 -2
- package/skills/oris-flow-fix/SKILL.md +1 -1
- package/skills/oris-flow-implement/SKILL.md +2 -2
- package/skills/oris-flow-merge/SKILL.md +45 -0
- package/skills/oris-flow-new/SKILL.md +58 -0
- package/skills/oris-flow-plan/SKILL.md +8 -4
- package/skills/oris-flow-setup/SKILL.md +54 -23
- package/skills/oris-flow-verify/SKILL.md +50 -0
- package/skills/oris-help/SKILL.md +4 -4
- package/skills/oris-loop/SKILL.md +12 -32
- package/skills/oris-loop/references/craft.md +10 -9
- package/skills/oris-loop/references/run.md +9 -7
- package/skills/oris-loop/templates/debriefer.md +1 -1
- package/skills/oris-loop/templates/doctor.md +9 -7
- package/skills/oris-loop/templates/executor.md +3 -2
- package/skills/oris-loop/templates/orchestrator.md +10 -7
- package/skills/oris-loop/templates/verifier.md +4 -2
- package/references/questions.md +0 -38
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oris-skills",
|
|
3
3
|
"description": "Oris Skills: one entry point (/oris-flow), guided discovery-to-implementation flow, and self-tuning verified loops. Cross-model: Cursor, Claude Code, Codex.",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.1.0",
|
|
5
5
|
"author": {
|
|
6
6
|
"name": "Davide Baldassarre"
|
|
7
7
|
},
|
|
@@ -19,12 +19,17 @@
|
|
|
19
19
|
"skills": [
|
|
20
20
|
"./skills/oris-flow",
|
|
21
21
|
"./skills/oris-flow-setup",
|
|
22
|
+
"./skills/oris-flow-new",
|
|
22
23
|
"./skills/oris-flow-discover",
|
|
23
24
|
"./skills/oris-flow-criteria",
|
|
24
25
|
"./skills/oris-flow-plan",
|
|
25
26
|
"./skills/oris-flow-implement",
|
|
26
27
|
"./skills/oris-flow-fix",
|
|
28
|
+
"./skills/oris-flow-verify",
|
|
29
|
+
"./skills/oris-flow-change",
|
|
27
30
|
"./skills/oris-flow-docs",
|
|
31
|
+
"./skills/oris-flow-architecture",
|
|
32
|
+
"./skills/oris-flow-merge",
|
|
28
33
|
"./skills/oris-loop",
|
|
29
34
|
"./skills/oris-help"
|
|
30
35
|
]
|
package/CHANGELOG.md
ADDED
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## 2.1.0 - 2026-07-05
|
|
4
|
+
|
|
5
|
+
- **Harness independence**: task documents default to `.oris-flow/tasks/{task}/` (`setup.tasksRoot` in the manifest) — Oris no longer writes into the project's `docs/`; repos already using `docs/tasks` keep it via a recorded setup choice.
|
|
6
|
+
- **Adaptive setup**: the scan detects `projectType` (webapp/api/library/cli/monorepo), derives build/test commands for .NET, Python, Go, and Rust (marked `inferred` until confirmed), walks breadth-first with a `truncated` flag, and honors `--area` for partial refreshes. Refresh merges instead of overwriting: `confirmed` sections, commands, and decisions survive; missing evidence marks them stale.
|
|
7
|
+
- `oris-flow-setup` rewritten: explore → present findings → decisions one at a time with explainers; AI-readiness check (AGENTS.md, CONTEXT.md, ADRs, project skills, confirmed verify commands) with per-file scaffold offers.
|
|
8
|
+
- New skills: `oris-flow-new` (bootstrap an AI-driven project: sparse commands-first AGENTS.md, CONTEXT.md glossary, ADR-0001, test+lint observed green, flow armed), `oris-flow-architecture` (deepening-opportunity review with visual HTML report in the OS temp dir), `oris-flow-merge` (intent-preserving merge/rebase conflict resolution).
|
|
9
|
+
- **Loops default to 2 roles** (executor + verifier); doctor and debriefer are opt-in via `roles:` in loop.md. Without a doctor, the verifier verdict (`goalMet`) drives the state directly.
|
|
10
|
+
- New flow skills: `oris-flow-verify` (one-shot acceptance-criteria verification with evidence report) and `oris-flow-change` (spec-change delta interview, homogeneous doc updates, `CH-xxx` change log). Implement/fix now route verification to `oris-flow-verify` instead of suggesting a loop.
|
|
11
|
+
- Canonical doctor decision enum (`continue|advance|complete|ask-user|propose-patch|blocked`) unified across agent specs, templates, and the headless runner; `ask-user` now pauses the loop instead of silently killing it.
|
|
12
|
+
- `limits.maxNoProgress` is enforced at runtime (stop hook + headless runner + `set-state --progress yes|no`); previously declared but never checked.
|
|
13
|
+
- Read-only roles (verifier, doctor) run without write access in headless mode.
|
|
14
|
+
- Stop hook: Cursor auto-detection fixed (payloads carrying both `conversation_id` and `session_id`); exhausted limits and corrupt state now surface a user-visible message on Claude Code.
|
|
15
|
+
- Executor gate literal `ORIS LOOP ACTIVE` ships in the executor prompt template; role output is a ```json fenced block (robust extraction in the headless runner).
|
|
16
|
+
- All CLI commands in skills, templates, and docs use `npx oris-skills …` (the CLI is not installed globally).
|
|
17
|
+
- Installer now generates Cursor/Claude/Codex loop-agent adapters into the detected agent homes.
|
|
18
|
+
- `{task}` slug convention defined once in `references/doc-policy.md`; `references/questions.md` merged into `references/conventions.md`; clean-code checklist trimmed to its implement/fix use.
|
|
19
|
+
- Removed dead surface: `repairCycles`, `--node-only`/`test:node`/`npm run validate` duplication, empty `scripts/maintenance/`, unused `.gitattributes` rules.
|
|
20
|
+
|
|
21
|
+
## 2.0.0 - 2026-07-04
|
|
22
|
+
|
|
23
|
+
- Public npm package (MIT): `npx oris-skills@latest install`, multi-agent installer for Cursor, Claude Code, and Codex; bundle moved to `~/.oris/`.
|
|
24
|
+
- Flattened layout: `skills/`, `references/`, `agents/`; 10 essential skills, single entry point `/oris-flow` with inline routing.
|
|
25
|
+
- Loop document schemaVersion 2: `approved` gate, per-role `models` (`inherit` | adapter alias | model id), `improve.mode: auto|propose`.
|
|
26
|
+
- Role prompts moved to per-loop editable files `prompts/{orchestrator,executor,verifier,doctor,debriefer}.md`; orchestrator prompt no longer hardcoded in the stop hook.
|
|
27
|
+
- Self-tuning loops: in `auto` mode the debriefer rewrites prompt files between passes and archives old versions to `history/`.
|
|
28
|
+
- Cross-model triggers: shared stop hook now speaks Cursor (`followup_message`) and Claude Code (`decision: block`); new headless runner `oris-skills loop run --agent codex|claude` (one CLI process per role).
|
|
29
|
+
- Learnability: `oris-skills loop demo` (sandboxed tutorial loop), `oris-skills loop dry-run` (preview the injected pass message).
|
|
30
|
+
- Skill texts rewritten with leading words (~60% shorter); shared rules centralized in `references/conventions.md`.
|
|
31
|
+
- Removed: org-specific MCP config, DevOps story skills, scaffold/service standards, utility skills, demo showcase, legacy fallbacks.
|
|
32
|
+
|
|
33
|
+
## 1.0.0 - 2026-06-29
|
|
34
|
+
|
|
35
|
+
- Release Oris Skills 1.0 with Node-based install, validation, packaging, and cross-platform CI.
|
|
36
|
+
- Add Oris Loop 1.0 with project-local `.oris-flow/` storage, schemaVersion 1 loop documents, compact receipts, Doctor proposals, and subagent-first orchestration.
|
|
37
|
+
- Add canonical subagent contracts for executor, verifier, Doctor, and debriefer, plus generated Cursor, Claude, and Codex adapters.
|
|
38
|
+
- Add clean Node CLI entrypoints through `oris-skills install`, `oris-skills validate`, `oris-skills doctor`, and `oris-skills loop`.
|
package/README.md
CHANGED
|
@@ -19,37 +19,39 @@ The installer detects your agents (`~/.cursor`, `~/.claude`, `~/.codex`) or take
|
|
|
19
19
|
| criteria | verifiable acceptance criteria → `acceptance-criteria.md` |
|
|
20
20
|
| plan | technical interview → `implementation-plan.md` |
|
|
21
21
|
| implement / fix | execute the plan, or the smallest safe bug fix |
|
|
22
|
+
| verify | check every acceptance criterion against the real product, once → `verification-report.md` |
|
|
23
|
+
| change | spec changed mid-flight: delta interview, all docs updated together → `change-log.md` (CH-xxx) |
|
|
22
24
|
| loop | repeat work until verified, with subagents and receipts |
|
|
23
25
|
| docs / help | keep task docs aligned; explain Oris |
|
|
24
26
|
|
|
25
|
-
**Oris loops** run the cycle *observe → one bounded action → independent verify → record → repeat/stop* with
|
|
27
|
+
**Oris loops** run the cycle *observe → one bounded action → independent verify → record → repeat/stop* with two default roles (executor + verifier) — doctor and debriefer are opt-in — each driven by **an editable prompt file**:
|
|
26
28
|
|
|
27
29
|
```text
|
|
28
30
|
.oris-flow/loops/{slug}/
|
|
29
|
-
loop.md contract: goal, scope, limits, per-role models, improve mode
|
|
30
|
-
prompts/
|
|
31
|
+
loop.md contract: goal, scope, roles, limits, per-role models, improve mode
|
|
32
|
+
prompts/ executor.md verifier.md (+ orchestrator/doctor/debriefer when opted in) ← edit freely
|
|
31
33
|
context.md receipts/ proposals/ history/
|
|
32
34
|
```
|
|
33
35
|
|
|
34
36
|
- **Per-role models** — `models:` in `loop.md`: `inherit` (session model), an adapter alias, or a platform model id.
|
|
35
37
|
- **Self-tuning** — `improve.mode: auto` lets the debriefer rewrite the prompt files between passes (old versions archived in `history/`); scope and limits always require your approval.
|
|
36
|
-
- **Cross-platform triggers** — Cursor stop hook, Claude Code Stop hook (same chat continues automatically), or `oris-skills loop run --agent codex|claude` for headless/CI where each role is a separate CLI process.
|
|
38
|
+
- **Cross-platform triggers** — Cursor stop hook, Claude Code Stop hook (same chat continues automatically), or `npx oris-skills loop run --agent codex|claude` for headless/CI where each role is a separate CLI process.
|
|
37
39
|
|
|
38
40
|
## Try a loop in 3 minutes
|
|
39
41
|
|
|
40
42
|
```bash
|
|
41
|
-
oris-skills loop demo # creates a sandboxed tutorial loop
|
|
42
|
-
oris-skills loop dry-run --loop oris-demo # preview the exact pass message — runs nothing
|
|
43
|
-
oris-skills loop chat --action start --loop oris-demo # then end the chat turn; the hook does the rest
|
|
43
|
+
npx oris-skills loop demo # creates a sandboxed tutorial loop
|
|
44
|
+
npx oris-skills loop dry-run --loop oris-demo # preview the exact pass message — runs nothing
|
|
45
|
+
npx oris-skills loop chat --action start --loop oris-demo # then end the chat turn; the hook does the rest
|
|
44
46
|
```
|
|
45
47
|
|
|
46
|
-
Stop anytime: `oris-skills loop chat --action stop`. Self-check the runtime: `oris-skills loop verify --temp`.
|
|
48
|
+
Stop anytime: `npx oris-skills loop chat --action stop`. Self-check the runtime: `npx oris-skills loop verify --temp`.
|
|
47
49
|
|
|
48
50
|
## Repository layout
|
|
49
51
|
|
|
50
52
|
| Path | Purpose |
|
|
51
53
|
|------|---------|
|
|
52
|
-
| `skills/` | the
|
|
54
|
+
| `skills/` | the 12 Oris skills (`SKILL.md` each) |
|
|
53
55
|
| `skills/oris-loop/templates/` | role prompt templates copied into new loops |
|
|
54
56
|
| `references/` | shared contracts and JSON schemas |
|
|
55
57
|
| `agents/` | canonical subagent definitions (Cursor/Claude/Codex adapters generated) |
|
|
@@ -60,7 +62,6 @@ Stop anytime: `oris-skills loop chat --action stop`. Self-check the runtime: `or
|
|
|
60
62
|
|
|
61
63
|
```bash
|
|
62
64
|
npm test # cross-platform Node test suite
|
|
63
|
-
npm run validate
|
|
64
65
|
npm run verify:loop # end-to-end stop-hook simulation (cursor + claude)
|
|
65
66
|
```
|
|
66
67
|
|
|
@@ -22,6 +22,7 @@ Output:
|
|
|
22
22
|
{
|
|
23
23
|
"role": "verifier",
|
|
24
24
|
"state": "pass|fail|blocked|inconclusive",
|
|
25
|
+
"goalMet": false,
|
|
25
26
|
"summary": "",
|
|
26
27
|
"evidence": "",
|
|
27
28
|
"evidencePath": "",
|
|
@@ -29,3 +30,5 @@ Output:
|
|
|
29
30
|
"nextRecommendation": ""
|
|
30
31
|
}
|
|
31
32
|
```
|
|
33
|
+
|
|
34
|
+
`goalMet` is true only when the loop goal itself is satisfied, not just this pass.
|
package/docs/architecture.md
CHANGED
|
@@ -5,8 +5,8 @@ Read this before explaining or changing the project.
|
|
|
5
5
|
## Shape
|
|
6
6
|
|
|
7
7
|
```text
|
|
8
|
-
skills/
|
|
9
|
-
references/ shared contracts (conventions, loop-contract, settings,
|
|
8
|
+
skills/ 15 skills; oris-flow is the router, oris-loop the loop system
|
|
9
|
+
references/ shared contracts (conventions, loop-contract, settings, repo-map, doc-policy, clean-code-checklist) + JSON schemas
|
|
10
10
|
agents/ canonical subagent definitions; adapters generated per platform
|
|
11
11
|
scripts/ Node CLI (oris-skills.mjs), loop runtime, installer, tests
|
|
12
12
|
docs/ this file, user-guide, maintainer-guide, distribution
|
|
@@ -17,10 +17,11 @@ docs/ this file, user-guide, maintainer-guide, distribution
|
|
|
17
17
|
- ONE source of truth per fact: contracts live in `references/`, skills point at them.
|
|
18
18
|
- Skills use leading words (READ / ASK / NEVER / IF) and stay short; shared rules live in `references/conventions.md`.
|
|
19
19
|
- Everything repeatable lives in the target project under `.oris-flow/`; the bundle at `~/.oris/oris-skills/` owns scripts and templates.
|
|
20
|
+
- Oris never dirties the project: task documents default to `.oris-flow/tasks/` (`setup.tasksRoot` in the manifest; legacy `docs/tasks` supported).
|
|
20
21
|
- Loop prompts are per-loop editable files (`prompts/*.md`), never hardcoded in scripts.
|
|
21
22
|
|
|
22
23
|
## Runtime
|
|
23
24
|
|
|
24
25
|
- `/oris-flow` routes; destination skills own their gates.
|
|
25
26
|
- Loop triggers: Cursor stop hook + Claude Stop hook (shared `scripts/loop/oris-loop-stop.mjs`, `--platform` switch), headless `loop run` for Codex/CI.
|
|
26
|
-
- State machine: `.oris-flow/runtime/chat-active.json`, managed only by `oris-skills loop chat`.
|
|
27
|
+
- State machine: `.oris-flow/runtime/chat-active.json`, managed only by `npx oris-skills loop chat`.
|
package/docs/distribution.md
CHANGED
|
@@ -20,7 +20,7 @@ The installer detects Cursor / Claude Code / Codex from `~/.cursor`, `~/.claude`
|
|
|
20
20
|
~/.codex/prompts/<name>.md Codex prompts pointing to the bundled SKILL.md
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
Project assets live only in each repository's `.oris-flow/` (adapter, loops, runtime) plus thin hook wrappers in `.cursor/hooks/` and `.claude/hooks/` written by `oris-skills loop bootstrap`.
|
|
23
|
+
Project assets live only in each repository's `.oris-flow/` (adapter, loops, runtime) plus thin hook wrappers in `.cursor/hooks/` and `.claude/hooks/` written by `npx oris-skills loop bootstrap`.
|
|
24
24
|
|
|
25
25
|
## Uninstall / reinstall
|
|
26
26
|
|
package/docs/maintainer-guide.md
CHANGED
|
@@ -9,7 +9,8 @@ Use when improving Oris Skills itself. Keep changes tiny; update the canonical f
|
|
|
9
9
|
| User-facing explanation | `docs/user-guide.md`, `skills/oris-help/SKILL.md` |
|
|
10
10
|
| Project structure | `docs/architecture.md` |
|
|
11
11
|
| Routing | `skills/oris-flow/SKILL.md` (route table) |
|
|
12
|
-
| Shared interaction rules | `references/conventions.md
|
|
12
|
+
| Shared interaction rules | `references/conventions.md` |
|
|
13
|
+
| Task doc standards | `references/doc-policy.md` ({task} slug, per-doc ownership) |
|
|
13
14
|
| Loop behavior | `references/loop-contract.md`, `skills/oris-loop/` |
|
|
14
15
|
| Loop prompt templates | `skills/oris-loop/templates/` |
|
|
15
16
|
| Loop runtime | `scripts/loop/` |
|
|
@@ -20,7 +21,6 @@ Use when improving Oris Skills itself. Keep changes tiny; update the canonical f
|
|
|
20
21
|
|
|
21
22
|
```bash
|
|
22
23
|
npm test
|
|
23
|
-
npm run validate
|
|
24
24
|
npm run verify:loop
|
|
25
25
|
```
|
|
26
26
|
|
package/docs/user-guide.md
CHANGED
|
@@ -6,7 +6,9 @@ Install once, remember one command:
|
|
|
6
6
|
npx oris-skills@latest install # detects Cursor / Claude Code / Codex
|
|
7
7
|
```
|
|
8
8
|
|
|
9
|
-
Then type **`/oris-flow`** in your agent chat. It routes your request or shows a short menu (setup, discovery, criteria, plan, implement/fix, loop, docs, help). On Codex use the installed `/oris-flow` prompt.
|
|
9
|
+
Then type **`/oris-flow`** in your agent chat. It routes your request or shows a short menu (setup, new project, discovery, criteria, plan, implement/fix, verify, spec change, loop, architecture review, merge conflicts, docs, help). On Codex use the installed `/oris-flow` prompt.
|
|
10
|
+
|
|
11
|
+
The flow in one line: **discover → criteria → plan → implement → verify**, with `fix` for bugs, `change` when the spec changes mid-flight (it updates all task docs together and logs `CH-xxx` history), and `loop` for work that must repeat until verified. `new` bootstraps an AI-driven project from scratch; `architecture` maps deepening/refactor opportunities; `merge` resolves merge/rebase conflicts. Task documents live in `.oris-flow/tasks/` by default — your project's own docs stay untouched.
|
|
10
12
|
|
|
11
13
|
## Loops in short
|
|
12
14
|
|
|
@@ -15,17 +17,17 @@ A loop repeats: one bounded action → independent verification → receipt →
|
|
|
15
17
|
Learn it safely:
|
|
16
18
|
|
|
17
19
|
```bash
|
|
18
|
-
oris-skills loop demo # sandboxed tutorial loop
|
|
19
|
-
oris-skills loop dry-run --loop oris-demo # preview, nothing runs
|
|
20
|
-
oris-skills loop chat --action start --loop oris-demo # arm, then end the chat turn
|
|
20
|
+
npx oris-skills loop demo # sandboxed tutorial loop
|
|
21
|
+
npx oris-skills loop dry-run --loop oris-demo # preview, nothing runs
|
|
22
|
+
npx oris-skills loop chat --action start --loop oris-demo # arm, then end the chat turn
|
|
21
23
|
```
|
|
22
24
|
|
|
23
25
|
Control it:
|
|
24
26
|
|
|
25
27
|
```bash
|
|
26
|
-
oris-skills loop list # what exists
|
|
27
|
-
oris-skills loop chat --action status
|
|
28
|
-
oris-skills loop chat --action stop
|
|
28
|
+
npx oris-skills loop list # what exists
|
|
29
|
+
npx oris-skills loop chat --action status
|
|
30
|
+
npx oris-skills loop chat --action stop
|
|
29
31
|
```
|
|
30
32
|
|
|
31
33
|
Tune it: edit the files in `.oris-flow/loops/{slug}/prompts/` — the next pass obeys them. With `improve.mode: auto` in `loop.md`, the loop tunes those prompts itself and archives old versions in `history/`.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "oris-skills",
|
|
3
|
-
"version": "2.
|
|
3
|
+
"version": "2.1.0",
|
|
4
4
|
"description": "Oris Skills: one entry point (/oris-flow), guided discovery-to-implementation flow, and self-tuning verified loops for Cursor, Claude Code, and Codex.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Davide Baldassarre",
|
|
@@ -16,6 +16,7 @@
|
|
|
16
16
|
"docs",
|
|
17
17
|
".cursor-plugin",
|
|
18
18
|
"README.md",
|
|
19
|
+
"CHANGELOG.md",
|
|
19
20
|
"LICENSE"
|
|
20
21
|
],
|
|
21
22
|
"keywords": [
|
|
@@ -37,8 +38,6 @@
|
|
|
37
38
|
},
|
|
38
39
|
"scripts": {
|
|
39
40
|
"test": "node scripts/tests/run-all-tests.mjs",
|
|
40
|
-
"test:node": "node scripts/tests/run-all-tests.mjs --node-only",
|
|
41
|
-
"validate": "node scripts/oris-skills.mjs validate",
|
|
42
41
|
"scan": "node scripts/flow/oris-flow-scan.mjs --json",
|
|
43
42
|
"install:dry-run": "node scripts/install/install-user-skills.mjs --dry-run",
|
|
44
43
|
"verify:loop": "node scripts/loop/oris-loop-verify.mjs --temp"
|
|
@@ -1,107 +1,20 @@
|
|
|
1
|
-
# Clean Code Checklist
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
##
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
-
|
|
21
|
-
- Orphan tests for removed behavior
|
|
22
|
-
|
|
23
|
-
Verify with cross-file search, DI/container registration, reflection, dynamic imports, string-based dispatch, routing tables, Razor/tag helpers, code generation, and framework conventions before marking dead.
|
|
24
|
-
|
|
25
|
-
### Duplication
|
|
26
|
-
|
|
27
|
-
- Copy-pasted logic with only naming changes
|
|
28
|
-
- Parallel helpers that should be one function
|
|
29
|
-
- Repeated validation, mapping, or query patterns in the same feature area
|
|
30
|
-
|
|
31
|
-
Prefer the existing project abstraction level. Do not introduce new shared layers for one-off duplication unless the user approves.
|
|
32
|
-
|
|
33
|
-
### Abandoned attempts
|
|
34
|
-
|
|
35
|
-
- Half-finished branches with TODO/FIXME/HACK tied to the current feature
|
|
36
|
-
- Alternate implementations left in place after a chosen approach
|
|
37
|
-
- Debug logging, temporary guards, or experimental code paths no longer needed
|
|
38
|
-
- Stale comments describing behavior that no longer exists
|
|
39
|
-
|
|
40
|
-
### Typos and wording
|
|
41
|
-
|
|
42
|
-
- Misspellings in user-visible strings when the task scope includes them
|
|
43
|
-
- Wrong identifiers that reduce readability but are not public API contracts
|
|
44
|
-
- Misleading names for variables or methods introduced in the current work
|
|
45
|
-
|
|
46
|
-
Do not rename public API surface, routes, database fields, or serialized property names unless the user explicitly approves.
|
|
47
|
-
|
|
48
|
-
### Obvious inefficiencies
|
|
49
|
-
|
|
50
|
-
- Duplicate queries or remote calls inside loops
|
|
51
|
-
- Repeated allocations or parsing in hot paths within the scoped change
|
|
52
|
-
- Redundant null checks, casts, or conversions introduced during iteration
|
|
53
|
-
|
|
54
|
-
Flag only clear wins with low regression risk. Do not micro-optimize unrelated code.
|
|
55
|
-
|
|
56
|
-
### Style and format
|
|
57
|
-
|
|
58
|
-
Apply only when conventions are explicit in project docs or `.cursor/rules`:
|
|
59
|
-
|
|
60
|
-
- Naming patterns
|
|
61
|
-
- Import/order rules
|
|
62
|
-
- Formatter or analyzer expectations
|
|
63
|
-
- File layout conventions
|
|
64
|
-
|
|
65
|
-
Avoid formatting-only churn outside the scoped files.
|
|
66
|
-
|
|
67
|
-
## Out of Scope
|
|
68
|
-
|
|
69
|
-
- Bug fixes or behavior corrections - use `/oris-flow-fix`
|
|
70
|
-
- Architectural deepening, module consolidation, or seam redesign
|
|
71
|
-
- Large refactors, API redesign, or cross-feature rewrites
|
|
72
|
-
- DevOps, commits, branches, pull requests, or documentation updates
|
|
73
|
-
- Rewriting tests to change behavior instead of removing obsolete coverage
|
|
74
|
-
|
|
75
|
-
## Evidence Bar
|
|
76
|
-
|
|
77
|
-
Before reporting a finding:
|
|
78
|
-
|
|
79
|
-
- Search references and call sites in the scoped area and direct dependents
|
|
80
|
-
- Check whether tests, config, or registration files still require the symbol
|
|
81
|
-
- For dead code candidates, note what search was performed
|
|
82
|
-
- For duplication, cite both locations and why consolidation is safe
|
|
83
|
-
- For abandoned attempts, tie the finding to the current feature or recent diff when possible
|
|
84
|
-
|
|
85
|
-
## Report Shape
|
|
86
|
-
|
|
87
|
-
Keep chat output compact:
|
|
88
|
-
|
|
89
|
-
```text
|
|
90
|
-
Blue src/Feature/Foo.cs:42 - unused import `System.Linq`
|
|
91
|
-
Yellow src/Feature/Bar.cs:18-31 - duplicated validation with Baz.cs:44-57 - extract local helper
|
|
92
|
-
Red src/Feature/Qux.cs:90 - private method appears unused but referenced via reflection in Registry.cs
|
|
93
|
-
```
|
|
94
|
-
|
|
95
|
-
## Post-Fix Recap Shape
|
|
96
|
-
|
|
97
|
-
After approved fixes, show a short bulleted recap in settings `uiLanguage`:
|
|
98
|
-
|
|
99
|
-
```text
|
|
100
|
-
- Removed unused imports in Foo.cs and Bar.cs - no references remained after cross-file search.
|
|
101
|
-
- Deleted commented fallback block in Qux.cs - superseded by current handler.
|
|
102
|
-
- Aligned member order in Baz.cs to project rule X.
|
|
103
|
-
```
|
|
104
|
-
|
|
105
|
-
## Last updated
|
|
106
|
-
|
|
107
|
-
2026-06-23
|
|
1
|
+
# Clean Code Checklist
|
|
2
|
+
|
|
3
|
+
Used by `oris-flow-implement` and `oris-flow-fix` while closing work: clean what YOU introduced, in the files you touched. Investigate before concluding; absence in one file is not proof of dead code.
|
|
4
|
+
|
|
5
|
+
## Check, in the touched scope only
|
|
6
|
+
|
|
7
|
+
- **Dead code you left behind**: unused imports, variables, parameters, helpers; unreachable branches from earlier attempts; commented-out code that is not documentation.
|
|
8
|
+
- **Abandoned attempts**: half-finished alternates, debug logging, temporary guards, TODO/FIXME tied to this change, stale comments describing behavior that no longer exists.
|
|
9
|
+
- **Duplication you introduced**: copy-pasted logic that should be one function — at the project's existing abstraction level, no new shared layers without approval.
|
|
10
|
+
- **Naming and wording**: misleading identifiers introduced in this work; misspellings in user-visible strings when in scope. NEVER rename public API surface, routes, DB fields, or serialized names without explicit approval.
|
|
11
|
+
- **Obvious inefficiencies**: duplicate queries/calls in loops, repeated parsing in hot paths — only clear wins with low regression risk.
|
|
12
|
+
- **Style**: match the file's existing conventions (naming, import order, layout). No formatting-only churn outside touched files.
|
|
13
|
+
|
|
14
|
+
## Evidence bar
|
|
15
|
+
|
|
16
|
+
Before removing anything: search references and call sites (including DI registration, reflection, dynamic imports, routing, code generation, framework conventions). Tests, config, or registration may still require the symbol.
|
|
17
|
+
|
|
18
|
+
## Never here
|
|
19
|
+
|
|
20
|
+
Bug fixes (→ `skills/oris-flow-fix/SKILL.md`), architectural redesign, cross-feature refactors, DevOps, drive-by cleanup of code you did not touch.
|
|
@@ -8,15 +8,29 @@ Shared rules for every Oris skill. Skills reference this file instead of repeati
|
|
|
8
8
|
- Installed: `~/.oris/oris-skills/`
|
|
9
9
|
- Repo checkout: repository root.
|
|
10
10
|
|
|
11
|
+
## Routing handles
|
|
12
|
+
|
|
13
|
+
Name a destination skill by its file path (`skills/oris-flow-fix/SKILL.md`) — the one canonical handle. Never by slash command or prose nickname.
|
|
14
|
+
|
|
15
|
+
## CLI commands
|
|
16
|
+
|
|
17
|
+
The `oris-skills` CLI is NOT installed globally. ALWAYS invoke it as `npx oris-skills <command>` — a bare `oris-skills …` fails on user machines.
|
|
18
|
+
|
|
11
19
|
## Questions
|
|
12
20
|
|
|
13
21
|
- ASK with the platform question UI (Cursor `AskQuestion`, Claude `AskUserQuestion`); ELSE ask plainly in chat.
|
|
14
22
|
- ONE question per turn. Recommended answer FIRST.
|
|
15
23
|
- ALWAYS include, localized to `uiLanguage`:
|
|
16
|
-
- `Explain the options` / `Spiega le opzioni` — explain, then re-ask.
|
|
17
|
-
- During interviews: `Enough questions — proceed` / `Basta domande — procedi` (early exit).
|
|
24
|
+
- `Explain the options` / `Spiega le opzioni` — explain, then re-ask the same question.
|
|
25
|
+
- During interviews: `Enough questions — proceed` / `Basta domande — procedi` (early exit → go to the generation gate; NOT approval to write).
|
|
18
26
|
- NEVER ask what the workspace, docs, code, or setup map already answer. Explore first.
|
|
19
27
|
|
|
28
|
+
## Generation gates
|
|
29
|
+
|
|
30
|
+
- Standard labels, localized: `Generate the document` / `Genera il documento`, `Approve document` / `Approva documento`, `Continue the interview` / `Continua l'intervista`, `Cancel` / `Annulla`.
|
|
31
|
+
- NEVER write documents before the explicit gate choice. Exception: `oris-flow-criteria` writes first, then asks ONCE — the document is confirmed only on approval.
|
|
32
|
+
- After a document is written: concise summary + contextual next-step menu. NEVER auto-start the next phase.
|
|
33
|
+
|
|
20
34
|
## Language
|
|
21
35
|
|
|
22
36
|
- READ `references/settings.md` (user settings: `~/.oris/settings.json`).
|
package/references/doc-policy.md
CHANGED
|
@@ -2,18 +2,34 @@
|
|
|
2
2
|
|
|
3
3
|
Applies whenever an Oris skill writes or updates task documentation. Project-agnostic.
|
|
4
4
|
|
|
5
|
+
## The {tasksRoot}
|
|
6
|
+
|
|
7
|
+
Oris keeps its artifacts in its own folder — it never dirties the project's docs by default.
|
|
8
|
+
|
|
9
|
+
- RESOLVE: `setup.tasksRoot` from `.oris-flow/manifest.json`; DEFAULT `.oris-flow/tasks` when missing.
|
|
10
|
+
- LEGACY: a repo with populated `docs/tasks/` and no manifest value keeps `docs/tasks` — setup records the choice once.
|
|
11
|
+
- NEVER mix roots in one repo; the manifest value is the single truth.
|
|
12
|
+
|
|
5
13
|
## Task folder
|
|
6
14
|
|
|
7
15
|
One folder per feature, whole lifecycle:
|
|
8
16
|
|
|
9
17
|
| File | Purpose | Written by |
|
|
10
18
|
|------|---------|------------|
|
|
11
|
-
| `
|
|
12
|
-
| `
|
|
13
|
-
| `
|
|
19
|
+
| `{tasksRoot}/{task}/functional-analysis.md` | confirmed business behavior | discover |
|
|
20
|
+
| `{tasksRoot}/{task}/acceptance-criteria.md` | QA criteria, stable `AC-xxx` IDs | criteria |
|
|
21
|
+
| `{tasksRoot}/{task}/implementation-plan.md` | execution-ready technical plan | plan |
|
|
22
|
+
| `{tasksRoot}/{task}/verification-report.md` | AC results with evidence | verify |
|
|
23
|
+
| `{tasksRoot}/{task}/change-log.md` | spec changes, stable `CH-xxx` IDs | change |
|
|
14
24
|
|
|
15
25
|
NEVER split one feature's docs across unrelated directories.
|
|
16
26
|
|
|
27
|
+
## The {task} slug
|
|
28
|
+
|
|
29
|
+
- DERIVE: kebab-case from the confirmed feature name (e.g. "Export invoices to CSV" → `export-invoices-csv`); prefix with the tracker ID when one exists (`feature-1213-export-invoices-csv`).
|
|
30
|
+
- BEFORE creating: LIST `{tasksRoot}/` and REUSE the existing folder when it covers the same feature — one feature, one folder, forever.
|
|
31
|
+
- IF two candidates could match → ask ONE question; never guess between them, never create a duplicate.
|
|
32
|
+
|
|
17
33
|
## Rules
|
|
18
34
|
|
|
19
35
|
1. Language: documents in `artifactLanguage`; skill instructions stay English.
|
|
@@ -6,15 +6,15 @@ An Oris loop is a project-local feedback system: observe → choose ONE bounded
|
|
|
6
6
|
|
|
7
7
|
```text
|
|
8
8
|
.oris-flow/
|
|
9
|
-
adapter.json repo adapter (paths, commands, model aliases) — `oris-skills loop bootstrap`
|
|
9
|
+
adapter.json repo adapter (paths, commands, model aliases) — `npx oris-skills loop bootstrap`
|
|
10
10
|
loops/{slug}/
|
|
11
11
|
loop.md approved contract (front matter below)
|
|
12
|
-
prompts/ one editable file per role
|
|
12
|
+
prompts/ one editable file per ACTIVE role
|
|
13
13
|
orchestrator.md injected each pass by the stop hook (optional; default shipped)
|
|
14
14
|
executor.md required
|
|
15
15
|
verifier.md required
|
|
16
|
-
doctor.md
|
|
17
|
-
debriefer.md
|
|
16
|
+
doctor.md only when roles includes doctor
|
|
17
|
+
debriefer.md only when roles includes debriefer (required for improve.mode: auto)
|
|
18
18
|
context.md living handoff snapshot (facts, next action)
|
|
19
19
|
receipts/ one compact receipt per pass
|
|
20
20
|
proposals/ unapproved improvement patches
|
|
@@ -31,9 +31,10 @@ kind: oris-loop
|
|
|
31
31
|
name: my-loop # stable slug
|
|
32
32
|
approved: true # set by the user's approval at craft — loop cannot start without it
|
|
33
33
|
phases: [work]
|
|
34
|
+
roles: [executor, verifier] # default; opt in doctor and/or debriefer only when needed
|
|
34
35
|
limits:
|
|
35
36
|
maxIterations: 25
|
|
36
|
-
maxNoProgress: 2
|
|
37
|
+
maxNoProgress: 2 # consecutive passes without verified progress → blocked
|
|
37
38
|
maxMinutes: 240
|
|
38
39
|
models: # per-role: "inherit" | adapter alias | platform model id
|
|
39
40
|
default: inherit
|
|
@@ -56,15 +57,19 @@ Schema: `references/loop.schema.json`. Body = human summary; prompts live in `pr
|
|
|
56
57
|
|
|
57
58
|
## Roles
|
|
58
59
|
|
|
59
|
-
|
|
60
|
-
|------|------|-------|
|
|
61
|
-
| orchestrator (main chat) | reads context, spawns roles, writes receipts, sets state | executor/verifier/doctor work |
|
|
62
|
-
| executor | ONE bounded action per pass | self-verify, exceed scope |
|
|
63
|
-
| verifier | independent evidence check per user criteria | trust claims, edit product files |
|
|
64
|
-
| doctor | continue / advance / complete / stop from evidence | edit files, patch loop.md |
|
|
65
|
-
| debriefer | learn across receipts; tune prompts (auto) or propose (propose) | touch scope/limits/permissions |
|
|
60
|
+
Default roles are **executor + verifier** — enough for most loops. Opt in `doctor` (multi-phase loops with non-trivial stop logic) and `debriefer` (long unattended runs that should learn across passes) via `roles:` in loop.md.
|
|
66
61
|
|
|
67
|
-
|
|
62
|
+
| Role | Default | Does | Never |
|
|
63
|
+
|------|---------|------|-------|
|
|
64
|
+
| orchestrator (main chat) | always | reads context, spawns roles, writes receipts, sets state | executor/verifier/doctor work |
|
|
65
|
+
| executor | yes | ONE bounded action per pass | self-verify, exceed scope |
|
|
66
|
+
| verifier | yes | independent evidence check per user criteria; sets `goalMet` when the LOOP goal is satisfied | trust claims, edit product files |
|
|
67
|
+
| doctor | opt-in | decision from evidence: `continue \| advance \| complete \| ask-user \| propose-patch \| blocked` (canonical enum — every doctor prompt uses exactly these) | edit files, patch loop.md |
|
|
68
|
+
| debriefer | opt-in | learn across receipts; tune prompts (auto) or propose (propose) | touch scope/limits/permissions |
|
|
69
|
+
|
|
70
|
+
Without a doctor, the verifier verdict maps to the state directly: `pass` + `goalMet` → complete; `pass`/`fail` → continue; `blocked`/`inconclusive` → ask-user.
|
|
71
|
+
|
|
72
|
+
Every prompt is a file the user can edit; the next pass obeys the edited file. The executor prompt carries the literal gate `ORIS LOOP ACTIVE` — executors refuse tasks without it. Subagent output is a single ```json fenced block; raw logs go to `.oris-flow/runtime/evidence/`. Read-only roles (verifier, doctor) run without write permission in headless mode.
|
|
68
73
|
|
|
69
74
|
## Models
|
|
70
75
|
|
|
@@ -78,14 +83,16 @@ Anything else → passed through as a platform model id.
|
|
|
78
83
|
|----------|-----------|
|
|
79
84
|
| Cursor | `.cursor/hooks.json` stop hook → injects the next pass into the same chat |
|
|
80
85
|
| Claude Code | `.claude/settings.json` Stop hook → `decision: block` continues the same session |
|
|
81
|
-
| Codex / CI | `oris-skills loop run` — each role is a separate CLI process |
|
|
86
|
+
| Codex / CI | `npx oris-skills loop run` — each role is a separate CLI process |
|
|
82
87
|
|
|
83
|
-
`oris-skills loop bootstrap` writes adapter + hooks + wrappers. The injected pass message comes from `prompts/orchestrator.md` (or the shipped default) with `{{placeholders}}` filled from runtime state.
|
|
88
|
+
`npx oris-skills loop bootstrap` writes adapter + hooks + wrappers. The injected pass message comes from `prompts/orchestrator.md` (or the shipped default) with `{{placeholders}}` filled from runtime state.
|
|
84
89
|
|
|
85
90
|
## States and outcomes
|
|
86
91
|
|
|
87
|
-
Machine states: `continue` | `advance` | `complete` | `blocked` | `cancelled`.
|
|
92
|
+
Machine states: `continue` | `advance` | `complete` | `ask-user` | `blocked` | `cancelled`.
|
|
93
|
+
`ask-user` pauses the loop for input or approval — the hook stops resuming until the state is set back to `continue` (or the loop is restarted). It is NOT a failure.
|
|
88
94
|
Receipt results: `Success` | `Clean no-op` | `Blocked` | `Approval required` | `Exhausted` | `No progress`.
|
|
95
|
+
Every `set-state` carries `--progress yes|no` (yes = the verifier confirmed forward movement); `maxNoProgress` consecutive `no` passes force `blocked`.
|
|
89
96
|
Hitting any limit without meeting the goal = `blocked`, NEVER success.
|
|
90
97
|
|
|
91
98
|
## Receipt (per pass)
|
|
@@ -62,6 +62,19 @@
|
|
|
62
62
|
"pattern": "^[a-z][a-z0-9-]*$"
|
|
63
63
|
}
|
|
64
64
|
},
|
|
65
|
+
"roles": {
|
|
66
|
+
"type": "array",
|
|
67
|
+
"description": "Active roles per pass. Default [executor, verifier]; opt in doctor and/or debriefer. Executor and verifier are always required.",
|
|
68
|
+
"minItems": 2,
|
|
69
|
+
"uniqueItems": true,
|
|
70
|
+
"items": {
|
|
71
|
+
"enum": ["executor", "verifier", "doctor", "debriefer"]
|
|
72
|
+
},
|
|
73
|
+
"allOf": [
|
|
74
|
+
{ "contains": { "const": "executor" } },
|
|
75
|
+
{ "contains": { "const": "verifier" } }
|
|
76
|
+
]
|
|
77
|
+
},
|
|
65
78
|
"limits": {
|
|
66
79
|
"type": "object",
|
|
67
80
|
"required": [
|
package/references/repo-map.md
CHANGED
|
@@ -10,7 +10,7 @@ Setup map = the default project context for every Oris skill and loop. It exists
|
|
|
10
10
|
| `.oris-flow/maps/**` | repo | short markdown maps: docs, stack, commands, code areas, tests |
|
|
11
11
|
| `.oris-flow/adapter.json` | repo | loop adapter: paths, commands, model aliases |
|
|
12
12
|
| `~/.oris/settings.json` | user | language + test profiles |
|
|
13
|
-
| `
|
|
13
|
+
| `{tasksRoot}/{task}/…` | task | business artifacts only — `setup.tasksRoot` in the manifest, default `.oris-flow/tasks` (see `references/doc-policy.md`) |
|
|
14
14
|
|
|
15
15
|
Manifest and maps are never task authority and NEVER hold secrets.
|
|
16
16
|
|
|
@@ -32,7 +32,7 @@ Manifest and maps are never task authority and NEVER hold secrets.
|
|
|
32
32
|
- Small: only sections that exist for the detected stack; no placeholders.
|
|
33
33
|
- Each section: file path, one-line summary, `confidence`, `lastScannedAt`, stale flag.
|
|
34
34
|
- Confidence: `confirmed` (user/authoritative) | `detected` (strong scan evidence) | `inferred` (unverified) | `stale` (no longer matches).
|
|
35
|
-
- `setup.versionControl.orisFlowMap`: `commit` | `gitignore` — applied via `oris-skills flow version-control --mode <choice>`.
|
|
35
|
+
- `setup.versionControl.orisFlowMap`: `commit` | `gitignore` — applied via `npx oris-skills flow version-control --mode <choice>`.
|
|
36
36
|
- Schema: `references/repo-map.schema.json`.
|
|
37
37
|
|
|
38
38
|
## Map sections
|
|
@@ -50,4 +50,4 @@ Each section: purpose, authoritative paths, confirmed decisions, key commands/co
|
|
|
50
50
|
|
|
51
51
|
## Command surface
|
|
52
52
|
|
|
53
|
-
In target repositories always use the installed CLI (`oris-skills flow scan|version-control|clean-runtime`, `oris-skills loop …`), never `node scripts/...` paths — those exist only in the OrisSkills source checkout.
|
|
53
|
+
In target repositories always use the installed CLI (`npx oris-skills flow scan|version-control|clean-runtime`, `npx oris-skills loop …`), never `node scripts/...` paths — those exist only in the OrisSkills source checkout.
|