aiwg 2026.5.12 → 2026.6.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.
Files changed (253) hide show
  1. package/CLAUDE.md +21 -4
  2. package/README.md +32 -1
  3. package/agentic/code/addons/agent-loop/skills/agent-loop/SKILL.md +4 -1
  4. package/agentic/code/addons/aiwg-utils/agents/aiwg-steward.md +15 -0
  5. package/agentic/code/addons/aiwg-utils/manifest.json +24 -1
  6. package/agentic/code/addons/aiwg-utils/rules/auto-compact-continue.md +2 -2
  7. package/agentic/code/addons/aiwg-utils/skills/aiwg-mission/SKILL.md +68 -0
  8. package/agentic/code/addons/aiwg-utils/workflow/README.md +118 -0
  9. package/agentic/code/addons/aiwg-utils/workflow/docs/migration-from-ops.md +142 -0
  10. package/agentic/code/addons/aiwg-utils/workflow/docs/overview.md +275 -0
  11. package/agentic/code/addons/aiwg-utils/workflow/examples/capability-minimal.yaml +35 -0
  12. package/agentic/code/addons/aiwg-utils/workflow/examples/playbook-with-gate.yaml +61 -0
  13. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-capability.schema.json +176 -0
  14. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-extension.schema.json +103 -0
  15. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-gate.schema.json +86 -0
  16. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-inventory.schema.json +112 -0
  17. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-playbook.schema.json +256 -0
  18. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-role.schema.json +135 -0
  19. package/agentic/code/addons/aiwg-utils/workflow/schemas/workflow-target.schema.json +82 -0
  20. package/agentic/code/agents/personas/aiwg-steward.md +15 -0
  21. package/agentic/code/extensions/corpus-templates/README.md +4 -4
  22. package/agentic/code/extensions/corpus-templates/templates/TEMPLATES-README.md +1 -1
  23. package/agentic/code/frameworks/forensics-complete/manifest.json +11 -11
  24. package/agentic/code/frameworks/knowledge-base/manifest.json +32 -8
  25. package/agentic/code/frameworks/media-curator/manifest.json +11 -11
  26. package/agentic/code/frameworks/media-marketing-kit/manifest.json +28 -7
  27. package/agentic/code/frameworks/research-complete/config/source-types.yaml +212 -0
  28. package/agentic/code/frameworks/research-complete/docs/corpus-data-model.md +1 -1
  29. package/agentic/code/frameworks/research-complete/elaboration/agents/acquisition-agent-spec.md +1 -1
  30. package/agentic/code/frameworks/research-complete/elaboration/architecture/adrs/ADR-RF-004-artifact-storage-structure.md +2 -2
  31. package/agentic/code/frameworks/research-complete/elaboration/nfr/NFR-RF-specifications.md +3 -3
  32. package/agentic/code/frameworks/research-complete/inception/initial-risk-assessment.md +1 -1
  33. package/agentic/code/frameworks/research-complete/inception/project-intake.md +5 -5
  34. package/agentic/code/frameworks/research-complete/inception/solution-profile.md +2 -2
  35. package/agentic/code/frameworks/research-complete/inception/stakeholder-analysis.md +4 -4
  36. package/agentic/code/frameworks/research-complete/inception/vision-document.md +5 -5
  37. package/agentic/code/frameworks/research-complete/manifest.json +9 -9
  38. package/agentic/code/frameworks/research-complete/skills/citation-backfill/SKILL.md +27 -0
  39. package/agentic/code/frameworks/research-complete/skills/induction-audit/SKILL.md +78 -0
  40. package/agentic/code/frameworks/research-complete/skills/integrity-scan/SKILL.md +106 -0
  41. package/agentic/code/frameworks/research-complete/skills/profile-graph/SKILL.md +71 -0
  42. package/agentic/code/frameworks/research-complete/skills/research-lint/SKILL.md +11 -0
  43. package/agentic/code/frameworks/research-complete/skills/sidecar-lint/SKILL.md +100 -0
  44. package/agentic/code/frameworks/research-complete/skills/source-types/SKILL.md +122 -0
  45. package/agentic/code/frameworks/research-complete/skills/vision-extract/SKILL.md +75 -0
  46. package/agentic/code/frameworks/sdlc-complete/agents/issue-workflow-guide.md +1 -1
  47. package/agentic/code/frameworks/sdlc-complete/commands/address-issues.md +21 -9
  48. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/arch-create-adr.yaml +14 -0
  49. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/arch-evolution-report.yaml +13 -0
  50. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/arch-migration-analysis.yaml +13 -0
  51. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/arch-options-analysis.yaml +13 -0
  52. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/arch-trigger-assess.yaml +13 -0
  53. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/incorporate-review.yaml +14 -0
  54. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/release-assert-artifacts.yaml +17 -0
  55. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/release-build-gate.yaml +17 -0
  56. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/release-ci-poll.yaml +17 -0
  57. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/release-cut-tag.yaml +16 -0
  58. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/release-doc-sync.yaml +17 -0
  59. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/release-post-actions.yaml +16 -0
  60. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/review-legacy-impact.yaml +14 -0
  61. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/review-performance.yaml +14 -0
  62. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/review-security.yaml +14 -0
  63. package/agentic/code/frameworks/sdlc-complete/flows/capabilities/review-testability.yaml +14 -0
  64. package/agentic/code/frameworks/sdlc-complete/flows/flow-architecture-evolution.playbook.yaml +76 -0
  65. package/agentic/code/frameworks/sdlc-complete/flows/flow-release.playbook.yaml +99 -0
  66. package/agentic/code/frameworks/sdlc-complete/skills/flow-architecture-evolution/SKILL.md +10 -0
  67. package/agentic/code/frameworks/sdlc-complete/skills/flow-release/SKILL.md +9 -0
  68. package/agentic/code/frameworks/sdlc-complete/templates/aiwg-sections/02b-discover-first.md +17 -1
  69. package/agentic/code/frameworks/sdlc-complete/templates/openclaw/AGENTS.md.aiwg-template +96 -0
  70. package/agentic/code/frameworks/sdlc-complete/templates/openclaw/SOUL.md.aiwg-template +32 -0
  71. package/agentic/code/frameworks/sdlc-complete/templates/openhuman/AGENTS.md.aiwg-template +89 -0
  72. package/agentic/code/frameworks/sdlc-complete/templates/research/ref-template-with-frontmatter.md +0 -1
  73. package/agentic/code/frameworks/security-engineering/manifest.json +9 -9
  74. package/agentic/code/frameworks/security-engineering/skills/cargo-supply-chain-audit/SKILL.md +181 -0
  75. package/agentic/code/frameworks/security-engineering/skills/security-engineering-quickref/SKILL.md +2 -0
  76. package/agentic/code/providers/capability-matrix.yaml +50 -4
  77. package/bin/aiwg.mjs +40 -1
  78. package/dist/src/agents/agent-deployer.d.ts.map +1 -1
  79. package/dist/src/agents/agent-deployer.js +1 -0
  80. package/dist/src/agents/agent-deployer.js.map +1 -1
  81. package/dist/src/agents/types.d.ts +3 -2
  82. package/dist/src/agents/types.d.ts.map +1 -1
  83. package/dist/src/artifacts/browser-export.d.ts +57 -0
  84. package/dist/src/artifacts/browser-export.d.ts.map +1 -0
  85. package/dist/src/artifacts/browser-export.js +111 -0
  86. package/dist/src/artifacts/browser-export.js.map +1 -0
  87. package/dist/src/artifacts/cli.d.ts.map +1 -1
  88. package/dist/src/artifacts/cli.js +206 -1
  89. package/dist/src/artifacts/cli.js.map +1 -1
  90. package/dist/src/artifacts/corpus-tools/citation-densify.d.ts +51 -0
  91. package/dist/src/artifacts/corpus-tools/citation-densify.d.ts.map +1 -0
  92. package/dist/src/artifacts/corpus-tools/citation-densify.js +311 -0
  93. package/dist/src/artifacts/corpus-tools/citation-densify.js.map +1 -0
  94. package/dist/src/artifacts/corpus-tools/cli.d.ts.map +1 -1
  95. package/dist/src/artifacts/corpus-tools/cli.js +146 -0
  96. package/dist/src/artifacts/corpus-tools/cli.js.map +1 -1
  97. package/dist/src/artifacts/corpus-tools/induction-audit.d.ts +50 -0
  98. package/dist/src/artifacts/corpus-tools/induction-audit.d.ts.map +1 -0
  99. package/dist/src/artifacts/corpus-tools/induction-audit.js +233 -0
  100. package/dist/src/artifacts/corpus-tools/induction-audit.js.map +1 -0
  101. package/dist/src/artifacts/corpus-tools/integrity-scan.d.ts +69 -0
  102. package/dist/src/artifacts/corpus-tools/integrity-scan.d.ts.map +1 -0
  103. package/dist/src/artifacts/corpus-tools/integrity-scan.js +202 -0
  104. package/dist/src/artifacts/corpus-tools/integrity-scan.js.map +1 -0
  105. package/dist/src/artifacts/corpus-tools/profile-edges.d.ts +43 -0
  106. package/dist/src/artifacts/corpus-tools/profile-edges.d.ts.map +1 -0
  107. package/dist/src/artifacts/corpus-tools/profile-edges.js +72 -0
  108. package/dist/src/artifacts/corpus-tools/profile-edges.js.map +1 -0
  109. package/dist/src/artifacts/corpus-tools/profile-embed.d.ts +49 -0
  110. package/dist/src/artifacts/corpus-tools/profile-embed.d.ts.map +1 -0
  111. package/dist/src/artifacts/corpus-tools/profile-embed.js +113 -0
  112. package/dist/src/artifacts/corpus-tools/profile-embed.js.map +1 -0
  113. package/dist/src/artifacts/corpus-tools/sidecar-lint.d.ts +45 -0
  114. package/dist/src/artifacts/corpus-tools/sidecar-lint.d.ts.map +1 -0
  115. package/dist/src/artifacts/corpus-tools/sidecar-lint.js +233 -0
  116. package/dist/src/artifacts/corpus-tools/sidecar-lint.js.map +1 -0
  117. package/dist/src/artifacts/corpus-tools/sidecar-repair.d.ts +57 -0
  118. package/dist/src/artifacts/corpus-tools/sidecar-repair.d.ts.map +1 -0
  119. package/dist/src/artifacts/corpus-tools/sidecar-repair.js +277 -0
  120. package/dist/src/artifacts/corpus-tools/sidecar-repair.js.map +1 -0
  121. package/dist/src/artifacts/corpus-tools/source-types.d.ts +67 -0
  122. package/dist/src/artifacts/corpus-tools/source-types.d.ts.map +1 -0
  123. package/dist/src/artifacts/corpus-tools/source-types.js +160 -0
  124. package/dist/src/artifacts/corpus-tools/source-types.js.map +1 -0
  125. package/dist/src/artifacts/corpus-tools/vision-extract.d.ts +74 -0
  126. package/dist/src/artifacts/corpus-tools/vision-extract.d.ts.map +1 -0
  127. package/dist/src/artifacts/corpus-tools/vision-extract.js +243 -0
  128. package/dist/src/artifacts/corpus-tools/vision-extract.js.map +1 -0
  129. package/dist/src/artifacts/corpus-views/corpus-config.d.ts +15 -0
  130. package/dist/src/artifacts/corpus-views/corpus-config.d.ts.map +1 -1
  131. package/dist/src/artifacts/corpus-views/corpus-config.js +37 -0
  132. package/dist/src/artifacts/corpus-views/corpus-config.js.map +1 -1
  133. package/dist/src/artifacts/corpus-views/ref-parser.d.ts +10 -0
  134. package/dist/src/artifacts/corpus-views/ref-parser.d.ts.map +1 -1
  135. package/dist/src/artifacts/corpus-views/ref-parser.js +52 -0
  136. package/dist/src/artifacts/corpus-views/ref-parser.js.map +1 -1
  137. package/dist/src/artifacts/corpus-views/renderers.d.ts +1 -2
  138. package/dist/src/artifacts/corpus-views/renderers.d.ts.map +1 -1
  139. package/dist/src/artifacts/corpus-views/renderers.js +26 -0
  140. package/dist/src/artifacts/corpus-views/renderers.js.map +1 -1
  141. package/dist/src/artifacts/embedding-index.d.ts +18 -0
  142. package/dist/src/artifacts/embedding-index.d.ts.map +1 -1
  143. package/dist/src/artifacts/embedding-index.js +47 -1
  144. package/dist/src/artifacts/embedding-index.js.map +1 -1
  145. package/dist/src/artifacts/fulltext.d.ts +56 -0
  146. package/dist/src/artifacts/fulltext.d.ts.map +1 -0
  147. package/dist/src/artifacts/fulltext.js +108 -0
  148. package/dist/src/artifacts/fulltext.js.map +1 -0
  149. package/dist/src/artifacts/index-builder.d.ts +15 -0
  150. package/dist/src/artifacts/index-builder.d.ts.map +1 -1
  151. package/dist/src/artifacts/index-builder.js +57 -11
  152. package/dist/src/artifacts/index-builder.js.map +1 -1
  153. package/dist/src/artifacts/query-engine.d.ts +2 -2
  154. package/dist/src/artifacts/query-engine.d.ts.map +1 -1
  155. package/dist/src/artifacts/query-engine.js +185 -35
  156. package/dist/src/artifacts/query-engine.js.map +1 -1
  157. package/dist/src/artifacts/types.d.ts +6 -0
  158. package/dist/src/artifacts/types.d.ts.map +1 -1
  159. package/dist/src/artifacts/types.js.map +1 -1
  160. package/dist/src/channel/manager.mjs +25 -0
  161. package/dist/src/cli/handlers/diagnose.d.ts.map +1 -1
  162. package/dist/src/cli/handlers/diagnose.js +4 -1
  163. package/dist/src/cli/handlers/diagnose.js.map +1 -1
  164. package/dist/src/cli/handlers/index.d.ts +2 -2
  165. package/dist/src/cli/handlers/index.d.ts.map +1 -1
  166. package/dist/src/cli/handlers/index.js +2 -3
  167. package/dist/src/cli/handlers/index.js.map +1 -1
  168. package/dist/src/cli/handlers/issues.d.ts +0 -1
  169. package/dist/src/cli/handlers/issues.d.ts.map +1 -1
  170. package/dist/src/cli/handlers/issues.js +0 -18
  171. package/dist/src/cli/handlers/issues.js.map +1 -1
  172. package/dist/src/cli/handlers/regenerate.d.ts.map +1 -1
  173. package/dist/src/cli/handlers/regenerate.js +3 -0
  174. package/dist/src/cli/handlers/regenerate.js.map +1 -1
  175. package/dist/src/cli/handlers/subcommands.d.ts.map +1 -1
  176. package/dist/src/cli/handlers/subcommands.js +73 -8
  177. package/dist/src/cli/handlers/subcommands.js.map +1 -1
  178. package/dist/src/cli/handlers/use.d.ts.map +1 -1
  179. package/dist/src/cli/handlers/use.js +43 -3
  180. package/dist/src/cli/handlers/use.js.map +1 -1
  181. package/dist/src/cli/provider-resolution.d.ts +1 -0
  182. package/dist/src/cli/provider-resolution.d.ts.map +1 -1
  183. package/dist/src/cli/provider-resolution.js +6 -1
  184. package/dist/src/cli/provider-resolution.js.map +1 -1
  185. package/dist/src/config/aiwg-config.d.ts +1 -1
  186. package/dist/src/config/aiwg-config.d.ts.map +1 -1
  187. package/dist/src/config/aiwg-config.js +9 -2
  188. package/dist/src/config/aiwg-config.js.map +1 -1
  189. package/dist/src/extensions/claude-hooks-installer.d.ts.map +1 -1
  190. package/dist/src/extensions/claude-hooks-installer.js +24 -4
  191. package/dist/src/extensions/claude-hooks-installer.js.map +1 -1
  192. package/dist/src/extensions/commands/definitions.d.ts.map +1 -1
  193. package/dist/src/extensions/commands/definitions.js +6 -5
  194. package/dist/src/extensions/commands/definitions.js.map +1 -1
  195. package/dist/src/extensions/deployment-registration.d.ts.map +1 -1
  196. package/dist/src/extensions/deployment-registration.js +22 -4
  197. package/dist/src/extensions/deployment-registration.js.map +1 -1
  198. package/dist/src/extensions/manifest.d.ts +4 -4
  199. package/dist/src/extensions/validation.d.ts +4 -4
  200. package/dist/src/issues/workflows.d.ts +0 -1
  201. package/dist/src/issues/workflows.d.ts.map +1 -1
  202. package/dist/src/issues/workflows.js +0 -130
  203. package/dist/src/issues/workflows.js.map +1 -1
  204. package/dist/src/lint/cli.d.ts.map +1 -1
  205. package/dist/src/lint/cli.js +33 -4
  206. package/dist/src/lint/cli.js.map +1 -1
  207. package/dist/src/mcp/cli.mjs +34 -10
  208. package/dist/src/plugin/framework-detector.d.ts +3 -1
  209. package/dist/src/plugin/framework-detector.d.ts.map +1 -1
  210. package/dist/src/plugin/framework-detector.js +36 -15
  211. package/dist/src/plugin/framework-detector.js.map +1 -1
  212. package/dist/src/plugin/skill-command-translator.d.ts.map +1 -1
  213. package/dist/src/plugin/skill-command-translator.js +1 -0
  214. package/dist/src/plugin/skill-command-translator.js.map +1 -1
  215. package/dist/src/skills/cli.js +1 -1
  216. package/dist/src/skills/cli.js.map +1 -1
  217. package/dist/src/smiths/agentsmith/generator.d.ts.map +1 -1
  218. package/dist/src/smiths/agentsmith/generator.js +1 -0
  219. package/dist/src/smiths/agentsmith/generator.js.map +1 -1
  220. package/dist/src/smiths/context-pipeline/finalization.d.ts.map +1 -1
  221. package/dist/src/smiths/context-pipeline/finalization.js +3 -1
  222. package/dist/src/smiths/context-pipeline/finalization.js.map +1 -1
  223. package/dist/src/smiths/context-pipeline/provider-policy.d.ts +1 -1
  224. package/dist/src/smiths/context-pipeline/provider-policy.d.ts.map +1 -1
  225. package/dist/src/smiths/context-pipeline/provider-policy.js +6 -0
  226. package/dist/src/smiths/context-pipeline/provider-policy.js.map +1 -1
  227. package/dist/src/smiths/context-pipeline/types.d.ts.map +1 -1
  228. package/dist/src/smiths/context-pipeline/types.js.map +1 -1
  229. package/dist/src/smiths/platform-paths.d.ts.map +1 -1
  230. package/dist/src/smiths/platform-paths.js +5 -0
  231. package/dist/src/smiths/platform-paths.js.map +1 -1
  232. package/dist/src/smiths/skillsmith/collision-detector.d.ts.map +1 -1
  233. package/dist/src/smiths/skillsmith/collision-detector.js +1 -0
  234. package/dist/src/smiths/skillsmith/collision-detector.js.map +1 -1
  235. package/dist/src/smiths/skillsmith/namespace-adapter.d.ts +1 -1
  236. package/dist/src/smiths/skillsmith/namespace-adapter.d.ts.map +1 -1
  237. package/dist/src/smiths/skillsmith/namespace-adapter.js +8 -1
  238. package/dist/src/smiths/skillsmith/namespace-adapter.js.map +1 -1
  239. package/dist/src/smiths/skillsmith/platform-resolver.d.ts.map +1 -1
  240. package/dist/src/smiths/skillsmith/platform-resolver.js +6 -0
  241. package/dist/src/smiths/skillsmith/platform-resolver.js.map +1 -1
  242. package/package.json +2 -2
  243. package/tools/agents/deploy-agents.mjs +7 -2
  244. package/tools/agents/providers/base.mjs +80 -27
  245. package/tools/agents/providers/codex.mjs +76 -30
  246. package/tools/agents/providers/cursor.mjs +20 -3
  247. package/tools/agents/providers/hermes.mjs +48 -40
  248. package/tools/agents/providers/openclaw.mjs +69 -1
  249. package/tools/agents/providers/opencode.mjs +67 -0
  250. package/tools/agents/providers/openhuman.mjs +302 -0
  251. package/tools/cli/doctor.mjs +39 -0
  252. package/tools/cli/workspace-status.mjs +32 -3
  253. package/tools/skills/deploy-skills-codex.mjs +14 -4
package/CLAUDE.md CHANGED
@@ -79,7 +79,7 @@ All 10 providers receive all 4 artifact types (agents, commands, skills, rules).
79
79
  | Platform | Agents | Commands | Skills | Rules | Command |
80
80
  |----------|--------|----------|--------|-------|---------|
81
81
  | Claude Code | `.claude/agents/` | `.claude/commands/` | `.claude/skills/` | `.claude/rules/` | `aiwg use sdlc` |
82
- | OpenAI/Codex | `.codex/agents/` | `~/.codex/prompts/` (scanned) + `.codex/commands/` (deployed for visibility; not scanned — Codex commands are a static enum) | `~/.codex/skills/` + `.agents/skills/` | `.codex/rules/` | `aiwg use sdlc --provider codex` |
82
+ | OpenAI/Codex | `.codex/agents/` | `~/.codex/prompts/` (scanned) + `.codex/commands/` (deployed for visibility; not scanned — Codex commands are a static enum) | `.agents/skills/` (project) + `~/.agents/skills/` (user) | `.codex/rules/` | `aiwg use sdlc --provider codex` |
83
83
  | GitHub Copilot | `.github/agents/` | `.github/prompts/` | `.github/skills/` + `.agents/skills/` | `.github/instructions/` | `aiwg use sdlc --provider copilot` |
84
84
  | Factory AI | `.factory/droids/` | `.factory/commands/` | `.factory/skills/` | `.factory/rules/` | `aiwg use sdlc --provider factory` |
85
85
  | Cursor | `.cursor/agents/` | `.cursor/commands/` | `.cursor/skills/` | `.cursor/rules/` | `aiwg use sdlc --provider cursor` |
@@ -87,16 +87,18 @@ All 10 providers receive all 4 artifact types (agents, commands, skills, rules).
87
87
  | Warp Terminal | `.warp/agents/` + WARP.md | `.warp/commands/` | `.warp/skills/` + `.agents/skills/` | `.warp/rules/` | `aiwg use sdlc --provider warp` |
88
88
  | Windsurf | AGENTS.md | `.windsurf/workflows/` | `.windsurf/skills/` + `.agents/skills/` | `.windsurf/rules/` | `aiwg use sdlc --provider windsurf` |
89
89
  | OpenClaw | `~/.openclaw/agents/` | `~/.openclaw/commands/` | `~/.openclaw/skills/` + `.agents/skills/` | `~/.openclaw/rules/` | `aiwg use sdlc --provider openclaw` |
90
- | Hermes | AGENTS.md + .hermes.md | via MCP `command-run` | `~/.hermes/skills/` (kernel) + `~/.hermes/skills/.aiwg/` (standard) | inlined in AGENTS.md + MCP `rule-list`/`rule-show` | `aiwg use sdlc --provider hermes` |
90
+ | Hermes | AGENTS.md + .hermes.md | AGENTS.md bridge + `aiwg discover`/`show` (MCP `command-run` optional) | `~/.hermes/skills/` (kernel) + `~/.hermes/skills/.aiwg/` (standard) | AGENTS.md `### Rule:` sections + `aiwg show rule` (MCP `rule-list`/`rule-show` optional) | `aiwg use sdlc --provider hermes` |
91
+ | OpenHuman | `.agents/agents/` | AGENTS.md bridge | `~/.openhuman/skills/` (kernel, global) + `~/.openhuman/.aiwg/skills/` (standard) | AGENTS.md `### Rule:` sections + `aiwg show rule` | `aiwg use sdlc --provider openhuman` |
91
92
  | Omnius (bundled, first-party integrator) | bundled in Omnius runtime | bundled in Omnius runtime | bundled in Omnius runtime | bundled in Omnius runtime | `npm i -g omnius` |
92
93
 
93
94
  **Special cases:**
94
- - **Codex**: Commands and skills deploy to home directory (`~/.codex/prompts/`, `~/.codex/skills/`) for user-level availability across all projects. `.codex/commands/` also deploys at project scope for operator visibility, but Codex commands are a static built-in enum in codex-rs and these files are not auto-scanned by the loader; AGENTS.md is the discovery bridge per ADR-1. Reference: `src/smiths/platform-paths.ts:23`.
95
+ - **Codex**: Commands deploy to the home directory (`~/.codex/prompts/`) for user-level availability across all projects. Skills deploy to the cross-provider `.agents/skills/` (project scope) or `~/.agents/skills/` (user scope) — the paths codex-rs natively scans (`codex-rs/core-skills/src/loader.rs`). The legacy `~/.codex/skills/` home dir is deprecated and pruned on deploy: writing both it and `.agents/skills/` made codex list every kernel skill twice (`/aiwg-regenerate` etc.), since codex-rs scans both. `.codex/commands/` also deploys at project scope for operator visibility, but Codex commands are a static built-in enum in codex-rs and these files are not auto-scanned by the loader; AGENTS.md is the discovery bridge per ADR-1. Reference: `src/smiths/platform-paths.ts:23`.
95
96
  - **Copilot**: Agents use `.agent.md` format (Markdown + YAML frontmatter). Commands deploy as prompt files (`.github/prompts/`). Rules deploy as path-scoped instructions (`.github/instructions/`)
96
97
  - **Warp**: Agents and commands are also aggregated into `WARP.md` for single-file context loading
97
98
  - **Windsurf**: Agents are aggregated into `AGENTS.md` at project root
98
99
  - **OpenClaw**: All artifacts deploy to home directory (`~/.openclaw/`). First provider to support behaviors (`~/.openclaw/behaviors/`)
99
- - **Hermes**: MCP sidecar architecture (`Hermes MCP AIWG`). Commands reach AIWG via `mcp_aiwg_command_run` (allow-listed). Standard skills (~385) live under `~/.hermes/skills/.aiwg/` and are recursively discovered; kernel skills (~9) live at the top level and are protected from the Curator (v0.12.0+) via the `.bundled_manifest`. The MCP server has ~12 core tools by default; ~45 additional via `AIWG_MCP_TOOLSETS=<csv>`. See `docs/integrations/hermes-quickstart.md`.
100
+ - **Hermes**: Integrates like Claude Code and Codex — file-based deploy + `aiwg discover`/`aiwg show` CLI + AGENTS.md/.hermes.md bridge (Discover-First Protocol). **MCP is optional**: AIWG's MCP server is a global hook any provider may use, but Hermes does not require it (validated v2026.5.13, #1527). When MCP is enabled, commands reach AIWG via `mcp_aiwg_command_run` (allow-listed) and the server exposes 16 core tools by default (45 more via `AIWG_MCP_TOOLSETS=<csv>`). Standard skills (~385) live under `~/.hermes/skills/.aiwg/` (recursively discovered) and are also reachable through the capability index without file deploy; kernel skills (~9) live at the top level, protected from the Curator (v0.12.0+) via the `.bundled_manifest`. Rules are inlined into AGENTS.md as compressed `### Rule:` directives, with full bodies reachable through `aiwg show rule <name>` even when MCP is disabled. Broader MCP modernization is tracked in #1533. See `docs/integrations/hermes-quickstart.md`.
101
+ - **OpenHuman** (tinyhumansai): OSS personal-AI runtime (Rust core + Tauri desktop), AIWG-convention-aware out of the box — ships `.agents/`, `AGENTS.md`, `.claude/`, `.codex/`. Kernel skills install **globally like OpenClaw** to `~/.openhuman/skills/` (ungated user-scope native scan via `ops_discover.rs`, one-level — exactly what the app's Skills library surfaces), standard skills sequestered under `~/.openhuman/.aiwg/skills/` for index-driven discovery. Markdown personas stay **workspace-scoped** at `.agents/agents/` (consumed by the coding hosts OpenHuman drives — `claude_code`/`factory`), and commands/rules aggregate into the workspace `AGENTS.md` bridge. The project-scope trust marker is no longer written — user-scope is ungated (#1553). The native agent harness (TOML specialists) is an opt-in Tier-2 surface (#1559). Induction epic #1552; see `docs/integrations/openhuman-quickstart.md` (#1558).
100
102
  - **Omnius** (first-party integrator): Ships AIWG embedded inside the Omnius autonomous coding agent runtime — no separate `aiwg use` step required. `npm i -g omnius` installs both. AIWG skills, agents, and rules are reachable through `aiwg discover` from inside Omnius sessions and through Omnius's REST (`/v1/aiwg/*`) and MCP bridges. Treat Omnius like any AIWG-aware host: the `skill-discovery`, `delivery-policy`, `human-authorization`, and `anti-laziness` rules all apply unchanged. See https://www.npmjs.com/package/omnius.
101
103
 
102
104
  ## Writing Principles
@@ -681,3 +683,18 @@ Before pushing a version tag:
681
683
  - PATCH resets each month
682
684
  - Tag format: `vYYYY.M.PATCH` (e.g., `v2026.1.5`)
683
685
  - See `@docs/contributing/versioning.md` for full details
686
+
687
+ <!-- AIWG:claude-md-hook:start -->
688
+
689
+ # AIWG
690
+
691
+ @AIWG.md
692
+
693
+ <!--
694
+ This block is managed by `aiwg regenerate` and `aiwg use`.
695
+ Operator content above and below this block is preserved on regenerate.
696
+ To change AIWG.md content, edit .aiwg/AIWG.md (the normalized source)
697
+ then run `aiwg regenerate`.
698
+ -->
699
+
700
+ <!-- AIWG:claude-md-hook:end -->
package/README.md CHANGED
@@ -11,6 +11,9 @@ npm i -g aiwg # install globally
11
11
  aiwg use sdlc # deploy SDLC framework
12
12
  ```
13
13
 
14
+ macOS users: if npm fails with `EACCES` under `/usr/local/lib/node_modules`,
15
+ use the [macOS Install Guide](docs/getting-started/macos-install.md).
16
+
14
17
  [![npm version](https://img.shields.io/npm/v/aiwg/latest?label=npm&color=CB3837&logo=npm&style=flat-square)](https://www.npmjs.com/package/aiwg)
15
18
  [![npm downloads](https://img.shields.io/npm/dm/aiwg?color=CB3837&logo=npm&style=flat-square)](https://www.npmjs.com/package/aiwg)
16
19
  [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg?style=flat-square)](LICENSE)
@@ -30,6 +33,34 @@ aiwg use sdlc # deploy SDLC framework
30
33
 
31
34
  ## Installation Troubleshooting
32
35
 
36
+ ### macOS npm `EACCES`
37
+
38
+ If `npm install -g aiwg` fails with `EACCES` while writing to
39
+ `/usr/local/lib/node_modules/aiwg`, npm is using a system-owned global install
40
+ directory. The recommended Mac path is Node 24 through `nvm`, then:
41
+
42
+ ```bash
43
+ npm install -g aiwg
44
+ aiwg --version
45
+ ```
46
+
47
+ If Node is already installed and you need a quick recovery, use npm's current
48
+ user-owned prefix guidance:
49
+
50
+ ```bash
51
+ npm config set prefix ~/.local
52
+ echo 'PATH="$HOME/.local/bin:$PATH"' >> ~/.profile
53
+ echo 'source ~/.profile' >> ~/.zprofile
54
+ source ~/.profile
55
+ npm install -g aiwg
56
+ ```
57
+
58
+ See [macOS Install Guide](docs/getting-started/macos-install.md) for the full
59
+ walkthrough. Avoid `sudo npm install -g aiwg` as the default fix; it can create
60
+ root-owned npm files that break later upgrades.
61
+
62
+ ### `aiwg` command not found
63
+
33
64
  If `aiwg` is not found after `npm i -g aiwg`, the npm global `bin` directory is not on your `PATH`. Confirm and fix:
34
65
 
35
66
  ```bash
@@ -1501,7 +1532,7 @@ Research foundation: Recursive Language Models (Zhang, Kraska, Khattab — MIT C
1501
1532
 
1502
1533
  ## Research Foundations
1503
1534
 
1504
- AIWG's architecture is grounded in peer-reviewed research across cognitive science, multi-agent systems, software engineering, and AI safety. Full corpus: [research-papers](https://github.com/jmagly/research-papers) (168 papers). Entries ordered highest to lowest GRADE evidence quality within each category.
1535
+ AIWG's architecture is grounded in peer-reviewed research across cognitive science, multi-agent systems, software engineering, and AI safety. Reference summaries live in `docs/references/` (REF-NNN entries), ordered highest to lowest GRADE evidence quality within each category.
1505
1536
 
1506
1537
  ### Cognitive Foundations
1507
1538
 
@@ -46,8 +46,9 @@ Before choosing the loop mechanism, detect the active provider via `aiwg runtime
46
46
  | Provider capability | Route | Notes |
47
47
  |---|---|---|
48
48
  | Provider with native `/goal` (Codex, Claude Code) | Delegate the in-session loop to `/goal` | Convert the task plus completion criterion into a standing goal. If a programmatic goal tool is unavailable, print the exact `/goal "..."` command for the operator instead of emulating a duplicate loop. |
49
+ | Provider with native dynamic orchestration (Claude Code Workflow tool) | In-session multi-agent fan-out MAY delegate to the native orchestration tool | AIWG retains audit, gates, best-output selection, and cross-session durability. The native tool is in-session/background scoped — NOT a detached daemon — so detached/resume-after-session work stays AIWG-native (see external row). |
49
50
  | Other providers | AIWG internal loop discipline | Keep the existing visible act/verify/adapt cycle in the current session. |
50
- | Explicit external/background request | `agent-loop-ext` / `ralph-external` | External crash-resilient loops stay AIWG-native because `/goal` is in-session only. |
51
+ | Explicit external/background request | `agent-loop-ext` / `ralph-external` | Detached, crash-resilient, resume-after-session-ends work stays AIWG-native: `/goal` is in-session, and the Claude Code Workflow tool is session-scoped. Codex has no core `/workflow` (verified, `codex-cli 0.135.0`, #1535). |
51
52
 
52
53
  Native `/goal` mapping:
53
54
 
@@ -59,6 +60,8 @@ When completion is omitted, run `infer-completion-criteria` first and include th
59
60
 
60
61
  Research and decision record: `.aiwg/research/codex-goal-integration.md`, `.aiwg/architecture/adr-codex-goal-routing.md`. The Claude Code dialect is the same operator-facing form: `/goal "<task>; completion: <criterion>"`.
61
62
 
63
+ External/orchestration routing (provider-native `/workflow`): `.aiwg/research/provider-workflow-integration.md`, `.aiwg/architecture/adr-workflow-routing.md`. Verified against `codex-cli 0.135.0` (#1535): Codex has no core `/workflow`; Claude Code's Workflow tool is the in-session orchestration analog. Detached/cross-session work stays AIWG-native (`ralph-external`).
64
+
62
65
  ### Default: Internal/In-Session Loop
63
66
 
64
67
  Use the internal loop when the user says `agent-loop`, `al`, `ralph`, `loop`, `iterate`, `keep trying`, `fix until green`, `address issues`, `handle all listed issues`, or supplies an iteration bound such as `--iterations 200` without explicit external wording.
@@ -325,6 +325,21 @@ When a user asks "what command should I use for X?", follow this protocol:
325
325
  | "I want to use behaviors" | claude-code | AIWG emulation — `aiwg add-behavior` + daemon; Claude Code has hooks but not full behaviors |
326
326
  | "Does Cursor support MCP?" | cursor | Yes — native MCP support. Configure with `aiwg mcp install cursor` |
327
327
 
328
+ ### Orchestration & loop routing
329
+
330
+ For "iterate until done" / multi-agent orchestration / Mission requests, the canonical routing surface is the **agent-loop Step 0 table** (`agentic/code/addons/agent-loop/skills/agent-loop/SKILL.md`), backed by `.aiwg/architecture/adr-workflow-routing.md`. Summary:
331
+
332
+ | User Request | Provider | Correct Answer |
333
+ |-------------|----------|----------------|
334
+ | "iterate on this until tests pass" (in-session) | claude-code / codex | Native `/goal "<task>; completion: <criterion>"` (#1451/#1469) — in-session loop |
335
+ | "fan out multiple agents in-session" | claude-code | MAY delegate the mechanism to the native Workflow tool; AIWG retains audit/gates/best-output/durability |
336
+ | "fan out multiple agents in-session" | codex | No core `/workflow` (it's plugin-provided, #1535); use the AIWG-owned `/aiwg-mission` or `aiwg mc dispatch` |
337
+ | "launch a Mission" / dynamic orchestration | any | `/aiwg-mission` (Codex) or `aiwg mc dispatch`; AIWG-owned durable conductor |
338
+ | "run detached/background/crash-resilient" | any | AIWG-native external route (`agent-loop-ext` / `ralph-external`) — native primitives are session-scoped |
339
+ | "coordinate Codex AND Claude agents" (cross-stack) | any | Cross-stack Mission (#1546) — one AIWG conductor dispatches workers to executors advertising the target `runtime:<name>` (e.g. `runtime:codex`) via the `serve` registry (routeMission) |
340
+
341
+ **Invariant:** whatever drives the worker mechanism, AIWG owns activity-log, gates, best-output selection, checkpoint/resume durability, reproducibility, and cost. Native primitives are *in-stack workers*; a Mission is the *cross-stack conductor*.
342
+
328
343
  ## Cross-Provider Diagnostic
329
344
 
330
345
  When asked to diagnose capability gaps (e.g., "how does my setup compare to Claude Code?"):
@@ -31,7 +31,30 @@
31
31
  "rules": "rules/",
32
32
  "skills": "skills/",
33
33
  "templates": "templates/",
34
- "prompts": "prompts/"
34
+ "prompts": "prompts/",
35
+ "workflow": "workflow/"
36
+ },
37
+ "workflow": {
38
+ "description": "Core AIWG workflow metalanguage (apiVersion: workflow.aiwg.io/v1) — declarative spec for capabilities, playbooks, inventories, targets, gates, roles, and extensions. Lifted from ops-complete to a core primitive so any framework can author workflows.",
39
+ "schemas": "workflow/schemas/",
40
+ "docs": "workflow/docs/",
41
+ "examples": "workflow/examples/",
42
+ "kinds": [
43
+ "WorkflowCapability",
44
+ "WorkflowPlaybook",
45
+ "WorkflowInventory",
46
+ "WorkflowTarget",
47
+ "WorkflowGate",
48
+ "WorkflowRole",
49
+ "WorkflowExtension"
50
+ ],
51
+ "legacy_apiversion_aliases": {
52
+ "ops.aiwg.io/v1": "workflow.aiwg.io/v1",
53
+ "sys.ops.aiwg.io/v1": "sys.workflow.aiwg.io/v1",
54
+ "it.ops.aiwg.io/v1": "it.workflow.aiwg.io/v1",
55
+ "dev.ops.aiwg.io/v1": "dev.workflow.aiwg.io/v1",
56
+ "stream.ops.aiwg.io/v1": "stream.workflow.aiwg.io/v1"
57
+ }
35
58
  },
36
59
  "consolidation": {
37
60
  "strategy": "index-with-links",
@@ -246,8 +246,8 @@ If none of those apply: **continue**.
246
246
  - @$AIWG_ROOT/agentic/code/addons/aiwg-utils/rules/context-budget.md — Aggressive budgeting when `AIWG_CONTEXT_WINDOW` is set
247
247
  - @$AIWG_ROOT/agentic/code/addons/aiwg-utils/rules/skill-discovery.md — Rule 0: classify new directives
248
248
  - @$AIWG_ROOT/agentic/code/frameworks/sdlc-complete/rules/anti-laziness.md — Rule 6: 3-attempts escalation
249
- - REF-909 (Anthropic — *Effective Harnesses for Long-Running Agents*) — initializer-agent / coding-agent pattern, progress files. Induction: [roctinam/research-papers#615](https://git.integrolabs.net/roctinam/research-papers/issues/615). Source URL: https://www.anthropic.com/engineering/effective-harnesses-for-long-running-agents
250
- - REF-910 (Anthropic — *Compaction*) — auto-compact mechanics, Compact Instructions, what survives. Induction: [roctinam/research-papers#616](https://git.integrolabs.net/roctinam/research-papers/issues/616). Source URL: https://platform.claude.com/docs/en/build-with-claude/compaction
249
+ - REF-909 (Anthropic — *Effective Harnesses for Long-Running Agents*) — initializer-agent / coding-agent pattern, progress files. Source URL: https://www.anthropic.com/engineering/effective-harnesses-for-long-running-agents
250
+ - REF-910 (Anthropic — *Compaction*) — auto-compact mechanics, Compact Instructions, what survives. Source URL: https://platform.claude.com/docs/en/build-with-claude/compaction
251
251
  - REF-122 (Verma — *Active Context Compression / Focus Agent*) — aggressive vs passive compression discipline (22.7% vs 6%)
252
252
  - REF-128 (Zylos Research — *Context Window Management Strategies*) — effective context is 30-40% smaller than advertised
253
253
  - Commissioning anchor: [roctinam/aiwg#1348](https://git.integrolabs.net/roctinam/aiwg/issues/1348)
@@ -0,0 +1,68 @@
1
+ ---
2
+ namespace: aiwg
3
+ name: aiwg-mission
4
+ platforms: [all]
5
+ kernel: true
6
+ description: Launch an AIWG Mission — durable, audited dynamic agent orchestration toward a completion criterion. AIWG owns the conductor (activity-log, gates, best-output, checkpoint/resume, cost); native primitives drive worker mechanism. Surfaces as /aiwg-mission in Codex (AIWG-owned, no plugin dependency).
7
+ ---
8
+
9
+ # AIWG Mission
10
+
11
+ You are launching (or participating in) an **AIWG Mission** — AIWG's dynamic, durable, audited agent orchestration. A Mission decomposes a goal into worker cycles, runs them toward a measurable completion criterion, and aggregates the result, while AIWG owns the bookkeeping and gates regardless of which agent stack each worker runs on.
12
+
13
+ This is an **AIWG-specific kernel capability**. On Codex it surfaces as `/aiwg-mission`, deployed by AIWG to `~/.codex/prompts/` — it is **AIWG-owned**, not the plugin-provided `/workflow` an arbitrary Codex install may or may not have (`/workflow` is not a core Codex primitive — see `.aiwg/research/provider-workflow-integration.md`).
14
+
15
+ ## Mission vs Flow vs in-stack primitive
16
+
17
+ - **Mission** (this skill) = *dynamic* orchestration. The shape emerges at run time from the goal. Cross-stack capable.
18
+ - **Flow** = a *pre-established* declarative YAML sequence (`flow.aiwg.io/v1`); use `aiwg discover` to find a matching Flow before improvising a Mission.
19
+ - **In-stack primitive** (Codex `/goal`, Claude's Workflow tool) = orchestrates *within one stack's process/turn*. A Mission may dispatch workers **to** these; they do not replace the Mission conductor.
20
+
21
+ ## When this fires
22
+
23
+ Natural-language triggers:
24
+
25
+ - "launch a mission" / "start an AIWG mission"
26
+ - "orchestrate this across agents"
27
+ - "fan this out to several agents and aggregate"
28
+ - "spawn workers to do X until Y"
29
+ - "run a long unattended orchestration"
30
+ - "coordinate Codex and Claude agents on this" (cross-stack — see #1546)
31
+
32
+ Non-triggers (route elsewhere):
33
+
34
+ - A single focused task → just do it (no orchestration overhead; see `god-session` / `subagent-scoping`).
35
+ - A pre-established repeatable sequence → find the **Flow** via `aiwg discover` (e.g. `flow-release`, `flow-deploy-to-production`).
36
+ - An in-session "iterate until condition" on one stack → the provider-native `/goal` (Codex, Claude Code) already routes for that (#1451/#1469).
37
+ - "Address open issues" → the `address-issues` skill (which may itself run as a Mission).
38
+
39
+ ## How to run a Mission
40
+
41
+ 1. **State the completion criterion measurably** (per the `vague-discretion` rule). "good enough" is not a criterion; "all tests pass and CI green", "score ≥ 85", "every flagged finding verified" are. If the user's goal is vague, extract a checkable criterion first.
42
+
43
+ 2. **Right-size + decompose.** Break the goal into independently-verifiable worker cycles (`subagent-scoping`). Decide single-stack vs cross-stack:
44
+ - **Single-stack** (default): workers run on the current stack. Use this stack's native primitive for in-session fan-out where available; otherwise AIWG's external loop.
45
+ - **Cross-stack** (#1546): when the operator wants heterogeneous stacks (e.g. Claude conductor → Codex workers), dispatch worker cycles to executors advertising the target `stack:<name>` capability via AIWG's `serve` executor-registry. The conductor stays AIWG-owned.
46
+
47
+ 3. **Dispatch.** For durable/detached/unattended Missions use AIWG's external route (`aiwg mc dispatch` / `ralph-external`) so the Mission survives the session ending. For in-session orchestration, the native primitive may drive the *mechanism* — but AIWG still owns everything in step 4.
48
+
49
+ 4. **Retain ownership (non-negotiable, identical across stacks).** Whatever drives the worker mechanism, AIWG owns:
50
+ - activity-log entries (per the `activity-log` rule)
51
+ - issue-thread comments / progress
52
+ - human-authorization + threat gates (per `human-authorization`)
53
+ - best-output selection across cycles
54
+ - crash-resilient checkpoint/resume (durability)
55
+ - reproducibility + cost tracking
56
+
57
+ 5. **Converge + report.** Run cycles until the completion criterion is met (with a `max-cycles` escape hatch), select the best output, and report what each worker did and the aggregated result. Apply the anti-laziness recovery protocol (PAUSE→DIAGNOSE→ADAPT→RETRY→ESCALATE) rather than abandoning on failure.
58
+
59
+ ## Discover before improvising
60
+
61
+ Before hand-rolling a Mission, run `aiwg discover "<the goal>"` — a curated Flow or skill may already exist (the `skill-discovery` rule). A Mission is for genuinely *dynamic* orchestration where no pre-established Flow fits.
62
+
63
+ ## References
64
+
65
+ - `.aiwg/architecture/adr-workflow-routing.md` — routing + cross-stack amendment
66
+ - `.aiwg/research/provider-workflow-integration.md` — why Codex `/workflow` is not core (#1535)
67
+ - #1534 (epic), #1544 (this command), #1546 (cross-stack Missions), #1536 (Missions/Flows naming)
68
+ - `aiwg mc` (mission-control) — the durable dispatch surface
@@ -0,0 +1,118 @@
1
+ # AIWG Flows Metalanguage (core primitive)
2
+
3
+ `apiVersion: flow.aiwg.io/v1` (forward) — `workflow.aiwg.io/v1` accepted for back-compat
4
+
5
+ > **Naming (#1536):** this declarative spec defines **Flows** (pre-established,
6
+ > authored sequences). The complementary **dynamic** orchestration concept is a
7
+ > **Mission** (`mc` mission-control). "Workflow" was the original name and
8
+ > collides with provider `/workflow` commands, so AIWG uses **Flows + Missions**.
9
+ > Wire identifiers are dual-recognized — `flow.aiwg.io/v1` + `Flow*` kinds are
10
+ > the forward spelling; `workflow.aiwg.io/v1` + `Workflow*` remain valid (mirrors
11
+ > the existing `ops.aiwg.io/v1` alias). No authored document breaks; the
12
+ > `workflow.*` spelling is deprecated for removal no earlier than the release
13
+ > after this alias ships. See `.aiwg/architecture/adr-workflow-naming.md`.
14
+
15
+ A declarative YAML spec for composing automation work. Any AIWG framework, addon, or extension can author workflows in this language and route them through the shared executor. The metalanguage is a **core utility primitive** — it ships in `aiwg-utils` so every install has access to it, regardless of which frameworks are deployed.
16
+
17
+ ## What this replaces
18
+
19
+ This metalanguage was originally authored as `ops.aiwg.io/v1` under `ops-complete`. The shape — capability + playbook + inventory + target + gate — is generic; the `Ops` label was a packaging artifact. Lifting the spec to `aiwg-utils` makes it usable by any domain (release validation, content production, research orchestration, CI/CD) without forcing the consumer to depend on ops-complete.
20
+
21
+ `ops.aiwg.io/v1` documents still parse via apiVersion alias (see `docs/migration-from-ops.md`); no existing playbook breaks.
22
+
23
+ ## The 7 kinds
24
+
25
+ | Kind | Purpose | Schema |
26
+ |---|---|---|
27
+ | **WorkflowCapability** | A reusable named verb with declared inputs, outputs, verification command, and executor agent | [schemas/workflow-capability.schema.json](schemas/workflow-capability.schema.json) |
28
+ | **WorkflowPlaybook** | A DAG of capability invocations against a target inventory, with retry / depends_on / gates | [schemas/workflow-playbook.schema.json](schemas/workflow-playbook.schema.json) |
29
+ | **WorkflowInventory** | Declarative target set (hosts, providers, environments, anything addressable) | [schemas/workflow-inventory.schema.json](schemas/workflow-inventory.schema.json) |
30
+ | **WorkflowTarget** | A single addressable resource referenced from inventory | [schemas/workflow-target.schema.json](schemas/workflow-target.schema.json) |
31
+ | **WorkflowGate** | A pause point for human-in-the-loop authorization or judgment | [schemas/workflow-gate.schema.json](schemas/workflow-gate.schema.json) |
32
+ | **WorkflowRole** | A bundle of capabilities scoped to a role identity for permission boundaries | [schemas/workflow-role.schema.json](schemas/workflow-role.schema.json) |
33
+ | **WorkflowExtension** | A domain-specific extension declaring its own apiVersion namespace, kinds, and capability bundle | [schemas/workflow-extension.schema.json](schemas/workflow-extension.schema.json) |
34
+
35
+ ## Authoring model
36
+
37
+ Three layers from most reusable to most specific:
38
+
39
+ ```
40
+ [ core metalanguage ] apiVersion: workflow.aiwg.io/v1 ← lives in aiwg-utils (this spec)
41
+
42
+ [ domain extension ] apiVersion: <domain>.workflow.aiwg.io/v1 ← e.g. ops, validation, research
43
+
44
+ [ user instance ] a specific Capability or Playbook in a project ← lives in .aiwg/workflow/
45
+ ```
46
+
47
+ The core metalanguage defines the *shape* of capabilities, playbooks, inventories, etc. A domain extension declares its own `apiVersion` namespace and contributes its own capability library. A user instance is a single capability or playbook file in a project's `.aiwg/workflow/` directory.
48
+
49
+ ## Where files live
50
+
51
+ | Layer | Location |
52
+ |---|---|
53
+ | Core schemas (this addon) | `agentic/code/addons/aiwg-utils/workflow/schemas/` |
54
+ | Core docs | `agentic/code/addons/aiwg-utils/workflow/docs/` |
55
+ | Domain extension (e.g. `ops`) | `agentic/code/frameworks/ops-complete/capabilities/` |
56
+ | Domain extension (e.g. `validation`) | `agentic/code/frameworks/validation-complete/capabilities/` |
57
+ | User instance (per project) | `.aiwg/workflow/capabilities/` and `.aiwg/workflow/playbooks/` |
58
+
59
+ ## Executor contract
60
+
61
+ A single agent satisfies the executor contract for every workflow kind, regardless of domain. Today that agent is `ops-runbook-executor` (under ops-complete) — it will be renamed/lifted to `workflow-executor` as part of the lift (see migration plan).
62
+
63
+ The contract:
64
+
65
+ 1. **Resolve**: load the playbook, resolve every `capability:` reference, validate each capability against its schema.
66
+ 2. **Plan**: build the step DAG from `depends_on` edges; reject cycles.
67
+ 3. **Bind**: bind playbook `vars` and per-step `inputs` into capability inputs; resolve `from: <step-id>.<output>` references after step completion.
68
+ 4. **Execute**: for each ready step, dispatch to the capability's `agent`. Capture stdout/stderr/exit-status. If `verification.command` is present, run it and compare against `verification.expect`.
69
+ 4a. **Fan-out** (`fanout` step, #1547): when a step carries a `fanout` block instead of a `capability`, dispatch each `fanout.agents[*]` capability — concurrently for `strategy: parallel` (a review panel), or chained (each agent sees the prior output) for `strategy: pipeline`. Await all panel agents, collect their structured outputs, then dispatch `fanout.synthesize` with the panel outputs as input; the synthesis result is the step's output for downstream `from:`/`depends_on` consumers. The retained-ownership invariant applies **across the whole panel**: audit every panel agent + the synthesis (step 7), honor gates/authorization, and apply best-output selection over the panel. This is the declarative spelling of the multi-agent documentation pattern (Primary → Parallel Reviewers → Synthesizer); see `.aiwg/architecture/adr-flow-agentic-steps.md`. A step MUST NOT set both `capability` and `fanout`.
70
+ 5. **Gate**: when a `kind: gate` step is reached, pause; surface the gate's `description` and `inputs` to the human; resume when the gate is acknowledged.
71
+ 6. **Retry**: respect each step's `retry.limit` and `retry.on` policy.
72
+ 7. **Audit**: append every step outcome (start, end, verification result, outputs, gate decisions) to `.aiwg/workflow/runs/<run-id>/audit.jsonl`.
73
+ 8. **Report**: at playbook completion, emit a structured report to `.aiwg/workflow/runs/<run-id>/report.md`.
74
+
75
+ The executor MUST NOT mutate the playbook or its capabilities. It MUST honor `idempotent: true` (re-runs against the same target produce the same outcome). It MUST refuse to execute capabilities whose `target_requirements` are unmet (missing OS, missing binary, missing access).
76
+
77
+ ## Cross-stack Missions (#1546)
78
+
79
+ A **Mission** (dynamic orchestration) can fan worker cycles across *heterogeneous agentic stacks* — e.g. a Claude-conductor Mission dispatching a worker (or a `fanout` panel agent) to a **Codex** executor, or a single Mission spanning multiple stacks under one durable conductor. This needs **no new transport**: the `serve` executor registry already routes by capability.
80
+
81
+ - **Convention:** an executor advertises its stack via the established `runtime:<name>` capability — `runtime:codex`, `runtime:claude-code` (already in the `serve` fixtures). Do **not** invent a parallel `stack:<name>` token.
82
+ - **Dispatch:** the conductor selects a worker's stack with an `executor_filter` on that capability; `src/serve/agent-router.ts` `routeMission()` / `ExecutorRegistry.pickByFilter()` pick a connected executor advertising **all** filtered capabilities. A `fanout` step's panel agents may each target a different `runtime:<name>` — the YAML `fanout` is the cross-stack authoring surface.
83
+ - **Invariant (across stacks):** the conductor retains activity-log, human-authorization/threat gates, best-output selection, checkpoint/resume durability, reproducibility, and cost — regardless of which stack each worker ran on. The per-stack executor drives the *worker mechanism* only.
84
+
85
+ See `.aiwg/architecture/adr-workflow-routing.md` (cross-stack amendment).
86
+
87
+ ## Apiversion aliasing
88
+
89
+ For backward compatibility, the executor accepts the following apiVersion equivalences:
90
+
91
+ | Legacy | Resolves to |
92
+ |---|---|
93
+ | `ops.aiwg.io/v1` | `workflow.aiwg.io/v1` |
94
+ | `sys.ops.aiwg.io/v1` | `sys.workflow.aiwg.io/v1` |
95
+ | `it.ops.aiwg.io/v1` | `it.workflow.aiwg.io/v1` |
96
+ | `dev.ops.aiwg.io/v1` | `dev.workflow.aiwg.io/v1` |
97
+ | `stream.ops.aiwg.io/v1` | `stream.workflow.aiwg.io/v1` |
98
+
99
+ Equivalence is bidirectional for the v1 line. The aliasing layer is removed when `ops` and its extensions are migrated to native `workflow.*` apiVersions (target: release after the lift ships).
100
+
101
+ ## Why this lives in aiwg-utils
102
+
103
+ - **Universal**: every AIWG install carries `aiwg-utils`; the workflow metalanguage is available without installing a domain framework first.
104
+ - **No domain bias**: the schemas describe shape only — they say nothing about hosts, services, certs, or providers. Domain semantics live in domain extensions.
105
+ - **One executor, many domains**: ops, validation, and any future domain share the same DAG runner, the same audit format, the same gate semantics.
106
+
107
+ ## What's NOT in scope
108
+
109
+ - The executor implementation. The agent that runs playbooks lives outside the spec (currently `ops-runbook-executor`, lifted later).
110
+ - Domain-specific capability libraries. Each domain authors its own. This addon ships zero capabilities — only the spec.
111
+ - Per-language SDKs / bindings. The spec is the authoritative contract; bindings can be written but aren't required.
112
+
113
+ ## See also
114
+
115
+ - `docs/overview.md` — narrative tour of the metalanguage with worked examples
116
+ - `docs/migration-from-ops.md` — how existing `ops.aiwg.io/v1` documents migrate
117
+ - `examples/` — minimal authored examples for each kind
118
+ - ops-complete (`agentic/code/frameworks/ops-complete/`) — the first domain consumer; will be migrated to native `workflow.*` apiVersion in a follow-up
@@ -0,0 +1,142 @@
1
+ # Migration: `ops.aiwg.io/v1` → `workflow.aiwg.io/v1`
2
+
3
+ The workflow metalanguage (this addon) is the lifted form of what shipped originally as `ops.aiwg.io/v1` under `ops-complete`. Existing playbooks and capabilities continue to work via apiVersion aliasing. This doc describes the migration path for consumers who want to author against the new namespace directly.
4
+
5
+ ## What changed
6
+
7
+ | Aspect | Before | After |
8
+ |---|---|---|
9
+ | Where the spec lives | `agentic/code/frameworks/ops-complete/schemas/metalanguage/` | `agentic/code/addons/aiwg-utils/workflow/schemas/` |
10
+ | Schema names | `ops-capability.schema.json`, etc. | `workflow-capability.schema.json`, etc. |
11
+ | `apiVersion` | `ops.aiwg.io/v1` (and `<ext>.ops.aiwg.io/v1` for extensions) | `workflow.aiwg.io/v1` (and `<ext>.workflow.aiwg.io/v1`) |
12
+ | `kind` | `OpsCapability`, `OpsPlaybook`, … | `WorkflowCapability`, `WorkflowPlaybook`, … |
13
+ | Schema `$id` URL | `https://aiwg.io/schemas/ops/v1/ops-X.schema.json` | `https://aiwg.io/schemas/workflow/v1/workflow-X.schema.json` |
14
+ | Executor agent | `ops-runbook-executor` | `workflow-executor` (alias of the same agent during the migration window) |
15
+ | Carrying addon | `ops-complete` (heavyweight) | `aiwg-utils` (universal core) |
16
+
17
+ What did NOT change:
18
+
19
+ - Field names within each kind's `spec` block (same `inputs`, `outputs`, `verification`, `target_requirements`, `depends_on`, `gate.description`, …).
20
+ - Capability semantics. A `verify-tls-expiry` capability authored against the ops apiVersion behaves identically when migrated.
21
+ - Inventory/target structure.
22
+ - Audit trail format.
23
+
24
+ The lift is a rename pass and a relocation. No field-level semantics change.
25
+
26
+ ## Apiversion aliasing (transitional)
27
+
28
+ While both apiVersions exist, the executor accepts these equivalences for the v1 line:
29
+
30
+ | Legacy apiVersion | Resolves to |
31
+ |---|---|
32
+ | `ops.aiwg.io/v1` | `workflow.aiwg.io/v1` |
33
+ | `sys.ops.aiwg.io/v1` | `sys.workflow.aiwg.io/v1` |
34
+ | `it.ops.aiwg.io/v1` | `it.workflow.aiwg.io/v1` |
35
+ | `dev.ops.aiwg.io/v1` | `dev.workflow.aiwg.io/v1` |
36
+ | `stream.ops.aiwg.io/v1` | `stream.workflow.aiwg.io/v1` |
37
+
38
+ A document carrying the legacy apiVersion validates against the legacy schema and is normalized to the workflow apiVersion before execution. Outputs and audit-trail entries carry the workflow apiVersion regardless of input.
39
+
40
+ The legacy schemas continue to live under `ops-complete` for the v1 line's lifetime. When the v2 line ships, only `workflow.aiwg.io/v2` exists and `ops.aiwg.io/v1` documents will need explicit migration to v2.
41
+
42
+ ## Migrating an existing capability
43
+
44
+ Mechanical rewrite:
45
+
46
+ ```diff
47
+ - apiVersion: ops.aiwg.io/v1
48
+ - kind: OpsCapability
49
+ + apiVersion: workflow.aiwg.io/v1
50
+ + kind: WorkflowCapability
51
+ metadata:
52
+ name: check-tls-expiry
53
+ labels:
54
+ category: pki
55
+ spec:
56
+ description: Check a TLS certificate's expiry date
57
+ version: "1.0.0"
58
+ inputs:
59
+ - name: hostname
60
+ type: string
61
+ required: true
62
+ # ... rest unchanged
63
+ agent: cert-lifecycle-monitor
64
+ idempotent: true
65
+ verification:
66
+ command: "openssl s_client -connect {{ hostname }}:443 </dev/null | openssl x509 -noout -dates"
67
+ expect: "notAfter="
68
+ ```
69
+
70
+ Two lines change. The rest of the document is untouched.
71
+
72
+ If the capability lives inside a domain extension (`<ext>.ops.aiwg.io/v1`), the migration is:
73
+
74
+ ```diff
75
+ - apiVersion: sys.ops.aiwg.io/v1
76
+ - kind: OpsCapability
77
+ + apiVersion: sys.workflow.aiwg.io/v1
78
+ + kind: WorkflowCapability
79
+ ```
80
+
81
+ ## Migrating an existing playbook
82
+
83
+ Same shape — change the apiVersion line and the kind line. Step references to capabilities continue to resolve by name; the executor looks across all registered extension namespaces.
84
+
85
+ ```diff
86
+ - apiVersion: ops.aiwg.io/v1
87
+ - kind: OpsPlaybook
88
+ + apiVersion: workflow.aiwg.io/v1
89
+ + kind: WorkflowPlaybook
90
+ metadata:
91
+ name: rotate-tls-cert
92
+ spec:
93
+ inventory: production-web-tier
94
+ targets:
95
+ groups: [edge]
96
+ steps:
97
+ - id: pre-check
98
+ capability: check-tls-expiry # still resolves by capability name
99
+ # ... rest unchanged
100
+ ```
101
+
102
+ ## Migrating an inventory / target / gate / role / extension
103
+
104
+ Pattern repeats — change apiVersion and kind, nothing else.
105
+
106
+ | Legacy kind | New kind |
107
+ |---|---|
108
+ | `OpsCapability` | `WorkflowCapability` |
109
+ | `OpsPlaybook` | `WorkflowPlaybook` |
110
+ | `OpsInventory` | `WorkflowInventory` |
111
+ | `OpsTarget` | `WorkflowTarget` |
112
+ | `OpsGate` | `WorkflowGate` |
113
+ | `OpsRole` | `WorkflowRole` |
114
+ | `OpsExtension` | `WorkflowExtension` |
115
+
116
+ ## When to migrate
117
+
118
+ - **New work**: author against `workflow.aiwg.io/v1` directly. No reason to use the legacy apiVersion for new capabilities or playbooks.
119
+ - **Existing ops-complete capabilities**: stay on `ops.aiwg.io/v1` until the next routine touch (capability update, schema change, new extension version). Aliasing means there's no urgency.
120
+ - **`ops-complete` itself**: a single coordinated migration PR renames the apiVersion across all capabilities/playbooks and updates `manifest.json`. Plan to do this once ahead of the v2 schema work, not piecemeal.
121
+
122
+ ## Validation
123
+
124
+ To validate a migrated document against the new schemas:
125
+
126
+ ```bash
127
+ # Using ajv or any JSON Schema validator
128
+ ajv validate \
129
+ -s agentic/code/addons/aiwg-utils/workflow/schemas/workflow-capability.schema.json \
130
+ -d path/to/your-capability.yaml
131
+ ```
132
+
133
+ `aiwg validate-metadata` includes the workflow schemas in its corpus and will flag capability/playbook documents that fail validation.
134
+
135
+ ## Tracking
136
+
137
+ - Spec lift (this work): authored under `agentic/code/addons/aiwg-utils/workflow/`. Schemas, README, overview, this doc.
138
+ - Executor alias (`workflow-executor` → `ops-runbook-executor`): follow-up.
139
+ - `ops-complete` migration to native `workflow.*` apiVersion: follow-up after the executor alias lands.
140
+ - `sdlc-complete/flows/` consolidation onto the workflow metalanguage: follow-up; not part of the initial lift.
141
+
142
+ Track via the planning issue (see release-validation epic comments).