@ritualai/cli 0.36.11 → 0.36.14
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/dist/commands/lite.js +102 -0
- package/dist/commands/lite.js.map +1 -0
- package/dist/commands/project.js +82 -0
- package/dist/commands/project.js.map +1 -0
- package/dist/index.js +21 -0
- package/dist/index.js.map +1 -1
- package/dist/lib/agents/launch.js +21 -5
- package/dist/lib/agents/launch.js.map +1 -1
- package/dist/lib/okf-projection.js +118 -0
- package/dist/lib/okf-projection.js.map +1 -0
- package/dist/lib/worktree.js +87 -0
- package/dist/lib/worktree.js.map +1 -0
- package/package.json +1 -1
- package/skills/claude-code/ritual/.ritual-bundle.json +3 -3
- package/skills/claude-code/ritual/SKILL.md +1 -1
- package/skills/claude-code/ritual/references/build-flow.md +27 -1
- package/skills/claude-code/ritual/references/lite-flow.md +53 -2
- package/skills/codex/ritual/.ritual-bundle.json +3 -3
- package/skills/codex/ritual/SKILL.md +1 -1
- package/skills/codex/ritual/references/build-flow.md +27 -1
- package/skills/codex/ritual/references/lite-flow.md +53 -2
- package/skills/cursor/ritual/.ritual-bundle.json +3 -3
- package/skills/cursor/ritual/SKILL.md +1 -1
- package/skills/cursor/ritual/references/build-flow.md +27 -1
- package/skills/cursor/ritual/references/lite-flow.md +53 -2
- package/skills/gemini/ritual/.ritual-bundle.json +3 -3
- package/skills/gemini/ritual/SKILL.md +1 -1
- package/skills/gemini/ritual/references/build-flow.md +27 -1
- package/skills/gemini/ritual/references/lite-flow.md +53 -2
- package/skills/kiro/ritual/.ritual-bundle.json +3 -3
- package/skills/kiro/ritual/SKILL.md +1 -1
- package/skills/kiro/ritual/references/build-flow.md +27 -1
- package/skills/kiro/ritual/references/lite-flow.md +53 -2
- package/skills/vscode/ritual/.ritual-bundle.json +3 -3
- package/skills/vscode/ritual/SKILL.md +1 -1
- package/skills/vscode/ritual/references/build-flow.md +27 -1
- package/skills/vscode/ritual/references/lite-flow.md +53 -2
|
@@ -3,7 +3,7 @@ name: ritual
|
|
|
3
3
|
description: "Use when an engineer wants a coding agent to plan or build a feature, refactor, or implementation-heavy change that depends on context the agent can't infer on its own — strategic intent, constraints, prior decisions, and trade-offs that live in the user's head. Ritual runs a structured exploration to surface that context through targeted discovery questions, combines it with codebase signals and prior explorations, and delivers a validated build brief (sub-problems, recommendations, dependencies) — additional context to fold into plan mode before the agent writes code. Prefer this over jumping straight to implementation or plan mode when the problem is ambiguous, cross-cutting, or has non-obvious constraints. Subcommands: build (full planning-to-sync cycle — default for new features), resume (continue an in-flight exploration), lineage (file-path KG history — what decisions shaped this code), context-pulse (readiness and context-debt scoring — is this safe to build yet?)."
|
|
4
4
|
argument-hint: "[subcommand] <args> (e.g. 'build Reduce T2 churn in Q3', 'resume', 'lineage src/checkout/views.py', 'context-pulse Add billing export')"
|
|
5
5
|
user-invocable: true
|
|
6
|
-
stamp:
|
|
6
|
+
stamp: ee9a77046c96
|
|
7
7
|
---
|
|
8
8
|
|
|
9
9
|
# /ritual
|
|
@@ -554,7 +554,33 @@ Steps:
|
|
|
554
554
|
f. **If the user picks one (1-N):**
|
|
555
555
|
- Set the chosen candidate's `summary` as the `raw_input` for the rest of the flow.
|
|
556
556
|
- **Skip Step 1.5 step 8 (overlap check)** — the user just picked from system suggestions explicitly grounded in workspace state; a fresh overlap pass would be redundant noise.
|
|
557
|
-
-
|
|
557
|
+
- **Run the unchosen-candidates gate (f.1) BEFORE continuing**, then continue to Step 2.
|
|
558
|
+
|
|
559
|
+
<!-- skill-options:no-gate-change: f.1 is an OPTIONAL skippable sub-prompt nested in Step 1.5 step 6 (default skip); adds no tracked pause gate or Step header, so the structural fingerprint is unchanged (check-skill-options-contract green). -->
|
|
560
|
+
f.1 **Unchosen-candidates gate (2026-06-14, unchosen-options → discovery worktrees).** The candidates the user did NOT pick are paths worth not silently dropping. Render ONE compact, SKIPPABLE prompt — for each unchosen candidate, the user can spin up **discovery now** (a background worktree reasons it to a build brief) or **log it as a future job**. Promote DELIBERATELY: the default is to drop. (This gate is itself skipped in autonomous/worktree mode — never spawn discovery recursively.)
|
|
561
|
+
|
|
562
|
+
```text
|
|
563
|
+
You picked #{k}. The other {M} — want to keep any going?
|
|
564
|
+
• `discover <nums>` — spin up discovery NOW in a background git worktree: an agent reasons it
|
|
565
|
+
end-to-end to a build brief (reasoning only, no code). e.g. `discover 1`
|
|
566
|
+
• `next-job <nums>` — just log it as a future job (a draft exploration in this workspace; nothing runs)
|
|
567
|
+
• `skip` — drop them (default)
|
|
568
|
+
```
|
|
569
|
+
|
|
570
|
+
Resolve the reply, then continue to Step 2 for the picked candidate:
|
|
571
|
+
- **`discover <nums>`** → for each, run `ritual lite "{candidate.summary}" --worktree` **in the
|
|
572
|
+
BACKGROUND** (do not block the build — use your shell's background/async execution). It spins a
|
|
573
|
+
git worktree and runs autonomous discovery to a brief there; tell the user where (`<repo>.ritual-discover/<slug>`).
|
|
574
|
+
The result is an exploration with `spawn_origin: 'discovery_worktree'`; its brief is
|
|
575
|
+
agent-authored, not human-reviewed. (See `references/unchosen-options-discovery-worktrees.md` in `documents/architecture/`.)
|
|
576
|
+
- **`next-job <nums>`** → for each, call `mcp__ritual__create_exploration` with the candidate's
|
|
577
|
+
`title` as `name`, its `summary` as `problem_statement`, `spawn_origin: 'next_job'`, and NO
|
|
578
|
+
`agentic` flag — a NOT_STARTED draft that shows in the workspace roster as a future job. Cheap; nothing runs.
|
|
579
|
+
- **`skip` / no reply about them** → drop silently.
|
|
580
|
+
|
|
581
|
+
Keep it ONE prompt, never per-candidate pauses. If the user just proceeds without addressing it, treat as `skip`.
|
|
582
|
+
|
|
583
|
+
f.2 **Continue to Step 2 (template selection)** for the picked candidate.
|
|
558
584
|
|
|
559
585
|
g. **If the user says "none" / "let me describe":** continue to Step 2 normally; treat as if they had originally picked "start fresh" with no raw_input yet (they'll provide one at Step 3-4 time).
|
|
560
586
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
<!-- GENERATED from references/build-flow.md by apps/cli/scripts/generate-lite-flow.js — DO NOT EDIT. -->
|
|
2
|
-
<!-- source-sha:
|
|
2
|
+
<!-- source-sha: 3d973c8d7e6a514b -->
|
|
3
3
|
|
|
4
4
|
# /ritual lite — fast build (generated; do not edit)
|
|
5
5
|
|
|
@@ -40,6 +40,31 @@ Follow build-flow.md's steps below EXACTLY, with these **LITE OVERRIDES**:
|
|
|
40
40
|
UX brief review, plan-fidelity audit, and sibling-exploration forks are omitted
|
|
41
41
|
(they're removed from the flow below).
|
|
42
42
|
|
|
43
|
+
## Autonomous worktree mode (discovery — no human, stop at the brief)
|
|
44
|
+
**Trigger:** the invocation carries the `--worktree` flag (you were launched by
|
|
45
|
+
`ritual lite --worktree "<ask>"` — a git worktree was spun up and you are running
|
|
46
|
+
HEADLESS inside it, with no human present). A developer parked an unchosen option
|
|
47
|
+
for background discovery (unchosen-options → discovery worktrees). When you see
|
|
48
|
+
`--worktree`, apply these EXTRA rules on top of the lite overrides above:
|
|
49
|
+
- **There is no human, so auto-resolve EVEN the two touchpoints.** Accept the
|
|
50
|
+
classified job (Step 0.7) and the recommendations (Step 9) without waiting —
|
|
51
|
+
take the default at every gate, including those two. (If the job comes back
|
|
52
|
+
generic, proceed as the generic `Feature Brief` build; there's no one to
|
|
53
|
+
clarify with.)
|
|
54
|
+
- **Create the exploration with `spawn_origin: 'discovery_worktree'`** (Step 6,
|
|
55
|
+
`create_exploration`) so `get_exploration_status` reports
|
|
56
|
+
`autonomousDiscovery: true`.
|
|
57
|
+
- **Materialize the reasoning as files (OKF projection).** Once the brief is
|
|
58
|
+
written, run `ritual project <exploration-id>` — it projects the exploration
|
|
59
|
+
(index + build-brief + scope-contract + recommendations) into `.ritual/` in
|
|
60
|
+
this worktree, so the developer who `cd`s in reads the reasoning as files, not
|
|
61
|
+
just a graph id. Projection, not replica: the live graph stays authoritative.
|
|
62
|
+
- **STOP there.** Do NOT branch, plan, implement, or open a PR — that is the
|
|
63
|
+
developer's call when they land in the worktree. The brief is **agent-authored
|
|
64
|
+
and NOT human-reviewed**; surface it as such so it's read with skepticism.
|
|
65
|
+
This mode adds no new skill — it IS `lite`, just with no human to pause for and a
|
|
66
|
+
hard stop at the brief. A normal (attended) `lite` run ignores this section.
|
|
67
|
+
|
|
43
68
|
---
|
|
44
69
|
|
|
45
70
|
## /ritual build
|
|
@@ -598,7 +623,33 @@ Steps:
|
|
|
598
623
|
f. **If the user picks one (1-N):**
|
|
599
624
|
- Set the chosen candidate's `summary` as the `raw_input` for the rest of the flow.
|
|
600
625
|
- **Skip Step 1.5 step 8 (overlap check)** — the user just picked from system suggestions explicitly grounded in workspace state; a fresh overlap pass would be redundant noise.
|
|
601
|
-
-
|
|
626
|
+
- **Run the unchosen-candidates gate (f.1) BEFORE continuing**, then continue to Step 2.
|
|
627
|
+
|
|
628
|
+
<!-- skill-options:no-gate-change: f.1 is an OPTIONAL skippable sub-prompt nested in Step 1.5 step 6 (default skip); adds no tracked pause gate or Step header, so the structural fingerprint is unchanged (check-skill-options-contract green). -->
|
|
629
|
+
f.1 **Unchosen-candidates gate (2026-06-14, unchosen-options → discovery worktrees).** The candidates the user did NOT pick are paths worth not silently dropping. Render ONE compact, SKIPPABLE prompt — for each unchosen candidate, the user can spin up **discovery now** (a background worktree reasons it to a build brief) or **log it as a future job**. Promote DELIBERATELY: the default is to drop. (This gate is itself skipped in autonomous/worktree mode — never spawn discovery recursively.)
|
|
630
|
+
|
|
631
|
+
```text
|
|
632
|
+
You picked #{k}. The other {M} — want to keep any going?
|
|
633
|
+
• `discover <nums>` — spin up discovery NOW in a background git worktree: an agent reasons it
|
|
634
|
+
end-to-end to a build brief (reasoning only, no code). e.g. `discover 1`
|
|
635
|
+
• `next-job <nums>` — just log it as a future job (a draft exploration in this workspace; nothing runs)
|
|
636
|
+
• `skip` — drop them (default)
|
|
637
|
+
```
|
|
638
|
+
|
|
639
|
+
Resolve the reply, then continue to Step 2 for the picked candidate:
|
|
640
|
+
- **`discover <nums>`** → for each, run `ritual lite "{candidate.summary}" --worktree` **in the
|
|
641
|
+
BACKGROUND** (do not block the build — use your shell's background/async execution). It spins a
|
|
642
|
+
git worktree and runs autonomous discovery to a brief there; tell the user where (`<repo>.ritual-discover/<slug>`).
|
|
643
|
+
The result is an exploration with `spawn_origin: 'discovery_worktree'`; its brief is
|
|
644
|
+
agent-authored, not human-reviewed. (See `references/unchosen-options-discovery-worktrees.md` in `documents/architecture/`.)
|
|
645
|
+
- **`next-job <nums>`** → for each, call `mcp__ritual__create_exploration` with the candidate's
|
|
646
|
+
`title` as `name`, its `summary` as `problem_statement`, `spawn_origin: 'next_job'`, and NO
|
|
647
|
+
`agentic` flag — a NOT_STARTED draft that shows in the workspace roster as a future job. Cheap; nothing runs.
|
|
648
|
+
- **`skip` / no reply about them** → drop silently.
|
|
649
|
+
|
|
650
|
+
Keep it ONE prompt, never per-candidate pauses. If the user just proceeds without addressing it, treat as `skip`.
|
|
651
|
+
|
|
652
|
+
f.2 **Continue to Step 2 (template selection)** for the picked candidate.
|
|
602
653
|
|
|
603
654
|
g. **If the user says "none" / "let me describe":** continue to Step 2 normally; treat as if they had originally picked "start fresh" with no raw_input yet (they'll provide one at Step 3-4 time).
|
|
604
655
|
|