iriai-build 0.6.0 → 0.6.2
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/README.md +103 -15
- package/package.json +1 -1
- package/v3/budget.js +4 -4
package/README.md
CHANGED
|
@@ -18,32 +18,120 @@ npm install -g iriai-build
|
|
|
18
18
|
Run `iriai-build` with no arguments for an interactive menu, or use a subcommand directly.
|
|
19
19
|
|
|
20
20
|
```
|
|
21
|
-
iriai-build [command]
|
|
21
|
+
iriai-build [command] [options]
|
|
22
22
|
```
|
|
23
23
|
|
|
24
|
-
|
|
24
|
+
### Commands
|
|
25
25
|
|
|
26
26
|
| Command | Alias | Description |
|
|
27
27
|
|---|---|---|
|
|
28
|
-
| `launch [description]` | | Full flow: planning, implementation, and completion
|
|
29
|
-
| `plan [description]` | | Run the planning pipeline.
|
|
30
|
-
| `implementation` | `impl` | Select from planned or in-progress features and run implementation
|
|
31
|
-
| `slack` | | Launch the Slack bridge for
|
|
32
|
-
| `transfer-to-slack` | | Sync
|
|
33
|
-
| `setup` | | Interactive configuration for
|
|
28
|
+
| `launch [description]` | | Full flow: planning, implementation, and completion in one session |
|
|
29
|
+
| `plan [description]` | | Run the planning pipeline only. Prompts to continue to implementation after approval |
|
|
30
|
+
| `implementation` | `impl` | Select from planned or in-progress features and run implementation |
|
|
31
|
+
| `slack` | | Launch the Slack bridge for async decisions and updates via Slack |
|
|
32
|
+
| `transfer-to-slack` | | Sync CLI-created features to Slack channels and start the bridge |
|
|
33
|
+
| `setup` | | Interactive configuration for tokens, tool paths, budget tier, and preferences |
|
|
34
34
|
|
|
35
|
-
|
|
35
|
+
### Global Options
|
|
36
|
+
|
|
37
|
+
| Flag | Description |
|
|
38
|
+
|---|---|
|
|
39
|
+
| `--budget <tier>` | Set budget tier: `unrestricted`, `econ`, or `budget` |
|
|
40
|
+
|
|
41
|
+
## How It Works
|
|
42
|
+
|
|
43
|
+
### Feature Lifecycle
|
|
44
|
+
|
|
45
|
+
Each feature moves through a state machine:
|
|
46
|
+
|
|
47
|
+
1. **Planning** — Sequential agent pipeline: PM → Designer → Architect → Plan Compiler, with phase-review gates between each stage
|
|
48
|
+
2. **Plan Approval** — User reviews compiled plan, approves or rejects
|
|
49
|
+
3. **Implementation** — Feature Lead dispatches teams, role agents execute phases in parallel, review agents audit at gate boundaries
|
|
50
|
+
4. **Gate Reviews** — Review agents produce evidence; user approves or rejects each gate
|
|
51
|
+
5. **Completion** — Feature branch merged to main
|
|
52
|
+
|
|
53
|
+
### Signal-Based Agent Communication
|
|
54
|
+
|
|
55
|
+
Agents and the orchestrator communicate via filesystem signals:
|
|
56
|
+
|
|
57
|
+
- `.task` / `.user-message` — Bridge → Agent (job descriptions, user replies)
|
|
58
|
+
- `.agent-response` / `.done` / `.question` — Agent → Bridge (outputs, completion, decisions)
|
|
59
|
+
- `.gate-approved` / `.gate-rejected` — Bridge → Agent (verification results)
|
|
60
|
+
|
|
61
|
+
### Multi-Team Coordination
|
|
62
|
+
|
|
63
|
+
Features are partitioned across teams that work in parallel. A Feature Lead coordinates progress, dispatches review agents at gate boundaries, and compiles evidence for user decisions.
|
|
64
|
+
|
|
65
|
+
### Budget Tiers
|
|
66
|
+
|
|
67
|
+
Control cost and concurrency with three tiers:
|
|
68
|
+
|
|
69
|
+
| Tier | Models | Max Teams | Review Roles |
|
|
70
|
+
|---|---|---|---|
|
|
71
|
+
| `unrestricted` | Opus everywhere | 5 | All 5 reviewers |
|
|
72
|
+
| `econ` | Opus FL, Sonnet others | 1 | Code reviewer + verifier |
|
|
73
|
+
| `budget` | Sonnet/Haiku | 1 | Verifier only |
|
|
74
|
+
|
|
75
|
+
All tiers use the same timeouts: 75min per role agent, 45min for Feature Lead.
|
|
36
76
|
|
|
37
|
-
|
|
77
|
+
### Terminal vs Slack
|
|
38
78
|
|
|
39
|
-
|
|
79
|
+
- **Terminal mode** — Full feature lifecycle with inline `@inquirer/prompts` decisions. No Slack required.
|
|
80
|
+
- **Slack mode** — Long-running bridge posts Block Kit decisions to Slack channels. Supports async collaboration across multiple users.
|
|
81
|
+
- **Transfer** — Features started in the terminal can be synced to Slack via `transfer-to-slack`.
|
|
82
|
+
|
|
83
|
+
## Configuration
|
|
84
|
+
|
|
85
|
+
Run `iriai-build setup` to configure interactively. Values are saved to `~/.iriai/config.json`.
|
|
40
86
|
|
|
41
87
|
| Setting | Config key | Env var override | Default |
|
|
42
88
|
|---|---|---|---|
|
|
89
|
+
| Project root | `project_root` | `PROJECT_ROOT` | Current directory |
|
|
43
90
|
| Claude CLI path | `claude_bin` | `CLAUDE_BIN` | `claude` |
|
|
44
|
-
| QA feedback
|
|
45
|
-
| Slack App Token | `slack_app_token` | `SLACK_APP_TOKEN` |
|
|
46
|
-
| Slack Bot Token | `slack_bot_token` | `SLACK_BOT_TOKEN` |
|
|
47
|
-
| Slack Channel ID | `slack_channel_id` | `SLACK_CHANNEL_ID` |
|
|
91
|
+
| QA feedback tool | `qa_feedback_bin` | `QA_FEEDBACK_BIN` | `iriai-feedback` |
|
|
92
|
+
| Slack App Token | `slack_app_token` | `SLACK_APP_TOKEN` | — |
|
|
93
|
+
| Slack Bot Token | `slack_bot_token` | `SLACK_BOT_TOKEN` | — |
|
|
94
|
+
| Slack Channel ID | `slack_channel_id` | `SLACK_CHANNEL_ID` | — |
|
|
95
|
+
| Budget tier | `budget_tier` | `IRIAI_BUDGET` | `unrestricted` |
|
|
48
96
|
|
|
49
97
|
Environment variables always take precedence over config file values. Slack tokens are required only for `slack` and `transfer-to-slack` commands.
|
|
98
|
+
|
|
99
|
+
## Running as a Service (macOS)
|
|
100
|
+
|
|
101
|
+
A launchd plist is included for running the Slack bridge as a persistent background service:
|
|
102
|
+
|
|
103
|
+
```bash
|
|
104
|
+
# Install
|
|
105
|
+
launchctl load com.iriai.slack-bridge-v3.plist
|
|
106
|
+
|
|
107
|
+
# Restart
|
|
108
|
+
touch .restart-bridge-v3
|
|
109
|
+
|
|
110
|
+
# Logs
|
|
111
|
+
tail -f /tmp/iriai-bridge-v3.log
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
The service auto-restarts on crash and prevents macOS sleep while running.
|
|
115
|
+
|
|
116
|
+
## Architecture
|
|
117
|
+
|
|
118
|
+
```
|
|
119
|
+
bin/cli.js CLI entry point (commander)
|
|
120
|
+
cli/commands/ Command implementations
|
|
121
|
+
v3/
|
|
122
|
+
orchestrator.js Core state machine (planning → impl → completion)
|
|
123
|
+
agent-supervisor.js Process spawning, health monitoring, retries
|
|
124
|
+
file-io.js Signal directory watcher (chokidar)
|
|
125
|
+
recovery.js Startup recovery for orphaned processes
|
|
126
|
+
adapters/
|
|
127
|
+
slack-adapter.js Socket Mode + Block Kit decisions
|
|
128
|
+
terminal-adapter.js @inquirer/prompts inline decisions
|
|
129
|
+
budget.js Tier presets (models, concurrency, timeouts)
|
|
130
|
+
schema.sql SQLite schema (features, agents, decisions, events)
|
|
131
|
+
bridge-v3.js Slack bridge entry point
|
|
132
|
+
lib/ Shared utilities (agent process, slack helpers)
|
|
133
|
+
```
|
|
134
|
+
|
|
135
|
+
### Database
|
|
136
|
+
|
|
137
|
+
State is persisted in SQLite (`~/.iriai/bridge-v3.db`) with tables for features, agents, decisions, events, and an operator relay queue.
|
package/package.json
CHANGED
package/v3/budget.js
CHANGED
|
@@ -44,8 +44,8 @@ export const BUDGET_TIERS = {
|
|
|
44
44
|
maxTeams: 1,
|
|
45
45
|
reviewRoles: ["code-reviewer", "verifier"],
|
|
46
46
|
timeouts: {
|
|
47
|
-
roleHardMs:
|
|
48
|
-
flSoftMs:
|
|
47
|
+
roleHardMs: 75 * 60 * 1000,
|
|
48
|
+
flSoftMs: 45 * 60 * 1000,
|
|
49
49
|
},
|
|
50
50
|
retries: {
|
|
51
51
|
role: 2,
|
|
@@ -70,8 +70,8 @@ export const BUDGET_TIERS = {
|
|
|
70
70
|
maxTeams: 1,
|
|
71
71
|
reviewRoles: ["verifier"],
|
|
72
72
|
timeouts: {
|
|
73
|
-
roleHardMs:
|
|
74
|
-
flSoftMs:
|
|
73
|
+
roleHardMs: 75 * 60 * 1000,
|
|
74
|
+
flSoftMs: 45 * 60 * 1000,
|
|
75
75
|
},
|
|
76
76
|
retries: {
|
|
77
77
|
role: 1,
|