@imagile-dev/toil-ui 0.1.0-alpha.2 → 0.1.0-alpha.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -7,8 +7,8 @@ requests view for what is waiting on review, and a daily worklog of what happene
7
7
 
8
8
  **Status: alpha, local only.** It runs on your own machine, binds loopback, and
9
9
  reads through toil with your own connections and dossiers, read-only. Its
10
- settings pages are the one place it changes anything of toil's, and only toil's own
11
- connections and dossiers. The worklog keeps its pages and the notes you add in its own
10
+ settings pages, and a dossier's name and description edited in place, are the only
11
+ places it changes anything of toil's, and only toil's own connections and dossiers. The worklog keeps its pages and the notes you add in its own
12
12
  data folder, and writes anywhere else only when you export a page. Its Feedback dialog sends a report to Imagile through
13
13
  `toil feedback`, only when you approve it. It is a separate package from toil: installing toil
14
14
  never installs it.
@@ -34,7 +34,7 @@ It prints one URL and keeps running until you press Ctrl+C:
34
34
 
35
35
  ```text
36
36
  Toil UI 0.1.0-alpha.1 (alpha, local only), on toil 0.1.0-alpha.3
37
- Syncing through toil, read-only, with your own connections and dossiers. Only its Settings pages change anything: toil's own connections and dossiers, when you ask. The worklog keeps its pages and your notes in its data folder, and writes anywhere else only when you export one. Feedback goes to Imagile only when you send it.
37
+ Syncing through toil, read-only, with your own connections and dossiers. Only its Settings pages, and a dossier's name and description edited in place, change anything: toil's own connections and dossiers, when you ask. The worklog keeps its pages and your notes in its data folder, and writes anywhere else only when you export one. Feedback goes to Imagile only when you send it.
38
38
  The cache is /home/you/.toil-ui/cache/toil-ui.db, kept 30 days after each sync; toil-ui wipe deletes it.
39
39
 
40
40
  Open this URL in your browser. It carries this launch's token, so keep it to yourself:
@@ -46,8 +46,9 @@ token leaves the address bar. A reloaded page forgets its session, so open the U
46
46
  again to get back in. Each start prints a new token. Toil UI opens no browser
47
47
  itself.
48
48
 
49
- `toil-ui --sample` serves the sample dossiers and the scripted agent the site's
50
- preview uses, with nothing connected to a tracker.
49
+ `toil-ui --sample` serves the sample dossiers and the scripted agent that
50
+ [the site's Toil UI page](https://imagile-dev.github.io/toil/ui/) runs on, with
51
+ nothing connected to a tracker.
51
52
 
52
53
  ## What it reads
53
54
 
@@ -65,6 +66,66 @@ in-process through `@imagile-dev/toil/api`, read-only, and toil's audit log
65
66
  records it with `via: "api"` and `caller: "toil-ui"`. A call that fails shows on
66
67
  its own panel with toil's message and fix.
67
68
 
69
+ ## The Dossiers view
70
+
71
+ Toil UI opens on its dossiers, one card each, read from the same data the dashboards
72
+ read, so it asks no tracker anything: in the local app that is the cache a sync
73
+ filled, plus `dossiers list` and `dossiers show` for the dossiers themselves.
74
+
75
+ - **What each card shows:** the current sprint with its working days left, points
76
+ done and a small burn-up; how many items are in progress and blocked, and how many
77
+ pull requests wait on a review; the people with work in it, as avatars; its sources
78
+ as badges; when it was last synced; and how many work items and pull requests
79
+ changed since this browser last opened its dashboard.
80
+ - **Which card leads:** the dossier opened most recently in this browser, or, before
81
+ any was opened, the one with the most in motion (in progress, blocked and waiting on
82
+ review together), takes two columns where they fit. On a wide screen the grid goes
83
+ wider than the dashboards and fits more cards across; at 375px it is one column.
84
+ - **What this browser remembers:** when each dashboard was last opened, in
85
+ `localStorage`, never sent anywhere. Without it (a private window) the cards just
86
+ say nothing about "since".
87
+ - **The dashboard's header** uses the same parts: the description under the name, the
88
+ sources as badges, and the counts in one strip, so the panels start higher.
89
+
90
+ ### Renaming and describing a dossier
91
+
92
+ The name and the description have a pencil beside them, on the card and in the
93
+ dashboard's header. It opens an inline field: Enter saves through
94
+ `toil dossiers describe <dossier> --name <new name>` or `--description <text>`, run
95
+ on the settings pages' path (below), so toil's own checks apply and the change is in
96
+ its audit log as `caller: "toil-ui"`. Escape cancels, and a refusal shows toil's
97
+ message and fix under the field. Only a dossier in your own folder can be renamed or
98
+ described; a checked-in one is refused with the `toil dossiers import` fix.
99
+
100
+ A rename keeps everything Toil UI holds for the dossier: the server moves its cache
101
+ (responses, items, history, sources, sync runs, notes and agent runs), its assignments
102
+ and its worklog pages to the new name once toil has renamed the file, so its
103
+ dashboard opens straight away with no new sync. A rename waits, refused with a
104
+ message, while a sync or an assignment of that dossier is running, since both read it
105
+ by name as they go. What can't be moved is said beside toil's result, and the next
106
+ sync reads the dossier afresh under its new name.
107
+
108
+ ## Insights
109
+
110
+ The dashboard's **Needs attention** panel, the board's cards and the flow panels mark
111
+ each open work item with its insights, weightiest first, each naming the data it
112
+ rests on (`ui/src/model/insights.ts`). One the data can't support isn't raised at
113
+ all, rather than raised on a guess.
114
+
115
+ | Insight | Means | Weight |
116
+ |---|---|---|
117
+ | Blocked | Another item that isn't done blocks it (its links) | needs action now |
118
+ | Build failing | Its pull request's latest build failed | needs action now |
119
+ | Aging | In progress longer than 85% of the dossier's finished items took; needs at least three cycle times to compare with | needs action now |
120
+ | Deployed, still open | An environment runs it, but it isn't done | needs a look |
121
+ | Carried over | It was in the previous sprint too | needs a look |
122
+ | PR with no build | A pull request for it is open with no build | needs a look |
123
+ | Stale | No update for more than 5 days | needs a look |
124
+ | Blocking | It blocks another item | needs a look |
125
+ | Merged, not deployed | Its pull requests are merged, but no environment runs them yet; only for a dossier that names environments | worth knowing |
126
+ | No estimate | It has no estimate | worth knowing |
127
+ | Added mid-sprint | It joined the sprint after it started | worth knowing |
128
+
68
129
  ## Pull requests
69
130
 
70
131
  Each dossier has a **Pull requests** view (`#/dossier/<name>/prs`, linked from its
@@ -178,7 +239,7 @@ A page has:
178
239
  - **Builds and deployments** that failed or recovered (deployments from OpenShift,
179
240
  whose state a sync can see change): a build is recovered when a
180
241
  passing run follows a failing one of the same pull request or pipeline.
181
- - **Agent runs:** each question an agent adapter answers in the Ask pane, when it
242
+ - **Agent runs:** each question an agent adapter answers in the chat, when it
182
243
  started and ended,
183
244
  whether it finished, failed, was stopped or was stopped at a usage cap, what it
184
245
  cited, and its proposals, each
@@ -222,6 +283,43 @@ config. Publishing an exported page is a proposal: `toil confluence page create
222
283
  create --body-file <file>` in its repository, for you to run through toil's write gate.
223
284
  Toil UI posts nothing. With sample data, notes and export are off.
224
285
 
286
+ ### Stand-up
287
+
288
+ **Stand-up since the last working day**, on the Worklog
289
+ (`#/dossier/<name>/worklog/standup`), reshapes the worklog for a meeting: since the last
290
+ working day through today (Friday through Monday on a Monday), or any range of up to 31
291
+ days you pick (`#/dossier/<name>/worklog/standup/<from>/<to>`, or `/<day>` for one), and each day's page has a
292
+ **Stand-up for this day**. It is a fold of those days' pages by code, with no model, so the
293
+ same days always give the same report.
294
+
295
+ - **Team lines first:** the sprint's working days left, items added to or dropped from a
296
+ sprint, and builds and deployments that broke or recovered.
297
+ - **Then each person, agents included,** in four lists: **Done** (items moved into a done
298
+ status, pull requests merged or closed), **In progress** (every other status change,
299
+ pull requests opened or reviewed), **Blocked** (a new blocker on an item they hold, a
300
+ failed build of their pull request, a pull request of theirs waiting on review for 2
301
+ working days or more) and **Next** (current-sprint items assigned to them and not
302
+ started). A line belongs to whoever the fact names: who moved the item, who wrote or
303
+ reviewed the pull request. A pull request a dossier agent wrote goes under the agent.
304
+ - **People** come from the dossier's `people`, so one person's Jira, Azure DevOps and
305
+ GitHub accounts land under one name. An account the dossier doesn't map gets its own
306
+ card, named with its area and id; the People view suggests where it belongs.
307
+ - **What the worklog can't vouch for** in the range is said at the top. Review waits, the
308
+ sprint and Next aren't on any worklog page, so they are as of the latest sync, and the
309
+ report says which.
310
+ - **Every line links** to its item, pull request or build, and is numbered (F1, F2, ...).
311
+
312
+ It copies as **Markdown** (for Slack, Teams or a wiki) or **plain text**, line for line as
313
+ shown. **Export** writes the Markdown through toil's file service, as a page's export does,
314
+ to `standup-<dossier>-<from>-to-<to>.md`, and publishing it to Confluence or GitHub is a
315
+ proposal for you to run.
316
+
317
+ **Write it up** is optional: it asks the agent for a short narrative of the same report,
318
+ in the theme's voice when that is on. The agent reads the report through its
319
+ `standup_report` tool and ends each sentence with the fact numbers it rests on; the
320
+ write-up is labelled as the agent's, the lines it names are marked in the report, and its
321
+ usage counts like any chat's.
322
+
225
323
  ## Toil's configuration
226
324
 
227
325
  The Settings pages manage what `toil connections` and `toil dossiers` manage, by
@@ -231,11 +329,17 @@ running those commands through `@imagile-dev/toil/api`, never by editing a file:
231
329
  replace a secret (`toil connections login`) and remove. A secret goes from a
232
330
  password field to toil, which keeps it in the OS credential store; the page
233
331
  clears the field, and it is never logged, stored by Toil UI, or sent back.
332
+ A note under the field says how many characters it holds and what trimming
333
+ removes, never the value. The same paste checks as the CLI's run, in the
334
+ CLI's words: a line break (or, for a token, a space) in the middle is
335
+ refused, and quotes or a `Bearer ` / `token ` prefix ask Remove it or Keep
336
+ it before anything is saved.
234
337
  Turning writes on asks you to type the connection's name, as the CLI does. A
235
338
  connection made by `TOIL_*` env vars alone is shown read-only, with where it
236
339
  came from.
237
340
  - **Dossiers:** create one, add a repository, link an area, name a field, and
238
- show and check any of them. A link to a connection with writes on is refused
341
+ show and check any of them. A dossier's name and description are edited in place
342
+ on its card and dashboard, through `toil dossiers describe`. A link to a connection with writes on is refused
239
343
  here, as over MCP: make it on the CLI.
240
344
  - **Bounds and time limit:** toil has no command for these, so they are shown
241
345
  read-only, with the file or env var that sets them.
@@ -252,6 +356,18 @@ toil's audit log as `caller: "toil-ui"`. The page can run no other command on th
252
356
  path, and never a tracker write. Adding or changing connections needs a toil
253
357
  newer than 0.1.0-alpha.2; with that one, use the CLI.
254
358
 
359
+ ## Help and edit links
360
+
361
+ An **(i)** beside a term explains it in a sentence or two when you hover or focus
362
+ it, and pressing it opens the same words with a **Read more** link to the section
363
+ of these docs that says the rest. A **pencil** beside a configurable value (a
364
+ connection, a dossier's sources, people, field names or work-in-progress limit,
365
+ the agent, a usage cap) opens the settings page where it's set, at that value; it
366
+ only navigates. **Help** in the header opens the docs for the view you're on.
367
+ Read more and Help open the docs site in a new tab, which is the one place the app
368
+ links out to. [Help and edit links](https://imagile-dev.github.io/toil/docs/ui-help/)
369
+ has the rule views follow.
370
+
255
371
  ## Feedback
256
372
 
257
373
  The **Feedback** button in the header opens a dialog for a bug report or a feature
@@ -322,9 +438,40 @@ by the page: `toil audit list`, read-only, to see whether a proposal was applied
322
438
 
323
439
  ## The agent
324
440
 
325
- The docked chat answers with the agent your organization already approved, on the
441
+ Every dossier page has an **Ask bar** under the header: one line, with **Analyze**
442
+ beside it. Pressing into it opens the **focused view**: the conversation takes the
443
+ screen and the page steps back, with a slim strip that keeps the dossier, its sprint
444
+ and the agent answering in sight. **Escape** or **Close** puts it away; the
445
+ conversation stays, for the rest of the dossier's pages, until you reload.
446
+
447
+ - **Starter questions** are a row of chips before the first question, then a
448
+ **Suggestions** menu.
449
+ - **Answers stream in** as the agent writes them, under a **status line** that says
450
+ what it is doing: reading the cache with `owi_query`, reading live through toil with
451
+ `github issue list`, writing, and at the end how long it took. **Stop** cancels the
452
+ question on the server and keeps what had arrived. Claude and Copilot stream as they
453
+ write; Codex's SDK hands over its text a message at a time, so with Codex the status
454
+ line is what moves between messages.
455
+ - **The wording follows the theme**: the bar's placeholder, the welcome and the status
456
+ words are in each game theme's voice, and Plain stays neutral. The starter questions
457
+ read the same in every theme.
458
+ - **Analyze** asks for a pulse check in one press: what changed since the last Analyze
459
+ (from the worklog), who is on what, what is blocked or stuck in review, the sprint's
460
+ health and risks, and anything that looks off, such as a ticket marked done while its
461
+ pull request is open. Every line cites its items, and follow-up questions continue
462
+ from it.
463
+ - **Each question carries the chat so far**: its last 8 questions and answers, each
464
+ answer cut to 1,500 characters. An item an earlier answer named is still checked
465
+ against what the tools return for the new question.
466
+ - **Switch agent from the chat.** The strip's switcher lists Claude, GitHub Copilot and
467
+ Codex, each with its model and whether it can answer. A choice holds for this chat
468
+ from its next question, which carries the conversation so far; the default stays in
469
+ Settings. An adapter that can't answer is listed with the reason and **Install** or
470
+ **Fix**, never left out. Each answer names the adapter and model that wrote it.
471
+
472
+ The chat answers with the agent your organization already approved, on the
326
473
  subscription you already have. Toil UI has three adapters, each an optional peer
327
- dependency that is loaded only when you choose it:
474
+ dependency that is loaded only when it answers:
328
475
 
329
476
  | Adapter | Package | Starts | Signs in with |
330
477
  |---|---|---|---|
@@ -332,16 +479,54 @@ dependency that is loaded only when you choose it:
332
479
  | GitHub Copilot | `@github/copilot-sdk` | `copilot` (the Copilot CLI) | your Copilot seat, through the CLI |
333
480
  | Codex | `@openai/codex-sdk` | `codex` (the Codex CLI) | the CLI's ChatGPT sign-in or its own API key setup |
334
481
 
482
+ Choose the default under **Settings, Agent**: the adapter, each adapter's model
483
+ (empty for its CLI's default), the CLI's path (empty to use the one on `PATH`) and,
484
+ for Claude, the endpoint. The choice is kept in `<data folder>/agent.json`, never in
485
+ toil's config, and has no field for a key: each SDK signs in the way its CLI does.
486
+
487
+ ### Installing an adapter's SDK
488
+
489
+ **Settings, Agent** lists each adapter: whether its SDK is installed and at which
490
+ version against the one Toil UI was tested with, which CLI it would start, and
491
+ anything worth knowing. A missing SDK has an **Install** button, which shows the one
492
+ command it will run, word for word, before anything runs:
493
+
335
494
  ```bash
336
- npm install -g @anthropic-ai/claude-agent-sdk zod # beside a global toil-ui
495
+ npm install --global --prefix <the prefix Toil UI is installed in> --ignore-scripts --before=<14 days ago> --no-audit --no-fund --omit=optional @openai/codex-sdk@0.160.0
337
496
  ```
338
497
 
339
- Then choose it under **Settings, Agent**: the adapter, the model (empty for the CLI's
340
- default), the CLI's path (empty to use the one on `PATH`) and, for Claude, the
341
- endpoint. The choice is kept in `<data folder>/agent.json`, never in toil's config,
342
- and has no field for a key: each SDK signs in the way its CLI does. Install the SDK
343
- with `--omit=optional` if you don't want its bundled copy of the CLI on disk; Toil UI
344
- never starts that copy anyway.
498
+ Pressing **Install** runs it through the npm that came with your Node, with no shell and
499
+ your own npm config, so your organization's registry and proxy apply. npm's output
500
+ streams into the dialog, and Toil UI then loads the SDK to prove it installed; a
501
+ failure shows npm's own message and the fix. **Copy command** is beside it, for a
502
+ machine where you'd rather run it yourself. This is the one thing Toil UI runs npm
503
+ for (docs/decisions/343-ask-up-front.md).
504
+
505
+ - **Only the tested versions**: `@anthropic-ai/claude-agent-sdk@0.3.289` with
506
+ `zod@4.6.5`, `@github/copilot-sdk@1.0.16` and `@openai/codex-sdk@0.160.0`, exactly
507
+ (`ui/server/agents/tested.ts`). Nothing else is ever named, and `--before` holds
508
+ everything npm resolves, the SDK's own dependencies included, to releases at least
509
+ 14 days old.
510
+ - **Where it goes depends on how Toil UI is installed.** Installed globally, the SDK
511
+ is installed globally into the same prefix, read from where Toil UI is rather than
512
+ from npm's config, so a global install under another prefix still lands beside it.
513
+ Its optional dependencies, each SDK's own copy of its CLI, are left out: Toil UI
514
+ never starts them. In a project's `node_modules`, it installs into the project with
515
+ `--save-exact`. In a clone of this repository, it installs at the root with
516
+ `--no-save`, naming the agent SDKs already there again, since an unsaved install
517
+ removes the ones it doesn't name.
518
+ - **Run with `npx`, it can't install**: npx runs Toil UI from its cache, which npm
519
+ clears when it likes, so there is no folder to install beside. The dialog says so;
520
+ install Toil UI with `npm install -g @imagile-dev/toil-ui` and start it as `toil-ui`.
521
+ - **Not into Toil UI's own folder.** Its `package.json` lists the SDKs as optional
522
+ peers, so npm reports them up to date there and installs nothing.
523
+ - **Claude's bundled CLI.** `@anthropic-ai/claude-agent-sdk`'s platform package is an
524
+ optional dependency that npm sometimes skips. Toil UI doesn't need it, since it
525
+ starts the `claude` it finds, and the status says so rather than fail.
526
+ - **Copilot on Windows.** npm installs the Copilot CLI as `copilot.cmd`, a shim no SDK
527
+ can start without a shell. Copilot's SDK starts a `.js` CLI with Node itself, so
528
+ Toil UI starts the script the shim runs (`node_modules\@github\copilot\npm-loader.js`
529
+ beside it) and says so in the status. Claude Code and Codex install as `.exe` files.
345
530
 
346
531
  - **Only the CLI already on this machine.** Toil UI finds it on `PATH` (skipping
347
532
  relative entries and the working directory) or at the path you set, which must
@@ -350,7 +535,7 @@ never starts that copy anyway.
350
535
  and temp folders, proxy and CA settings) and its own sign-in variables. toil's
351
536
  `TOIL_*` variables, `GITHUB_TOKEN` and CI tokens never reach it. Not found is a plain
352
537
  error naming the CLI and the fix. On Windows a `.cmd` shim can't be started by the
353
- SDKs, so point at the `.exe`.
538
+ SDKs, so point at the `.exe` (Copilot's npm shim is the exception, above).
354
539
  - **Read-only tools, one dossier.** The agent gets `owi_query`, `owi_get`,
355
540
  `owi_similar` (likely duplicates, scored as `toil util owi similar` scores them)
356
541
  and `owi_history` over the cache, `pr_query`, `pr_get` and `pr_metrics` over its
@@ -361,7 +546,8 @@ never starts that copy anyway.
361
546
  `readiness_get` (each item's readiness verdict and its rows, as the Command Center
362
547
  works them out), `proposal_fields` (a write command's input fields,
363
548
  told it describes load, never performance), `worklog_day` (one day's worklog page,
364
- with what it can't vouch for), `proposal_fields` (a write command's input fields,
549
+ with what it can't vouch for), `standup_report` (a range of days as the Stand-up folds
550
+ them, each line numbered), `proposal_fields` (a write command's input fields,
365
551
  from toil's registry), and `toil mcp`'s read tools for live lookups, called through
366
552
  toil's `execute()` with `readOnly: true`. The dossier is fixed to the one on screen.
367
553
  There is no write tool, and each SDK's own tools (shell, files, web, plugins, other
@@ -397,8 +583,21 @@ never starts that copy anyway.
397
583
  proposals or what the tools can do. **Show the full prompt** shows exactly what
398
584
  the agent is sent.
399
585
 
400
- With no adapter chosen, the chat says so and names the three. `toil-ui --sample`
401
- keeps the scripted agent, which answers its starter questions from the sample data.
586
+ With no adapter chosen, the chat says so and names the three; its switcher can still
587
+ choose an installed one for that chat. `toil-ui --sample` keeps the scripted agent,
588
+ which answers its starter questions and Analyze from the sample data.
589
+
590
+ ### Not ticketed yet
591
+
592
+ When you ask the chat for work that names no ticket (not a question, which ends in `?` or
593
+ opens with what, why, how and the like, and no key such as `PAY-12` or `#42`), a **Not ticketed yet** banner lists up to three of the
594
+ dossier's open items likeliest to cover it, scored as `toil util owi similar` scores
595
+ them, each with why. Attach the work to one by naming its key in your branch and
596
+ commits, which writes nothing, or press **Ticket this** for proposals: a sub-task
597
+ under each match, and a new ticket on the dossier's tracker. They are proposal cards
598
+ like the chat's others, with the command line to run through toil's write gate, and
599
+ nothing is created until you run one. With no match, it says there is no likely
600
+ ticket and offers only a new one. It asks once per chat, and **Not now** hides it.
402
601
 
403
602
  ### What the agent's models used
404
603
 
@@ -410,7 +609,7 @@ called):
410
609
  |---|---|---|
411
610
  | Claude | each step's `usage` by message id, then the result's `modelUsage` per model and its `costUSD` | tokens (in, out, cache read, cache write) per model, and the dollar figure as the SDK's estimate; on a Claude plan (no API key, Anthropic's own API) it says "API-equivalent", since the plan isn't billed per token |
412
611
  | Codex | `turn.completed`'s `usage`: input (which holds the cached input), cached input, cache writes, output | tokens; a dollar figure only from rates you enter, labelled "computed from your rates". The SDK names no model, so a Codex record names the model you chose, or says it wasn't named |
413
- | GitHub Copilot | one `assistant.usage` event per model call, with `cost` as the premium-request multiplier, and `session.usage_info` for the context | tokens and premium requests, never dollars; premium requests left from the SDK's experimental `account.getQuota`, marked experimental |
612
+ | GitHub Copilot | one `assistant.usage` event per model call, with `cost` as the premium-request multiplier, and `session.usage_info` for the context. Copilot bills the multiplier once per prompt: only the call the prompt started (`initiator` `user`) counts it, and the agent's follow-up calls in the tool loop count 0 | tokens and premium requests, never dollars; premium requests left from the SDK's experimental `account.getQuota`, marked experimental |
414
613
 
415
614
  - **Under each answer**, one line per model: `2.1k in · 380 out · 14k cached · cache
416
615
  write not reported · ~$0.012 (SDK estimate)`. A figure the SDK didn't report reads
@@ -441,7 +640,8 @@ the vendor's own bill is the authority.
441
640
 
442
641
  ## Assigning work to an agent
443
642
 
444
- From an item's page, or **Assign** on its card on the board, a work item can be
643
+ From an item's page, or **Assign to an agent…** in its card's menu on the board
644
+ (right-click the card, long-press it, or press M while it has focus), a work item can be
445
645
  assigned to Claude, GitHub Copilot or Codex in one of three modes. The agent works on
446
646
  the subscription you already have, and nothing it proposes leaves this machine until
447
647
  you apply it.
@@ -490,12 +690,80 @@ you apply it.
490
690
  commands and file changes Codex reports, and each proposal and what came of it.
491
691
  Each assignment also records what it started on: the toil and Toil UI versions, the
492
692
  adapter and model, the tools, and SHA-256 fingerprints of the dossier, the item and
493
- the prompt. Assignments are kept under the cache, in
693
+ the prompt, and the install fingerprint a later look holds it to (Stale sessions, below). Assignments are kept under the cache, in
494
694
  `<data folder>/cache/assignments/`, so a wipe deletes them.
495
695
  - **For programs on the same server**, `api/assignments` lists, assigns, starts,
496
- stops, applies and dismisses, and `api/assignments/events?since=<n>` streams every
696
+ stops, applies, dismisses and renews, and `api/assignments/events?since=<n>` streams every
497
697
  change of state as NDJSON.
498
698
 
699
+ ## Stale sessions
700
+
701
+ An agent works from the instructions it got when it started. Upgrade toil, edit the
702
+ dossier or change your instructions under **Settings, Agent**, and the chats and
703
+ assignments already going are still on the old ones. Toil UI records what each one
704
+ started on, says which have gone stale and why, and renews them on request.
705
+
706
+ - **What it records.** Each chat at its first question, and each assignment when its
707
+ run starts, keeps an install fingerprint: toil's and Toil UI's version and commit,
708
+ one SHA-256 per toil area of the tools the agent was handed (Toil UI loads no skill
709
+ page, so those tools are the toil instructions its agent reads), SHA-256 of the
710
+ dossier as `toil dossiers show` reads it, and SHA-256 of the prompts (the system
711
+ prompt, the starters or the mode's task, and your own instructions and voice). The
712
+ theme on screen isn't part of it. An assignment recorded before this has none, and
713
+ is never called stale.
714
+ - **When it's stale.** Every answer, every read of the Agents lane and every
715
+ assignment page compares what the session started on with the current fingerprint,
716
+ whose builds are the ones on disk, read again only when their files change. The
717
+ reason names what moved: "started on toil 0.1.0-alpha.3 · now alpha.4 · skills
718
+ changed: github · dossier changed". A session's earlier turns aren't marked; only
719
+ the instructions it started on are.
720
+ - **Where it shows.** A **Stale** badge with the reason on the chat (in the Ask bar and
721
+ the focused view), on each assignment in the Agents lane and on its page, and on the
722
+ agent's card in the People view. A done assignment is closed and isn't marked.
723
+ - **Renew.** On the chat, **Renew** in the focused view records what it starts on now;
724
+ the conversation stays, and the next question carries it as every question does. The
725
+ chat's usage total carries on, so renewing never resets a cap. On a stale assignment
726
+ that has failed, **Renew** queues a fresh one on the same item, mode, adapter and
727
+ repository, whose prompt carries what the old run left, fenced as data; the old one
728
+ stays readable, marked as renewed. Renew never interrupts a turn: a chat that is
729
+ answering and a working assignment wait, and an assignment that needs you is
730
+ skipped until you've reviewed it.
731
+ - **Renew all stale**, in the Agents lane, lists every stale session of the dossier
732
+ first, the chat included, each saying whether it renews or why it's skipped, and
733
+ renews the rest with one press.
734
+ - **The server itself.** When toil or Toil UI on disk is newer than the running
735
+ server, the header says so, with the command that starts it again. A session renewed
736
+ then would start on the old build and be stale at once, so until it restarts, Renew
737
+ is refused (and Renew all stale skips every session), saying so with that command.
738
+
739
+ ## Notifications
740
+
741
+ Toil UI tells you when an agent's state changes, and stays quiet otherwise. A tool
742
+ call, its progress, or a state that didn't change never notifies.
743
+
744
+ - **What notifies:** an assignment reaching **needs you** (with why: "asked a
745
+ question", "3 proposals to review"), **done** or **failed**, one stopped at its
746
+ **usage cap**, and a chat or assignment gone **stale** (Stale sessions, above). A
747
+ run going from queued to working says nothing, and neither does your own Stop.
748
+ - **Once, together.** Changes within four seconds become one notice: "2 agents need
749
+ you", each line linking to its assignment. A change undone inside those seconds,
750
+ such as a question answered elsewhere, sends nothing.
751
+ - **Where.** A notice under the header, with Dismiss. While the tab is hidden its
752
+ title counts them, `(2) Toil UI`, until you come back. With **Browser
753
+ notifications** on, the browser's own notification shows them too, drawn on this
754
+ computer: nothing leaves the machine. The browser is asked for permission only when
755
+ you turn that on, never before.
756
+ - **Settings**, under **Settings, General**, kept in this browser: a switch for each
757
+ kind (**needs you**, **failed** and the usage cap on, **done** off, **stale** on, by
758
+ default), **only for agents I started** (the chats in this browser and the
759
+ assignments assigned, started or renewed here), and quiet hours, which hold every
760
+ notice while the title still counts.
761
+ - **Plain words.** Notices read the same in every theme: the theme's wording stays in
762
+ the views.
763
+ - **Where it listens.** The server's `api/assignments/events?since=latest` stream,
764
+ which carries what a notice says with each event, and a minute's read of the
765
+ dossier on screen for sessions gone stale.
766
+
499
767
  ## Themes
500
768
 
501
769
  Five built-in themes: Plain, Crate (the default), Harvest, Starship and Realm. Pick
@@ -510,8 +778,14 @@ it goes, both on by default:
510
778
  dockworker in Crate, a patient farmhand in Harvest, a ship's log in Starship, a
511
779
  house's steward in Realm. It changes phrasing only.
512
780
 
513
- Plain has neither, so both are off while it's chosen. The choice is kept in this
514
- browser. Toil UI doesn't install themes from anywhere else: to ask for one, send a
781
+ A theme with particles also gets **Particles and ambient effects**, kept for each
782
+ theme on its own: off, that theme's particles are gone entirely, while its other
783
+ motion keeps following **Reduce motion and effects** (and the operating system's
784
+ reduced-motion setting, which stops everything).
785
+
786
+ Plain has neither wording nor voice, so both are off while it's chosen. It sets
787
+ headings and figures in Fredoka, toil's wordmark face, on IBM Plex Sans. The choice
788
+ is kept in this browser. Toil UI doesn't install themes from anywhere else: to ask for one, send a
515
789
  feature request from **Feedback** or with `toil feedback feature`. A `themes/` folder
516
790
  left in the data folder by an earlier alpha is not read, and Toil UI says so when it
517
791
  starts. [Themes](https://imagile-dev.github.io/toil/docs/themes/) has the whole
@@ -574,6 +848,26 @@ GitHub CLI signed in (`gh auth login`), or `TOIL_GITHUB_TOKEN` set in the shell.
574
848
  Codex under **Settings, Agent**. The script points `CODEX_HOME` at your real
575
849
  `~/.codex`, which is where Toil UI finds the `auth.json` it links into its own
576
850
  Codex home.
851
+ - **Ask with GitHub Copilot, on a cheap model.** Install `@github/copilot-sdk@1.0.16`
852
+ the same way (or press **Install** under **Settings, Agent**). The Copilot CLI found
853
+ its own sign-in from the scratch home in our runs; if it says it isn't signed in, run
854
+ `copilot` once on its own. Then pick the model: Copilot lists the models your
855
+ account can use, each with its premium-request multiplier (`/model` in the CLI, or
856
+ the SDK's `listModels()`). Choose the lowest, ideally one at 0×; otherwise the
857
+ cheapest multiplier, such as `mai-code-1.1-flash` at 0.25×, never a premium model.
858
+ Type its id as Copilot's model under **Settings, Agent**, and check the model each
859
+ answer names and the premium requests under it.
860
+ - **Ask with Claude, on Haiku.** Install `@anthropic-ai/claude-agent-sdk@0.3.289` and
861
+ `zod@4.6.5` the same way, and type `haiku` (or `claude-haiku-5-5`) as Claude's
862
+ model under **Settings, Agent**; empty would be Claude Code's own default, which
863
+ may be Opus. Claude Code keeps its sign-in in `~/.claude`, which the scratch home
864
+ hides, and refreshing it from there would rewrite your credentials file, so the
865
+ script only reads it: a `CLAUDE_CODE_OAUTH_TOKEN` or `ANTHROPIC_API_KEY` in the
866
+ shell goes through as it is, and otherwise the access token in
867
+ `~/.claude/.credentials.json` goes into Toil UI's environment as
868
+ `CLAUDE_CODE_OAUTH_TOKEN` while it has ten minutes left. When it has expired the
869
+ script says so: run `claude` once in a terminal, which refreshes its own sign-in,
870
+ or set a token from `claude setup-token`, and start the script again.
577
871
 
578
872
  ## Verify before you open a PR: `npm run verify:ui`
579
873
 
@@ -584,6 +878,7 @@ from the root or from `ui/`, and paste the report's table into the PR.
584
878
  ```bash
585
879
  npm run verify:ui # build, sample data, real data
586
880
  npm run verify:ui -- --ask # and one Codex question
881
+ npm run verify:ui -- --ask --adapter copilot --model mai-code-1.1-flash # or --adapter claude --model haiku
587
882
  npm run verify:ui -- --no-build --starter standup
588
883
  ```
589
884
 
@@ -600,13 +895,20 @@ npm run verify:ui -- --no-build --starter standup
600
895
  - **Real data:** the home `dev-real.mjs` sets up, made fresh at
601
896
  `.scratch/verify/home`, on `imagile-dev/toil-sandbox` with the token from `gh auth
602
897
  token` in Toil UI's environment only. It syncs the `sandbox` dossier and runs the
603
- same check over the home page, the dossier, one of its items and the settings pages.
898
+ same check over the home page, the dossier, one of its items and the settings pages,
899
+ except that its header may fold into the Menu at 1440px, since a real dossier's name
900
+ and links can genuinely fill the row.
604
901
  Without a GitHub sign-in it skips this part and says so; nothing else depends on it.
605
902
  - **`--ask`** asks Codex one starter question (`hygiene` unless `--starter <id>`) and
606
903
  checks that an answer arrived, that the server verified every `[[id]]` it cites,
607
904
  that its proposals parsed, that nothing ran (no write in toil's audit log for the
608
- run), and that `codex mcp list` in Toil UI's Codex home shows only `toil_ui`. It
609
- needs the Codex CLI signed in and the SDK installed in the clone (above).
905
+ run), and that `codex mcp list` in Toil UI's Codex home shows only `toil_ui`. Then it
906
+ asks Analyze as the chat's second question. It needs the Codex CLI signed in and the
907
+ SDK installed in the clone (above). `--adapter copilot` or `--adapter claude` asks that
908
+ adapter instead, held to the same checks (Codex is the reference; its MCP check is
909
+ skipped), and `--model <id>` sets its model and fails the run when an answer or a
910
+ usage record names another one, so a cheap-model run can't quietly use a dear one. Each adapter's full live run, every agent feature on the sandbox, is
911
+ recorded in `ui/docs/live-runs/`.
610
912
  - **What fails it:** any layout problem in any theme, and any axe violation at WCAG
611
913
  2.2 AA in Plain and Crate. Axe findings in the other themes are listed in the report
612
914
  and never fail it. Screenshots are of Plain and Crate.
@@ -722,7 +1024,7 @@ Windows too.
722
1024
 
723
1025
  `@imagile-dev/toil-ui` ships the server (`dist/server/toil-ui.js`) and the built app
724
1026
  (`dist/app/`), and nothing else. It has no install scripts and no native addons,
725
- spawns no program of its own (an agent SDK you install starts its CLI), and its
1027
+ spawns no program of its own but npm, for Install alone (an agent SDK you install starts its CLI), and its
726
1028
  front end's framework is built in rather than installed. The agent SDKs are
727
1029
  optional peer dependencies: none is installed with it.
728
1030