@agimon-ai/doompi-workflow 0.0.1-alpha.21 → 0.0.1-alpha.23

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 (2) hide show
  1. package/README.md +69 -45
  2. package/package.json +11 -9
package/README.md CHANGED
@@ -1,72 +1,96 @@
1
1
  # @agimon-ai/doompi-workflow
2
2
 
3
- **Long work needs edges.**
3
+ Asynchronous workflow discovery, launch, monitoring, control, and terminal-failure recovery for DoomPi.
4
4
 
5
- This package gives Doompi the job graph GitHub Actions users already know: `on:`, `jobs:`,
6
- `needs:`, `steps:`, timeouts, and declared artifacts. Every step names the session it wants,
7
- so implementation can use coding tools while a later release note gets marketing context
8
- and a brand profile. One run does not mean one swollen context window.
5
+ Part of the [DoomPi distribution](https://www.npmjs.com/package/@agimon-ai/doompi).
9
6
 
10
- Workflow is a minor mode. Its tools can be enabled or removed during the session, while
11
- running jobs continue under the boundaries declared by the workflow.
7
+ The integration embeds `@agimon-ai/workflow-mcp`; workflow files describe job dependencies and host-executed steps while DoomPi provides session-scoped tools and TUI surfaces.
12
8
 
13
- This is part of [Doompi](https://www.npmjs.com/package/@agimon-ai/doompi). Most users get
14
- it with the distribution.
9
+ > **Alpha:** workflow and recovery contracts may change between releases.
10
+
11
+ ## Requirements
12
+
13
+ - Node.js 22.19.0 or newer
14
+ - Pi 0.84.2 and Pi TUI 0.84.2
15
15
 
16
16
  ## Install
17
17
 
18
+ DoomPi loads Workflow as core. For standalone Pi:
19
+
18
20
  ```bash
19
- npm install @agimon-ai/doompi-workflow
21
+ pi install npm:@agimon-ai/doompi-workflow
20
22
  ```
21
23
 
22
- ## How it loads
24
+ Enable tools with `SPC w e`, or set `WORKFLOW_MCP_MODE=on` for a non-interactive harness that cannot toggle the minor mode.
23
25
 
24
- Doompi loads the workflow integration as core. It is not a major-mode layer and does not
25
- appear in `.doom/modes.yaml`. The bare package name follows its Pi manifest and loads the
26
- Pi adapter.
26
+ ## Define a workflow
27
27
 
28
- ## Leader
28
+ Create a `*.workflow.yml` file:
29
29
 
30
- - `SPC w w` chooses and launches a workflow.
31
- - `SPC w l` opens running workflows and their controls.
32
- - `SPC w r` recovers a failed workflow.
33
- - `SPC w e` gives the agent workflow tools or takes them back.
30
+ ```yaml
31
+ name: verify
34
32
 
35
- ## Recovery
33
+ jobs:
34
+ test:
35
+ runs-on: ubuntu-latest
36
+ steps:
37
+ - name: Run tests
38
+ run: pnpm test
39
+
40
+ summarize:
41
+ runs-on: ubuntu-latest
42
+ needs: test
43
+ steps:
44
+ - name: Record result
45
+ run: node scripts/write-verification-summary.mjs
46
+ ```
47
+
48
+ `run` commands execute on the host with the workflow process's environment and privileges. Review workflow files as executable code. Runner-specific `interactiveRun` mappings are available for commands that genuinely require a TTY.
49
+
50
+ ## Launch and monitor
51
+
52
+ Core tools are:
53
+
54
+ - `list_workflows`: discover workflows;
55
+ - `launch_workflow`: register and start an asynchronous run;
56
+ - `workflow_run`: inspect or control a run through supported actions.
36
57
 
37
- The recovery picker can see terminal failures from earlier Pi sessions. The
38
- `workflow_run` action `recovery-evidence` reads only terminal registry evidence; status,
39
- tail, and every live control remain scoped to the session that owns the run.
58
+ Launch returns after the run is registered, not after all jobs complete. Use status/follow controls for progress and wait for a terminal notification.
40
59
 
41
- Replay claims the failed record atomically, transfers only `PI_SESSION_ID`, and binds new
42
- controls to the exact run generation that was authorized. Recovery resumes the failed
43
- work; it does not quietly launch a second copy beside it.
60
+ In the TUI, `SPC w w` launches, `SPC w l` manages runs, `SPC w r` opens recovery, and `SPC w e` toggles model-visible tools. The root session can launch; child sessions can inspect the catalog but do not receive an unrestricted workflow factory.
44
61
 
45
- ## Package guidance
62
+ ## Storage, concurrency, and lifecycle
46
63
 
47
- The package ships a root `llms.txt` index. While the parent-only Help mode is active it
48
- contributes `workflow-help`; deactivating Help removes that generated wrapper. The
49
- `workflow-recovery` skill is model-visible only while Workflow mode is active.
64
+ Registry data defaults to `$HOME/.workflow-mcp`; set `WORKFLOW_MCP_HOME` to relocate it. Persisted records contain workflow/run identity, job and step state, ownership, output locations, and recovery evidence. The default concurrency ceiling is five runs.
50
65
 
51
- ## Progress without transcript noise
66
+ Runs embedded directly in the Pi process end with that process. Runs launched through a terminal host can have a different lifetime and remain CLI-manageable. Reconciliation distinguishes stale registry records from live processes; do not assume every run outlives its parent session.
52
67
 
53
- Running workflows appear in a transient task-like list above the editor with the current
54
- step and an animated spinner. Step updates and raw launcher frames stay out of chat. The
55
- list disappears on completion, and only terminal success or failure emits an agent
56
- message. Raw output remains available through the follow and open views; it does not take
57
- over the footer.
68
+ Each workflow or repair step can launch commands and model-backed agents, consuming provider quota and repeating external side effects.
58
69
 
59
- The dispatcher exposes `list_workflows` to any session, but only the root session gets
60
- `launch_workflow`. A subagent may inspect the catalog; it may not spawn a new factory.
70
+ ## Recovery
71
+
72
+ Recovery is available only for terminal failed records. A recovery claim atomically adopts the eligible failure, validates the evidence, and transfers ownership to the replay session. Live controls remain scoped to the owning session. Recovery does not launch a second copy beside a still-running job and is not a blanket promise that parent-session work survives shutdown.
73
+
74
+ The package publishes `workflow-recovery` for active Workflow mode and contributes `workflow-help` while parent Help mode is active. Help deactivation logically hides the descriptor; cached files may remain.
75
+
76
+ ## Public API
77
+
78
+ ```ts
79
+ import { registerWorkflowDispatcherExtension, registerWorkflowExtension } from '@agimon-ai/doompi-workflow';
80
+ ```
81
+
82
+ The dispatcher extension is available at `/extensions/dispatcher`; the Pi host entry is `/extensions/pi`.
83
+
84
+ ## Development
61
85
 
62
- ## Entry points
86
+ ```bash
87
+ pnpm build
88
+ pnpm typecheck
89
+ pnpm test
90
+ pnpm lint
91
+ ```
63
92
 
64
- | Import | Purpose |
65
- | -------------------------------------------------------------- | ----------------------------- |
66
- | `@agimon-ai/doompi-workflow` | Library API |
67
- | `@agimon-ai/doompi-workflow/extensions/dispatcher` | Workflow dispatcher extension |
68
- | `@agimon-ai/doompi-workflow/extensions/pi` | Pi extension entry point |
69
- | `@agimon-ai/doompi-workflow/skills/workflow-recovery/SKILL.md` | Recovery skill |
93
+ Maintained by [Agimon](https://agimon.ai/about).
70
94
 
71
95
  ## License
72
96
 
package/package.json CHANGED
@@ -1,13 +1,15 @@
1
1
  {
2
2
  "name": "@agimon-ai/doompi-workflow",
3
- "version": "0.0.1-alpha.21",
4
- "description": "Doompi workflow execution and monitoring integration",
3
+ "version": "0.0.1-alpha.23",
4
+ "description": "GitHub Actions-style workflow graphs, artifacts, recovery, and asynchronous runs for DoomPi.",
5
5
  "keywords": [
6
- "ai",
6
+ "automation",
7
7
  "coding-agent",
8
- "developer-tools",
9
8
  "doompi",
10
- "pi-package"
9
+ "github-actions",
10
+ "pi-extension",
11
+ "workflow",
12
+ "workflow-orchestration"
11
13
  ],
12
14
  "homepage": "https://agimon.ai",
13
15
  "license": "MIT",
@@ -47,10 +49,10 @@
47
49
  "dependencies": {
48
50
  "@modelcontextprotocol/sdk": "1.29.0",
49
51
  "zod": "4.4.3",
50
- "@agimon-ai/doompi-extension-contracts": "0.0.1-alpha.21",
51
- "@agimon-ai/doompi-telemetry": "0.0.1-alpha.21",
52
- "@agimon-ai/workflow-mcp": "0.23.11",
53
- "@agimon-ai/doompi-ui": "0.0.1-alpha.21"
52
+ "@agimon-ai/doompi-extension-contracts": "0.0.1-alpha.23",
53
+ "@agimon-ai/workflow-mcp": "0.23.13",
54
+ "@agimon-ai/doompi-ui": "0.0.1-alpha.23",
55
+ "@agimon-ai/doompi-telemetry": "0.0.1-alpha.23"
54
56
  },
55
57
  "devDependencies": {
56
58
  "@earendil-works/pi-coding-agent": "0.84.2",