@sabaiway/agent-workflow-engine 1.1.0 → 1.2.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/CHANGELOG.md CHANGED
@@ -4,6 +4,27 @@ All notable changes to the methodology engine. Versions are this **package's** n
4
4
  they are distinct from the **deployment-lineage** stamp written into a project's `docs/ai/`
5
5
  (which tracks the shared `agent-workflow` lineage, head `1.3.0`).
6
6
 
7
+ ## 1.2.0 — Orchestration recipes: a named vocabulary for composing the bridges
8
+
9
+ The engine now also owns the **orchestration-recipe** canon — the named patterns an agent uses to
10
+ compose the optional execution-backends (the `codex` / `agy` bridges) into `plan → execute → review`.
11
+ Four recipes, built over the bridges' role vocabulary: **Solo** (no backend — the floor), **Reviewed**
12
+ (one backend reviews), **Council** (both review, you synthesize), **Delegated** (a backend executes a
13
+ bounded sub-task). The orchestrator always owns the decisions and the single commit; a backend is
14
+ advisory or delegated, never autonomous. The kit reads this canon **live** and surfaces a read-only
15
+ `/agent-workflow-kit recipes` advisor that plans a recipe for the current environment.
16
+
17
+ ### Added
18
+ - **`references/orchestration.md`** — the canonical narrative: the four recipes over the role
19
+ vocabulary, the when/why decision guidance, the graceful-degradation lattice (Council → Reviewed →
20
+ Solo; Delegated → Solo, always with a stated reason), and the quota/health guard.
21
+ - **`references/orchestration-slot.md`** — the bounded **one-line** fragment the composition root
22
+ injects into a deployed `AGENTS.md` (between the `workflow:orchestration` markers). It names the four
23
+ recipes and routes to `/agent-workflow-kit recipes` — never to this engine-internal reference.
24
+
25
+ The deployment-lineage head stays **`1.3.0`** (no `docs/ai` structural change; no migration file). The
26
+ npm package version is a separate axis.
27
+
7
28
  ## 1.1.0 — Live-read ready: never-downgrade gate + installer hardening
8
29
 
9
30
  The kit now reads this canon **live from the installed engine** and has retired its bundled mirror
package/README.md CHANGED
@@ -3,8 +3,9 @@
3
3
  **The canonical home of the `agent-workflow` planning methodology.** It owns the
4
4
  methodology *text* — the Plan → Phase → Step vocabulary, the plan-file lifecycle
5
5
  (`docs/plans/*.md`, ephemeral, never committed), the `queue.md` series index, the mandatory
6
- final **Phase: Cleanup**, and the bounded methodology slot fragment the family kit injects
7
- into a deployed project's `AGENTS.md`.
6
+ final **Phase: Cleanup**, the **orchestration-recipe** vocabulary (Solo / Reviewed / Council /
7
+ Delegated), and the two bounded slot fragments the family kit injects into a deployed project's
8
+ `AGENTS.md`.
8
9
 
9
10
  This is the **methodology engine** of the `agent-workflow` family — the canonical source the
10
11
  rest of the family builds on. It is **content**, not a runtime: it reads nothing, writes
@@ -41,13 +42,19 @@ the canonical methodology reference on disk:
41
42
  Plan → Phase → Step vocabulary, the plan-file lifecycle, the `queue.md` series index, the
42
43
  mandatory final **Phase: Cleanup**, and the plan-then-execute split.
43
44
  - [`references/methodology-slot.md`](references/methodology-slot.md) — the **bounded**
44
- fragment the composition root injects into a deployed `AGENTS.md` (a short summary +
45
+ methodology fragment the composition root injects into a deployed `AGENTS.md` (a short summary +
45
46
  pointer, kept under the entry point's line cap).
47
+ - [`references/orchestration.md`](references/orchestration.md) — the canonical **orchestration-recipe**
48
+ reference: the four recipes (Solo / Reviewed / Council / Delegated) over the bridges' role
49
+ vocabulary, the when/why, the graceful-degradation lattice, and the quota/health guard.
50
+ - [`references/orchestration-slot.md`](references/orchestration-slot.md) — the **bounded** one-line
51
+ orchestration fragment the composition root injects into a deployed `AGENTS.md`, routing to the
52
+ in-project recipes surface.
46
53
 
47
54
  ## What this package ships
48
55
 
49
- `SKILL.md` (the canon overview + ownership rule), `references/` (the full methodology
50
- reference + the bounded slot fragment), `capability.json` (the family manifest), and this
56
+ `SKILL.md` (the canon overview + ownership rule), `references/` (the full methodology + orchestration
57
+ references + the two bounded slot fragments), `capability.json` (the family manifest), and this
51
58
  installer. It ships **no** family-wide tooling (the schema/validator/injection live in the
52
59
  composition root) and mutates nothing — preserving "knows nobody".
53
60
 
package/SKILL.md CHANGED
@@ -1,9 +1,9 @@
1
1
  ---
2
2
  name: agent-workflow-engine
3
- description: Canonical home of the agent-workflow planning methodology — the Plan→Phase→Step→Substep vocabulary, plan lifecycle, queue.md series index, mandatory Cleanup phase, and the bounded methodology slot fragment. A published, installable npm package (available:true) that *provides* the methodology text; it mutates nothing. The composition root (agent-workflow-kit) reads this canon LIVE from the installed engine and injects the bounded slot from it — one source of truth, no bundled mirror; `npx @sabaiway/agent-workflow-kit@latest init` installs the engine.
3
+ description: Canonical home of the agent-workflow planning methodology — the Plan→Phase→Step→Substep vocabulary, plan lifecycle, queue.md series index, mandatory Cleanup phase, the bounded methodology slot fragment, and the orchestration-recipe vocabulary (Solo / Reviewed / Council / Delegated). A published, installable npm package (available:true) that *provides* the methodology text; it mutates nothing. The composition root (agent-workflow-kit) reads this canon LIVE from the installed engine and injects the bounded slots from it — one source of truth, no bundled mirror; `npx @sabaiway/agent-workflow-kit@latest init` installs the engine.
4
4
  disable-model-invocation: true
5
5
  metadata:
6
- version: '1.1.0'
6
+ version: '1.2.0'
7
7
  ---
8
8
 
9
9
  # agent-workflow-engine
@@ -26,6 +26,14 @@ slot fill is needed but the engine is absent, the kit's reconcile **fails loudly
26
26
  composition root injects into a deployed project's `AGENTS.md`, between the
27
27
  `<!-- workflow:methodology:start -->` / `<!-- workflow:methodology:end -->` markers. A short
28
28
  summary + pointer, not the full reference, so the entry point stays under its line cap.
29
+ - [`references/orchestration.md`](references/orchestration.md) — the canonical **orchestration-recipe**
30
+ reference: the four recipes (Solo / Reviewed / Council / Delegated) defined over the bridges' role
31
+ vocabulary, the when/why decision guidance, the graceful-degradation lattice, and the quota/health
32
+ guard. The kit owns the executable dispatch and surfaces it as `/agent-workflow-kit recipes`.
33
+ - [`references/orchestration-slot.md`](references/orchestration-slot.md) — the **bounded** one-line
34
+ orchestration fragment the composition root injects into a deployed `AGENTS.md`, between the
35
+ `<!-- workflow:orchestration:start -->` / `<!-- workflow:orchestration:end -->` markers. It names the
36
+ four recipes and routes to `/agent-workflow-kit recipes`, never to this engine-internal reference.
29
37
 
30
38
  ## Ownership rule (the engine knows nobody)
31
39
 
package/capability.json CHANGED
@@ -3,7 +3,7 @@
3
3
  "schema": 1,
4
4
  "name": "agent-workflow-engine",
5
5
  "kind": "methodology-engine",
6
- "version": "1.1.0",
6
+ "version": "1.2.0",
7
7
  "available": true,
8
8
  "provides": ["plan"],
9
9
  "roles": {},
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sabaiway/agent-workflow-engine",
3
- "version": "1.1.0",
3
+ "version": "1.2.0",
4
4
  "description": "Canonical home of the agent-workflow planning methodology — the Plan→Phase→Step vocabulary, plan lifecycle, queue.md series index, and mandatory Cleanup phase, consumed by the kit (composition root). The methodology engine of the agent-workflow family.",
5
5
  "keywords": [
6
6
  "ai-agents",
@@ -0,0 +1 @@
1
+ > **Orchestration recipes** — compose plan → execute → review with a named recipe: **Solo** (no backend), **Reviewed** (one backend reviews), **Council** (both review, you synthesize), **Delegated** (a backend executes a bounded sub-task); the orchestrator always commits, a backend is never autonomous. Pick + plan one for this environment with `/agent-workflow-kit recipes` (read-only); the deployed how/why lives in your `docs/ai/` workflow docs.
@@ -0,0 +1,92 @@
1
+ # Orchestration Recipes
2
+
3
+ Canonical, on-demand reference for **how an orchestrating agent composes the optional
4
+ execution-backends** (the family's subscription-CLI bridges) into the `plan → execute → review`
5
+ flow. This is the *narrative* source of truth — the **vocabulary** (what each recipe is), the
6
+ **when/why** (which to reach for), the **graceful-degradation lattice** (what happens when a backend
7
+ is unavailable), and the **quota/health guard**. The kit (`agent-workflow-kit`) owns the *executable*
8
+ dispatch (`tools/recipes.mjs` — `planRecipe` / `recommendRecipe`) and surfaces it read-only as
9
+ `/agent-workflow-kit recipes`; the two representations are kept in lockstep by a recipe-name parity
10
+ guard. For the plan lifecycle this composes with, see [`planning.md`](planning.md).
11
+
12
+ ---
13
+
14
+ ## 1. The role vocabulary recipes are built over
15
+
16
+ A recipe is an **orchestration pattern**, not a runnable script. The **orchestrator** (the main
17
+ agent) always owns the decisions, the edits it accepts, verification, and the **single commit** — a
18
+ backend is **advisory or delegated, never autonomous, and never commits**.
19
+
20
+ Each backend declares what it can do in its `capability.json` `provides` / `roles`:
21
+
22
+ - **`codex-cli-bridge`** (`codex`) — `provides: ["execute", "review"]`. It can run a bounded
23
+ execution sub-task (`codex-exec`, output: a diff) and give an advisory review (`codex-review`,
24
+ modes `plan` / `code`).
25
+ - **`antigravity-cli-bridge`** (`agy`) — `provides: ["review", "probe"]`. It can give an advisory
26
+ review and answer a bounded probe (both via `agy-run`).
27
+
28
+ Both are **subscription** backends with a **finite quota** — spend deliberately.
29
+
30
+ ## 2. The four recipes
31
+
32
+ | Recipe (id) | Pattern | Roles needed | Backends that satisfy it |
33
+ |-------------|---------|--------------|--------------------------|
34
+ | **Solo** (`solo`) | The orchestrator plans, executes, and self-reviews. No backend. | none | — (always available; the floor) |
35
+ | **Reviewed** (`reviewed`) | The orchestrator executes; **one** backend reviews the result (advisory). | ≥1 backend providing `review` | `codex` and/or `agy` |
36
+ | **Council** (`council`) | **Both** backends review independently; the orchestrator synthesizes the two opinions. | ≥2 backends providing `review` | `codex` **and** `agy` |
37
+ | **Delegated** (`delegated`) | The orchestrator hands a **bounded** execution sub-task to a backend, then reviews the returned diff and commits. | ≥1 backend providing `execute` | `codex` only |
38
+
39
+ ## 3. When / why to reach for each (the decision vocabulary)
40
+
41
+ - **Solo** — the default for small, self-contained, low-risk work where a second opinion would not
42
+ change the outcome: typos, one-line fixes, mechanical edits, doc tweaks. It is also the **floor**
43
+ every other recipe degrades to, so the flow never blocks on a backend.
44
+ - **Reviewed** — the everyday choice when work carries real risk (a bug class, a security surface, a
45
+ non-obvious refactor) and an independent reviewer is worth one backend's quota. When **both**
46
+ backends can review, prefer **`codex`** (deterministic tie-break — `agy` carries a standing health
47
+ caveat, §5).
48
+ - **Council** — for high-stakes or genuinely ambiguous decisions where two *diverse* opinions catch
49
+ what one would miss. It spends **two** backends' quota, so reserve it for changes that justify the
50
+ cost.
51
+ - **Delegated** — when a bounded, well-specified sub-task can be handed off (parallelism, or to keep
52
+ the orchestrator's own context focused). Only `codex` provides `execute`. The orchestrator still
53
+ reviews the returned diff and owns the commit — delegation never bypasses the review or the gate.
54
+
55
+ ## 4. Graceful degradation (never silent)
56
+
57
+ Availability is **pure file-presence**: a backend is dispatchable **iff its detector `readiness` is
58
+ `ready`** — full stop. Every other readiness (`needs-skill` / `needs-cli` / `needs-credentials` /
59
+ `degraded`) means *not dispatchable*, and the specific value is the human reason (not installed → run
60
+ `/agent-workflow-kit setup`; CLI missing → install the CLI; credentials missing → log in; degraded →
61
+ the wrapper is not on `PATH`). This is a claim about **set-up state only** — never about whether a
62
+ backend's *service* is actually responsive.
63
+
64
+ When a recipe's roles can't be satisfied, it **degrades to a weaker recipe with a stated reason** —
65
+ always reported, never silently dropped:
66
+
67
+ - **Council → Reviewed → Solo.** Only one of the two reviewers is `ready` → Reviewed with that one;
68
+ neither is `ready` → Solo.
69
+ - **Delegated → Solo.** No backend provides `execute` and is `ready` → Solo, with the reason.
70
+ - **Reviewed → Solo.** No backend provides `review` and is `ready` → Solo, with the reason.
71
+
72
+ ## 5. Quota & health guard (advisory)
73
+
74
+ Backends are **subscription** services with **finite** quota. The orchestrator should: prefer the
75
+ cheapest model that fits the task; not reach for a top-tier model by reflex; and remember that
76
+ **Council spends two backends' quota** for one decision.
77
+
78
+ A **standing health advisory** applies to `agy`: the Antigravity service can **stall on substantive
79
+ prompts** (a long hang that returns nothing — an external service issue, not a setup problem;
80
+ tracked as **Issue-001** in the kit's known issues). It is **invisible to file-presence detection**,
81
+ so it is *not* a readiness signal — it is a static caveat attached whenever a recipe would use `agy`. While it lasts, **prefer `codex`** for substantive
82
+ reviews (this is the Reviewed tie-break in §3). The recipe machinery **never runs a subscription
83
+ CLI** to check — detection stays read-only.
84
+
85
+ ## 6. The orchestrator always commits
86
+
87
+ No recipe makes a backend write to the repo or create a commit. The kit's `recipes` surface is
88
+ **read-only** — it lists the recipes, plans one for the current environment, and recommends a
89
+ default; it **never executes** a recipe and **never runs a subscription CLI**. The orchestrator
90
+ executes the chosen recipe through the bridge skills, accepts or rejects every edit, runs the
91
+ verification gate, and makes the **one** commit — exactly as the plan lifecycle (`planning.md`)
92
+ requires.