ai-agentmanager 1.21.0 → 1.22.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,13 @@
1
1
  # Changelog
2
2
 
3
+ ## 1.22.0 (2026-11-06)
4
+
5
+ - **Value.** A **Value** button (or `v`) shows what the delivered work is worth, by day, week, month and quarter: engineering hours saved (valued at your loaded hourly rate), other savings, potential revenue and strategic weight, against the AI cost and your own time (leverage, value per AI dollar). Each delivered item (its pull request merged, or done without one) gets an estimate from one short model call, with reasons; correct any figure and yours win, marked ✎ in reports. Weekly, monthly and quarterly reports (daily if you like) go to Slack and, if you choose, a Google Doc, and are saved in `~/.agentmanager/value` with `value.csv`. `agentmgr value` (`edit`, `estimate`, `report`, `set`).
6
+ - **Jira summary.** A **Jira** button (or `i`) lists every Jira or Linear issue an agent works on, the ones waiting for your review first, with a count on the button: the issue and its Jira status, where the work stands (ready for your review, needs your answer, approved but not merged, checks failing, merged), its plan (steps done, approval) and design doc (read it here, its page and Google Doc), its pull request and checks, and a link to the agent's session. **Copy** puts the list on the clipboard as a Markdown table. From the terminal: `agentmgr issues` (`--all`, `--markdown`, `--json`).
7
+ - **Pick which Jira issues get agents.** **Let me pick** in **Assistant** (`agentmgr assistant set --pick-issues on`): the assistant lists new Jira and Linear issues assigned to you under **Jira → Not started** instead of starting agents for them. Tick the ones you want and **Start**; agents start only for those. **Dismiss** takes the rest off the list for good. Also `agentmgr issues propose`, `start` and `dismiss`.
8
+ - **Explain the review, by voice.** **🔊 Explain** on each pull request (in Jira, Land and the agent's AI review) reads a short briefing for the person about to review it: the issue, what the PR does (from its design doc or walkthrough), its state and checks, what the AI review found met, missing and risky, the high-risk changes, open questions, and what's left before it can merge. It starts at once (no model call); Review's change-by-change walkthrough goes deeper.
9
+ - **Designs.** A **Designs** button (or `d`) lists every agent's design doc, the ones waiting for your review first: its name and summary from DESIGN.md, the agent and its issue, and links to read it here, its design page, its Google Doc and the specs it builds on. Search, filters and **Copy** as Markdown. `agentmgr designs` (`--waiting`, `--markdown`, `--json`).
10
+
3
11
  ## 1.21.0 (2026-11-06)
4
12
 
5
13
  - **Map: where agents are in the code.** A **Map** page (or `m`) shows a project's folders as tiles with each agent on the folders it's changing or reading now. Two agents that changed the same file are joined in red; one reading a file another changed is joined with a dashed line, the warning before they collide, and each is spelled out above the map.
package/README.md CHANGED
@@ -32,7 +32,7 @@ Run one background [Claude Code](https://claude.com/claude-code) agent per inten
32
32
  - **Standup.** Each weekday at 9:00 (or whenever you press **Standup**, or `p`), each agent with news since the last one is read aloud in a sentence or two, each in its own voice: what it did, what it's on, what it needs from you. Agents that need you go first and quiet ones are left out. It stops on an agent that needs you, with its questions beside it to answer by tap, or by voice when **Answer by voice** is on (what you say is read back, then sent when you say "send"). The wording comes from one short tool-less model call, plain wording if that fails. A Slack alert says when it's ready (Alerts). Change the time, weekends and wording in the player, or in config.json: `"standup": { "at": "09:00", "weekends": false, "ai": true, "notify": true }`. Speech is your browser's own; voice answers may be sent to your browser's maker to be turned into text.
33
33
  - **Map.** A project's folders as tiles sized by their files, with each agent as a badge on the folders it is changing (filled) or reading right now (ring), refreshed every few seconds (**Map** at the top, `m`, or `#map`). A red line joins two agents that changed the same file: they will conflict when merged. A dashed line runs from an agent reading a file to the agent that already changed it, which is the warning before they collide. Each pair is also spelled out above the map. Reading comes from the last half hour of each agent's session; changes from the conflict radar.
34
34
  - **Watch.** Every running agent's session side by side on one page, live (**Watch** at the top, or `#watch`), so you follow them all without clicking from one to the next. Tiles keep a fixed order; one waiting on you gets a red border and is counted at the top. Click a tile and type to answer it there; its name opens the agent. Show running agents, only those waiting on you or only those working, one project's, or a fixed number per row; **Fit** sizes the tiles so all of them (up to 12) are on screen, keeping the newest lines in view. Tiles show each session at its own size and never resize it.
35
- - **Keyboard shortcuts.** Press **?** for the list. `j`/`k` move through the agents, `Enter` opens the terminal, `r` reviews changes, `s` resumes, `Shift+X` closes the session, `e` edits; `n` new agents, `a` Ask Agent, `/` filter, `w` Watch, `m` Map, `p` the standup, `1`-`5` the side tabs. Single keys work when you're not typing in a field or a terminal. From inside a terminal, `Ctrl+Shift+↓`/`↑` switch to the next or previous agent's terminal and `Ctrl+Shift+L` leaves it.
35
+ - **Keyboard shortcuts.** Press **?** for the list. `j`/`k` move through the agents, `Enter` opens the terminal, `r` reviews changes, `s` resumes, `Shift+X` closes the session, `e` edits; `n` new agents, `a` Ask Agent, `/` filter, `w` Watch, `m` Map, `p` the standup, `i` the Jira summary, `d` Designs, `1`-`5` the side tabs. Single keys work when you're not typing in a field or a terminal. From inside a terminal, `Ctrl+Shift+↓`/`↑` switch to the next or previous agent's terminal and `Ctrl+Shift+L` leaves it.
36
36
  - **Landing.** A **Land** tab with every agent's open pull request: ready to merge, needs fixes, behind, waiting. Failing checks and requested changes go back to the agent automatically (a few times at most), and so does every new review comment while the PR is open; **Update**, **Ask to fix** and **Merge** in one click.
37
37
  - **Triggers.** A label on a GitHub issue starts an agent for it, `/agent …` comments on an agent's pull request reach the agent, and a webhook starts agents from Jira automation or CI. No model watches, so no tokens are spent waiting.
38
38
  - **Repo memory.** What one agent learns about a repo (how to run its tests, a gotcha) is recorded in one line and given to every later agent there.
@@ -905,7 +905,7 @@ An always-on Claude session that works on your behalf. **Assistant** in the top
905
905
 
906
906
  | It watches | What it does |
907
907
  |---|---|
908
- | Jira issues newly assigned to you | Starts an agent in the matching project, with the issue link first so the agent is named after the issue (`OPS-7`) |
908
+ | Jira issues newly assigned to you | Starts an agent in the matching project, with the issue link first so the agent is named after the issue (`OPS-7`); with **Let me pick** on, lists it under **Jira → Not started** for you to tick instead |
909
909
  | Linear issues newly assigned to you (turn it on in the dialog) | The same, with the Linear link first (`ENG-42`) |
910
910
  | New comments and mentions on your Jira issues | Passes the comment to the agent on that issue (`agentmgr tell`), or starts one if the comment asks for new work |
911
911
  | GitHub pull requests waiting for your review | Starts a review agent that drafts the review for you to post |
@@ -926,6 +926,43 @@ agentmgr assistant pause # stop checking and close the sessio
926
926
 
927
927
  Settings live in `config.json` under `"assistant"`. A running assistant reads new watch lists and notes after **Pause** and **Turn on**.
928
928
 
929
+ ### Jira summary
930
+
931
+ **Jira** in the top bar (or `i`) lists every Jira or Linear issue an agent works on (the ones started from an issue link, by you or the assistant), one row per agent. **Waiting for you** comes first, and its count shows on the button:
932
+
933
+ | Where it stands | When |
934
+ |---|---|
935
+ | Needs your answer | The agent asked a question, waits at a prompt, or its plan waits for review |
936
+ | Ready for your review | Its pull request is open, not a draft, with no review yet and checks not failing; or it finished without a pull request |
937
+ | Blocked | It says it can't go on |
938
+ | Approved, not merged yet | You approved; merging is left |
939
+
940
+ **Not started** comes before them: issues proposed for agents, each with a box to tick. Tick the ones you want and press **Start**: agents start only for those, named after the issue. **Dismiss** takes ticked ones off the list, and they aren't proposed again. Issues get there when **Let me pick** is on in **Assistant** (`agentmgr assistant set --pick-issues on`): the assistant then proposes new Jira and Linear issues assigned to you instead of starting agents for them. You can propose one yourself too: `agentmgr issues propose @cc "<issue link> what to do"`.
941
+
942
+ **Agents on it** has the ones still working, fixing failing checks or working on your review comments; **Done** the merged and closed ones. Each row shows the issue with its Jira status, the agent's plan (**Read** it here, steps done, and whether it waits for your approval) and design doc (**Read**, its design page and Google Doc), the pull request with its checks and AI review, and the agent, which opens its session. Jira status needs your site, email and API token in **Settings → Jira** (public Atlassian Cloud issues need nothing); it's fetched a few issues at a time and kept five minutes. **Copy** puts the list as a Markdown table on the clipboard, for Slack, Jira or a doc.
943
+
944
+ ```bash
945
+ agentmgr issues # not started, and waiting for your review
946
+ agentmgr issues start OPS-7 OPS-9 # start agents for proposed issues
947
+ agentmgr issues dismiss OPS-8 # not for an agent
948
+ agentmgr issues --all # and the rest
949
+ agentmgr issues --markdown # a table to paste
950
+ ```
951
+
952
+ ### Explain the review, by voice
953
+
954
+ **🔊 Explain** on a pull request (in **Jira**, **Land**, and next to **Review with AI** on the agent) reads a short spoken briefing for whoever reviews it, in this order: the issue; the PR and its state (open or draft, checks, conflicts, approved or changes requested); what it does, from the agent's design doc, else its change walkthrough; the AI review's verdict with what is met, missing and risky; the high-risk changes from the walkthrough; questions the agent is waiting on; and what's left before it can merge. It's built from what AI Agent Manager already tracks, so it starts at once; for each change in turn, use 🔊 Listen in **Review**. Pause, stop and speed are next to it while it plays.
955
+
956
+ ### Designs
957
+
958
+ **Designs** in the top bar (or `d`) lists every agent's design doc, the ones whose work waits for your review first, with their count on the button. Each shows the doc's name and the summary from its DESIGN.md, the agent (opens its session), its Jira issue and where the work stands, and links: **Read** it here, the design page the agent published, its Google Doc after **Publish to Google Drive**, and the PRDs and tech specs in the agent's brief. Search by name, summary, agent, project or issue; **Copy** puts the shown list on the clipboard as Markdown.
959
+
960
+ ```bash
961
+ agentmgr designs # all design docs
962
+ agentmgr designs --waiting # only the ones waiting for your review
963
+ agentmgr designs --markdown # a list to paste
964
+ ```
965
+
929
966
  ## Triggers
930
967
 
931
968
  Start agents from where the work lives, with no session watching and no tokens spent on it. **Assistant → Triggers…**, or `agentmgr triggers`:
@@ -945,6 +982,29 @@ Agents started this way are marked **⚡ GitHub** or **⚡ webhook**, Slack aler
945
982
  }
946
983
  ```
947
984
 
985
+ ## Value
986
+
987
+ **Value** in the top bar (or `v`) shows what the work delivered with agents is worth, for you and for management: by **Day**, **Week**, **Month** or **Quarter**, with bars for the last periods and the items behind each.
988
+
989
+ | Figure | What it is |
990
+ |---|---|
991
+ | Value delivered | Engineering hours the work saved × your loaded hourly rate, plus other savings in its first year |
992
+ | Potential revenue | Revenue the work plausibly enables or protects in its first year (kept apart: it's the least certain) |
993
+ | Strategic | Items rated 4 or 5 of 5 for moving the product or company position |
994
+ | Leverage | Engineering hours delivered per hour of your own time (30 minutes per item unless you set it) |
995
+ | AI cost | What the agents cost, and value per AI dollar |
996
+
997
+ Work counts once it's delivered: its pull request merged, or the agent finished without one. Each item gets an estimate from one short model call (at most 30 a day) based on its issue, pull request, design doc, results and AI review, with a reason for each figure. They are estimates, and conservative by instruction. **Edit** any figure, category or the one-line summary for management: yours win, are marked, and stay through re-estimates. **Don't count it** leaves an item out. **Notes for the estimates** in settings give the model your context ("B2B SaaS, ~2,000 customers; checkout work affects revenue").
998
+
999
+ Reports: **Copy report** (Markdown) or **Send** for the current period or the one just ended, and on a schedule (weekly on Mondays, monthly on the 1st and quarterly by default; daily if you turn it on; at 09:00) to Slack (with **value reports** on in Slack alerts) and, if you choose, as a Google Doc in "Value reports (AI Agent Manager)" through the Google Drive connector of your Claude account. Every report is also saved in `~/.agentmanager/value/`, next to `value.csv` with every item's figures.
1000
+
1001
+ ```bash
1002
+ agentmgr value --period month # totals by month, and this month's items
1003
+ agentmgr value edit OPS-7 --revenue 15000 --summary "Ends login timeouts for our largest customer"
1004
+ agentmgr value report --kind quarter --current # this quarter so far, as Markdown
1005
+ agentmgr value set --rate 140 --reports weekly,monthly,quarterly --at 08:30 --drive on
1006
+ ```
1007
+
948
1008
  ## Results and spend
949
1009
 
950
1010
  **Results** in the top bar shows how agents did over the last 7, 30 or 90 days (or all time): how many started and how many opened a pull request, PRs merged and closed, the merge rate, the median time from starting an agent to its first PR and to merge, and the cost per merged PR. The same by engine and model (which one gets merged more, for less), by where agents came from (you, the assistant, triggers, the backlog, teams, races) and by project. `agentmgr stats --days 30`.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "ai-agentmanager",
3
- "version": "1.21.0",
3
+ "version": "1.22.0",
4
4
  "description": "Run background coding agents (Claude Code, Codex) per intent, and keep track of them from a web UI, your phone or the CLI",
5
5
  "keywords": [
6
6
  "claude",
package/public/app.js CHANGED
@@ -25,6 +25,10 @@ import { initCode } from '/code.js';
25
25
  import { initMachine } from '/machine.js';
26
26
  import { initWatch } from '/watch.js';
27
27
  import { initStandup } from '/standup.js';
28
+ import { initIssues } from '/issues.js';
29
+ import { reviewSpeech } from '/prvoice.js';
30
+ import { initDesigns } from '/designs.js';
31
+ import { initValue } from '/value.js';
28
32
  import { initCodeMap } from '/codemap.js';
29
33
  import { initKeys } from '/keys.js';
30
34
  import { morph } from '/morph.js';
@@ -51,8 +55,9 @@ const [hashId, hashView] = loginHash ? [null, null] : (ticketHash ? goHash : loc
51
55
  const watchOnLoad = hashId === 'watch';
52
56
  const standupOnLoad = hashId === 'standup';
53
57
  const mapOnLoad = hashId === 'map';
58
+ const valueOnLoad = hashId === 'value';
54
59
  let watchShown = false;
55
- let selectedId = (watchOnLoad || standupOnLoad || mapOnLoad ? null : hashId) || null;
60
+ let selectedId = (watchOnLoad || standupOnLoad || mapOnLoad || valueOnLoad ? null : hashId) || null;
56
61
  let openTermOnLoad = hashView === 'term' || hashView === 'code' || isShell(hashView) || isBrowser(hashView);
57
62
  let filterText = '';
58
63
  // "Only agents created in the last N days": remembered in this browser.
@@ -202,6 +207,31 @@ const standupUi = initStandup({
202
207
  toast: (m, ms) => toast(m, ms),
203
208
  openAgent: (id) => (showTab('agents'), select(id)),
204
209
  });
210
+ // Jira: every issue an agent works on, the ones waiting for your review first.
211
+ const issuesUi = initIssues({
212
+ api,
213
+ $,
214
+ esc,
215
+ ago,
216
+ toast: (m, ms) => toast(m, ms),
217
+ openAgent: (id) => (showTab('agents'), select(id)),
218
+ openDoc: (id, kind) => (showTab('agents'), select(id), openDoc(id, kind)),
219
+ });
220
+ $('#issues-btn').onclick = () => issuesUi.open();
221
+ // Designs: every agent's design doc, the ones waiting for your review first.
222
+ const designsUi = initDesigns({
223
+ api,
224
+ $,
225
+ esc,
226
+ ago,
227
+ toast: (m, ms) => toast(m, ms),
228
+ openAgent: (id) => (showTab('agents'), select(id)),
229
+ openDoc: (id) => (showTab('agents'), select(id), openDoc(id, 'designdoc')),
230
+ });
231
+ $('#designs-btn').onclick = () => designsUi.open();
232
+ // Value: what the delivered work is worth, for you and for management.
233
+ const valueUi = initValue({ api, $, esc, toast: (m, ms) => toast(m, ms), openAgent: (id) => (showTab('agents'), select(id)) });
234
+ $('#value-btn').onclick = () => valueUi.open();
205
235
  // Keyboard shortcuts (keys.js): the same actions as the buttons.
206
236
  const keysUi = initKeys({ $, esc, run: (act) => shortcut(act) });
207
237
  $('#keys-btn').onclick = () => keysUi.help();
@@ -243,6 +273,9 @@ function shortcut(act) {
243
273
  if (act === 'watch') return $('#watch-btn') ? $('#watch-btn').click() : false;
244
274
  if (act === 'standup') return standupUi.open();
245
275
  if (act === 'map') return $('#map-btn').click();
276
+ if (act === 'issues') return issuesUi.open();
277
+ if (act === 'designs') return designsUi.open();
278
+ if (act === 'value') return valueUi.open();
246
279
  if (act.startsWith('tab:')) return showTab(act.slice(4));
247
280
  return false;
248
281
  }
@@ -377,7 +410,11 @@ function reviewBox(a) {
377
410
  if (noRepo(a)) return { button: '', box: '' };
378
411
  const r = a.aiReview;
379
412
  const button = `<button class="small" data-act="review" ${r?.pending ? 'disabled' : ''}
380
- title="Check the work against the intent and brief: what is met, missing or risky. A separate one-off model call; runs by itself when the agent says it is done">${r?.pending ? 'Reviewing…' : 'Review with AI'}</button>`;
413
+ title="Check the work against the intent and brief: what is met, missing or risky. A separate one-off model call; runs by itself when the agent says it is done">${r?.pending ? 'Reviewing…' : 'Review with AI'}</button>${
414
+ r?.verdict || a.prs?.some((p) => p.source !== 'mentioned' && p.state)
415
+ ? listenHtml(`prvoice:${a.id}`, { title: 'Explain the review aloud: the PR, its checks, the AI review, the riskiest changes and what is left', label: 'Explain review' })
416
+ : ''
417
+ }`;
381
418
  // An unhandled review shows as a card above the brief; a handled one stays here, compact.
382
419
  if (!r?.verdict || !r.seen) return { button, box: '' };
383
420
  return {
@@ -691,6 +728,7 @@ bindListen((id) => {
691
728
  else if (what === 'walk') parts = reviewUi.listenParts();
692
729
  else if (what === 'score') parts = a?.docs?.scorecard?.data ? scorecardSpeech(a.docs.scorecard) : null;
693
730
  else if (what === 'sidewalk') parts = sidePane?.listenParts();
731
+ else if (what === 'prvoice') parts = reviewSpeech(a, issuesUi.about(agentId));
694
732
  if (!parts?.length || !play(id, parts)) toast('Nothing to read aloud here (or this browser has no speech)');
695
733
  });
696
734
 
@@ -4102,6 +4140,11 @@ function handleEvent(msg) {
4102
4140
  watchShown = true;
4103
4141
  mapUi.show(true);
4104
4142
  }
4143
+ if (valueOnLoad && !watchShown) {
4144
+ watchShown = true;
4145
+ history.replaceState(null, '', '#');
4146
+ valueUi.open();
4147
+ }
4105
4148
  if (standupOnLoad && !watchShown) {
4106
4149
  watchShown = true;
4107
4150
  history.replaceState(null, '', '#');
@@ -4117,6 +4160,8 @@ function handleEvent(msg) {
4117
4160
  watchDocs(msg.agent);
4118
4161
  agentChanged(msg.agent);
4119
4162
  if (msg.agent.builds) builtUi.sessionChanged(msg.agent);
4163
+ issuesUi.changed();
4164
+ designsUi.changed();
4120
4165
  // The detail, terminal and document views show one agent; another agent's update leaves them be.
4121
4166
  return invalidate([
4122
4167
  'list', 'backlog', 'land', 'inbox', 'race', 'team',
@@ -4137,6 +4182,8 @@ function handleEvent(msg) {
4137
4182
  teams.set(msg.team.id, msg.team);
4138
4183
  } else if (msg.t === 'team-removed') {
4139
4184
  teams.delete(msg.id);
4185
+ } else if (msg.t === 'value') {
4186
+ valueUi.changed();
4140
4187
  } else if (msg.t === 'standup') {
4141
4188
  standupUi.set(msg.latest);
4142
4189
  if (msg.latest?.reason === 'scheduled' && msg.latest.items.length) toast('Standup ready: press Standup (or p) to play it', 8000);
@@ -4494,6 +4541,7 @@ async function loadAssistant({ fill = true } = {}) {
4494
4541
  f.maxPerDay.value = a.maxPerDay;
4495
4542
  f.maxRunning.value = a.maxRunning;
4496
4543
  f.notes.value = a.notes ?? '';
4544
+ f.pickIssues.checked = Boolean(a.pickIssues);
4497
4545
  }
4498
4546
  const state = !a.agentId ? 'Not set up yet. Start it to create its session.' : a.on ? (a.busy ? 'On: checking now.' : 'On.') : 'Paused: not checking.';
4499
4547
  $('#assistant-status').innerHTML = `<p><b>${esc(state)}</b>
@@ -4516,6 +4564,7 @@ const assistantPatch = (f) => ({
4516
4564
  maxPerDay: Number(f.maxPerDay.value),
4517
4565
  maxRunning: Number(f.maxRunning.value),
4518
4566
  notes: f.notes.value,
4567
+ pickIssues: f.pickIssues.checked,
4519
4568
  });
4520
4569
  const assistantError = (err) => {
4521
4570
  $('#assistant-error').textContent = err.message;
@@ -0,0 +1,172 @@
1
+ // Designs: every agent's design doc in one list, the ones waiting for your review first: its name
2
+ // and summary, where it's published, the specs it builds on, and the agent and its issue.
3
+
4
+ const SAVED = 'agentmgr.designsFilter';
5
+ const FILTERS = [
6
+ ['you', 'Waiting for you'],
7
+ ['agent', 'Agents on it'],
8
+ ['done', 'Done'],
9
+ ['all', 'All'],
10
+ ];
11
+
12
+ export function initDesigns({ api, $, esc, ago, openAgent, openDoc, toast }) {
13
+ const dialog = $('#designs-dialog');
14
+ const body = $('#designs-body');
15
+ let rows = null;
16
+ let loading = false;
17
+ let loadedAt = 0;
18
+ let again = null;
19
+ let query = '';
20
+ let filter = 'you';
21
+ try {
22
+ filter = localStorage.getItem(SAVED) || 'you';
23
+ } catch {}
24
+
25
+ async function load({ quiet = false } = {}) {
26
+ if (loading) return;
27
+ loading = true;
28
+ try {
29
+ rows = (await api('GET', '/designs')).rows;
30
+ loadedAt = Date.now();
31
+ } catch (e) {
32
+ if (!quiet) toast?.(e.message, 5000);
33
+ } finally {
34
+ loading = false;
35
+ }
36
+ badge();
37
+ render();
38
+ }
39
+
40
+ /** The button's count: design docs waiting for your review. */
41
+ function badge() {
42
+ const n = rows ? rows.filter((r) => r.group === 'you').length : 0;
43
+ const el = $('#designs-count');
44
+ if (el) {
45
+ el.textContent = n ? String(n) : '';
46
+ el.title = n ? `${n} design docs waiting for your review` : '';
47
+ }
48
+ }
49
+
50
+ const ext = (label, url, title = '') => `<a href="${esc(url)}" target="_blank" rel="noopener" title="${esc(title)}">${esc(label)} ↗</a>`;
51
+
52
+ function card(r) {
53
+ const links = [
54
+ r.written ? `<button class="link" data-design-read="${esc(r.agent.id)}" title="Read DESIGN.md here">Read</button>` : '<span class="hint">not written yet</span>',
55
+ r.page?.url ? ext('Design page', r.page.url, 'The Artifact the agent published') : r.page?.note ? `<span class="hint" title="${esc(r.page.note)}">page not published</span>` : '',
56
+ r.google ? ext('Google Doc', r.google) : '',
57
+ ...r.specs.map((s) => ext(s.label, s.url, s.title ?? '')),
58
+ ].filter(Boolean);
59
+ const dot = r.agent.busy ? '<span class="dot busy" title="Working"></span>' : r.agent.running ? '<span class="dot idle" title="Session open"></span>' : '';
60
+ return `<article class="design-card stage-${esc(r.stage)}">
61
+ <header>
62
+ <h3>${esc(r.title)}</h3>
63
+ <span class="hint">${esc(ago(r.updatedAt))}</span>
64
+ </header>
65
+ <div class="design-meta">
66
+ <button class="link" data-design-open="${esc(r.agent.id)}" title="Open the agent's session">${dot}${esc(r.agent.name)}</button>
67
+ ${r.agent.project ? `<span class="hint">${esc(r.agent.project)}</span>` : ''}
68
+ ${r.issue ? (r.issue.url ? ext(r.issue.key, r.issue.url) : `<span>${esc(r.issue.key)}</span>`) : ''}
69
+ <span class="design-note">${esc(r.note)}</span>
70
+ </div>
71
+ ${r.summary ? `<p class="design-summary">${esc(r.summary)}</p>` : ''}
72
+ <div class="design-links">${links.join('<span class="sep">·</span>')}</div>
73
+ </article>`;
74
+ }
75
+
76
+ function render() {
77
+ if (!dialog.open) return;
78
+ if (!rows) {
79
+ body.innerHTML = '<p class="hint">Loading…</p>';
80
+ return;
81
+ }
82
+ const count = (g) => (g === 'all' ? rows.length : rows.filter((r) => r.group === g).length);
83
+ const q = query.trim().toLowerCase();
84
+ const shown = rows
85
+ .filter((r) => filter === 'all' || r.group === filter)
86
+ .filter((r) => !q || [r.title, r.summary, r.agent.name, r.agent.project, r.issue?.key].some((s) => String(s ?? '').toLowerCase().includes(q)));
87
+ const empty = !rows.length
88
+ ? 'No design docs yet. Agents write one once their plan is settled (Design doc, on by default when you create an agent).'
89
+ : q
90
+ ? 'No design doc matches.'
91
+ : filter === 'you'
92
+ ? 'No design doc is waiting for your review.'
93
+ : 'None here.';
94
+ const focused = document.activeElement?.dataset?.designs === 'search';
95
+ body.innerHTML = `
96
+ <div class="issues-head">
97
+ <h2>Designs</h2>
98
+ <div class="chips" role="tablist">${FILTERS.map(([k, label]) => `<button class="chip ${k === filter ? 'active' : ''}" role="tab" aria-selected="${k === filter}" data-designs-filter="${k}">${label} <span class="count">${count(k)}</span></button>`).join('')}</div>
99
+ <input type="search" class="designs-search" data-designs="search" placeholder="Search" value="${esc(query)}" aria-label="Search design docs" />
100
+ <span class="spacer"></span>
101
+ <button class="small" data-designs="copy" title="Copy this list as Markdown, to paste into Slack, Jira or a doc" ${shown.length ? '' : 'disabled'}>Copy</button>
102
+ <button class="small" data-designs="refresh" title="Look again now">↻</button>
103
+ <button class="small" data-designs="close" title="Close (Esc)">Close</button>
104
+ </div>
105
+ ${shown.length ? `<div class="designs-list">${shown.map(card).join('')}</div>` : `<p class="hint issues-empty">${esc(empty)}</p>`}`;
106
+ if (focused) {
107
+ const s = body.querySelector('[data-designs="search"]');
108
+ s.focus();
109
+ s.setSelectionRange(s.value.length, s.value.length);
110
+ }
111
+ }
112
+
113
+ body.addEventListener('input', (e) => {
114
+ if (e.target.dataset.designs !== 'search') return;
115
+ query = e.target.value;
116
+ render();
117
+ });
118
+
119
+ body.addEventListener('click', async (e) => {
120
+ const o = e.target.closest('[data-design-open]');
121
+ if (o) {
122
+ dialog.close();
123
+ return openAgent(o.dataset.designOpen);
124
+ }
125
+ const rd = e.target.closest('[data-design-read]');
126
+ if (rd) {
127
+ dialog.close();
128
+ return openDoc(rd.dataset.designRead);
129
+ }
130
+ const f = e.target.closest('[data-designs-filter]');
131
+ if (f) {
132
+ filter = f.dataset.designsFilter;
133
+ try {
134
+ localStorage.setItem(SAVED, filter);
135
+ } catch {}
136
+ return render();
137
+ }
138
+ const b = e.target.closest('[data-designs]')?.dataset.designs;
139
+ if (b === 'close') return dialog.close();
140
+ if (b === 'refresh') return load();
141
+ if (b === 'copy') {
142
+ try {
143
+ const { markdown } = await api('GET', `/designs?group=${encodeURIComponent(filter)}&q=${encodeURIComponent(query)}&format=markdown`);
144
+ await navigator.clipboard.writeText(markdown);
145
+ toast?.('Copied as Markdown');
146
+ } catch (err) {
147
+ toast?.(`Couldn't copy: ${err.message}`, 5000);
148
+ }
149
+ }
150
+ });
151
+
152
+ function open() {
153
+ if (dialog.open) return dialog.close();
154
+ dialog.showModal();
155
+ render();
156
+ load();
157
+ }
158
+
159
+ /** An agent changed: look again shortly while open, and now and then for the count. */
160
+ function changed() {
161
+ if (!dialog.open && again) return;
162
+ clearTimeout(again);
163
+ const wait = dialog.open ? 1500 : Math.max(5000, 30_000 - (Date.now() - loadedAt));
164
+ again = setTimeout(() => {
165
+ again = null;
166
+ load({ quiet: true });
167
+ }, wait);
168
+ }
169
+
170
+ load({ quiet: true });
171
+ return { open, changed, isOpen: () => dialog.open };
172
+ }
package/public/index.html CHANGED
@@ -32,6 +32,9 @@
32
32
  <button id="assistant-btn" title="An always-on session that finds new work and starts agents for it">Assistant <span id="assistant-dot" class="assistant-dot" hidden></span></button>
33
33
  <button id="spend-btn" title="Results across agents (merge rate, time to PR, cost per merged PR), what they cost, and spending limits">Results <span id="spend-today" class="spend-today"></span></button>
34
34
  <button id="standup-btn" title="Today's standup: each agent's news read aloud, and what they need from you">Standup <span id="standup-dot" class="assistant-dot" hidden></span></button>
35
+ <button id="issues-btn" title="Jira: every issue an agent works on, with its Jira status, pull request and agent, the ones waiting for your review first">Jira <span id="issues-count" class="badge ready"></span></button>
36
+ <button id="designs-btn" title="Designs: every agent's design doc with its summary and links, the ones waiting for your review first">Designs <span id="designs-count" class="badge ready"></span></button>
37
+ <button id="value-btn" title="Value: what the delivered work is worth, by day, week, month and quarter, against the AI cost and your time; reports for management">Value</button>
35
38
  <button id="map-btn" title="The codebase map: where each agent is changing and reading code, and who is about to collide">Map</button>
36
39
  <button id="watch-btn" title="Running agents' sessions side by side, live: follow them all without clicking from one to the next">Watch</button>
37
40
  <button id="machine-btn" title="A terminal on this computer (your home folder), from any device you're signed in on">Terminal</button>
@@ -376,6 +379,15 @@
376
379
  </form>
377
380
  </dialog>
378
381
 
382
+ <dialog id="issues-dialog" class="issues-dialog" aria-label="Jira issues">
383
+ <div id="issues-body"></div>
384
+ </dialog>
385
+ <dialog id="designs-dialog" class="issues-dialog" aria-label="Design docs">
386
+ <div id="designs-body"></div>
387
+ </dialog>
388
+ <dialog id="value-dialog" class="issues-dialog value-dialog" aria-label="Value">
389
+ <div id="value-body"></div>
390
+ </dialog>
379
391
  <dialog id="standup-dialog" class="standup-dialog" aria-label="Standup">
380
392
  <div id="standup-body"></div>
381
393
  </dialog>
@@ -530,6 +542,7 @@
530
542
  <label class="check"><input type="checkbox" name="ev_assistant" /> is started for new work (by the assistant, a GitHub label or a webhook)</label>
531
543
  <label class="check"><input type="checkbox" name="ev_budget" /> nears or reaches its budget, or today's spend reaches the daily limit</label>
532
544
  <label class="check"><input type="checkbox" name="ev_standup" /> the daily standup is ready (with a link to play it)</label>
545
+ <label class="check"><input type="checkbox" name="ev_value" /> value reports (weekly, monthly, quarterly, as set in Value)</label>
533
546
  <label class="check"><input type="checkbox" name="ev_waiting" /> finished its turn and is idle after <input name="waitingDelaySec" type="number" min="0" class="num" />s</label>
534
547
  <label class="check"><input type="checkbox" name="skipWhenWatching" /> not while I have its terminal open</label>
535
548
  <label class="check"><input type="checkbox" name="includeIntent" /> include the intent text in the message</label>
@@ -589,6 +602,7 @@
589
602
  <label class="check"><input type="checkbox" name="src_ci" /> Failing checks on my open pull requests</label>
590
603
  <label class="check"><input type="checkbox" name="src_slack" /> Slack messages to me that ask for work</label>
591
604
  <label class="check"><input type="checkbox" name="src_linear" /> Linear issues newly assigned to me</label>
605
+ <label class="check"><input type="checkbox" name="pickIssues" /> Let me pick: list new Jira and Linear issues under <b>Jira → Not started</b>, and start agents only for the ones I tick</label>
592
606
  </fieldset>
593
607
  <div class="row three">
594
608
  <label>Check every <span class="hint">minutes</span><input name="everyMin" type="number" min="1" /></label>