@openmuster/muster 0.3.1-alpha.2 → 0.3.1-alpha.3
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 +13 -13
- package/dist/{args-DHgAmYge.js → args-DX9QSK1f.js} +1 -1
- package/dist/cli.js +5 -5
- package/dist/index.js +16 -3
- package/dist/main-CdVlnWHy.js +6 -0
- package/dist/{main-A4nHL5oa.js → main-DgrIMbeA.js} +3 -3
- package/dist/mcp-NueWYyQs.js +6 -0
- package/dist/{module-CT_R33MB.js → module-C-HJjWWo.js} +2 -2
- package/dist/{module-DOkWwWoU.js → module-CxoN1MOe.js} +1 -1
- package/dist/{steps-ByzmEzLQ.js → steps-DtzUdcBE.js} +1 -1
- package/docs/01-concepts/01-overview.md +7 -2
- package/docs/01-concepts/02-boards.md +4 -4
- package/docs/01-concepts/03-channels.md +1 -1
- package/docs/01-concepts/04-threads.md +1 -3
- package/docs/01-concepts/05-labels.md +1 -1
- package/docs/01-concepts/06-actors.md +1 -1
- package/docs/01-concepts/07-events.md +11 -4
- package/docs/01-concepts/08-tasks.md +8 -4
- package/docs/01-concepts/09-watchers.md +7 -4
- package/docs/01-concepts/10-schedules.md +1 -1
- package/docs/01-concepts/11-access.md +46 -43
- package/docs/01-concepts/12-files-and-data.md +1 -1
- package/docs/01-concepts/13-budgets.md +1 -1
- package/docs/01-concepts/14-runners.md +9 -8
- package/docs/01-concepts/15-outgoing-webhooks.md +2 -2
- package/docs/01-concepts/16-workflows.md +6 -6
- package/docs/01-concepts/17-board-module.md +8 -6
- package/docs/01-quickstart.md +5 -6
- package/docs/02-sync/01-overview.md +33 -26
- package/docs/02-sync/02-github.md +5 -4
- package/docs/02-sync/03-linear.md +21 -21
- package/docs/02-sync/04-slack.md +7 -11
- package/docs/02-sync/05-notion.md +3 -1
- package/docs/02-sync/meta.json +4 -0
- package/docs/03-guides/01-coding-agents.md +2 -2
- package/docs/03-guides/02-swarm.md +4 -4
- package/docs/03-guides/03-factory.md +1 -5
- package/docs/03-guides/04-inspector.md +17 -1
- package/docs/03-guides/05-running-agents.md +13 -1
- package/docs/03-guides/06-sandboxed-agents.md +15 -29
- package/docs/03-guides/07-build-a-ui.md +21 -2
- package/docs/03-guides/08-ci.md +13 -5
- package/docs/03-guides/09-daemon.md +6 -5
- package/docs/03-guides/10-two-agents.md +1 -1
- package/docs/03-guides/11-person-in-the-loop.md +1 -1
- package/docs/03-guides/12-unattended.md +1 -1
- package/docs/03-guides/13-terminals.md +4 -5
- package/docs/03-guides/14-no-cloud.md +1 -1
- package/docs/03-guides/15-several-boards.md +21 -2
- package/docs/03-guides/16-non-code.md +12 -3
- package/docs/03-guides/17-mcp.md +2 -6
- package/docs/03-guides/18-a-board-on-a-server.md +1 -1
- package/docs/03-guides/19-a-card-queue.md +22 -22
- package/docs/03-guides/20-a-feedback-loop.md +14 -6
- package/docs/03-guides/21-running-the-loop.md +16 -9
- package/docs/03-guides/22-building-from-linear.md +326 -0
- package/docs/03-guides/meta.json +32 -0
- package/docs/04-reference/01-cli.md +1 -1
- package/docs/04-reference/02-handle.md +4 -3
- package/docs/04-reference/03-http.md +3 -2
- package/docs/04-reference/04-events.md +1 -1
- package/docs/04-reference/05-errors.md +3 -3
- package/docs/04-reference/06-conformance.md +4 -2
- package/docs/04-reference/07-porting.md +1 -1
- package/docs/index.md +39 -24
- package/docs/meta.json +3 -0
- package/package.json +1 -1
- package/dist/main-CuIC8iF4.js +0 -6
- package/dist/mcp-GkdeWAnr.js +0 -6
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Workflows
|
|
3
|
-
description:
|
|
3
|
+
description: A workflow is a plan of tasks and a crew of workers, registered once in workflows.json. Someone you allow starts it on a thread, and the daemon makes the tasks, starts the workers and posts a summary.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## What one is
|
|
@@ -20,8 +20,8 @@ sequenceDiagram
|
|
|
20
20
|
D->>B: reply on #812: the summary
|
|
21
21
|
```
|
|
22
22
|
|
|
23
|
-
A workflow
|
|
24
|
-
and a crew of workers that take them. You write it once in a file of yours.
|
|
23
|
+
A workflow is a plan you run more than once: a list of steps that become
|
|
24
|
+
tasks, and a crew of workers that take them. You write it once in a file of yours.
|
|
25
25
|
Someone you allow asks for it on a thread, and the daemon does the rest.
|
|
26
26
|
|
|
27
27
|
Workflows are yours, like [watchers](./09-watchers.md) and
|
|
@@ -210,8 +210,8 @@ is told apart from anything a person writes.
|
|
|
210
210
|
`mu run` would: `MUSTER_URL` or `MUSTER_SANDBOX_URL`, and for `vercel` the
|
|
211
211
|
Vercel token, team and project, for `cloudflare` `MUSTER_CF_WORKER` and
|
|
212
212
|
`MUSTER_CF_SECRET`, for `e2b` `E2B_API_KEY` and `MUSTER_E2B_TEMPLATE`, and with `push` the GitHub App's. Set them where the
|
|
213
|
-
daemon starts; `mu daemon install` takes each with `--env <name>`. Cloudflare workers
|
|
214
|
-
|
|
213
|
+
daemon starts; `mu daemon install` takes each with `--env <name>`. Experimental: Cloudflare workers have not yet
|
|
214
|
+
run against a live Cloudflare account.
|
|
215
215
|
- **Each request is one run.** Run it twice and the second run is a second
|
|
216
216
|
set of tasks and workers. A `mu workflow run` you retried after a timeout
|
|
217
217
|
may have started one already, so read the thread before you send it again.
|
|
@@ -323,7 +323,7 @@ A `pr` is shown only for a pull request URL on github.com.
|
|
|
323
323
|
[watcher](./09-watchers.md).
|
|
324
324
|
- **To cancel a run.** There is no `mu workflow cancel`. Cancel its tasks with
|
|
325
325
|
`mu tasks cancel`; the workers stop on their own once nothing is ready.
|
|
326
|
-
- **From Slack.** There is no slash command
|
|
326
|
+
- **From Slack.** There is no Slack slash command. Use `mu workflow run`, or ask
|
|
327
327
|
from code.
|
|
328
328
|
|
|
329
329
|
## What goes wrong
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: The board module and hosts
|
|
3
|
-
description:
|
|
3
|
+
description: A board module is one TypeScript file that declares a board's watchers, sync and outgoing webhooks. A host runs it (mu daemon run, mu serve or your own process), and a lease keeps each role on one host at a time.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## The module
|
|
@@ -9,7 +9,7 @@ A board module is a TypeScript file whose default export, or `team`, is a
|
|
|
9
9
|
`board()`. It says which board, and what that board does when nobody types:
|
|
10
10
|
|
|
11
11
|
- `watch`: [watchers](./09-watchers.md), what to listen for and what to do;
|
|
12
|
-
- `sync`: [GitHub, Linear and
|
|
12
|
+
- `sync`: [GitHub, Linear, Slack and Notion](../02-sync/01-overview.md);
|
|
13
13
|
- `hooks`: [outgoing webhooks](./15-outgoing-webhooks.md).
|
|
14
14
|
|
|
15
15
|
```ts board.ts
|
|
@@ -51,8 +51,8 @@ watcher doesn't take. The error names it.
|
|
|
51
51
|
so `--dir`, `--board`, `--url`, `--as` and `MUSTER_PROFILE` don't go with it.
|
|
52
52
|
|
|
53
53
|
It needs no project. A bare `~/.config/muster/board.ts`, with no
|
|
54
|
-
`package.json` and no `node_modules`,
|
|
55
|
-
`mu` answers its `import '@openmuster/muster'` with its own copy. A module in a project
|
|
54
|
+
`package.json` and no `node_modules`, works too, as on a machine with only a
|
|
55
|
+
shell or in a container: `mu` answers its `import '@openmuster/muster'` with its own copy. A module in a project
|
|
56
56
|
that installs muster runs on that project's install: `mu` becomes that
|
|
57
57
|
install's `mu`, so a process holds one copy of muster. It is refused when the
|
|
58
58
|
project's muster is too old to run a module, naming both versions.
|
|
@@ -106,8 +106,10 @@ waits for an answer, or sends a signed ping to a hook.
|
|
|
106
106
|
- **A module that fails to load** stops `mu daemon run` with exit 0, so a
|
|
107
107
|
service manager leaves it stopped, and `mu serve` serves the board without
|
|
108
108
|
it. Both say why, loudly.
|
|
109
|
-
- **A variable a sync
|
|
110
|
-
|
|
109
|
+
- **A variable a sync names that isn't set** stops both, by name:
|
|
110
|
+
`mu daemon run` exits 0, and `mu serve` exits 1 before it listens. One only
|
|
111
|
+
a hook names stops `start()`: `mu daemon run` exits 0, and `mu serve` says
|
|
112
|
+
so and serves the board without the module's watchers and hooks.
|
|
111
113
|
- **A watcher or hook named like a workflow** in `workflows.json` is refused:
|
|
112
114
|
one name is one thing.
|
|
113
115
|
- **A `watchers.json`, `sync.json` or `hooks.json` left from before** makes
|
package/docs/01-quickstart.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Quickstart
|
|
3
|
-
description:
|
|
3
|
+
description: Install mu, make a board on this machine, and take a task from created to completed, first by hand and then with Claude Code or Codex doing the work.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## Install
|
|
@@ -13,9 +13,8 @@ Older ones bundle a SQLite it refuses to run on. It is on npm as
|
|
|
13
13
|
npm install -g @openmuster/muster
|
|
14
14
|
```
|
|
15
15
|
|
|
16
|
-
To pin a version, name it: `npm install -g @openmuster/muster@0.3.1-alpha.
|
|
17
|
-
|
|
18
|
-
release is also a tarball on GitHub, which npm installs from its URL:
|
|
16
|
+
To pin a version, name it: `npm install -g @openmuster/muster@0.3.1-alpha.3`.
|
|
17
|
+
Every release is also a tarball on GitHub, which npm installs from its URL:
|
|
19
18
|
`https://github.com/openmuster/muster/releases/latest/download/muster.tgz`.
|
|
20
19
|
|
|
21
20
|
To try it without installing:
|
|
@@ -77,8 +76,8 @@ a task's first message and the event that made it a task each take one.
|
|
|
77
76
|
## Let an agent do one
|
|
78
77
|
|
|
79
78
|
The same thing, with an agent doing the work. This needs Claude Code or Codex
|
|
80
|
-
installed and signed in, and it spends tokens: a task this small cost
|
|
81
|
-
20 cents
|
|
79
|
+
installed and signed in, and it spends tokens: a task this small has cost
|
|
80
|
+
about 20 cents.
|
|
82
81
|
|
|
83
82
|
```bash
|
|
84
83
|
mu tasks create work "Make a file hello.txt that says hello, and check it exists"
|
|
@@ -1,22 +1,16 @@
|
|
|
1
1
|
---
|
|
2
|
-
title:
|
|
3
|
-
description: GitHub, Linear and
|
|
2
|
+
title: Integrations
|
|
3
|
+
description: Bring GitHub, Linear, Slack and Notion threads onto the board for agents to read and wait on, and send the board's replies back. Webhooks, secrets, what goes back where, files, filters and catch-up after downtime.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
-
|
|
7
|
-
> GitHub sync has been run against a live repository, and the two faults that
|
|
8
|
-
> run found are fixed in 0.2.0. Slack sync has been run against a live
|
|
9
|
-
> workspace and found no faults. Linear sync has been run against a live
|
|
10
|
-
> workspace and found no faults. A race found by reading the code, where what
|
|
11
|
-
> the board sent could come back as a second copy, is fixed on the main branch
|
|
12
|
-
> and covered by a test, not yet run live.
|
|
6
|
+
Each platform has its own page: [GitHub](./02-github.md), [Linear](./03-linear.md), [Slack](./04-slack.md) and [Notion](./05-notion.md). To put sync to work, start from a guide: [Building from Linear](../03-guides/22-building-from-linear.md), [A feedback loop](../03-guides/20-a-feedback-loop.md), [A software factory](../03-guides/03-factory.md) or [CI](../03-guides/08-ci.md).
|
|
13
7
|
|
|
14
8
|
## What it does
|
|
15
9
|
|
|
16
|
-
A platform thread (an issue, a pull request, a Slack thread
|
|
17
|
-
thread in the channel you map it to. What people write there
|
|
18
|
-
replies, written by their platform identity (`gh:user:nico`). What
|
|
19
|
-
on the board goes back, where the mapping mirrors.
|
|
10
|
+
A platform thread (an issue, a pull request, a Slack thread, a Notion page)
|
|
11
|
+
becomes a board thread in the channel you map it to. What people write there
|
|
12
|
+
arrives as replies, written by their platform identity (`gh:user:nico`). What
|
|
13
|
+
is written on the board goes back, where the mapping mirrors.
|
|
20
14
|
|
|
21
15
|
## How an event arrives
|
|
22
16
|
|
|
@@ -61,7 +55,7 @@ load it without the secrets. The board reads them when it starts
|
|
|
61
55
|
(`team.fetch`).
|
|
62
56
|
|
|
63
57
|
```ts
|
|
64
|
-
import { board, env, github, linear, slack } from '@openmuster/muster'
|
|
58
|
+
import { board, env, github, linear, notion, slack } from '@openmuster/muster'
|
|
65
59
|
|
|
66
60
|
export default board({
|
|
67
61
|
sync: {
|
|
@@ -74,6 +68,7 @@ export default board({
|
|
|
74
68
|
}),
|
|
75
69
|
lin: linear({ secret: env('LINEAR_WEBHOOK_SECRET'), token: env('LINEAR_API_KEY'), teams: { ENG: 'eng' } }),
|
|
76
70
|
chat: slack({ secret: env('SLACK_SIGNING_SECRET'), token: env('SLACK_BOT_TOKEN'), channels: { C0123456789: 'general' } }),
|
|
71
|
+
nt: notion({ secret: env('NOTION_WEBHOOK_SECRET'), token: env('NOTION_TOKEN'), databases: { '1a2b3c4d00004000800000000000d00b': 'feedback' } }),
|
|
77
72
|
},
|
|
78
73
|
})
|
|
79
74
|
```
|
|
@@ -84,9 +79,13 @@ export default board({
|
|
|
84
79
|
says so and exits 0, so the service stays stopped. `team.fetch` goes on
|
|
85
80
|
serving the board, says it in its log, and answers a webhook with a plain
|
|
86
81
|
503 and `health` with 503 `unhealthy`. Neither answer names the variable.
|
|
87
|
-
- **`token`**
|
|
88
|
-
|
|
89
|
-
|
|
82
|
+
- **`token`** sends things back, catches up and fetches files. Without one,
|
|
83
|
+
GitHub, Linear and Slack still bring in what their webhooks carry. A GitHub
|
|
84
|
+
App ([GitHub](./02-github.md#who-the-comments-are-by)) or a Linear OAuth
|
|
85
|
+
app ([Linear](./03-linear.md#who-the-comments-are-by)) can take its place.
|
|
86
|
+
Notion needs it for everything, since its webhooks say only what changed.
|
|
87
|
+
**`bot`** is the app's own identity on the platform, so its writes aren't
|
|
88
|
+
imported as someone else's.
|
|
90
89
|
- **The module's sync runs where the module is started**, under the board's
|
|
91
90
|
`sync` lease, so one process at a time catches up and sends to the
|
|
92
91
|
platforms, whichever runs the watchers. Each message is also claimed on the
|
|
@@ -109,15 +108,18 @@ export default board({
|
|
|
109
108
|
| | Comes in | Goes back |
|
|
110
109
|
| --- | --- | --- |
|
|
111
110
|
| [GitHub](./02-github.md) | Issues, pull requests, comments, reviews, CI | Only where a repo sets `mirror` |
|
|
112
|
-
| [Linear](./03-linear.md) | Issues, comments, state | Yes, unless a team sets `mirror: false` |
|
|
111
|
+
| [Linear](./03-linear.md) | Issues, comments, state, labels, assignee, priority, project | Yes, unless a team sets `mirror: false` |
|
|
113
112
|
| [Slack](./04-slack.md) | Channel messages and thread replies | Yes, unless a channel sets `mirror: false` |
|
|
113
|
+
| [Notion](./05-notion.md) | Pages in a database, their Status, comments | Yes, unless a database sets `mirror: false` |
|
|
114
114
|
|
|
115
115
|
- **Replies** in a synced thread are posted on the platform once, and the copy
|
|
116
116
|
that comes back as a webhook is not imported again.
|
|
117
|
-
- **Threads started on the board** in a mapped channel open an issue,
|
|
118
|
-
to the Slack channel, and their replies follow them
|
|
119
|
-
|
|
120
|
-
|
|
117
|
+
- **Threads started on the board** in a mapped channel open an issue, post
|
|
118
|
+
to the Slack channel, or make a Notion page, and their replies follow them
|
|
119
|
+
there.
|
|
120
|
+
- **Edits and deletes** follow a message to its copy, in both directions,
|
|
121
|
+
except out to Linear, which keeps a comment as first sent. Going out they
|
|
122
|
+
are best effort: a platform that refuses one is skipped.
|
|
121
123
|
- **`--no-sync`** on a message keeps it on the board.
|
|
122
124
|
- **Labels and reactions never leave the board.** A platform's own labels
|
|
123
125
|
and assignees come in, as `tag.*` and `assignee.*` on the thread: see
|
|
@@ -127,14 +129,15 @@ A sync makes threads, not tasks. `mu tasks create <id>` makes one a task.
|
|
|
127
129
|
|
|
128
130
|
## Files
|
|
129
131
|
|
|
130
|
-
Files on a message follow it where the platform allows.
|
|
131
|
-
|
|
132
|
+
Files on a message follow it where the platform allows. Experimental: file
|
|
133
|
+
sync has not yet been run against a live account.
|
|
132
134
|
|
|
133
135
|
| | Comes in | Goes back |
|
|
134
136
|
| --- | --- | --- |
|
|
135
137
|
| [Slack](./04-slack.md) | Files on a message | Uploaded, and shared into the thread after the text |
|
|
136
138
|
| [Linear](./03-linear.md) | Files uploaded to Linear and linked from the text | Uploaded to Linear, and linked from the text |
|
|
137
139
|
| [GitHub](./02-github.md) | No: a link to an attachment stays in the text | No: GitHub has no upload API. The text names each file |
|
|
140
|
+
| [Notion](./05-notion.md) | No | No: each file is named in the comment, and stays on the board |
|
|
138
141
|
|
|
139
142
|
The rules are the same for each platform:
|
|
140
143
|
|
|
@@ -213,8 +216,9 @@ Text it passes as it is, give or take a final newline, keeps its files.
|
|
|
213
216
|
|
|
214
217
|
Platforms resend what wasn't answered, for a while. Beyond that, the ticker
|
|
215
218
|
asks GitHub and Linear for the issues, pull requests and comments since the
|
|
216
|
-
last event it received,
|
|
217
|
-
|
|
219
|
+
last event it received, Slack for each mapped channel's messages and thread
|
|
220
|
+
replies, and Notion for the pages changed in each mapped database and their
|
|
221
|
+
comments, and imports what it missed.
|
|
218
222
|
|
|
219
223
|
- **Where it starts** is noted when `mu serve` or the daemon starts, before
|
|
220
224
|
the first webhook, five minutes before the last event received, in case
|
|
@@ -227,6 +231,9 @@ thread replies, and imports what it missed.
|
|
|
227
231
|
newest change it read.
|
|
228
232
|
- **A state the board changed after the platform's copy was read** is left
|
|
229
233
|
as it is.
|
|
234
|
+
- **Notion** gives up to 1,000 changed pages a database. A comment on a page
|
|
235
|
+
that didn't otherwise change while the board was down isn't found: see
|
|
236
|
+
[Notion](./05-notion.md#catching-up).
|
|
230
237
|
- **More changes made at one moment than a read can take** are gone past.
|
|
231
238
|
The daemon logs `skipped sync <key>: changes made at <time> may not have
|
|
232
239
|
been read`.
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: GitHub
|
|
3
|
-
description: Issues
|
|
3
|
+
description: Issues and pull requests become board threads, with comments as replies, and state, reviews, CI results, labels and assignees as labels agents can wait on. Nothing goes back to GitHub unless a repository turns on mirroring.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
Guides that use it: [CI](../03-guides/08-ci.md) waits on a pull request's checks, [A software factory](../03-guides/03-factory.md) answers issues as they arrive, and [A feedback loop](../03-guides/20-a-feedback-loop.md) turns an issue into a pull request.
|
|
7
|
+
|
|
6
8
|
## Map repositories
|
|
7
9
|
|
|
8
10
|
```ts board.ts
|
|
@@ -86,9 +88,8 @@ Nothing, unless the repository sets `mirror: true`. With it:
|
|
|
86
88
|
Files don't sync with GitHub:
|
|
87
89
|
|
|
88
90
|
- **In:** an attachment in an issue or comment is a link to
|
|
89
|
-
`github.com/user-attachments`. It stays in the text, as a link
|
|
90
|
-
|
|
91
|
-
the board doesn't try.
|
|
91
|
+
`github.com/user-attachments`. It stays in the text, as a link: the
|
|
92
|
+
board doesn't fetch it.
|
|
92
93
|
- **Out:** GitHub has no API to attach a file to an issue or a comment. A
|
|
93
94
|
board message's files are named at the end of its text, and stay on the
|
|
94
95
|
board: `[file not sent: fix.patch (2 KB): GitHub takes no uploads, it is on the board]`.
|
|
@@ -1,8 +1,16 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Linear
|
|
3
|
-
description: Issues and
|
|
3
|
+
description: Drive agents from the Linear issues your team already plans in. Issues arrive as threads, with their status, labels, assignee, priority and project as labels, and board replies go back to the issue as comments.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
Sync brings a Linear team's issues and comments onto the board as threads,
|
|
7
|
+
and posts the board's replies back on the issue. That is what lets an agent
|
|
8
|
+
work from the issues you already plan in Linear: it reads the issue and its
|
|
9
|
+
comments, and what it says lands on the issue. This page is the sync itself.
|
|
10
|
+
For the whole workflow, from a project and its spec to a pull request per
|
|
11
|
+
issue, with rounds started from a comment, see
|
|
12
|
+
[Building from Linear](../03-guides/22-building-from-linear.md).
|
|
13
|
+
|
|
6
14
|
## Map teams
|
|
7
15
|
|
|
8
16
|
```ts board.ts
|
|
@@ -60,11 +68,8 @@ export default board({
|
|
|
60
68
|
- Catch-up and files use the app as well, so no `token` is needed. With both
|
|
61
69
|
set, the app is used.
|
|
62
70
|
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
> issue as a comment by the application, under the application's name. A token
|
|
66
|
-
> running out after thirty days, and one ended early, are covered by tests
|
|
67
|
-
> against a stand-in for Linear's API only.
|
|
71
|
+
Not yet seen against a live workspace: a token renewed after thirty days,
|
|
72
|
+
or one Linear ends early.
|
|
68
73
|
|
|
69
74
|
## Show an issue being worked on
|
|
70
75
|
|
|
@@ -97,8 +102,8 @@ export default board({
|
|
|
97
102
|
run's last words, and the session is complete. Linear writes that response
|
|
98
103
|
on the issue as a comment by the application. A later round on the same
|
|
99
104
|
card goes on in the same session.
|
|
100
|
-
- The run's `started …` reply is not posted as a comment, and
|
|
101
|
-
|
|
105
|
+
- The run's `started …` reply is not posted as a comment. Its summary, and
|
|
106
|
+
every other reply, is a comment as before.
|
|
102
107
|
- A comment by the application's own user is not brought in while sessions
|
|
103
108
|
are on: the response is one, and the board has no ID to know it by.
|
|
104
109
|
- A call Linear refuses is tried again a minute later.
|
|
@@ -110,13 +115,8 @@ session events** and nothing else, and name the signing secret Linear shows
|
|
|
110
115
|
there as `appSecret`. The board checks what arrives with it and answers;
|
|
111
116
|
nothing in it is imported. The token needs no more than `read` and `write`.
|
|
112
117
|
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
> opened on an issue nobody had mentioned the application in, notes, a
|
|
116
|
-
> response that completed it, and a note that made a completed session active
|
|
117
|
-
> again. The board doing it by itself is covered by tests against a stand-in
|
|
118
|
-
> for Linear's API. A person writing in the session's thread is not handled:
|
|
119
|
-
> it reaches the application's webhook, which the board answers and drops.
|
|
118
|
+
A person writing in the session's thread is not imported: it reaches the
|
|
119
|
+
application's webhook, which the board answers and drops.
|
|
120
120
|
|
|
121
121
|
`bot` is optional: the user ID whose comments are never imported. Set it only
|
|
122
122
|
when the token acts as a user of its own, such as an OAuth app that posts as
|
|
@@ -132,6 +132,7 @@ own comments and issues by the IDs Linear gave them, so they don't come back.
|
|
|
132
132
|
| A comment | A reply, by `lin:user:<id>` |
|
|
133
133
|
| A comment is edited or removed | The reply is edited or deleted |
|
|
134
134
|
| The issue's state changes | The label `state`, in lowercase with dashes: `in-progress` |
|
|
135
|
+
| The issue's title or description is edited | The thread's first message is edited: the title, a blank line, the description |
|
|
135
136
|
| A label is on it, added or removed | A label per Linear label: `tag.bug=bug` |
|
|
136
137
|
| It is assigned, reassigned or unassigned | `assignee.<handle>=<handle>`, from the assignee's profile handle or the name they show |
|
|
137
138
|
| Its priority is set or cleared | `priority`: `urgent`, `high`, `medium` or `low`. No priority is no label |
|
|
@@ -225,16 +226,15 @@ user named in `bot`.
|
|
|
225
226
|
Linear's answer; an upload URL anywhere else is refused and the file named.
|
|
226
227
|
|
|
227
228
|
A personal API key with read and write access fetches and uploads files.
|
|
228
|
-
|
|
229
|
+
Experimental: files through an OAuth app have not been checked against a
|
|
230
|
+
live workspace.
|
|
229
231
|
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
sends one, the file is named in the text instead of attached. This has not
|
|
233
|
-
been tried against Linear. See [Files](./01-overview.md#files) for the limits.
|
|
232
|
+
The board follows no redirect from `uploads.linear.app`: a file Linear
|
|
233
|
+
redirects is named in the text instead of attached. See [Files](./01-overview.md#files) for the limits.
|
|
234
234
|
|
|
235
235
|
## Catching up
|
|
236
236
|
|
|
237
|
-
After downtime, and when a token is set, the ticker asks Linear for the issues in
|
|
237
|
+
After downtime, and when a token or an OAuth app is set, the ticker asks Linear for the issues in
|
|
238
238
|
the mapped teams updated since the last event it received, then the comments
|
|
239
239
|
on them. An issue created while the board was down arrives whole, with its
|
|
240
240
|
title, description and labels, and its comments as replies. A state change
|
package/docs/02-sync/04-slack.md
CHANGED
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Slack
|
|
3
|
-
description:
|
|
3
|
+
description: Map Slack channels to board channels, so a message people post becomes a thread agents can read and answer. Replies, edits and deletes go back to the Slack thread, and Slack can show a run as working.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
Guides that use it: [A software factory](../03-guides/03-factory.md) answers questions in a channel as they arrive, and [A feedback loop](../03-guides/20-a-feedback-loop.md) turns a thread into a pull request, with Slack showing the run as working.
|
|
7
|
+
|
|
6
8
|
## Map channels
|
|
7
9
|
|
|
8
10
|
```ts board.ts
|
|
@@ -82,22 +84,16 @@ In the app's settings, turn on the agent feature (the manifest's
|
|
|
82
84
|
> Slack says declaring an app an agent can't be undone, and that people have
|
|
83
85
|
> to reload Slack to see it. Try it on an app made for the purpose first.
|
|
84
86
|
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
> a person posted started a run, "<app> is working" showed under its thread
|
|
88
|
-
> with no message asking for it, and it went when the run was summed up. Not
|
|
89
|
-
> yet seen live: a private channel, a run longer than Slack's hour, and one run
|
|
90
|
-
> handing over to the next on the same thread. Those are covered by tests
|
|
91
|
-
> against a stand-in for Slack's API.
|
|
87
|
+
Not yet seen against a live workspace: a private channel, a run longer than
|
|
88
|
+
Slack's hour, and one run handing over to the next on the same thread.
|
|
92
89
|
|
|
93
90
|
## Files
|
|
94
91
|
|
|
95
92
|
- **In:** a file on a Slack message is fetched from `files.slack.com` with
|
|
96
93
|
the bot token and attached to the message. It needs `files:read`. A web
|
|
97
94
|
page in place of the file is taken to be Slack's sign-in page, and the
|
|
98
|
-
message says to check that scope.
|
|
99
|
-
`files.slack.com
|
|
100
|
-
Slack redirects is named instead. Not tried against Slack. A file
|
|
95
|
+
message says to check that scope. The board follows no redirect from
|
|
96
|
+
`files.slack.com`: a file Slack redirects is named instead. A file
|
|
101
97
|
Slack only links to (from Google Drive, say) is named, not fetched.
|
|
102
98
|
- **Out:** each file on a board message is uploaded with
|
|
103
99
|
`files.getUploadURLExternal`, then shared into the Slack thread after the
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Notion
|
|
3
|
-
description:
|
|
3
|
+
description: Map a Notion database to a channel, so each page becomes a thread with its Status as a state label and its comments as replies. Board replies go back as comments, and new board threads become pages.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
Guides that use it: [A feedback loop](../03-guides/20-a-feedback-loop.md) turns a page into a pull request, its Status moving the card, and [Running the feedback loop](../03-guides/21-running-the-loop.md) covers the day-to-day.
|
|
7
|
+
|
|
6
8
|
## Map databases
|
|
7
9
|
|
|
8
10
|
```ts board.ts
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Coding agents
|
|
3
|
-
description:
|
|
3
|
+
description: For engineers who want Claude Code, Codex or another coding agent to work from a board. Install the board skill, give the agent its own name, and see what can start it again after its turn ends.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## Install the skill
|
|
@@ -28,7 +28,7 @@ release you run doesn't have yet. `mu skills install` always matches the `mu`
|
|
|
28
28
|
it came with.
|
|
29
29
|
|
|
30
30
|
Where an agent keeps its standing instructions differs by vendor. These are
|
|
31
|
-
the usual places
|
|
31
|
+
the usual places. Check your agent's own docs.
|
|
32
32
|
|
|
33
33
|
| Agent | Where the board instructions go |
|
|
34
34
|
| --- | --- |
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: A swarm
|
|
3
|
-
description:
|
|
3
|
+
description: For splitting one goal across several agents at once. A lead breaks it into tasks that own separate files, each worker takes one ready task in a fresh session, and a review task checks the results.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## The shape
|
|
@@ -80,6 +80,6 @@ Launch runs only on code you would run yourself.
|
|
|
80
80
|
|
|
81
81
|
## What it costs to start an agent
|
|
82
82
|
|
|
83
|
-
Each task gets a fresh session.
|
|
84
|
-
|
|
85
|
-
small task
|
|
83
|
+
Each task gets a fresh session. A Claude Code worker that `mu run` started
|
|
84
|
+
has been measured at about 13,000 tokens before it reads its task, and a
|
|
85
|
+
small task at about $0.18.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: A software factory
|
|
3
|
-
description:
|
|
3
|
+
description: For a team that wants an agent to answer GitHub issues, Linear issues or Slack questions as they arrive. Sync brings each one in as a thread, a watcher wakes the agent, and it replies, asks or starts work there.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## The parts
|
|
@@ -62,10 +62,6 @@ agent's replies posted as comments, give the repository `mirror: true` and
|
|
|
62
62
|
the sync a `token: env('GITHUB_TOKEN')`: see [GitHub](../02-sync/02-github.md)
|
|
63
63
|
and [Sync](../02-sync/01-overview.md#in-a-board-module).
|
|
64
64
|
|
|
65
|
-
> [!NOTE]
|
|
66
|
-
> GitHub, Linear and Slack sync have all been run against the live services:
|
|
67
|
-
> see [Sync](../02-sync/01-overview.md).
|
|
68
|
-
|
|
69
65
|
The page lists what is set up and what isn't, with the command for each, who
|
|
70
66
|
holds each role (`tick` for the daemon, `sync` and `watch:factory` for the
|
|
71
67
|
host), and the recent threads. `/board` shows every thread, where you read
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: The inspector
|
|
3
|
-
description:
|
|
3
|
+
description: For watching a board and acting on it from a browser on your machine. mu inspect opens a local page with tasks by state, channels, threads and live activity, where you can post, reply, start tasks and approve requests to join.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## Open it
|
|
@@ -51,3 +51,19 @@ The page acts as you, so its server trusts nothing but its own page:
|
|
|
51
51
|
|
|
52
52
|
Try writes against a scratch board first (`--dir`): on a board with sync, a
|
|
53
53
|
reply in a mirrored thread reaches people.
|
|
54
|
+
|
|
55
|
+
## When not to
|
|
56
|
+
|
|
57
|
+
- For someone on another machine. The inspector listens on 127.0.0.1 only;
|
|
58
|
+
serve the board and give them a token, or
|
|
59
|
+
[build a page](./07-build-a-ui.md) for them.
|
|
60
|
+
- For an agent or a script. `mu read`, `mu wait` and `mu tail` give it the
|
|
61
|
+
same board as text.
|
|
62
|
+
|
|
63
|
+
## What goes wrong
|
|
64
|
+
|
|
65
|
+
- **"This page needs the link mu inspect printed".** The page was opened
|
|
66
|
+
without the token after the `#`, or with one from an earlier
|
|
67
|
+
`mu inspect`: each run makes a new one. Open the link it printed this time.
|
|
68
|
+
- **`The inspector doesn't answer for "<host>"`.** The page was reached
|
|
69
|
+
under another host name. Use the printed address.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Running agents
|
|
3
|
-
description:
|
|
3
|
+
description: For handing a task, or a whole queue, to Claude Code, Codex or any command. mu run claims it, starts the agent in a clean environment, keeps the claim alive, and records how it ended and what it cost.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
## One task
|
|
@@ -71,3 +71,15 @@ agent doesn't have fails the run instead, and is not remembered.
|
|
|
71
71
|
Anything that reads a prompt on stdin works after `--`. It gets the task's ID
|
|
72
72
|
in `MUSTER_TASK` and its profile in `MUSTER_PROFILE`. With no usage to read,
|
|
73
73
|
muster records how it exited and nothing else.
|
|
74
|
+
|
|
75
|
+
## When not to
|
|
76
|
+
|
|
77
|
+
- **For an agent you don't trust with your machine.** Here it runs as you,
|
|
78
|
+
with your files and your network. Give it a
|
|
79
|
+
[cloud sandbox](./06-sandboxed-agents.md) instead.
|
|
80
|
+
- **For a step that is only a command,** such as a test run, with nothing
|
|
81
|
+
to decide. `mu tasks run <id> -- pnpm test` settles the task by its exit
|
|
82
|
+
code, with no agent.
|
|
83
|
+
- **For a budget alone on Codex.** It reports no cost, so a budget never
|
|
84
|
+
stops it. Give it a `--timeout`. See
|
|
85
|
+
[Budgets](../01-concepts/13-budgets.md).
|
|
@@ -1,27 +1,13 @@
|
|
|
1
1
|
---
|
|
2
2
|
title: Agents in cloud sandboxes
|
|
3
|
-
description:
|
|
3
|
+
description: For running agents off your machine, in Vercel Sandbox, a Cloudflare container or E2B. Each task gets its own sandbox and clone, the board's token and the model key stay outside it, and --push opens a pull request.
|
|
4
4
|
---
|
|
5
5
|
|
|
6
6
|
> [!WARNING]
|
|
7
|
-
> The Vercel
|
|
8
|
-
>
|
|
9
|
-
>
|
|
10
|
-
>
|
|
11
|
-
> App. The Cloudflare runner's Worker in `templates/cloudflare-runner` has
|
|
12
|
-
> been deployed and run: the board and a private repository reached only
|
|
13
|
-
> through it, Claude Code doing a task in a repository from start to end,
|
|
14
|
-
> `--push` opening a pull request, and the container removed when the run
|
|
15
|
-
> ends. The E2B runner has run against E2B, on its Hobby plan with Claude
|
|
16
|
-
> Code: a task worked from start to end with nothing left stored after, the
|
|
17
|
-
> board's refusals and the closed hosts checked from inside, a private
|
|
18
|
-
> repository cloned, `--push` opening a pull request, a worker giving each
|
|
19
|
-
> task a sandbox, a kept snapshot started from, and a registered workflow
|
|
20
|
-
> whose steps each ran in a sandbox. Codex started there and reached its
|
|
21
|
-
> provider with the key added on the way, but has not finished a task: it
|
|
22
|
-
> was run with a key that isn't one. An E2B you run yourself has not been
|
|
23
|
-
> tried, only `E2B_DOMAIN` with E2B's own name. Treat all three
|
|
24
|
-
> runners as experimental.
|
|
7
|
+
> Experimental. The Vercel, Cloudflare and E2B runners have each worked real
|
|
8
|
+
> tasks from start to end, with `--push` opening a pull request. Not yet run
|
|
9
|
+
> live: a Cloudflare `--ready --loop` worker, dependency installs on
|
|
10
|
+
> Cloudflare, and an E2B you run yourself. Codex has run only on E2B.
|
|
25
11
|
|
|
26
12
|
## What a sandbox needs
|
|
27
13
|
|
|
@@ -41,7 +27,7 @@ mu token create --as fixer --can 'work/=read,post,react,label' --ttl 2h
|
|
|
41
27
|
export MUSTER_URL=https://board.example.com/api/board
|
|
42
28
|
export MUSTER_TOKEN=mu1... # yours: mu run reads the task and has a token made for the agent
|
|
43
29
|
mu run 12 --runner vercel --agent claude --as fixer --repo https://github.com/acme/web.git
|
|
44
|
-
mu run --ready work/ --runner cloudflare --agent
|
|
30
|
+
mu run --ready work/ --runner cloudflare --agent claude --as worker-3
|
|
45
31
|
```
|
|
46
32
|
|
|
47
33
|
What runs in the sandbox is `mu run`
|
|
@@ -59,8 +45,9 @@ policy until then. On Cloudflare the command returns once the run starts,
|
|
|
59
45
|
unless it is a `--push` run or a task of a `--ready --loop` worker, which
|
|
60
46
|
are waited on in the same way.
|
|
61
47
|
|
|
62
|
-
One length of time sets the rest. `--timeout
|
|
63
|
-
|
|
48
|
+
One length of time sets the rest. `--timeout` is how long the agent works on
|
|
49
|
+
the task: 30 minutes when you don't pass one, except on Cloudflare without
|
|
50
|
+
`--push` and outside a worker, where the Worker gives it an hour. The sandbox lives ten
|
|
64
51
|
minutes longer, to install muster and settle the task, so it is `mu run` in
|
|
65
52
|
it that fails a task that ran out of time, never the platform cutting it off.
|
|
66
53
|
A `--ready` worker's sandbox lives two hours when you pass no `--timeout`,
|
|
@@ -74,7 +61,8 @@ mu run --ready work/ --loop --runner vercel --agent claude --as worker-1 --repo
|
|
|
74
61
|
mu run --ready work/ --loop --runner cloudflare --agent claude --as worker-2 --repo https://github.com/acme/web.git --push
|
|
75
62
|
```
|
|
76
63
|
|
|
77
|
-
On
|
|
64
|
+
On each of the three clouds, `--ready` with `--loop` is a worker that stays
|
|
65
|
+
on this machine.
|
|
78
66
|
It claims the next ready task as `worker-1`, under a claim token made for
|
|
79
67
|
that task, and runs it as above in a sandbox of its own, which takes the same
|
|
80
68
|
claim: no other worker can have it, and each task gets its own clone, its own
|
|
@@ -86,8 +74,7 @@ waited on and stopped once its agent exits, before the next task is claimed,
|
|
|
86
74
|
so the Worker keeps none of them for its 15 minutes. A task whose run
|
|
87
75
|
doesn't start, or ends without saying how, is given back, ready, and its
|
|
88
76
|
token revoked. A worker stops at once when the runner refuses a start, and
|
|
89
|
-
after three failures in a row otherwise (`runner_start_failed`).
|
|
90
|
-
is covered by tests against a stand-in Worker only; it has not been run live.
|
|
77
|
+
after three failures in a row otherwise (`runner_start_failed`).
|
|
91
78
|
|
|
92
79
|
Without `--loop`, `--ready` is one sandbox, or one container, that takes
|
|
93
80
|
task after task itself, sharing one checkout, so it can't `--push`.
|
|
@@ -153,10 +140,9 @@ The agent needs `mu` and its own CLI where it runs.
|
|
|
153
140
|
before the agent starts. The image is built for pnpm, npm and yarn; it has no bun, so
|
|
154
141
|
a `bun.lock` repository says `failed (exit 127)`. A private registry, a
|
|
155
142
|
git dependency or a package fetched from anywhere else fails the install.
|
|
156
|
-
`--no-install`, the `deps` label and the reply work as on Vercel.
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
when the agent exits or `--timeout` (an hour without one) has passed. Each
|
|
143
|
+
`--no-install`, the `deps` label and the reply work as on Vercel. The Worker checks the run every minute and removes the container
|
|
144
|
+
when the agent exits or `--timeout` has passed: without one, an hour, or 30
|
|
145
|
+
minutes for a `--push` run or a worker's task. Each
|
|
160
146
|
run gets a `standard-1` container (half a vCPU, 4 GiB); set `INSTANCE` in
|
|
161
147
|
the Worker's `wrangler.jsonc` for another size. Cloudflare's default, `lite`,
|
|
162
148
|
is too small for an agent's CLI.
|