@williambeto/ai-workflow 1.18.8 → 1.18.9

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
@@ -5,7 +5,11 @@ All notable changes to AI Workflow Kit (`ai-workflow`) are documented in this fi
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
- ## [Unreleased]
8
+ ## [1.18.9] - 2026-05-21
9
+
10
+ ### Removed
11
+
12
+ - **Consumer `workflow:validate` and `workflow:doctor` scripts**: removed thin wrapper aliases from consumer `package.json`. These provided marginal value over direct commands (`npm run validate`, `npx ai-workflow doctor`). Removed `merge-package-json.js`, updated `init.js`, `doctor.js`, `templates.js`, and all documentation references.
9
13
 
10
14
  ## [1.18.8] - 2026-05-20
11
15
 
@@ -330,6 +330,7 @@ Runbooks are operational guides for applying the workflow.
330
330
  | [`runbooks/how-to-use-skills.md`](runbooks/how-to-use-skills.md) | Choose specialist skills. |
331
331
  | [`runbooks/commands-cheatsheet.md`](runbooks/commands-cheatsheet.md) | Choose Codex/OpenCode commands. |
332
332
  | [`runbooks/agent-delegation-workflow.md`](runbooks/agent-delegation-workflow.md) | Use orchestrator and handoff routing. |
333
+ | [`runbooks/use-linear-for-operational-planning.md`](runbooks/use-linear-for-operational-planning.md) | Use Linear as the operational backlog when the roadmap is too large for daily planning. |
333
334
  | [`runbooks/validation-checklist.md`](runbooks/validation-checklist.md) | Validate docs, code, PRs, builds, security, accessibility, and deploy readiness. |
334
335
  | [`runbooks/team-governance-pr-readiness.md`](runbooks/team-governance-pr-readiness.md) | Define PR readiness and approval policy. |
335
336
  | [`runbooks/deploy-checklist.md`](runbooks/deploy-checklist.md) | Prepare deploy, smoke tests, and rollback. |
@@ -49,8 +49,7 @@ The `init` command creates:
49
49
  - managed `opencode.jsonc` sections (for `operational` and `full` profiles);
50
50
  - `.codex/prompts/README.md` — Codex prompt entrypoint reference;
51
51
  - `opencode/README.md` — OpenCode command reference;
52
- - starter agent and skill files (for the `full` profile);
53
- - `npm run workflow:validate` and `npm run workflow:doctor` scripts (when `package.json` exists).
52
+ - starter agent and skill files (for the `full` profile).
54
53
 
55
54
  Use `--dry-run` to preview changes before writing:
56
55
 
@@ -124,7 +123,7 @@ Codex users should treat [`AGENTS.md`](AGENTS.md) as the main operational contra
124
123
  After `init` and `doctor`, confirm:
125
124
 
126
125
  - [ ] `npx @williambeto/ai-workflow doctor` reports no errors
127
- - [ ] `npm run workflow:validate` passes
126
+ - [ ] `npm run validate` passes (or project-specific validation commands)
128
127
  - [ ] `README.workflow.md` exists at the project root
129
128
  - [ ] `opencode.jsonc` contains managed sections (for `operational`/`full` profiles)
130
129
  - [ ] Codex prompt placeholders exist (`.codex/prompts/`)
package/opencode.jsonc CHANGED
@@ -142,6 +142,13 @@
142
142
  "prompt": "{file:.agents/skills/playwright-cli/SKILL.md}"
143
143
  }
144
144
  },
145
+ "mcp": {
146
+ "linear": {
147
+ "type": "local",
148
+ "command": ["npx", "-y", "mcp-remote", "https://mcp.linear.app/mcp"],
149
+ "enabled": true
150
+ }
151
+ },
145
152
  "command": {
146
153
  "start": {
147
154
  "description": "Select default startup route (orchestrator with fallback)",
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "1.18.8",
2
+ "version": "1.18.9",
3
3
  "name": "@williambeto/ai-workflow",
4
4
  "description": "AI Workflow Kit repository for designing and validating AI-assisted software delivery workflows with Codex and OpenCode",
5
5
  "license": "MIT",
@@ -37,8 +37,8 @@ npx @williambeto/ai-workflow init --dry-run
37
37
  - `init` creates or merges managed sections in `opencode.jsonc` for operational/full profiles.
38
38
  - `full` profile also installs local Codex prompt starter files (`start`, `orchestrate-next`, `plan`, `execute`, `review`, `validate`) under `.codex/prompts/`, plus OpenCode agents and skills under `opencode/agents/` and `.agents/skills/`.
39
39
  - conflict backups are stored under `.ai-workflow-backups/` with per-file retention.
40
- - `workflow:validate` uses `npm run validate --if-present` for safer cross-project onboarding.
41
- - `doctor` validates profile readiness (`.ai-workflow.json`, workflow scripts, and `opencode.jsonc` managed blocks for operational/full profiles).
40
+
41
+ - `doctor` validates profile readiness (`.ai-workflow.json` and `opencode.jsonc` managed blocks for operational/full profiles).
42
42
 
43
43
  ## Profiles
44
44
 
@@ -77,6 +77,6 @@ This CLI is in preview. It is validated for:
77
77
  - `init --yes`;
78
78
  - `doctor`;
79
79
  - managed `opencode.jsonc` merge with JSONC comments;
80
- - `workflow:validate` in projects with a `validate` script.
80
+ - `npm run validate` in projects with a `validate` script.
81
81
 
82
82
  Before using it in a shared project, inspect generated files and commit only intentional changes.
@@ -148,16 +148,10 @@ export async function runDoctor({ cwd }) {
148
148
  try {
149
149
  const packageJson = await readJson(packageJsonPath);
150
150
  const scripts = packageJson.scripts ?? {};
151
- if (scripts["workflow:validate"] && scripts["workflow:doctor"]) {
152
- console.log("PASS package.json workflow scripts present");
153
- } else {
154
- hasWarning = true;
155
- console.log("WARN package.json missing workflow scripts");
156
- }
157
151
 
158
152
  if (!scripts.validate) {
159
153
  hasWarning = true;
160
- console.log("WARN package.json has no validate script; workflow:validate may be a no-op");
154
+ console.log("WARN package.json has no validate script");
161
155
  }
162
156
  } catch {
163
157
  hasFailure = true;
@@ -3,7 +3,6 @@ import path from "node:path";
3
3
  import { createInstallPlan } from "../core/install-plan.js";
4
4
  import { buildAiWorkflowConfig, getTemplateFiles, isValidProfile } from "../core/templates.js";
5
5
  import { exists, writeFileSafe } from "../core/filesystem.js";
6
- import { mergeWorkflowScripts } from "../core/merge-package-json.js";
7
6
  import { createManagedBackup, createManagedPathBackup } from "../core/backup.js";
8
7
  import { mergeOpencodeConfig } from "../core/opencode-merge.js";
9
8
  import { buildSymlinkEntries, isSymlinkTo } from "../core/symlink-layout.js";
@@ -135,7 +134,6 @@ export async function runInit({ cwd, yes, force, dryRun, noInstall, noOverwrite,
135
134
  linkCreated.push(linkPath);
136
135
  }
137
136
 
138
- const mergeResult = await mergeWorkflowScripts(cwd, { dryRun: false });
139
137
  const opencodeResult =
140
138
  selectedProfile === "minimal"
141
139
  ? { reason: "skipped (minimal profile)" }
@@ -143,7 +141,7 @@ export async function runInit({ cwd, yes, force, dryRun, noInstall, noOverwrite,
143
141
 
144
142
  console.log("Installation complete.");
145
143
  console.log(`- profile: ${selectedProfile}`);
146
- console.log(`- package.json scripts: ${mergeResult.reason}`);
144
+
147
145
  console.log(`- opencode.jsonc: ${opencodeResult.reason}`);
148
146
  console.log(`- symlink layout: ${linkCreated.length > 0 ? `created ${linkCreated.length}` : "already-up-to-date"}`);
149
147
  if (backups.length > 0) {
@@ -167,5 +165,4 @@ export async function runInit({ cwd, yes, force, dryRun, noInstall, noOverwrite,
167
165
  console.log(`- dependency install: ${noInstall ? "skipped (--no-install)" : "not managed in this step"}`);
168
166
  console.log("Next steps:");
169
167
  console.log(" npx @williambeto/ai-workflow doctor");
170
- console.log(" npm run workflow:validate");
171
168
  }
@@ -259,10 +259,6 @@ export function buildAiWorkflowConfig({ profile, managedFiles, managedLinks = []
259
259
  managedBlocks: getManagedBlocks(profile),
260
260
  fileHashes: {},
261
261
  backupsDir: ".ai-workflow-backups",
262
- scripts: {
263
- "workflow:validate": "npm run validate --if-present",
264
- "workflow:doctor": "ai-workflow doctor"
265
- },
266
262
  compatibility: {
267
263
  codex: true,
268
264
  opencode: true
@@ -46,13 +46,7 @@ Expected result: `Final status: PASS` or `PASS_WITH_NOTES` with actionable warni
46
46
 
47
47
  ### 3. Run project validation
48
48
 
49
- If the target project has a `validate` script, run:
50
-
51
- ```bash
52
- npm run workflow:validate
53
- ```
54
-
55
- If not, use the target project's real checks, for example:
49
+ Run the target project's validation commands, for example:
56
50
 
57
51
  ```bash
58
52
  npm run build
@@ -98,10 +92,10 @@ gh pr create --title "My first PR" --body "## Summary"
98
92
  ### 7. Run validation before opening a PR
99
93
 
100
94
  ```bash
101
- npm run workflow:validate
95
+ npm run validate
102
96
  ```
103
97
 
104
- If `workflow:validate` reports no project `validate` script, include the actual build/lint/test commands you ran in the PR body.
98
+ If the project has no `validate` script, run the actual build/lint/test commands directly and include them in the PR body.
105
99
 
106
100
  ## Workflow steps reference
107
101
 
@@ -212,7 +206,7 @@ npm run validate
212
206
  | `npx @williambeto/ai-workflow init --dry-run` | Previews target-project install changes |
213
207
  | `npx @williambeto/ai-workflow init --yes` | Installs default workflow assets |
214
208
  | `npx @williambeto/ai-workflow doctor` | Checks local workflow installation |
215
- | `npm run workflow:validate` | Runs target-project validation when available |
209
+ | `npm run validate` | Runs target-project validation when available |
216
210
  | `npm run validate` | Runs all repository validations when developing this kit |
217
211
  | `npm run test:e2e` | Tests validation scripts |
218
212
  | `npm run lint:md` | Checks Markdown formatting |
@@ -0,0 +1,185 @@
1
+ # Use Linear for Operational Planning
2
+
3
+ ## Purpose
4
+
5
+ Use this runbook when `ROADMAP.md` is too large for day-to-day planning and the team needs a smaller, current, and auditable operational backlog.
6
+
7
+ Linear should become the operational source of truth for next work. `ROADMAP.md` remains the strategic and historical source of truth.
8
+
9
+ ## When to use
10
+
11
+ Use Linear when:
12
+
13
+ - the next PR is hard to identify from `ROADMAP.md`;
14
+ - roadmap items are complete but still appear in older audit reports;
15
+ - product, planning, implementation, and validation work need one shared queue;
16
+ - each task needs owner, priority, status, acceptance criteria, and delivery evidence.
17
+
18
+ Skip Linear for one-off local edits where a short checklist is enough.
19
+
20
+ ## Source-of-truth split
21
+
22
+ | Source | Role |
23
+ | --- | --- |
24
+ | Linear | Current operational backlog, priorities, owners, status, blockers, and next PRs. |
25
+ | GitHub PRs | Delivery evidence, review discussion, changed files, validation results, and merge history. |
26
+ | `ROADMAP.md` | Strategic phases, durable product direction, historical context, and large milestone sequencing. |
27
+ | `CHANGELOG.md` | Published or release-relevant changes. |
28
+ | `docs/reports/` | Audit inputs, scorecards, and evidence-backed recommendations. |
29
+
30
+ Do not use `ROADMAP.md` alone to decide the next implementation step when Linear exists.
31
+
32
+ ## Linear MCP setup
33
+
34
+ Linear's remote MCP endpoint is:
35
+
36
+ ```txt
37
+ https://mcp.linear.app/mcp
38
+ ```
39
+
40
+ ### Codex
41
+
42
+ Preferred setup through the Codex CLI:
43
+
44
+ ```bash
45
+ codex mcp add linear --url https://mcp.linear.app/mcp
46
+ ```
47
+
48
+ If this is the first MCP server configured for Codex, enable the remote MCP client in `~/.codex/config.toml`:
49
+
50
+ ```toml
51
+ [features]
52
+ experimental_use_rmcp_client = true
53
+ ```
54
+
55
+ Equivalent manual configuration:
56
+
57
+ ```toml
58
+ [features]
59
+ experimental_use_rmcp_client = true
60
+
61
+ [mcp_servers.linear]
62
+ url = "https://mcp.linear.app/mcp"
63
+ ```
64
+
65
+ Then authenticate:
66
+
67
+ ```bash
68
+ codex mcp login linear
69
+ ```
70
+
71
+ ### OpenCode
72
+
73
+ This repository includes Linear's remote MCP server in `opencode.jsonc`:
74
+
75
+ ```json
76
+ {
77
+ "mcp": {
78
+ "linear": {
79
+ "type": "remote",
80
+ "url": "https://mcp.linear.app/mcp",
81
+ "enabled": true
82
+ }
83
+ }
84
+ }
85
+ ```
86
+
87
+ After updating `opencode.jsonc`, quit and restart OpenCode so the MCP server is loaded from the project config.
88
+
89
+ Authenticate through OpenCode's MCP/OAuth flow when prompted. Keep authentication state local to the developer machine.
90
+
91
+ Do not commit personal MCP tokens, OAuth state, API keys, or local `~/.codex/config.toml` files to this repository.
92
+
93
+ ## Recommended Linear project structure
94
+
95
+ Create one Linear project:
96
+
97
+ ```txt
98
+ Public readiness score improvement
99
+ ```
100
+
101
+ Use these milestones:
102
+
103
+ 1. **Validation trust**
104
+ 2. **Onboarding clarity**
105
+ 3. **Platform simplification**
106
+
107
+ Initial issue queue:
108
+
109
+ | Milestone | Issue | Initial status | Evidence source |
110
+ | --- | --- | --- | --- |
111
+ | Validation trust | Fix E2E validation drift | Done | `npm run test:e2e` passes 14/14; `ROADMAP.md`; `CHANGELOG.md`. |
112
+ | Validation trust | Define stable validation output contract | Todo | `docs/reports/public-readiness-backlog.md`. |
113
+ | Validation trust | Create Go/No-Go public checklist | Todo | `docs/reports/public-readiness-backlog.md`. |
114
+ | Onboarding clarity | Add one adoption decision table | Todo | `docs/reports/project-evaluation.md`. |
115
+ | Onboarding clarity | Reduce entry-doc circular/deep reference chains | Todo | `npm run validate` warnings and audit report. |
116
+ | Platform simplification | Phase 17 PR 1 — Move Codex prompts to legacy | Todo | `ROADMAP.md` Phase 17. |
117
+ | Platform simplification | Phase 17 PR 2 — Simplify `AGENTS.md` to OpenCode-only | Todo | `ROADMAP.md` Phase 17. |
118
+ | Platform simplification | Phase 17 PR 3 — Update README and core docs for single-path | Todo | `ROADMAP.md` Phase 17. |
119
+
120
+ ## Issue template
121
+
122
+ Use this format for Linear issues:
123
+
124
+ ```md
125
+ ## Objective
126
+
127
+ What outcome should this issue achieve?
128
+
129
+ ## Scope
130
+
131
+ Included:
132
+ - ...
133
+
134
+ Not included:
135
+ - ...
136
+
137
+ ## Acceptance criteria
138
+
139
+ - ...
140
+
141
+ ## Evidence required
142
+
143
+ - Command:
144
+ - Expected result:
145
+ - Manual review:
146
+
147
+ ## Source context
148
+
149
+ - ROADMAP.md:
150
+ - Report/backlog:
151
+ - Related PR:
152
+
153
+ ## Risk
154
+
155
+ Low | Medium | High
156
+ ```
157
+
158
+ ## Operating rules
159
+
160
+ - Keep one Linear issue equivalent to one small PR whenever possible.
161
+ - Mark an issue `Done` only when validation evidence is attached or linked.
162
+ - Link the GitHub PR to the Linear issue before review.
163
+ - If an audit finding is already fixed, close it with evidence instead of recreating work.
164
+ - Update `ROADMAP.md` only for durable strategic changes, phase status changes, or historical milestones.
165
+ - Update `CHANGELOG.md` only for published or release-relevant changes.
166
+
167
+ ## Planning cadence
168
+
169
+ Before selecting the next PR:
170
+
171
+ 1. Check Linear for highest-priority `Todo` or `Blocked` issues.
172
+ 2. Confirm the issue still matches current repository evidence.
173
+ 3. If evidence contradicts the issue, update or close the issue before implementation.
174
+ 4. Select one issue.
175
+ 5. Create a scoped branch.
176
+ 6. Implement only that issue.
177
+ 7. Attach validation evidence before marking it `Done`.
178
+
179
+ ## Acceptance criteria for Linear adoption
180
+
181
+ - A Linear project exists for public-readiness score improvement.
182
+ - The known completed E2E drift item is marked `Done` with evidence.
183
+ - Planned score-improvement items are represented as small issues.
184
+ - Each active issue has acceptance criteria and required evidence.
185
+ - `ROADMAP.md` is no longer used as the only day-to-day planning source.
@@ -1,44 +0,0 @@
1
- import path from "node:path";
2
- import { exists, readJson, writeFileSafe } from "./filesystem.js";
3
-
4
- export async function mergeWorkflowScripts(cwd, { dryRun = false } = {}) {
5
- const packageJsonPath = path.join(cwd, "package.json");
6
-
7
- if (!(await exists(packageJsonPath))) {
8
- return { changed: false, reason: "package.json not found" };
9
- }
10
-
11
- const packageJson = await readJson(packageJsonPath);
12
- const scripts = packageJson.scripts ?? {};
13
- const shouldSetDefaultValidate =
14
- scripts["workflow:validate"] === undefined ||
15
- scripts["workflow:validate"] === "npm run validate";
16
-
17
- const mergedScripts = {
18
- ...scripts,
19
- "workflow:validate": shouldSetDefaultValidate
20
- ? "npm run validate --if-present"
21
- : scripts["workflow:validate"],
22
- "workflow:doctor": scripts["workflow:doctor"] ?? "ai-workflow doctor"
23
- };
24
-
25
- const changed =
26
- scripts["workflow:validate"] !== mergedScripts["workflow:validate"] ||
27
- scripts["workflow:doctor"] !== mergedScripts["workflow:doctor"];
28
-
29
- if (!changed) {
30
- return { changed: false, reason: "workflow scripts already present" };
31
- }
32
-
33
- if (dryRun) {
34
- return { changed: true, reason: "dry-run" };
35
- }
36
-
37
- const next = {
38
- ...packageJson,
39
- scripts: mergedScripts
40
- };
41
-
42
- await writeFileSafe(packageJsonPath, `${JSON.stringify(next, null, 2)}\n`);
43
- return { changed: true, reason: "scripts merged" };
44
- }