create-pmos 0.361.0 → 0.363.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 (43) hide show
  1. package/package.json +40 -25
  2. package/payload/KIT-VERSION +1 -1
  3. package/payload/planning/evals/eval-calibration.md +1 -1
  4. package/payload/planning/okrs/health-budgets.md +1 -1
  5. package/payload/state/discoveries.md +1 -1
  6. package/workspace/briefing-premium-board-test.js +4 -4
  7. package/workspace/briefing-premium-calendar-2-test.js +3 -3
  8. package/workspace/briefing-premium-calendar-3-test.js +6 -5
  9. package/workspace/briefing-premium-calendar-test.js +3 -2
  10. package/workspace/briefing-premium-initiative-test.js +3 -3
  11. package/workspace/briefing-premium-insights-test.js +1 -1
  12. package/workspace/briefing-premium-test.js +26 -11
  13. package/workspace/briefing-premium-work-test.js +1 -1
  14. package/workspace/changelog.json +39 -0
  15. package/workspace/guide/briefing-premium.md +26 -21
  16. package/workspace/lib/board-premium.js +8 -3
  17. package/workspace/lib/engine/boards.js +5 -3
  18. package/workspace/lib/proactive.js +21 -3
  19. package/workspace/lib/routes-board-premium.js +1 -1
  20. package/workspace/lib/routes-boards.js +15 -1
  21. package/workspace/package-lock.json +2 -2
  22. package/workspace/package.json +1 -1
  23. package/workspace/premium-studio-test.js +6 -6
  24. package/workspace/premium-vw-item-test.js +2 -2
  25. package/workspace/premium-vw-jira-test.js +22 -6
  26. package/workspace/premium-vw-meet-test.js +32 -21
  27. package/workspace/premium-vw-notes-test.js +5 -5
  28. package/workspace/premium-vw-rec-test.js +1 -1
  29. package/workspace/public/pm/premium-board.js +3 -3
  30. package/workspace/public/pm/premium-meeting.js +28 -29
  31. package/workspace/public/pm/premium-shell.js +44 -21
  32. package/workspace/public/pm/premium-vw-jira-model.js +8 -5
  33. package/workspace/public/pm/premium-vw-jira.css +9 -0
  34. package/workspace/public/pm/premium-vw-jira.js +21 -9
  35. package/workspace/public/pm/premium-vw-meet.css +27 -7
  36. package/workspace/public/pm/premium-vw-meet.js +31 -16
  37. package/workspace/public/pm/premium.css +28 -4
  38. package/workspace/public/premium-board.html +1 -0
  39. package/workspace/public/premium-initiative.html +1 -0
  40. package/workspace/public/premium-insights.html +1 -0
  41. package/workspace/public/premium-work.html +2 -1
  42. package/workspace/public/premium.html +2 -1
  43. package/workspace/server.js +13 -2
@@ -2,7 +2,7 @@
2
2
  type: Guide
3
3
  title: "The premium Briefing (/premium.html)"
4
4
  description: "The Briefing page at /premium.html: the hero sentence, What you need to do, Today, the dock, and what each one reads from the repository."
5
- timestamp: 2026-10-20
5
+ timestamp: 2026-10-21
6
6
  ---
7
7
 
8
8
  # The premium Briefing
@@ -11,18 +11,18 @@ The premium Briefing is a page of its own at `/premium.html`. The console at `/`
11
11
 
12
12
  Every premium page uses the console's type: Space Grotesk for text, IBM Plex Mono for times and labels, and the same sizes and weights as the console. A premium page and the console at the same place read at the same size.
13
13
 
14
- A rail on the left names four places: Briefing, My work, Board and Insights. Each is a premium page. On a phone the rail is a bar at the bottom of the screen. It stays at the bottom after you type in a field and the keyboard closes.
14
+ A rail on the left has five places: Briefing, My work, **Chat**, Board and Insights. Chat is in the middle, a large round button, because the chat is the main place to work. The other four are premium pages. On a phone the rail is a bar at the bottom of the screen, and Chat rises above it. It stays at the bottom after you type in a field and the keyboard closes.
15
15
 
16
- Every premium page has the same top bar. On the left is where you are, then a round **Chat** button. On the right are the **Sources** chip, the bell and one **⋯** menu.
16
+ Every premium page has the same top bar. On the left is where you are. On the right are the **Sources** chip, the bell and one **⋯** menu.
17
17
 
18
- - **Chat** opens a conversation with Claude about the page you are on: the Briefing, My work, the board, or the initiative. On Insights, Chat opens the Insight Studio, because the Studio is that page's chat.
18
+ - **Chat** (in the rail) opens a conversation with Claude about the page you are on: the Briefing, My work, the board, or the initiative. On Insights, Chat opens the Insight Studio, because the Studio is that page's chat. An orange dot on Chat means one or more sessions are Ready or Maybe blocked; the button's name says how many.
19
19
  - **Sources** has a green dot when every source was read recently, and an orange dot when a source is old, was never read, failed, or the page could not read it. Hover to see which. A press opens the Sources dialog (see "Sources" below).
20
20
  - **The bell** is your inbox of agent results: see [The bell: what the agent has for you](#the-bell-what-the-agent-has-for-you).
21
- - **The ⋯ menu** holds **Search** (Ctrl K), **Sessions** with a count of the sessions that need you, **Console**, **Theme** (Light, Dark or Auto) and **Settings**. On the Board it also holds **Open initiatives** as Page or Popup. An orange dot on ⋯ means a newer PMOS is ready, and **Settings** then shows the version.
22
- - **On a phone** the bar is one row: the page name, Chat, the bell and ⋯. Sources moves into the ⋯ menu.
21
+ - **The ⋯ menu** holds **Search** (Ctrl K), **Console**, **Theme** (Light, Dark or Auto) and **Settings**. On the Board it also holds **Open initiatives** as Page or Popup. An orange dot on ⋯ means a newer PMOS is ready, and **Settings** then shows the version.
22
+ - **On a phone** the bar is one row: the page name, the bell and ⋯. Sources moves into the ⋯ menu.
23
23
  - **Menus.** An option that is too long for one line wraps onto the next line, and its row grows to hold it.
24
24
 
25
- **Search** (Ctrl K, or `/`) opens the search over places, initiatives, documents and your running sessions; Enter opens the result. Search and the bell only read; neither changes a record. **Console** opens the console at `/console.html`, for the places premium does not have yet. In the console, the More menu has **Open premium**, which opens this page. **Settings** opens one dialog. **Updates** comes first: the PMOS version you have, the newest published version, **Check now** and, when a newer one is ready, **Update**. Update does what the console's Settings › Updates does: it updates the kit in each workspace that is behind, then PMOS itself, which stops for about a minute and reloads the page. PMOS that runs from a checkout says to use `git pull` instead. Each workspace is a row with its kit version. PMOS checks once a day while a page is open (the console's **Check for updates** setting turns this off). **What's new** lists each published kit, newest first and grouped by day: its version, when it published, and one entry per pull request it carries: the pull request's title in bold, with its number, and under it the first sentence of its "After:" paragraph. Both are copied from the pull request when the kit is published; a parenthesis that holds code or a decision number is left out, and a pull request with no "After:" paragraph shows its title only. Kits newer than yours are tinted, and yours is marked. Five show per day; **Show more** opens the rest. Then come two choices. **Workspaces** lists the repositories PMOS works in, with Add (a folder path) and Remove; Remove forgets the address and never deletes the folder, and a refusal shows the server's reason. **Connectors** has an On/Off switch for each source the Briefing reads. Each press saves that one record. Every other setting runs on a default and stays in the console; the dialog links to it. Remove needs the page's launch nonce, so an agent session cannot call it.
25
+ **Search** (Ctrl K, or `/`) opens the search over places, initiatives, documents and your running sessions; Enter opens the result. Search and the bell only read; neither changes a record. **Console** opens the console at `/console.html`, for the places premium does not have yet. In the console, the More menu has **Open premium**, which opens this page. **Settings** opens one dialog. **Updates** comes first: the PMOS version you have, the newest published version, **Check now** and, when a newer one is ready, **Update**. Update does what the console's Settings › Updates does: it updates the kit in each workspace that is behind, then PMOS itself, which stops for about a minute and reloads the page. PMOS that runs from a checkout says to use `git pull` instead. Each workspace is a row with its kit version. PMOS checks once a day while a page is open (the console's **Check for updates** setting turns this off). **What's new** lists each published kit, newest first and grouped by day: its version, when it published, and one entry per pull request it carries: the pull request's title in bold, with its number, and under it the first sentence of its "After:" paragraph. Both are copied from the pull request when the kit is published; a parenthesis that holds code or a decision number is left out, and a pull request with no "After:" paragraph shows its title only. Kits newer than yours are tinted, and yours is marked. Five show per day; **Show more** opens the rest. Then come two choices. **Workspaces** lists the repositories PMOS works in, with Add (a folder path) and Remove; Remove forgets the address and never deletes the folder, and a refusal shows the server's reason. **Connectors** has an On/Off switch for each source the Briefing reads, then a row for every other connector your Claude session has (for example BigQuery). PMOS reads the connector names from the default profile, or from Claude Code's own settings when no profile is set. Your Claude sessions can use every connector whatever its switch says; a switch chooses only what PMOS reads on its own. Such a row is Off until you switch it on, and it says that nothing in PMOS reads it on its own yet: the switch saves your choice for a reader to come. Each press saves that one record. Every other setting runs on a default and stays in the console; the dialog links to it. Remove needs the page's launch nonce, so an agent session cannot call it.
26
26
 
27
27
  **Sources** is a dialog that lists each tracked source (Repository, Initiatives, Calendar, Jira status, My work and Tracker items) with its own state and the time it was last read. Each source except the repository has **Refresh**, and **Refresh all** reads them all again. Slack and email are read as part of My work, so they have no row of their own. A source PMOS does not track has no row: the dialog shows only what PMOS can say it read.
28
28
 
@@ -37,7 +37,7 @@ The first line of **Sources** says whether PMOS's background work is running. Wh
37
37
  - **End.** Every row has an **End** button (×) on its right: it shows when the pointer is over the row, and always on a touch screen. An idle session ends at once. A session that is Running, Ready or Maybe blocked asks first, in the row, with **End** and **Keep**. Ending stops the process and removes the row; files it already wrote stay. If it has not exited yet, the toast says so and the row stays.
38
38
  - **Idle shells.** A terminal shell with no agent in it and no output for a while folds under **Yours** into one line, "N more idle · Show", with **End all idle**. End all idle ends only those shells, never a goal or a session that needs you. PMOS opens one shell when it starts with no live session; it now checks after your sessions come back, so a restart no longer adds a shell each time.
39
39
  - **When the chat is not full screen,** a chip in the dialog's header shows the loudest dot and, for example, "2 ready". Press it to go full screen with the list. On a phone, it opens the list over the dialog, and a tap on a row switches to that session.
40
- - **Sessions in the ⋯ menu** counts the sessions that are Ready or Maybe blocked. It opens the dialog full screen on the session that needs you most. On a phone, it opens the list.
40
+ - **The dot on Chat** in the rail shows when sessions are Ready or Maybe blocked. Chat opens the page's conversation; its chip or its full-screen button shows the list. On a page with no conversation of its own, Chat opens the list itself.
41
41
  - When more than six agents are working at once, a note at the top of the list says how many, and suggests stopping the ones you are not watching. Nothing is stopped for you.
42
42
  - Terminals and new sessions stay in the console. Writing, answering and Stop need the page's launch nonce, so an agent session cannot call them.
43
43
 
@@ -164,7 +164,7 @@ In **Notes**, each next step has **Make task** when the note is linked to an ini
164
164
 
165
165
  **The recording chip.** While a note records or is paused, every premium page shows a chip at the bottom left with its name, **Open** and **Stop**. On the Briefing, while it records there, the chip has **Highlight**, **Pause**, **Focus**, **Open** (the Live notes tab) and **Stop**; a paused note has **Open**, **Resume** and **Stop**. The browser can capture audio only while the Briefing is open, because each premium page is its own page. If you leave the Briefing while it records, the browser asks first. If you leave anyway, the meeting is paused, so the record does not say "recording" for audio that nobody captures. The chip on the next page says "Paused", and **Open** takes you back to resume. A note that the server marks as recording, while the Briefing holds no recorder, shows "marked recording, but this page is not capturing audio".
166
166
 
167
- **Focus.** The dialog has a **Focus** press. Focus shows the meeting as it is now: the state (starts in, recording, paused, ended), a bar of the stretches by topic, the topic now (or the first topic before the start), the last lines of the talk with who said them, the topics, the material and the counts of decisions, next steps and questions. It reads the meeting every 3 seconds while it is open and stops when you leave it. While the note records, PMOS's companion, a read-only Claude run that sends nothing, may read the last minutes of the talk at most every 40 seconds and writes its own notes. The dialog says this before the first read. **Change** lists the topics. A press records one correction on the meeting through the console's route. If the companion is off, has not answered or has failed, Focus says so and shows only the talk. It shows no topic, line or count that the record does not hold.
167
+ **Focus.** The meeting dialog has **Focus** in its **More** menu. Focus shows the meeting as it is now: the state (starts in, recording, paused, ended), a bar of the stretches by topic, the topic now (or the first topic before the start), the last lines of the talk with who said them, the topics, the material and the counts of decisions, next steps and questions. It reads the meeting every 3 seconds while it is open and stops when you leave it. While the note records, PMOS's companion, a read-only Claude run that sends nothing, may read the last minutes of the talk at most every 40 seconds and writes its own notes. The dialog says this before the first read. **Change** lists the topics. A press records one correction on the meeting through the console's route. If the companion is off, has not answered or has failed, Focus says so and shows only the talk. It shows no topic, line or count that the record does not hold.
168
168
 
169
169
  **Replay.** When a recording is kept, the Replay part has a **Replay** press. Replay opens wide and hides the conversation panel; **Back to the meeting** puts both back. The header shows the meeting's day, start and end, length, the number of people, and the position as m:ss and as the time of day. The player plays the note's audio, with Back 10 s and 1x, 1.5x or 2x. Under it is a bar of the stretches by topic and, above the bar, one marker for each decision, next step, question and PMOS note that has a time. A ring marks a point that needs you (a question still open, or a next step with no owner). A shaded part of the bar is a gap where the recording was off. The line under the bar shows the topic being talked about and the key points near the playhead. Below are two panels: **On screen**, with the screen shot kept for that time and a strip of all shots, and **Conversation**, with the transcript and PMOS's notes. Its tabs show all lines, only the key-point lines or only PMOS's notes, and a search box narrows the lines. The key points sit in three columns: decisions, questions and next steps. **Confirm all** makes a task of each next step in the note's initiative, under its first stage; when the note has no initiative, it says to link one first. A press on a marker, stretch, key point, line or shot plays from there, and the current line is marked. A key point with no time has no play press. If no audio was kept, the playhead keeps its own clock.
170
170
 
@@ -299,16 +299,17 @@ Not drawn, because no record backs them: answers and ideas an agent files by its
299
299
 
300
300
  ## Board
301
301
 
302
- Board is the third place on the rail, at `/premium-board.html`. It reads what the production Initiatives page reads, for one board at a time, and shows a switcher only when more than one board is registered. The first time it takes a few seconds, because the routes derive every initiative. The page says "Reading the board" with the seconds, shows nothing in place of a guess, and asks again.
302
+ Board is the fourth place on the rail, after Chat, at `/premium-board.html`. It reads what the production Initiatives page reads, for one board at a time, and shows a switcher only when more than one board is registered. The first time it takes a few seconds, because the routes derive every initiative. The page says "Reading the board" with the seconds, shows nothing in place of a guess, and asks again.
303
303
 
304
304
  - **The header** counts the board's open initiatives: how many are on track, at risk, late and on hold, with a bar. A zero is shown.
305
305
  - **List** shows the late and at-risk initiatives first, then the board's now view, up to 100 loaded and 25 on screen at a time. A row shows the owner and lane, a status chip when it is not on track, how far through the workflow it is (and "derived" when the workflow engine placed it), a progress bar only when a record holds progress, and the planned finish only when an end date was set ("Not planned" otherwise). "Do this first" appears only when the first row is late.
306
306
  - **By stage** has one column for each stage of the board's workflow with the board's own count and its first five initiatives.
307
307
  - **List** and **Timeline** show ten tasks a page with Previous and Next; **By stage** shows six cards a column with Show more. **Timeline** draws a bar for each initiative that has both a start and an end date, with the days left or over, and counts the rest. With no dates on record it says so and draws nothing.
308
- - **Sprint** appears when an agent session has read Jira for the board. Otherwise it says there is none. Press it to open the sprint's facts, with the sprint as a board in a second tab: **To do**, **In progress** and **Done** columns from the last Jira read, with the goal, the dates, the days left and the points. When the board has more than one sprint, you can switch to another one. Press a card to open its ticket in another tab. A card that is on no initiative of this board is drawn, but it does not open. The board is read only: Jira owns each ticket's status and sprint, so you move tickets in Jira. Tickets with no sprint are not in this read. **Coming up** shows the next release, from the releases ledger.
308
+ - **Sprint** appears when an agent session has read Jira for the board. Otherwise it says there is none. Press it to open the sprint's facts, with the sprint as a board in a second tab: **To do**, **In progress** and **Done** columns from the last Jira read, with the dates, the days left and the points. The sprint goal is the one the Jira status check writes from the sprint's tickets, as on the console's Sprints tab, with its summary; Jira's own goal shows under it only as a reference (**In Jira: "…"**). Until the check has written one, the tab says **No goal yet**. The active and next sprints are buttons at the top. The closed sprints are behind **Past sprints**, which is shut until you press it. Press any card to open its ticket in another tab. A ticket that is on no initiative of this board shows what the sprint read holds (title, status, points and its Jira link). The board is read only: Jira owns each ticket's status and sprint, so you move tickets in Jira. Tickets with no sprint are not in this read. **Coming up** shows the next release, from the releases ledger.
309
309
  - **Open the backlog** is in the Sprint dialog and on its sprint tab. It opens the board's Jira backlog in a tab beside the dialog: the open sprints (active, then next) and then **Backlog**, the tickets in no sprint and not done. A row shows the key, title, status, points and initiative, and why a blocked ticket is blocked. **All**, **Blocked** and **Bugs** filter it (Bugs appears only when the Jira read holds the issue type). A row opens its ticket. The list holds only the tickets the board's initiatives pushed to Jira or hold under their epics, in key order: the Jira read has no rank, assignee or capacity. You move and rank tickets in Jira. With no Jira read, the tab says so.
310
+ - **Next release** shows the next release that carries an initiative of this board, the one planned after it, and the three latest past releases (**Released** when accepted, else **Past**). It reads the release records (`releases/releases.jsonl`, written from the console's Releases view); Jira fix versions alone do not make a release. With no release planned it says so and still lists the past ones. With none at all it says "No release is on record for this board, past or planned."
310
311
  - **Metrics** appears above the Initiatives card on the board of any workspace except the home one (PMOS itself), and counts from that workspace's own repository. It has four tiles. **Corrections per 100 runs** is the corrections logged on the week's runs in `planning/runs/agent-runs.jsonl`; a week with fewer than 10 runs is left blank. **Merged a week** counts the commits on the first-parent line of the trunk. **Blocked** and **Idle for a month** come from the workflow engine, which keeps no history. From the first day the card is read, PMOS keeps their counts once a day in the workspace's state folder (`board-metric-history.jsonl`), so their charts start on that day and their caption says **history starts today** (later, the date). Earlier weeks read **Not kept yet**. Move over a chart, or use the arrow keys, to read a week. A tile that cannot be counted says **Not read** and why; a repository with no run log says **No runs yet**. The line above the tiles starts with how many tiles need a look, and those tiles have a **Needs a look** chip and an orange outline. The line ends with **open Insights**, which opens the same board's Insights page. Press a tile for its definition and values, with the read-only agent beside it. A target is set on Insights, not here. A measure with a target shows it under the value, draws it as a dashed line, and carries **On target** or its gap (for example **2 short**); off target, it also has the orange outline. A measure without a target draws no line. Day and Month are off. It was tested only on made-up repositories, not on a real IDPF or microsite repository.
311
- - **The top bar** names the page and the board. With more than one board a menu switches between them, and **Chat** opens the board in the dialog with the read-only agent.
312
+ - **The top bar** names the page and the board. With more than one board a menu switches between them, and **Chat** in the rail opens the board in the dialog with the agent.
312
313
  - **Core documents** lists the board's documents with their state, cadence and writer, a summary (drafts to review, not started, up to date), a progress bar, a filter and a search. A document with a file opens in the dialog, read only, with its path and state; a draft there has **Issue it**, which marks it issued through the console's own route and sends nothing, and **Draft it again**, which starts a new draft that replaces this one (a board draft has no Edit tab). **Draft it** starts the existing read-only run that writes a draft and sends nothing; **Draft the N not started** does that for each document that can be drafted. **Open** stays on premium pages: the backlog goes to this page's initiatives, new asks to its New asks card, releases to the release dialog, a Horizon scan to the Briefing's Horizon scan, and **Set it up** for a report to Insights. **Add a document** opens a form (title, who writes it, where it lives) and saves a document the core set does not cover on the board's record, in `custom-docs.jsonl`. A document with no link reads "Not started". A document with a link to Confluence or Google Docs reads "Linked" and shows its address. PMOS does not read or sync the linked page, so a linked document is never counted as up to date. Issue and Drop are not on this page.
313
314
  - **Opening an initiative.** A click on an initiative opens its page (see "Initiative page"). **Open initiatives** (Page or Popup) in the ⋯ menu changes that: Popup opens the initiative's dialog instead, which shows its record as a grid and the path of its file, with the read-only agent beside it. The choice is kept in this browser. The dialog holds no press.
314
315
  - **New asks** sits at the top of the right column on a team board. Each ask shows where it came from and the drafted title, lane and anchor. **Accept** makes it an initiative in the first stage, through the console's accept route; **Decline** asks for a reason first. The card says when nothing is left to triage.
@@ -322,7 +323,7 @@ Not drawn, because PMOS holds no record for them: the mockup's demo measures (Ac
322
323
 
323
324
  The initiative page is at `/premium-initiative.html?id=<initiative>`. A click on a Board initiative opens it. The round back button at the top leads back to the Board. Like the Board it reads the records of the production Initiatives sheet, and the first read takes a few seconds, because the routes derive every initiative. Until they have, the page says so and shows nothing.
324
325
 
325
- - **The top bar** has a back button to the board, then the initiative's name with a menu of the board's initiatives. **Chat** opens the initiative in the dialog with the read-only agent beside it.
326
+ - **The top bar** has a back button to the board, then the initiative's name with a menu of the board's initiatives. **Chat** in the rail opens the initiative in the dialog with the agent beside it.
326
327
  - Long file names in the evidence of a check wrap inside the card instead of running past its edge.
327
328
  - **The header** shows a status chip, the owner and the planned finish. Each appears only when a record holds it. Under it, the stage strip shows how far through the board's workflow the initiative is.
328
329
  - **Overview** shows the description (the part of the record's title after " — "), then the next step with its reason, its action and what happens if you wait, as the workflow engine states them, and who it waits on. **PMOS can help** offers up to three presses that do something real: a draft of the first core document not started (the existing read-only run) and a question for the read-only agent. The health reasons and the board's warnings are shown as written.
@@ -335,13 +336,13 @@ Not drawn, because PMOS holds no record for them: the mockup's demo tasks, its J
335
336
 
336
337
  ## Insights
337
338
 
338
- Insights is the fourth place on the rail, at `/premium-insights.html`. It reads the KR metric records of the board's workspace, your saved dashboards, and the report files and report setups the console's Reports tab lists. It writes only when you press a button: a dashboard goes to the workspace's state folder (`premium-dashboards.jsonl`), and a report press goes to the report ledger through the console's own report routes. An agent session cannot make either write.
339
+ Insights is the fifth place on the rail, at `/premium-insights.html`. It reads the KR metric records of the board's workspace, your saved dashboards, and the report files and report setups the console's Reports tab lists. It writes only when you press a button: a dashboard goes to the workspace's state folder (`premium-dashboards.jsonl`), and a report press goes to the report ledger through the console's own report routes. An agent session cannot make either write.
339
340
 
340
341
  - **Charts.** One chart for each KR metric that holds at least two readings. The line runs through the readings at their dates, so a month with no reading is a gap and not a zero. The dashed line is the metric's target. The chip is the record's own line status: on its line, behind it, or well behind it. Pressing a chart, or its Details link, opens the metric's record in the dialog with the read-only agent beside it.
341
342
  - **The insight.** The page opens with one finding across the board's measures, in a large line, with the reason and its numbers under it, up to two more findings, **Ask PMOS why** (opens the measure's dialog on the Conversation tab) and **See the chart**. A measure that is short of its target, with a target date after its last reading, gets a projection: a straight line through its last four readings (all, when fewer), carried to the target date. When the line lands short, the finding says the measure will miss its target on that date at this pace, where it lands, how far short, and when it would get there. When the line lands on or past the target, it says the measure is on course. The page says how the projection is made, and no forecast line is drawn on a chart. With no KR metric, or none with two readings, the page says there is no insight yet and why.
342
343
  - **The pinned dashboard.** The card under the insight shows the pinned dashboard: its insight band (the next findings on it, past the one the page leads with), its charts and **Unpin**. When nothing is pinned, it shows All measures, marked **Not pinned**, with **Pin**. Pressing a dashboard in the list shows it in this card, with **Pin** and **Back to** the pinned one. One dashboard per board is pinned, All measures included; pillar groups cannot be pinned. The pin is a line in `premium-dashboards.jsonl` and shows on Insights only.
343
344
  - **Dashboards and reports.** One list holds the dashboards (All measures, your saved ones, then the pillars the metrics name) and then the reports (your set-up reports, then the report files). **All**, **Dashboards** and **Reports** filter it; it shows six rows to a page, with page numbers. A dashboard row shows its top finding and a pin. A report row quotes the opening sentence of its latest file; a set-up report with no file says no draft is written yet. **New** offers **Dashboard** or **Report**. Your requests and what PMOS found in your work stay at the top of the list. A saved dashboard draws its charts in the order you saved them. A chart whose record is gone, or that has fewer than two readings, is listed in its place with the reason and is not drawn.
344
- - **Open the Studio from the top.** **Chat** beside the board name opens the Insight Studio: on the saved dashboard you are looking at, otherwise on a new dashboard, or in Report mode when no measure has a series yet.
345
+ - **Open the Studio from the top.** **Chat** in the rail opens the Insight Studio: on the saved dashboard you are looking at, otherwise on a new dashboard, or in Report mode when no measure has a series yet.
345
346
  - **Make or edit a dashboard.** **+** (at the left of the report input), then **Dashboard**, or **Edit** on a saved one, opens the **Insight Studio**, a wide dialog. On the right, the brief shows the Name, Purpose, Charts and Main dashboard; press a chip to change it. **Library** lists the board's measures and saved dashboards to add. The preview draws the dashboard as the page will, and lists a measure with no series as not drawn. The checks (a name, a purpose, a chart, six or fewer, no repeat, a main dashboard on the board) say what fails, with a one-press fix. On the left you can say it instead: "add Partner activation", "remove …", "move … first", "call it …", "it is for …", "make it the main dashboard", "undo" or "start a new one". A turn changes the draft only. **Undo** steps back one change. **Save the dashboard** records it; **Remove the dashboard** asks once more and then removes it. In a chart's dialog, **On your dashboards** has a switch for each saved dashboard, which adds the chart to it or takes it off.
346
347
  - **Make your own chart.** **New chart**, or **Edit** on one of your charts, opens the Insight Studio in **Chart** mode; the switch at the top moves between Chart and Dashboard, and each keeps its own draft. The brief shows the Question, Measure, Form (line, bars, number or meter), Range (all readings or the last few) and Target; **More** adds the Title, Better when, Note and Add to (a dashboard). The Studio suggests a form from the question and says why. The checks (a question, a target, enough readings, a form that fits the question, one scale) say what fails, with a one-press fix. You can say it instead: "show it as bars", "last 4 readings", "target 35", "lower is better", "call it …", "note: …", "add it to Weekly", or a question. A pie is declined, with the reason. **Save the chart** records it in the workspace's state folder, and adds it to the dashboard you named. Your charts are listed under **All measures**, and a dashboard can hold them beside the measures. **Remove the chart** asks once more; a dashboard that held it then says it was removed.
347
348
  - **Set up a report in the Studio.** **+**, then **Report**, opens the Insight Studio in **Report** mode. The brief shows the Title, What it answers, Audience, Format, Schedule, Draw from (your work, or the board's dashboard) and the Sections. A new report always has the same sections, in the same order, so they are listed, not edited. The checks (what it answers, an audience, a format that fits the audience, a new title, the answer first) say what fails, with a one-press fix. You can say it instead: "it answers: …", "for leadership", "slides", "monthly", "every two weeks on Thursday", "call it …". **Set it up** records the report and writes its first draft as a file.
@@ -383,15 +384,19 @@ On a phone or tablet (under 1000 px) every dialog opens on **Detail**. On a touc
383
384
 
384
385
  A dialog's detail panel opens with the record's path, its heading and one lead line. A decision's evidence reads as a list. A measure's dialog draws the measure's chart above its facts and readings.
385
386
 
386
- A calendar meeting's panel follows the mockup's Design review panel: the title with a status chip (when it starts, on now, or done), **Focus** and **Record**, **Prepared for you** (what it is about, people, material and the last meeting, each Ready only when PMOS holds that record), **Material** with **Add material**, **Previous meetings** and **Topics**. What Record and Focus do is one press away under **What Record does** and **What Focus reads**.
387
+ A calendar meeting's panel is one scroll, with no Before, During and After switch. On a phone the dialog's head is short: the title, then the day and the time. When you scroll the detail, the head keeps only the title and the tools, so the detail gets most of the screen. Scroll back to the top to see the Detail and Conversation switch again.
387
388
 
388
- The panel is laid out like the console's note sheet. Under the head, a line shows the time, then what the meeting is about with **Change** (the link choice). When the meeting is part of a series, the series line names it with "N of M" and has a press for the meeting before and the one after. Each opens that meeting's notes as a tab in the viewer, and the tab pages through the series. **Not part of this series** takes the note out of the series, and **Put it back** returns it. A switch then shows one part at a time:
389
+ The detail starts with the meeting's state (when it starts, on now, or done) and its people as a count, for example **5 people**. Press the count to see the names. A line says what the meeting is about when it is linked. When the meeting is part of a series, the series line names it with "N of M" and has a press for the meeting before and the one after. Each opens that meeting's notes as a tab in the viewer, and the tab pages through the series.
389
390
 
390
- - **Before**: first the meeting prep the console's Calendar card shows: In short, What matters today (To settle in planning for a planning meeting), Since the last one with its decisions and the steps From last time, To be ready, and the meeting's links. When the note already carries in the meeting before, Since the last one is left to it. The prep is read once when the detail opens; that read is not a Focus read, and Focus still reads nothing until you open it. Then the open steps carried in from the meeting before, the agenda with each item marked when the transcript heard it, what the meeting is for, what to have ready, what to read first and the people. Prepared for you, Material, Previous meetings and Topics follow.
391
- - **During**: the transcript the note holds, with times. On the Briefing, while the note records or is paused there, During is the live capture instead, the same as the **Live notes** tab: Recording or Paused, **Highlight**, **Pause** or **Resume**, **Stop**, **Private**, **Your notes**, the highlights and the live transcript.
392
- - **After**: **Since the last one** (each step from the meeting before as Done, Raised again or Not mentioned, and the new steps), the replay, the summary, a table of decisions with their why, a table of next steps with owner, due and **Make task**, the open questions, the screenshots of the shared screen and the transcript, folded.
391
+ **Record** is the one press up front, and only for a meeting that can be recorded now. **More** holds the rest: **Focus**, **Change what it is about** (or **Choose what it is about**, the link choice), **Not part of this series** when the meeting is in a series, and **What Record and Focus do**. A note taken out of its series shows **Put it back** on the series line.
393
392
 
394
- The switch opens on During while the note records, on After once there are notes, and on Before otherwise. A part with no record behind it says so. A private note shows none of its notes.
393
+ Then the parts. The part that fits the meeting comes first and open: **Transcript and live notes** while the note records or is paused, **Notes and next steps** once there are notes, and **Prep and material** otherwise. The other parts follow, folded. Press a part's head to open or fold it. A part you open stays open while the dialog is open.
394
+
395
+ - **Prep and material**: first the meeting prep the console's Calendar card shows: In short, What matters today (To settle in planning for a planning meeting), Since the last one with its decisions and the steps From last time, To be ready, and the meeting's links. When the note already carries in the meeting before, Since the last one is left to it. The prep is read once when the detail opens; that read is not a Focus read, and Focus still reads nothing until you open it. Then the open steps carried in from the meeting before, the agenda with each item marked when the transcript heard it, what the meeting is for, what to have ready, what to read first and the people. **Prepared for you** (what it is about, the first two people and how many more, material and the last meeting, each Ready only when PMOS holds that record), **Material** with **Add material**, **Previous meetings** and **Topics** follow.
396
+ - **Transcript and live notes**: the transcript the note holds, with times. On the Briefing, while the note records or is paused there, this part is the live capture instead, the same as the **Live notes** tab: Recording or Paused, **Highlight**, **Pause** or **Resume**, **Stop**, **Private**, **Your notes**, the highlights and the live transcript.
397
+ - **Notes and next steps**: **Since the last one** (each step from the meeting before as Done, Raised again or Not mentioned, and the new steps), the replay, the summary, a table of decisions with their why, a table of next steps with owner, due and **Make task**, the open questions, the screenshots of the shared screen and the transcript, folded.
398
+
399
+ A part with no record behind it says so. A private note shows none of its notes. A meeting's note opened as a viewer tab uses the same parts in one scroll.
395
400
 
396
401
  A document opens in one sheet on both the Board and the initiative page. Its status line shows the state, the version, the checks, the file and the last change; the file's path and front matter sit behind the file chip. The outline lists the headings at their depth, with **Find a heading** when there are many and **Hide the outline**. The body shows lists, tables, bold, code and links. A board draft keeps **Issue it** and **Draft it again**.
397
402
 
@@ -12,6 +12,7 @@
12
12
  * sprints GET /api/boards/sprints → { source: 'jira'|'none', readAt, sprints: [{ name, state, start, end, counts: { todo, doing, done } }] }
13
13
  * docs GET /api/core-docs?level=board → { scope, summary, docs: [{ key, title, for, cadence, by, kind, st, act, running }] }
14
14
  * nextRelease { id, type, at } | null
15
+ * pastReleases [{ id, type, at, name, ini, accepted }] the board's release history, the latest first (at most 3)
15
16
  * held, cancelled, archived GET /api/boards/backlog?view=all&status=on hold | status=cancelled | archived=1 → rows (initiative premium-board-actions)
16
17
  * asks GET /api/boards/asks → asks [{ id, line, source, by, at, draft: { title, lane, anchor_suggestion } }]; null when it was not read
17
18
  *
@@ -146,12 +147,16 @@ function build(f) {
146
147
  return { name: r.name || r.id, tag, at: shortDate(String(r.at).slice(0, 10)), days: rd, away: rd != null ? (rd === 0 ? 'today' : rd + ' ' + plural(rd, 'day', 'days') + ' away') : '', type: r.type || '',
147
148
  ini: (r.ini || []).map((id) => rows.find((x) => x.id === id)).filter(Boolean).map((x) => ({ id: x.id, key: x.key, title: x.title, status: x.statusLabel || '', tone: x.late ? 'bad' : x.bad ? 'warn' : '' })) };
148
149
  };
150
+ // the board's release history, as the console's Released list shows it: accepted ones say Released, the others Past
151
+ const past = (f.pastReleases || []).filter((r) => r && r.at).map((r) => Object.assign(relOf(r, r.accepted ? 'Released' : 'Past'), { away: '' }));
149
152
  const release = nr && nr.at
150
- ? { ...relOf(nr, 'Next'), cap: relOf(nr, 'Next').away, rel: [relOf(nr, 'Next')].concat(nr.later && nr.later.at ? [relOf(nr.later, 'Planned')] : []) }
151
- : { cap: 'none', why: 'No release is planned for this board. A release appears here when one carries an initiative of this board.', rel: [] };
153
+ ? { ...relOf(nr, 'Next'), cap: relOf(nr, 'Next').away, rel: [relOf(nr, 'Next')].concat(nr.later && nr.later.at ? [relOf(nr.later, 'Planned')] : [], past) }
154
+ : past.length
155
+ ? { cap: 'none planned', rel: past, why: 'No release is planned for this board. The latest releases are listed below.' }
156
+ : { cap: 'none', why: 'No release is on record for this board, past or planned. A release appears here when a release record carries one of this board\'s initiatives.', rel: [] };
152
157
  const relRow = release.rel.length ? (() => {
153
158
  const rs = release.rel.flatMap((r) => [[r.name + ' · ' + r.tag, [r.at, r.away].filter(Boolean).join(' · ') + (r.type ? ' · ' + r.type : '')]].concat(r.ini.map((i) => ['Rides on it', i.title + (i.status ? ' · ' + i.status : '')])));
154
- return { key: 'board:release', id: null, title: release.name, sub: 'Release', dialog: { eye: 'Release', logTitle: 'Read from the releases', log: ['Read the releases that carry an initiative of this board', 'Took the earliest date from today on', 'Changed nothing'], say: release.name + ' is next: ' + release.at + ', ' + release.away + '.', head: 'Where it stands', facts: rs, hold: 'This dialog changes nothing.', pane: { label: 'Release', file: '', note: 'The releases as the release records hold them.', rows: rs } } };
159
+ return { key: 'board:release', id: null, title: release.name || past[0].name, sub: 'Release', dialog: { eye: 'Release', logTitle: 'Read from the releases', log: ['Read the releases that carry an initiative of this board', 'Took the earliest date from today on, and the latest before today', 'Changed nothing'], say: release.name ? release.name + ' is next: ' + release.at + ', ' + release.away + '.' : 'No release is planned. The latest was ' + past[0].name + ', ' + past[0].at + '.', head: 'Where it stands', facts: rs, hold: 'This dialog changes nothing.', pane: { label: 'Release', file: '', note: 'The releases as the release records hold them.', rows: rs } } };
155
160
  })() : null;
156
161
 
157
162
  const dd = f.docs || null;
@@ -627,6 +627,8 @@ function flowOf(issues) {
627
627
  const rank = { todo: 0, doing: 1, done: 2 };
628
628
  return [...by.values()].sort((a, b) => (rank[a.category] - rank[b.category]) || (b.n - a.n));
629
629
  }
630
+ // a sprint ticket carries its Jira page where the reading holds one, so a premium ticket tab can link to it
631
+ const urlOf = (t) => (typeof t.url === 'string' && /^https:\/\//.test(t.url) ? { url: t.url } : {});
630
632
  function sprintsOf(snapshots, onBoard = () => true, whole = null, notes = null, opts = {}) {
631
633
  const byName = new Map();
632
634
  let readAt = null;
@@ -644,7 +646,7 @@ function sprintsOf(snapshots, onBoard = () => true, whole = null, notes = null,
644
646
  if (!sp.start && typeof t.sprint.start === 'string' && t.sprint.start) sp.start = t.sprint.start; // the sprint's dates, as Jira holds them
645
647
  if (!sp.end && typeof t.sprint.end === 'string' && t.sprint.end) sp.end = t.sprint.end;
646
648
  const category = ['todo', 'doing', 'done'].includes(t.category) ? t.category : 'todo';
647
- sp.issues.push({ key: t.key, summary: t.summary || '', status: t.status || '', category, initiative: s.initiative, flagged: !!t.flagged, reason: t.flagged && t.reason ? String(t.reason) : null, points: ptsOf(t) });
649
+ sp.issues.push({ key: t.key, summary: t.summary || '', status: t.status || '', category, initiative: s.initiative, flagged: !!t.flagged, reason: t.flagged && t.reason ? String(t.reason) : null, points: ptsOf(t), ...urlOf(t) });
648
650
  sp.counts[category]++;
649
651
  }
650
652
  }
@@ -662,7 +664,7 @@ function sprintsOf(snapshots, onBoard = () => true, whole = null, notes = null,
662
664
  ...all.map((t) => {
663
665
  const category = ['todo', 'doing', 'done'].includes(t.category) ? t.category : 'todo';
664
666
  const o = own.get(t.key);
665
- return { key: t.key, summary: t.summary || '', status: t.status || '', category, initiative: o ? o.initiative : null, flagged: !!t.flagged, reason: t.flagged && t.reason ? String(t.reason) : null, points: ptsOf(t) };
667
+ return { key: t.key, summary: t.summary || '', status: t.status || '', category, initiative: o ? o.initiative : null, flagged: !!t.flagged, reason: t.flagged && t.reason ? String(t.reason) : null, points: ptsOf(t), ...urlOf(t.url ? t : o || {}) };
666
668
  }),
667
669
  ...sp.issues.filter((i) => !keys.has(i.key)), // a board ticket the sprint read has not seen yet keeps its own reading
668
670
  ];
@@ -685,7 +687,7 @@ function sprintsOf(snapshots, onBoard = () => true, whole = null, notes = null,
685
687
  if (!(n.themes || []).some((t) => t && t.initiative && onBoard(t.initiative))) continue;
686
688
  const issues = wt.filter((t) => t && t.key && t.sprint && same(t.sprint, n)).map((t) => {
687
689
  const category = ['todo', 'doing', 'done'].includes(t.category) ? t.category : 'todo';
688
- return { key: t.key, summary: t.summary || '', status: t.status || '', category, initiative: iniOf.get(t.key) || null, flagged: !!t.flagged, reason: t.flagged && t.reason ? String(t.reason) : null, points: ptsOf(t) };
690
+ return { key: t.key, summary: t.summary || '', status: t.status || '', category, initiative: iniOf.get(t.key) || null, flagged: !!t.flagged, reason: t.flagged && t.reason ? String(t.reason) : null, points: ptsOf(t), ...urlOf(t) };
689
691
  });
690
692
  const counts = { todo: 0, doing: 0, done: 0 };
691
693
  for (const i of issues) counts[i.category]++;
@@ -40,6 +40,15 @@ const SCOPE_SERVICES = ['slack', 'jira', 'confluence'];
40
40
  const SCOPE_LEVELS = ['watch', 'search', 'ignore'];
41
41
  const MAX_SCOPE_NAMES = 50;
42
42
  const MAX_WEBSITES = 10;
43
+ // The other connectors of the PM's Claude session (BigQuery, Sheets, ...): name → on. Nothing reads one yet, so a connector
44
+ // with no entry is off, and the switch only records the PM's choice for a reader to come (premium Settings › Connectors).
45
+ const MAX_CONNECTORS = 100;
46
+ // A connector name → the brief source it already backs, or null. Atlassian backs both Jira and Confluence.
47
+ const CONNECTOR_SOURCE = [[/calendar/i, 'calendar'], [/wispr/i, 'wispr'], [/gmail|outlook|\bmail\b/i, 'mail'], [/slack/i, 'slack'], [/atlassian|jira/i, 'jira'],
48
+ [/confluence/i, 'confluence'], [/github/i, 'github'], [/drive/i, 'drive'], [/figma/i, 'figma']];
49
+ const connectorSource = (name) => { const hit = CONNECTOR_SOURCE.find(([re]) => re.test(String(name || ''))); return hit ? hit[1] : null; };
50
+ /** The name a person knows a connector by: Claude Code keeps a claude.ai connector as "claude.ai <Name>". */
51
+ const connectorLabel = (name) => String(name || '').replace(/^claude\.ai\s+/i, '').trim();
43
52
  // G22: the daytime check — every 30 or 60 minutes, or off (0), between start and end of the working day.
44
53
  const DAY_CHECK_EVERY = [0, 30, 60];
45
54
  const DAY_CHECK_DEFAULT = Object.freeze({ every: 60, start: '09:00', end: '18:00' });
@@ -49,7 +58,7 @@ const DAY_CHECK_DEFAULT = Object.freeze({ every: 60, start: '09:00', end: '18:00
49
58
  const ABOUT_MAX = Object.freeze({ role: 80, work: 200, duties: 1000 });
50
59
  const ABOUT_DEFAULT = Object.freeze({ role: '', work: '', duties: '' });
51
60
  const DEFAULTS = Object.freeze({ name: '', about: ABOUT_DEFAULT, briefSources: BRIEF_DEFAULT, briefScoring: false, backgroundPrepare: false, enabled: true, triggers: Object.freeze(Object.fromEntries(TRIGGERS.map((t) => [t, true]))), stalledDays: 5, quiet: null, pauseLearning: false,
52
- scopes: Object.freeze({ slack: Object.freeze({}), jira: Object.freeze({}), confluence: Object.freeze({}) }), placeRepos: Object.freeze({ slack: Object.freeze({}), jira: Object.freeze({}), confluence: Object.freeze({}) }), dayCheck: DAY_CHECK_DEFAULT, websites: Object.freeze([]) });
61
+ scopes: Object.freeze({ slack: Object.freeze({}), jira: Object.freeze({}), confluence: Object.freeze({}) }), placeRepos: Object.freeze({ slack: Object.freeze({}), jira: Object.freeze({}), confluence: Object.freeze({}) }), dayCheck: DAY_CHECK_DEFAULT, websites: Object.freeze([]), connectors: Object.freeze({}) });
53
62
 
54
63
  const idOf = (key) => crypto.createHash('sha1').update(String(key)).digest('hex').slice(0, 12);
55
64
  const clip = (s, n) => String(s == null ? '' : s).replace(/\s+/g, ' ').trim().slice(0, n);
@@ -183,7 +192,7 @@ const HHMM = /^([01]\d|2[0-3]):([0-5]\d)$/;
183
192
  function normalizeSettings(raw) {
184
193
  const r = raw && typeof raw === 'object' ? raw : {};
185
194
  const s = { name: DEFAULTS.name, about: { ...ABOUT_DEFAULT }, briefSources: { ...BRIEF_DEFAULT }, briefScoring: DEFAULTS.briefScoring, backgroundPrepare: DEFAULTS.backgroundPrepare, enabled: DEFAULTS.enabled, triggers: { ...DEFAULTS.triggers }, stalledDays: DEFAULTS.stalledDays, quiet: DEFAULTS.quiet, pauseLearning: DEFAULTS.pauseLearning,
186
- scopes: { slack: {}, jira: {}, confluence: {} }, placeRepos: { slack: {}, jira: {}, confluence: {} }, dayCheck: { ...DAY_CHECK_DEFAULT }, websites: [] };
195
+ scopes: { slack: {}, jira: {}, confluence: {} }, placeRepos: { slack: {}, jira: {}, confluence: {} }, dayCheck: { ...DAY_CHECK_DEFAULT }, websites: [], connectors: {} };
187
196
  if (r.enabled !== undefined) { if (typeof r.enabled !== 'boolean') return { ok: false, error: 'enabled must be true or false' }; s.enabled = r.enabled; }
188
197
  if (r.name !== undefined) { if (typeof r.name !== 'string' || r.name.length > 40) return { ok: false, error: 'name must be text of at most 40 characters' }; s.name = r.name.replace(/\s+/g, ' ').trim(); }
189
198
  if (r.about !== undefined) {
@@ -204,6 +213,15 @@ function normalizeSettings(raw) {
204
213
  s.briefSources[k] = v;
205
214
  }
206
215
  }
216
+ if (r.connectors !== undefined) {
217
+ if (!r.connectors || typeof r.connectors !== 'object' || Array.isArray(r.connectors)) return { ok: false, error: 'connectors must be an object of connector name → true or false' };
218
+ for (const [k, v] of Object.entries(r.connectors)) {
219
+ if (!k.trim() || k.length > 120) return { ok: false, error: 'a connector name is 1 to 120 characters' };
220
+ if (typeof v !== 'boolean') return { ok: false, error: `connector "${k}" must be true or false` };
221
+ s.connectors[k] = v;
222
+ }
223
+ if (Object.keys(s.connectors).length > MAX_CONNECTORS) return { ok: false, error: `connectors has ${Object.keys(s.connectors).length} names — at most ${MAX_CONNECTORS}` };
224
+ }
207
225
  if (r.pauseLearning !== undefined) { if (typeof r.pauseLearning !== 'boolean') return { ok: false, error: 'pauseLearning must be true or false' }; s.pauseLearning = r.pauseLearning; }
208
226
  if (r.triggers !== undefined) {
209
227
  if (!r.triggers || typeof r.triggers !== 'object' || Array.isArray(r.triggers)) return { ok: false, error: `triggers must be an object of ${TRIGGERS.join(', ')} → true or false` };
@@ -287,4 +305,4 @@ function inQuietHours(nowMs, quiet) {
287
305
  return a < b ? m >= a && m < b : m >= a || m < b;
288
306
  }
289
307
 
290
- module.exports = { BRIEF_SOURCES, SCOPE_SERVICES, SCOPE_LEVELS, MAX_SCOPE_NAMES, MAX_WEBSITES, DAY_CHECK_EVERY, TRIGGERS, VERDICTS, EVENTS, DEFAULTS, DEDUPE_MS, DISMISS_MS, BASE, detect, rank, newSignals, dismissedIds, validateFeedback, normalizeSettings, inQuietHours };
308
+ module.exports = { BRIEF_SOURCES, MAX_CONNECTORS, connectorSource, connectorLabel, SCOPE_SERVICES, SCOPE_LEVELS, MAX_SCOPE_NAMES, MAX_WEBSITES, DAY_CHECK_EVERY, TRIGGERS, VERDICTS, EVENTS, DEFAULTS, DEDUPE_MS, DISMISS_MS, BASE, detect, rank, newSignals, dismissedIds, validateFeedback, normalizeSettings, inQuietHours };
@@ -85,7 +85,7 @@ module.exports = {
85
85
  try { const w = ctx.getWs ? ctx.getWs(pick.ws) : null; custom = w ? Custom.list(w.root, 'board:' + pick.id) : []; } catch { custom = []; missing.push('added documents'); }
86
86
  const model = BoardPremium.build({
87
87
  now: Date.now(), pending: false, missing: missing.filter((m) => m !== 'core documents'), boards: all.map((x) => ({ ws: x.ws, id: x.id, name: x.name })),
88
- board: head.body.board, counts: head.body.counts, nextRelease: head.body.nextRelease || null,
88
+ board: head.body.board, counts: head.body.counts, nextRelease: head.body.nextRelease || null, pastReleases: head.body.pastReleases || [],
89
89
  rows: listOf(rk, nw), columns: c ? c.columns : [], sprints: s || { source: 'none', sprints: [] }, docs: d, custom,
90
90
  held: hd ? hd.rows : [], cancelled: cn ? cn.rows : [], archived: ar ? ar.rows : [], asks: ak ? ak.asks || [] : null,
91
91
  });
@@ -348,6 +348,19 @@ function nextReleaseOf(releases, ids) {
348
348
  // the next one, with the one after it (the mockup's Planned row)
349
349
  return hits[0] ? { ...hits[0], later: hits[1] || null } : null;
350
350
  }
351
+ /** The past releases that carry an initiative of the board, the latest first (at most `n`): the board's release history. */
352
+ function pastReleasesOf(releases, ids, n = 3) {
353
+ const day = today();
354
+ const hits = [];
355
+ for (const r of releases) {
356
+ const on = (r.initiative_ids || []).filter((x) => ids.has(x));
357
+ if (!on.length) continue;
358
+ const at = r.release_at || r.deploy_at;
359
+ if (!at || at.slice(0, 10) >= day) continue;
360
+ hits.push({ id: r.id, type: r.type, at, name: r.fix_version || r.id, ini: on, accepted: !!r.accepted_at });
361
+ }
362
+ return hits.sort((x, y) => String(y.at).localeCompare(String(x.at))).slice(0, n);
363
+ }
351
364
  const openAsks = (folded, boardId) => [...folded.asks.values()].filter((a) => a.board === boardId && a.state === 'open').length;
352
365
  const pageAsk = (a) => ({ ...a, by: actorLib.pageName(a.by) });
353
366
  const pageMove = (m) => ({ ...m, by: actorLib.pageName(m.by) });
@@ -461,8 +474,9 @@ const READS = {
461
474
  if (!r) return;
462
475
  const c = B.counts(r.rows, r.board.workflow);
463
476
  const recent = r.fr.folded.moves.filter((m) => m.board === r.board.id).slice(-10).reverse().map(pageMove);
477
+ const rels = readReleases(ctx), ids = new Set(r.rows.map((x) => x.id));
464
478
  ctx.json(res, { ok: true, board: { ...r.board, health: B.health(r.rows) }, counts: { total: c.total, open: c.open, byStage: c.byStage, byStatus: c.byStatus, byCat: c.byCat },
465
- asks: openAsks(r.fr.folded, r.board.id), nextRelease: nextReleaseOf(readReleases(ctx), new Set(r.rows.map((x) => x.id))), recent });
479
+ asks: openAsks(r.fr.folded, r.board.id), nextRelease: nextReleaseOf(rels, ids), pastReleases: pastReleasesOf(rels, ids), recent });
466
480
  },
467
481
  '/api/boards/backlog': (ctx, res, url) => {
468
482
  const r = boardRead(ctx, res, url);
@@ -1,12 +1,12 @@
1
1
  {
2
2
  "name": "pmos-workspace",
3
- "version": "0.361.0",
3
+ "version": "0.363.0",
4
4
  "lockfileVersion": 3,
5
5
  "requires": true,
6
6
  "packages": {
7
7
  "": {
8
8
  "name": "pmos-workspace",
9
- "version": "0.361.0",
9
+ "version": "0.363.0",
10
10
  "license": "MIT",
11
11
  "dependencies": {
12
12
  "@xterm/addon-fit": "^0.11.0",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "pmos-workspace",
3
- "version": "0.361.0",
3
+ "version": "0.363.0",
4
4
  "private": true,
5
5
  "description": "PMOS Terminal Workspace — local companion hosting real PTYs beside the library and gates (D62)",
6
6
  "license": "MIT",
@@ -63,9 +63,9 @@ const saved = async () => { const j = await (await fetch(BASE + '/api/insights-p
63
63
  const open = async (sel) => { if (sel === '#pdNew' || sel === '#repNew') await p.click('#listNew'); await p.click(sel); await until(() => p.evaluate(() => document.querySelector('#dlg').classList.contains('on') && !!document.querySelector('#oMain .stu'))); await sleep(300); };
64
64
  const shut = async () => { for (let i = 0; i < 2 && await p.evaluate(() => document.querySelector('#dlg').classList.contains('on')); i++) { await p.keyboard.press('Escape'); await sleep(150); } };
65
65
 
66
- /* O0: the bar's Chat button opens the Studio on the dashboard shown (premium-topbar: the Studio is this page's chat) */
67
- ok('O0 the bar has the Chat button, no label, named for the Studio (premium-topbar)', await p.evaluate(() => { const b = document.querySelector('#crAsk'); return !!b && b.textContent.trim() === '' && !!b.querySelector('svg') && b.getAttribute('aria-label') === 'Open the Insight Studio'; }));
68
- await open('#crAsk');
66
+ /* O0: the rail's Chat opens the Studio on the dashboard shown (premium-chat-rail: the Studio is this page's chat) */
67
+ ok('O0 the bar has no chat button; Chat is the rail\'s middle place (premium-chat-rail)', await p.evaluate(() => !document.querySelector('#crAsk') && !!document.querySelector('.rail [data-go="chat"] svg')));
68
+ await open('.rail [data-go="chat"]');
69
69
  ok('O0b Chat opens the Studio', await p.evaluate(() => /^Insight Studio · /.test(document.querySelector('#dEye').textContent)));
70
70
  await shut();
71
71
  /* O: New dashboard opens the Studio */
@@ -166,9 +166,9 @@ const saved = async () => { const j = await (await fetch(BASE + '/api/insights-p
166
166
  for (const theme of ['light', 'dark']) {
167
167
  const c2 = await browser.newContext({ viewport: { width: 390, height: 844 }, colorScheme: theme }), q = await c2.newPage();
168
168
  await q.goto(BASE + '/premium-insights.html');
169
- await until(() => q.evaluate(() => !!document.querySelector('#crAsk') && !!document.querySelector('#listRows .dmr')));
170
- const pill = await q.evaluate(() => { const b = document.querySelector('#crAsk'), r = b.getBoundingClientRect(); return { txt: b.textContent.trim(), w: r.width, h: r.height, right: r.right, vw: innerWidth, vis: !!b.offsetParent }; });
171
- ok(`F0 at 390 px (${theme}) the Chat button shows, fits the width and is 44 px`, pill.vis && pill.right <= pill.vw && Math.round(pill.h) >= 44 && Math.round(pill.w) >= 44, JSON.stringify(pill));
169
+ await until(() => q.evaluate(() => !!document.querySelector('.rail [data-go="chat"]') && !!document.querySelector('#listRows .dmr')));
170
+ const pill = await q.evaluate(() => { const b = document.querySelector('.rail [data-go="chat"] .orb'), r = b.getBoundingClientRect(); return { txt: b.textContent.trim(), w: r.width, h: r.height, right: r.right, vw: innerWidth, vis: !!b.offsetParent }; });
171
+ ok(`F0 at 390 px (${theme}) the rail's Chat shows, fits the width and is 44 px`, pill.vis && pill.right <= pill.vw && Math.round(pill.h) >= 44 && Math.round(pill.w) >= 44, JSON.stringify(pill));
172
172
  await q.click('#listNew'); await q.click('#pdNew'); await until(() => q.evaluate(() => !!document.querySelector('#oMain .stu'))); await sleep(400);
173
173
  // measured once the dialog has finished opening: its rise animation scales the targets while it runs
174
174
  const measure = () => q.evaluate(() => {
@@ -78,7 +78,7 @@ process.on('unhandledRejection', (e) => { console.error(e); finish(1); });
78
78
  s = await st(page);
79
79
  ok('R9 the initiative link brings the open initiative tab forward, not a second one', s.on === INI && s.ids.length === 2, JSON.stringify(s));
80
80
  await page.keyboard.press('Escape'); await until(() => page.evaluate(() => !document.querySelector('#dlg').classList.contains('on')));
81
- await page.click('#crAsk'); await until(() => page.evaluate(() => document.querySelector('#dlg').classList.contains('on')));
81
+ await page.click('.rail [data-go="chat"]'); await until(() => page.evaluate(() => document.querySelector('#dlg').classList.contains('on')));
82
82
  s = await st(page);
83
83
  ok('R9 a new dialog starts with no extra tab; the initiative\'s own dialog offers Open the full record', s.ids.length === 0 && await page.evaluate(() => /Open the full record/.test((document.querySelector('#oMain [data-vwopen]') || {}).textContent || '')), JSON.stringify(s));
84
84
  ok('R9 no page error', S.errors.length === 0, S.errors.join(' | '));
@@ -88,7 +88,7 @@ process.on('unhandledRejection', (e) => { console.error(e); finish(1); });
88
88
  /* R6 a route that is reading, then fails */
89
89
  {
90
90
  const { page, ctx, S } = await open({ answer: (n) => (n === 1 ? { status: 200, body: { ok: true, state: 'ready', model: MODEL } } : n <= 3 ? { status: 202, body: { ok: true, state: 'reading' } } : { status: 500, body: { ok: false, state: 'error', error: 'the board could not be read' } }) });
91
- await page.click('#crAsk'); await until(() => page.evaluate(() => document.querySelector('#dlg').classList.contains('on')));
91
+ await page.click('.rail [data-go="chat"]'); await until(() => page.evaluate(() => document.querySelector('#dlg').classList.contains('on')));
92
92
  await page.evaluate(() => window.__premiumWorkItem.openWorkItem({ kind: 'initiative', id: 'other-two', title: 'Other' }));
93
93
  ok('R6 while the route reads, the tab says so', await until(async () => /Reading the initiative/.test(await paneTxt(page, 'item:ini:other-two')), 3000));
94
94
  ok('R6 a failed read says what failed and invents nothing', await until(async () => /could not be read: the board could not be read/.test(await paneTxt(page, 'item:ini:other-two')), 8000), await paneTxt(page, 'item:ini:other-two'));
@@ -33,13 +33,16 @@ const SP = { name: 'Sprint 14', state: 'active', start: '2026-10-07', end: '2026
33
33
  const SPRINTS = {
34
34
  ok: true, ws: 'w1', board: 'w1', source: 'jira', readAt: new Date().toISOString(), velocity: [],
35
35
  sprints: [
36
- { ...SP, goal: { from: 'tickets', text: 'Ship guided setup to new workspaces' }, points: { committed: 10, done: 3, unestimated: 0 }, pace: { daysLeft: 2 }, counts: { todo: 2, doing: 1, done: 1 },
36
+ { ...SP, goal: { from: 'tickets', text: 'Ship guided setup to new workspaces', jira: 'Setup' }, summary: 'Three tickets on guided setup, one blocked.', points: { committed: 10, done: 3, unestimated: 0 }, pace: { daysLeft: 2 }, counts: { todo: 2, doing: 1, done: 1 },
37
37
  issues: [
38
38
  { key: 'PMOS-142', summary: 'Migration check for older workspaces', status: 'To Do', category: 'todo', initiative: 'self-serve-v2', flagged: true, reason: 'Flagged in Jira', points: 5 },
39
39
  { key: 'PMOS-141', summary: 'Setup drops custom fields', status: 'Code review', category: 'doing', initiative: 'self-serve-v2', flagged: false, reason: null, points: 2 },
40
40
  { key: 'PMOS-138', summary: 'Guided setup copy', status: 'Done', category: 'done', initiative: 'self-serve-v2', flagged: false, reason: null, points: 3 },
41
- { key: 'OPS-9', summary: 'Rotate keys', status: 'To Do', category: 'todo', initiative: null, flagged: false, reason: null, points: null }] },
42
- { name: 'Sprint 15', state: 'future', start: '2026-10-22', end: '2026-11-04', goal: null, jiraGoal: null, points: null, counts: { todo: 0, doing: 0, done: 0 }, issues: [] }],
41
+ { key: 'OPS-9', summary: 'Rotate keys', status: 'To Do', category: 'todo', initiative: null, flagged: false, reason: null, points: null, url: 'https://acme.atlassian.net/browse/OPS-9' }] },
42
+ { name: 'Sprint 15', state: 'future', start: '2026-10-22', end: '2026-11-04', goal: null, jiraGoal: null, points: null, counts: { todo: 0, doing: 0, done: 0 }, issues: [] },
43
+ { name: 'Sprint 12', state: 'closed', start: '2026-09-09', end: '2026-09-23', goal: null, jiraGoal: null, points: null, counts: { todo: 0, doing: 0, done: 1 },
44
+ issues: [{ key: 'PMOS-120', summary: 'Old work', status: 'Done', category: 'done', initiative: null, flagged: false, reason: null, points: null }] },
45
+ { name: 'Sprint 13', state: 'closed', start: '2026-09-23', end: '2026-10-07', goal: null, jiraGoal: null, points: null, counts: { todo: 0, doing: 0, done: 0 }, issues: [] }],
43
46
  };
44
47
  const TICKETS = {
45
48
  ok: true, initiative: 'self-serve-v2', title: 'Self-serve onboarding v2', prd: 'planning/prd/self-serve-v2-prd.md', checkedAt: new Date().toISOString(),
@@ -85,14 +88,27 @@ const TICKETS = {
85
88
  await p.click('#cSpr [data-open="board:sprint"]');
86
89
  const board = await until(async () => { const t = await paneText(p, 'sprint:w1'); return t && /Migration check/.test(t) ? t : null; });
87
90
  ok('B1 the Sprint card opens the dialog with the sprint as a second tab', !!board && (await tabIds(p)).join() === 'main,sprint:w1', JSON.stringify(await tabIds(p)));
88
- ok('B2 the board names the sprint, its dates, goal, days left and points from the read', /Sprint 14 · 7 Oct – 21 Oct/.test(board) && /Goal: Ship guided setup/.test(board) && /2 days left/.test(board) && /3 of 10 points done/.test(board), board);
91
+ ok('B2 the board names the sprint, its dates, goal, days left and points from the read', /Sprint 14 · 7 Oct – 21 Oct/.test(board) && /Sprint goal · from the tickets/i.test(board) && /Ship guided setup/.test(board) && /Three tickets on guided setup/.test(board) && /In Jira: “Setup”/.test(board) && /2 days left/.test(board) && /3 of 10 points done/.test(board), board);
89
92
  const cols = await p.evaluate(() => [...document.querySelectorAll('.jcol')].map((c) => c.querySelector('.jcolh').textContent + ':' + c.querySelectorAll('.jcrd').length).join());
90
93
  ok('B3 the cards sit in To do, In progress and Done by the reading\'s category', cols === 'To do2:2,In progress1:1,Done1:1', cols);
91
94
  ok('B4 a card shows its own Jira status where it differs from the column, a flag, and points', await p.evaluate(() => { const c = [...document.querySelectorAll('.jcrd')]; const r = c.find((x) => /PMOS-141/.test(x.textContent)), f = c.find((x) => /PMOS-142/.test(x.textContent)); return /Code review/.test(r.textContent) && /2/.test(r.querySelector('.jpts').textContent) && f.classList.contains('risk') && /Flagged in Jira/.test(f.textContent); }));
92
- ok('B5 a ticket on no initiative of the board is drawn but not a button, and the note counts it', await p.evaluate(() => { const o = [...document.querySelectorAll('.jcrd')].find((x) => /OPS-9/.test(x.textContent)); return o.tagName === 'DIV' && o.classList.contains('off'); }) && /1 ticket is in this sprint but on no initiative/.test(board));
95
+ ok('B5 every ticket is a button, the one on no initiative of the board too', await p.evaluate(() => [...document.querySelectorAll('.jcrd')].every((x) => x.tagName === 'BUTTON')));
96
+ ok('B8 the closed sprints fold behind Past sprints, shut by default, after the active and next ones', await p.evaluate(() => { const f = document.querySelector('#jpast'), b = document.querySelector('[data-jpast]');
97
+ return !!f && f.hidden && /Past sprints\s*2/.test(b.textContent) && b.getAttribute('aria-expanded') === 'false' && [...document.querySelectorAll('.jseg:not(.jpast) [data-sp]')].map((x) => x.dataset.sp).join() === 'Sprint 14,Sprint 15'; }));
98
+ await p.click('[data-jpast]');
99
+ ok('B9 Past sprints opens the closed ones; one press shows a closed sprint and keeps the fold open', await p.evaluate(() => !document.querySelector('#jpast').hidden));
100
+ await p.click('#jpast [data-sp="Sprint 12"]');
101
+ ok('B10 a closed sprint draws its board, and the fold stays open on it', !!(await until(async () => { const t = await paneText(p, 'sprint:w1'); return t && /Sprint 12 · 9 Sep – 23 Sep/.test(t) && /Old work/.test(t) && await p.evaluate(() => !document.querySelector('#jpast').hidden); })));
102
+ await p.click('[data-jpast]'); await p.click('.jseg [data-sp="Sprint 14"]');
103
+ await until(async () => { const t = await paneText(p, 'sprint:w1'); return t && /Sprint 14 ·/.test(t); });
104
+ ok('B11 shut again, the fold stays shut on the active sprint', await p.evaluate(() => document.querySelector('#jpast').hidden));
105
+ await p.click('.jcrd[data-k="OPS-9"]');
106
+ const o9 = await until(async () => { const t = await paneText(p, 'jira:OPS-9'); return t && /Rotate keys/.test(t) ? t : null; });
107
+ ok('B12 a ticket on no initiative opens its tab from the sprint read, with its Jira link', !!o9 && /on no initiative of this board/.test(o9) && await p.evaluate(() => [...document.querySelectorAll('#dOut .obody.vw:not([hidden]) a[href]')].some((a) => a.href === 'https://acme.atlassian.net/browse/OPS-9')), o9);
108
+ await p.click('#vTabs [data-vx="jira:OPS-9"]'); await p.click('#vTabs .vtab[data-vw="sprint:w1"]');
93
109
  ok('B6 the view says it is read-only and moves nothing', /Read-only: Jira owns each ticket's status and sprint/.test(board) && !(await p.$('#dOut .obody.vw [draggable="true"]')));
94
110
  await p.click('.jseg [data-sp="Sprint 15"]');
95
- ok('B7 the other sprint is one press away, and an empty one draws empty columns', !!(await until(async () => { const t = await paneText(p, 'sprint:w1'); return t && /Sprint 15 · 22 Oct – 4 Nov/.test(t) && /No sprint goal on record/.test(t) && (t.match(/None/g) || []).length === 3; })));
111
+ ok('B7 the other sprint is one press away, and an empty one draws empty columns', !!(await until(async () => { const t = await paneText(p, 'sprint:w1'); return t && /Sprint 15 · 22 Oct – 4 Nov/.test(t) && /No goal yet\. The Jira status check writes one from the tickets/.test(t) && (t.match(/None/g) || []).length === 3; })));
96
112
  await p.click('.jseg [data-sp="Sprint 14"]');
97
113
  await until(() => p.$('.jcrd[data-k="PMOS-142"]'));
98
114