mirror of
https://github.com/bitbaum/loki.git
synced 2026-12-03 22:37:01 +01:00
feat/shared-knowledge-map
1516
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
d4a9c15387 | feat(memory): package the knowledge map for reuse | ||
|
|
22da232484 | test(dispatch): isolate remote checkout path | ||
|
|
b1a8ab38b8 | fix(deploy): establish receipt visibility from the workflow event (#1737) | ||
|
|
85192684b9 |
feat(memory): explore project connections and export agent handoffs (#1735)
* feat(memory): explore project connections and export portable agent handoffs * fix(memory): use the last report when development log dates tie |
||
|
|
7d8e94b7c2 |
fix(ai): a cost under a hundredth of a cent reads "under $0.0001", not "$0.0000" (#1733)
Live on 2026-11-15 the AI card said "about $0.0000 by estimate" for 66 priced OpenAI embedding calls: a real cost shown as nothing. Below $0.0001 the card now says "under $0.0001". Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
672c84141e |
feat(ai): the fleet AI card says what the paid calls cost (#1732)
ai-kit 1.30 prices each paid answered call from its tokens and the vendor's published price. The card now shows, per vendor and per app, "Cost: ≈ $X (estimate)" and how many paid calls could not be priced (never counted as $0); the headline adds "about $X by estimate". A note says the vendor's bill is the final word and where its link is. Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
247fa9d9b3 |
fix(crons): a job cut off by a deploy waits for the new app before giving up (#1731)
sync-package-updates paged on 15 Nov with 'Connection reset by peer' during a Loki deploy, although the runner reruns a converging job when loki-app restarts mid-request. It checked loki-app's start time the instant curl failed, but a reset or empty reply is the old process going down: the new one starts only after that stop finishes (up to ~13 s). So it never saw the restart. Wait up to 60 s for the start time to move before deciding; send-once jobs are still never repeated, and a cut with no restart still fails (after the wait). The test now also covers the production order (restart lands after the cut); it fails on the old runner. |
||
|
|
2b95afa78f |
chore(starter): sync scripts/site-template to bitbaum/fleet@a7ed7f39f5 (#1729)
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com> |
||
|
|
52b554ced6 |
fix(ai): the AI card says how to lift OpenRouter's 50-a-day free tier, and stops contradicting its own figures (#1728)
Live: 'Free models: 30 of 50 requests used today'. OpenRouter's rule (its limits page, read 2026-11-15): under $10 of credits bought in all, 50 free requests a day; from $10, 1,000. The card now says so on the low tier. And under OpenRouter's real balance it no longer says 'a free vendor does not publish what is left'. Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
c4aac59675 |
feat(ai): the fleet AI card shows what OpenRouter says is left (#1726)
OpenRouter publishes the server key's figures (GET /api/v1/key): free-model requests used and left today, credits spent today/this week/this month, credits left on the key, and whether the account ever bought credits. The card now shows them under OpenRouter, asked at most every five minutes; when OpenRouter does not answer, no figure is drawn. Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
0f62a33cff |
feat(ai): the fleet AI card covers today, 7 or 30 days, and every vendor says where to pay or stop (#1725)
The owner, 2026-11-15: one place to see every AI provider, how much was used, and an easy way to upgrade or add credits. The card showed today only, named OpenAI as the bare id 'openai' with no link, and offered one console link per vendor. Now a Today / 7 days / 30 days switch reads that many days of the log, the wording follows the period, OpenAI and Anthropic are named vendors, and each vendor has direct links: usage, limits, upgrade or add credits, billing, and for Google 'Turn billing off'. Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
e599c83fde |
Measure agent cost per verified outcome on 50 development cases (#1721)
* feat(evals): account for verified outcomes across fifty development cases * test(evals): align spoken-walk replay with its recording clock * fix(dev): preserve check status during push watchdog cleanup |
||
|
|
e974d4ecd9 |
feat(ai): the fleet AI card says what each app's calls were for (#1718)
ai-kit 1.29 lets a call name its feature; each app row now reads "Used for: law translate: 40 answered · 200 failed · law ask: …". The owner asked to know what the AI was used up for; on 14 Nov Solon spent Groq's free day before 09:10 UTC and the card could only say "Solon". An app that names nothing shows no line. ai-kit floor raised to 1.29. Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
cd90093f72 |
fix(orangecat): the fleet map links only project pages that answer; a build log is not a post (#1716)
* fix(widget): the edge tab says "Feedback" and is 44px to hit OrangeCat's UX audit (chrome#13, 2026-11-12) found the widget's edge tab a 24px-wide dark sliver marked only with the spiral: the hardest control on a near-black page to see, and half the 44px touch minimum. - The tab button is 44px wide; its inner 12px is transparent padding and the visible handle is the outer 32px. - The handle is the surface ringed in the text colour, so in either mode one of the two clears 3:1 on near-white and near-black host pages. - A visitor's tab shows a speech bubble and a vertical "Feedback" label, named "Send feedback"; the owner's tab keeps its live dot and mark and now shows "Watching" / "Paused". - Still an edge tab, never the round launcher it replaced. The browser test now asserts the 44px width, the name and the label, and measures the visible handle for Minimize's "smaller than the button". Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn * fix(fleet-map): publish an OrangeCat project link only when the page answered The fleet map emitted the stored orangecat_project_id without asking, so Bitbaum's tile on orangecat.ch opened a project page deleted there (404). /fleet already probed its links; the map, which other sites copy, did not. The map now keeps only links whose page answered a read-only HEAD. An incomplete answer is asked again after a minute instead of ten. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn * fix(orangecat): a build log is not a post; a deleted project can be let go Closed runs and dev-log entries are no longer sent to OrangeCat's timeline. They were 78 of 80 posts on its public feed ("e2e ok, no changes", pull request numbers, commit hashes). They stay in Loki; the one moment still sent is a project going public. The backfill does not queue switched-off moments, and the activity switch is removed with the feed it governed (the stored answer is kept). Decision written in src/config/orangecat-publish.ts and docs/architecture/cross-product-identity-bridge.md. "Take it down" now clears the stored id when OrangeCat's API says the project does not exist, instead of answering that OrangeCat is too old. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
3304426bab |
fix(chat): a queued message stays in its conversation and survives a reload; an unanswered question says so and offers Try again (#1711)
* fix(chat): a queued message stays in its conversation and survives a reload; a question left unanswered says so and offers Try again Measured on production, 2026-11-13: - Three quick messages in a new chat became three conversations and the screen kept only the last. The queue was drained by a closure that still saw no conversation, so each queued message opened a new one. - Two queued messages vanished when the page reloaded. - Reloading mid-answer stops the turn (lib/api/sse), and the reopened thread showed the question with nothing under it: no working sign, no answer thirty seconds and a second reload later, and no way to ask again. - hooks/use-send-queue: each message belongs to the conversation it was typed in (as in @bitbaum/chatkit's useChatApp) and the queue is kept in sessionStorage; a message carrying files is not stored. - LokiWorkspace: the drain sends into the thread of the turn that landed. - lib/loki/unanswered + use-thread-recovery: a thread whose last message is the person's, with nothing answering it, says Loki did not finish and offers Try again (re-asks without a second bubble). Messages a reload brought back get Send now. - LokiWorkspace stays under its line limit: the rail filter and delete moved to use-visible-conversations. scripts/test/send-queue.ts. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * test(loki-work-trail): the queue's source pins follow the per-thread queue Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
137ff5d1fb |
fix(ai): Loki reads and writes the box's AI usage log; fleet-env usage-log points every app at it (#1709)
* ops(fleet-env): usage-log points every app at one AI usage log through the fleet file launch.sh.tmpl sets AI_USAGE_DIR, but a launch script is only rewritten by a site sync, so after #1704 no running app had it and Settings > AI said the server is not writing the log. Every launch script already sources /opt/fleet/env with export on. usage-log makes the directory, writes the one line there once, and restarts the apps one at a time. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(ai): Loki reads and writes the box's usage log without the launch variable Loki's launch script predates /opt/fleet/env, so after the box was pointed at one usage log Loki still had no AI_USAGE_DIR: the card said the server was not writing a log. lib/ai/usage-dir takes the box's directory when the variable is unset and it exists; instrumentation adopts it at boot (and names the app LOKI). Loki walks its own chain, so the package cannot see its calls: recordUsage reports each answered call to the log. scripts/test/usage-dir.ts. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * docs(env): AI_APP_ID in .env.example Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * ops(fleet-env): where and retire look beyond the app layout The platform's Google key was retired from /opt/fleet/env and the app env files on 2026-11-13, but nothing had looked at the builder's env (/opt/loki/runner/.env), the named runners' (/etc/loki/runners/*.env) or the Telegram gateway's (~openclaw/.openclaw/.env), where a copy of the same key could still be read by a process that spends. where and retire now also sweep /opt, /etc/loki, /home and /root for env files (not examples, not node_modules, not releases), reading root-owned ones through sudo. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
7c5c8e081b |
fix(widget): the edge tab says "Feedback" and is 44px to hit (#1707)
OrangeCat's UX audit (chrome#13, 2026-11-12) found the widget's edge tab a 24px-wide dark sliver marked only with the spiral: the hardest control on a near-black page to see, and half the 44px touch minimum. - The tab button is 44px wide; its inner 12px is transparent padding and the visible handle is the outer 32px. - The handle is the surface ringed in the text colour, so in either mode one of the two clears 3:1 on near-white and near-black host pages. - A visitor's tab shows a speech bubble and a vertical "Feedback" label, named "Send feedback"; the owner's tab keeps its live dot and mark and now shows "Watching" / "Paused". - Still an edge tab, never the round launcher it replaced. The browser test now asserts the 44px width, the name and the label, and measures the visible handle for Minimize's "smaller than the button". Claude-Session: https://claude.ai/code/session_019MDtmvT2nQyPBK4EfWf3Rn Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
3889d7e7c2 |
feat(settings): every app on this server and every AI vendor, today (#1705)
* ops(fleet-env): retire a key everywhere in one command; GEMINI_API_KEY is no longer a fleet key; ai-kit 1.26 GEMINI_API_KEY sat in /opt/fleet/env as a free tier. The Google project had billing and every app read the key: about $567 on 10-11 Nov 2026. On 2026-11-13 it was still set there, with eight apps on an ai-kit that puts Google in the free chain. - fleet-env.sh where KEY: every env file on the box that sets KEY, by fingerprint. retire KEY: its line in /opt/fleet/env and in every app env becomes a dated comment (the value is kept), and the app units restart one at a time so none keeps the value it started with. - fleet-keys.conf drops GEMINI_API_KEY, so seed never brings it back. - fleet-env.yml offers where and retire with a key input. - @bitbaum/ai-kit ^1.26.0: Google out of the free chain, paid AI off unless an app opts in, daily caps. test-fleet-env.sh covers where, retire (value kept, other lines untouched, no value printed, seed does not restore) and the refusal of a non-credential. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * test(ops): four .env cases that need an unreadable file are not run as root chmod 000 is how the section makes a .env unreadable, and root reads any file. In an agent's sandbox (uid 0) the four cases could only fail, on main too, and stopped every push that touched scripts/hetzner. They print as not run; CI and a developer's machine run them as an ordinary user. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * ops(launch): every app on the box writes to one AI usage log; ai-kit 1.27.0 launch.sh.tmpl exports AI_USAGE_DIR=/opt/fleet/ai-usage where that directory exists and AI_APP_ID from the app's directory name, unless the app's own .env sets them. @bitbaum/ai-kit 1.27.0 then writes one line per model call there (app, vendor, model, outcome; never content). fleet-env.yml creates the directory. Kivvi canaries 1.27.0, so the rollout gate no longer passes 1.26.0. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * feat(settings): every app on this server and every AI vendor, today The owner, 2026-11-13: 'I never know what is used up, what isn't, what it was used up for, and when. Is it just one app, or is it all the apps?' About $567 had gone to Google and nobody could say which app spent it. Settings > AI gains the operator's card 'Every app on this server'. It reads the one usage log every app writes (@bitbaum/ai-kit usage-log, AI_USAGE_DIR) and shows, per vendor: free or billing, whether its key is on this server, what today looked like, the last trouble in words, what that means for the next request, and which apps used it; then the same by app. A log that could not be read is never drawn as nothing used; a vendor nobody called is 'not called today', not full and not empty; a person's own key is counted apart. - lib/ai/fleet-usage.ts (pure view), /api/ai/fleet (operator only, key NAMES only), components/settings/AiFleetSettings.tsx - scripts/test/fleet-usage.ts: 12 checks Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * docs(env): AI_USAGE_DIR in .env.example Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(fleet-env): retire edits the file a symlinked .env points at, never the link /opt/<app>/app/.env is a symlink to shared/.env. An in-place sed on the link replaces it with a regular copy, which later changes to shared/.env never reach. where and retire resolve each file first, so the 13 paths the box listed for GEMINI_API_KEY are the 8 files they really are. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * test(npm-publish): tamper with the first character of the sealed body, not the last The last base64url character of a body carries bits that belong to no byte, so replacing only the tail could decode to the same bytes, and openSecret rightly accepted it: 'tampering is refused' failed on an unlucky random IV (CI on #1705, 2026-11-13). The first character always changes a byte. 40 of 40 runs pass. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
8b3727e464 |
ops(fleet-env): retire a key everywhere in one command; GEMINI_API_KEY is no longer a fleet key; ai-kit 1.26 (#1704)
* ops(fleet-env): retire a key everywhere in one command; GEMINI_API_KEY is no longer a fleet key; ai-kit 1.26 GEMINI_API_KEY sat in /opt/fleet/env as a free tier. The Google project had billing and every app read the key: about $567 on 10-11 Nov 2026. On 2026-11-13 it was still set there, with eight apps on an ai-kit that puts Google in the free chain. - fleet-env.sh where KEY: every env file on the box that sets KEY, by fingerprint. retire KEY: its line in /opt/fleet/env and in every app env becomes a dated comment (the value is kept), and the app units restart one at a time so none keeps the value it started with. - fleet-keys.conf drops GEMINI_API_KEY, so seed never brings it back. - fleet-env.yml offers where and retire with a key input. - @bitbaum/ai-kit ^1.26.0: Google out of the free chain, paid AI off unless an app opts in, daily caps. test-fleet-env.sh covers where, retire (value kept, other lines untouched, no value printed, seed does not restore) and the refusal of a non-credential. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * test(ops): four .env cases that need an unreadable file are not run as root chmod 000 is how the section makes a .env unreadable, and root reads any file. In an agent's sandbox (uid 0) the four cases could only fail, on main too, and stopped every push that touched scripts/hetzner. They print as not run; CI and a developer's machine run them as an ordinary user. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * ops(launch): every app on the box writes to one AI usage log; ai-kit 1.27.0 launch.sh.tmpl exports AI_USAGE_DIR=/opt/fleet/ai-usage where that directory exists and AI_APP_ID from the app's directory name, unless the app's own .env sets them. @bitbaum/ai-kit 1.27.0 then writes one line per model call there (app, vendor, model, outcome; never content). fleet-env.yml creates the directory. Kivvi canaries 1.27.0, so the rollout gate no longer passes 1.26.0. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
deb825bd99 |
feat(orangecat): a key saved in Loki can answer the person's OrangeCat bots (#1703)
* feat(orangecat): a key saved in Loki can answer the person's OrangeCat bots A person who gave Loki their model key was asked for it again on OrangeCat. The key now stays in one place: OrangeCat asks Loki, over the signed rail and as the linked account, to make the chat completion. - user_model_keys.for_orangecat: per key, off by default - POST /api/orangecat/model: keys, share, models, complete - never the person's own endpoint; chat fields only; 240 calls an hour per account; the key is never returned or logged - Settings → Your model: 'Also for your OrangeCat bots' Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * feat(orangecat): the model door carries native tool calls A bot offered its tools as prose guesses at them; every model was trained on its vendor's own function format. The door now passes function definitions and tool turns through and returns the calls the model asked for. OrangeCat runs them as the person; Loki runs none. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
d7da5375a0 |
fix(crons): a job cut off by a Loki restart runs once more on the new process (#1702)
fc-cron@sync-package-updates paged on 13 Nov with "curl: (52) Empty reply from server" while four Loki deploys landed in 50 minutes (07:27-08:09 UTC). Each deploy restarts loki-app; the runner already retried a refused connection (exit 7) through that window, but not a request the old process accepted and then dropped (52 empty reply, 56 reset, 28 timeout). The 120 s timeouts that paged for every job on 12 Nov have the same shape. Now, when curl fails that way AND loki-app.service's start time moved since the run began, the job runs once more on the new process. A job that sends or starts something exactly once (digest email, canary, autopilot, check-ins, chat review) is not repeated: it may already have acted, so it fails as before. An empty reply with no restart still fails. Test: scripts/hetzner/test-cron-runner.sh gains the three cases (restart: rerun and succeed; send-once job: no rerun; no restart: no rerun); 17 pass. |
||
|
|
5987663b6c |
fix(check): the rail check types into a search field; the walk and a bot's browser pass 15 of 15 on the live site (#1701)
* fix(check): the rail check types into a search field, not the button that says search First run on the live site (2026-11-13, run 43387876987): 14 of 15. The one failure was the check's own: it picked "Open search", a button, as the field to type into. It now takes a field, and a failed step prints Loki's sentence. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the walk and a bot's browser exercised on the live site, 15 of 15 Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
d493876bb0 |
test(live): the OrangeCat rail's browser doors are driven on the live site, from the box (#1700)
orangecat-rail-check.yml (on demand) runs scripts/test/orangecat-rail-e2e.ts on the box: it signs real requests with the rail's own secret, read there and never printed, as the operator's linked OrangeCat actor, and drives what a Cat Bot's walk_site and use_browser hands drive. A walk that must pass and one that must fail with its picture; a browser session with open, numbered elements, click, type, back, a password field refused, the box's own network and the metadata address refused, close; and the doors' edges (unsigned, stale, an actor with no account). Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
4ca1296fe8 |
fix(billing): an early Bitcoin-pass renewal keeps the days left (@bitbaum/paykit extendEntitlement) (#1699)
Renewing a pass before it ran out started the new period at the payment, so the days still left were lost. renewedPassExpiry stacks a same-plan renewal onto the running pass with paykit's extendEntitlement and starts any other at the payment. Taken out of #1652 while paykit's rollout gate could not see OrangeCat, its canary, live (fixed in bitbaum/fleet#529). Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
5199fff1dd |
feat(orangecat): a browser of its own for every bot; a picture a thread can show (#1697)
* feat(orangecat): a browser of its own for every bot; a picture a thread can show Cat Bot's computer use (OrangeCat docs/PARITY.md, plan step 2), Loki's half. POST /api/orangecat/browser, on the signed rail for the linked account, takes one step in the bot's browser: open, click, type, press, scroll, back, look, close. Every answer carries what the page now shows: address, title, the readable text, what can be clicked or typed into (numbered, so a model that cannot see pictures can still drive), and a picture. - lib/bot-browser: one session per (account, bot) in Loki's own Chromium, the whole context kept out of the private network, cookies kept between sessions in a file only this server reads. Closed after three idle minutes, twenty at the outside; two at once on the box, and a session in use is never closed for another. The page reader is sent as a string: a bundler that names inner functions made it read every page as empty. - lib/bot-browser-rules: pure. A bot never types a password, a sign-in code or a card; the step stops and says the owner does that. - lib/bot-shots + GET /api/orangecat/shot/[token]: a thread shows a picture only from a web address, so pictures are kept a week under a name nobody can guess. The site walk now answers a failed page with that address instead of bytes. - page-picture exports its private-network guard and its browser lookup, so there is still one of each. scripts/test/bot-browser.ts (11), site-walk.ts (13). Driven for real from a sandbox browser against orangecat.ch: open, numbered elements, click by label, scroll, back, a password field refused, a private address refused. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): Cat Bot parity with Grok Bot, the running checkpoint Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
900dbb6ae5 |
fix(ux): every Loki page reworked for a phone; idle sessions close; model-free commits; early pass renewals keep their days (#1652)
* fix(runner): idle agent sessions close themselves; agents sign commits without a model name; failures in plain words Three things from running a real task through Loki on 2026-11-11. - The cloud builder closes an agent session with no input or output for six hours (LOKI_AGENT_IDLE_CLOSE_HOURS; 0 turns it off), closed like a person closing it so a restart does not bring it back. 27 untouched sessions held the memory that took the sites down; the cap from #1634 stops the count growing, this gives the memory back. Shells and a person's own computer are left alone. The executor records the last byte in or out. - claude-prep sets Claude Code's attribution to a model-free trailer when none is set. The commit behind orangecat#1601 was signed 'Claude Opus 5.5', against the rule that no model identifier is pushed. A person's own attribution setting, including none, is kept. - Activity words three more causes (signed out, the builder could not start the agent, opened but never answered) and Home's failure card drops the runner's 'launched claude (pty) + injected, but Loki could not verify generation' and the operator note after it. The stored error is unchanged. Runner 0.8.65. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * chore(runner): 0.8.66, since 0.8.65 was taken on main while this was written Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix: an early pass renewal keeps its days; the menu shows @handle; three features work on any free model From the package audit of 2026-11-12, the cases a person meets: - A Bitcoin pass bought on OrangeCat was granted as 'now + days', so renewing before it ran out lost the days left. lib/billing/pass-renewal stacks onto a running pass of the same plan with @bitbaum/paykit's extendEntitlement (added); an upgrade or a lapsed pass starts at payment. - The account menu got name, email and image but not the username, so a person with no name saw 'Account' instead of @handle. - Event recovery, proposal extraction and Loki's chat fallback checked for GROQ_API_KEY although the call walks the whole free model chain; with OpenRouter or Gemini keys only they were silently off, and chat said 'Loki is offline'. They now check usableChatChain(). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * chore(deps): @bitbaum/chatkit ^0.26.0 Loki resolved chatkit 0.22.1 while 0.26.0 is published, so it lacked DictationField and CommentThread (0.23), the dictation sign-in/busy messages (0.24) and the hidden microphone on a page whose policy refuses one (0.26, bitbaum/chatkit#81). Type-check and the chat and voice tests pass. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(home): one answer to "is anything running?" Seen on a phone on 2026-11-12: Home's card said "Stalled — the latest run on 2 projects failed and nothing is currently building" and "Nothing is working. Waiting for your reply. Reply", while the section under it was headed "Being built" over two rows reading "Waiting for you · Waiting for your a…". Three answers to one question, and the "Reply" link scrolled to a project list that a phone hides, so the tap did nothing. - "Being built" lists only work being done. Agents waiting for the owner move into "Needs you", each row showing the agent's question instead of the state twice, with a neutral dot rather than the warning orange. - The card's waiting line reads "Nothing is running. 2 agents are waiting for you" and its link goes straight to the session ("Answer Orangecat") or to the waiting rows ("See who is waiting"), at least 44px and underlined so it reads as a link. - The failing state says "Last runs failed — the last run on N projects failed." and the card stays away when "Done" already lists those runs with "Ask it to finish": the same fact twice, with two fixes. - The card no longer repeats the builder line when the builder is on and working, and loses its "+" and settings icons: the foot rows are the one way to both. The foot row is titled "Settings" and says "Builds run in Loki's cloud" rather than "Cloud runner online". - Copy: "Your desktop app is closed; the cloud does the work", "An update installs when current work finishes", "Not started yet — sent 2h ago", "No word from it for 2h". - The composer's project picker says "Waiting for you" / "Gone quiet" for those jobs instead of "Being built now" for every open job. - A failed load shows "Home could not load" with "Try again" instead of a skeleton forever. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(activity): say which runs are running, in words, from the whole window Seen on 2026-11-12: Activity showed "Running (25)" while Home said nothing was working. The same run read "Running" on Activity and "Waiting for you" on Home, because Activity called every unfinished run running. Its rows showed the raw instructions sent to the agent (flags, paths, session URLs) and the builder's raw errors ("Sandbox cwd does not exist: /home/g/dev/…", "exited (code 129)"). "Last 7 days" showed the same totals as "Last 24 hours", because the headline was summed from the 60 rows the list shows, and the momentum line compared that capped count with an uncapped one. - One rule for an unfinished run (lib/open-run-state), read by Home and Activity: waiting for you, gone quiet, not started, or running. Only the last counts as Running; a run waiting for you counts as needing you, and one never picked up as queued. - Rows name the task the way Home titles it, and known failures in plain words: "Too many tasks were running at once", "The project's folder is missing on the builder", "The agent quit unexpectedly", "You cancelled it before it started", "Replaced by a newer request". An unknown error reads "It failed — open it to see why" instead of the raw text. - The headline, agent time and "Runs need you" come from every row in the window; momentum compares like with like and carries its unit ("64 tasks, up from 6 the window before"). A capped list says "Showing the latest 60". - "waiting on a runner" reads "waiting to start". Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(suggestions): keep PIN-gated goals and people off the board; say each fact once Seen on 2026-11-12 with the private zone locked: Today said "goals, people, habits, money & memory are hidden", while Suggestions showed "Due 43 days ago: Launch OrangeCat / Goal at 25%, target 43 days ago" and "Get ahead of: Reach out to Ana Argentina / Commitment due 2026-10-15". Goals, Crew and Events all live behind the PIN. Every row said its fact twice, three identical "Unlock to see these" rows stood one under another, a tap recorded a choice from a row with no sign it went anywhere, and an open "…" menu sat under the next row's "…" button. - Goals and Business (Crew) are private avenues: their reads and the build ranker's goals and commitments load only while the zone is unlocked, on /suggestions and in the build row alike. - The goal leads the row and the fact sits once on the grey line ("25% done · was due 43 days ago"); a goal more than 60 days past its date asks "still the goal?" and sinks. A commitment reads "Commitment overdue since 15 Oct." instead of a raw date. Report rows say "Sent by visitors to the site; none looked at yet." - Locked avenues are one row: "Goals, Business, People, Money and Habits — unlock to see". - Rows carry a chevron; "Not now" reads "Hide for a month"; the top line reads "You've taken 2 suggestions so far." beside "All (40)". - An open row menu rises above the rows below it. Recording a choice only when the prefilled message is actually sent needs the Loki chat to carry the suggestion through; left for a follow-up. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(today): say each need once, lead each card somewhere useful, show what is locked Seen on a phone on 2026-11-12: - "Needs you" said "7 approvals and 10 reports to triage." behind an orange warning triangle, then listed "7 actions waiting for approval" and "10 feedback reports to triage" — each fact twice, in two words. The rows were links that looked like text; the next row had a chevron. - "Last night Loki built nothing (tonight's plan was not approved)." mixed two nights and opened the feedback inbox. - The locked banner read "Private zone locked — goals, pe…", while "More" offered Goals and Money as if open. - In "Log a conversation", a locked zone made the people search answer 403 and the popover said "No results". - The main-projects editor showed each project twice (raw folder name over a text box of the same name), spoke of "repositories", linked "Control →" and kept a second "Choose main projects" button over the open editor. Now the rows are the answer (no summary sentence, no warning colour for a to-do) and every row that opens something has a chevron. The night note reads "built nothing — its plan was never approved" and, in that case, leads to Autopilot settings. The banner reads "Goals, people, money, habits and memory are locked." and wraps; locked rows under "More" show a lock and "Unlock to see". The people search says "Your contacts are locked." with Unlock. The editor lists each project once by its name, with "Rename" one tap away, links "Home →", and hides its own opener. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(home): plain words in the settings sheet, the inbox groups and the new-project form Seen on a phone on 2026-11-12: - The sheet behind the sliders had no title and was built from builder internals: "Pause fleet", "Runner / Cloud runner online / Runner sync 2m ago / cloud v0.8.64 / Page data just now", "Default agent for new launches", "Not on this computer: Install Cursor Install Codex" on a phone, and a free-text model box repeating the selected chip. - The two "Needs you" groups read "Widget not on live site" and "Feedback to triage" (Today calls the same thing differently), opened into "not enabled", "token paused", "never seen a boot from the live site", buttons "Install" / "Pause" and an unlabelled </> icon; a right-pointing chevron promised a page but the group opened in place. - The new-project form asked a phone for a local disk path and a Git URL, and its × had no accessible name. Now the sheet is titled "Settings"; "Pause all building"; the autopilot hint reads "Loki keeps working through each project's list, and builds overnight from visitor feedback within your budget."; "Where builds run" says "Builds run in Loki's cloud" with sync age, versions and page age folded under "Details"; "AI used for new work"; the model box opens from "Other model…" (or when the model is not a chip); install buttons only when the desktop app is connected; "Use it in running work too". The groups read "Visitor reports to read" and "Sites without the feedback button", the same words Today now uses, with "Not set up yet", "Turned off", "Not seen on the live site yet", "Add the button", "Turn off feedback" and a labelled "Copy code"; groups use a down chevron. The form asks only "Name your project", with folder and Git address under "Advanced", and its × is "Close". The hero's unused tool row style is gone. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(chat): say what runs, close drawers, plain words on cards (owner audit) The owner's phone opens on /loki. On 2026-11-12 an audit of the chat pages found it could not answer "is anything running, and can I watch it", and that several screens were hard to read or leave. What the person saw, and what changed: - The start screen said nothing while two agents waited for his answer. It now lists, above the greeting, every job being built or waiting for him, the same row Home draws (NowJobRow), each opening the live session. Read once when the screen opens; the snapshot is too large to poll from a phone. - If the chat list failed to load, Recent simply vanished. The start screen now says "Couldn't load your chats" with Try again. - The chats drawer and the project picker covered the full phone width with no close. Drawer takes a title and draws a heading with a 44px close. - A long thread name pushed the menu off a 390px screen; the floating title was drawn over the scrolled words. The header item gets min-width: 0 and the title the same frosted pill as its buttons. Render check added. - The same chat opened as "No project" from Recent and as "Loki" from the rail. One openConversation is used by the rail, Recent and the inbox line. - The chat's name was a hidden button to the project picker, and the menu had a third way to it. The composer's Project pill is now the one place; its whole pill is the button (it was a 27px name), and the queued-message x is 44px. - The project picker listed raw folder names as bordered cards with "· 0%", and "All" chose all ~50 projects. Rows are ListRows named by projectTitle, progress said as "40% done", "New project", and "Pick all N matches" only for a search. - "substrata~39554470" showed as a project. projectTitle and the By-project grouping use the base project key. - Recent and the rail drew the same chat two ways. Recent uses the rail's line; a project already in the title is not repeated. - A failed send printed the runner's admin instructions three times and offered "Watch it". It now reads "Couldn't start", says the reason in plain words, and offers Try again (the same words, same project) with Home second. - Month-old cards polled a 404 every 2.5s and still said "waiting". A gone record now reads "No longer tracked" with Send it again; unsettled cards slow to 30s after ten minutes. - An update said "Not done - nothing reached the site" beside a link to its pull request, then "Live" for the same change. A run that left a PR or push is part done; an earlier card for the same change folds into the later one; a real "Not done" offers Ask it to finish. - "Asked" quoted the report's "--- technical details ---" tail. One helper (lib/feedback/asked-text) strips it for the board and the chat, at write and at read. - "Not stated ... worth asking" appeared four times per card. It is one line, with an Ask button that sends the questions on that project. - Cards named the project "loki" and the page "/control"; now "Loki", "Home". - The answer footer listed model ids, routing and handler names. It now says "Answered with your xAI key · checked 24 of your records · 2.5 min"; the rest is behind Details, steps named from the tool-label SSOT (labels added for every handler). The work trail shows only a quoted search phrase. - The model sheet showed "Gemma 4 31B It", a model called "Free", an Auto line naming a model not in the list, and "186 left today" on eleven rows. Names lose packaging tokens, "free" reads "Any free model", Auto reads "Loki picks the model for each message", a row repeats the count only when it differs, and the header link has a chevron. - Answer replies came as a sideways pill strip cut mid-word; they now use the same rows as the other follow-ups (FollowUpRows). - "Dispatched" became "Sent"; executor copy names Home and Terminal, not Control and Sessions. - Build-next rows say "Start", since one tap sends the work. - Voice page: plain words for the switches and commands ("Stop voice", "things waiting for your OK", no Autopilot), and no "Studio voice" under six names. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(terminal): say what a session is doing, confirm an agent switch, one way to each action What the owner saw on a phone (audit, 2026-11-12): - Chat view: while a session waited for a reply nothing said so in words; the header read "Claude · 5 sessions · cloud" beside a coloured dot. While Claude was busy the line above the box said "Waiting for the agent", the word Home uses for "waiting for you". - A message Loki sent showed as the owner's own bubble with a "Dispatch details" fold holding a raw "<pasted_content id=…>" packet. - Session sheet: rows read "claude · needs you", "gemini", "claude"; two of five had no state. One tap on "Grok" under "Agent" swapped the running agent with no confirmation. "Your computer" was offered with no word that it was offline. - "New session" from inside Orangecat preselected Orangecat, so the sheet opened on a warning, "Start another session" and a "Go to its session" that only closed the sheet. - "What's going on?" was both a chip above the box and the first row of the ⋮ sheet; the feedback edge tab covered the ends of terminal lines. What changed: - New copy SSOT src/config/terminal-copy.ts. The live line says "Claude is working"; an answer with nothing running says "Done. Waiting for your reply". The header subtitle carries the status words ("Claude · needs you · 5 sessions · cloud"). - The fold is "Full instructions Loki sent", without the paste markers, and the bubble says "Sent by Loki" (also in project Watch). - Sheet rows always read "Agent · state" with the agent's name, "open" when the stream has nothing. The agent switch is titled "Switch this session to…", arms on the first tap ("Switch to Grok? Claude stops here") and switches on a second, like End. Disabled reasons drop "CLI"/"tab". "Your computer" says "Offline: open Fleet Runner on it" when it is. - Opened from a session, the launcher preselects a project with no session, and never offers to go to the session already on screen. - ⋮ offers "What's going on?" only while the chip is hidden (keys deck or full screen); on phones the raw terminal keeps 12px clear of the edge tab. Tests: terminal-conversation, terminal-launch-project and terminal-tabs-browser extended; terminal-clean-browser follows the new fold label. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(models): one primary choice, honest counts, one price source, quieter cards What the owner saw on /models on a phone (audit, 2026-11-12): - The page's only filled button was "Add your endpoint", in the most technical part (Ollama, Tailscale Funnel, "OpenAI shape", "shared pool"). - "343 of 343 models" sat over 60 cards and a "Show 60 more" with 283 left. - Two near-identical "where prices come from" paragraphs, with two different read times (06:05 and 06:18). - Every card repeated "OpenRouter USD per 1M tokens", drew "Direct" / "OpenRouter" as bordered boxes that did nothing when pressed, labelled closed models "Weights not listed", and coloured "Open weights", "Free tier" and "Free catalog rate" status green. - The lab filter listed "Meta · 9" and "Meta · 7"; picking one hid the other. - "Your keys: xAI grok-4.7. Manage →": a raw model id and an 18px link. - No name in the phone top bar and no way back to Settings. What changed: - "Run a model on your own computer": one line ("Optional. Loki works from your phone without it."), the how-to folded, plain words, and a secondary button. - "Showing 60 of 343 · …" (with "matching (N in all)" under a filter) and "Show more (283 left)". - Inside the store the Auto card drops its source paragraph; the footer says it once, with one time. - The unit is the card's label ("Price per 1M tokens"), a free model reads "Free", "Runs via" is plain text ("Direct (your key) or OpenRouter"), every tag is the neutral shape, and closed models carry no badge. The unused ui-store-badge-* and ui-store-via* rules are gone. - labsOf keys labs by name and applyFilters matches every namespace with that name, so Meta is one entry that shows all its models. - The keys line names the model as the list does; "Manage" carries ui-tap. - NAV.models (href MODEL_STORE_PATH) names the page in the top bar and the palette; the page links back to AI settings. Tests: model-store pins the card markup and the Meta merge. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(watch): one thing happening at a time, in plain words On 2026-11-12 the owner's watch page for Orangecat said "Next in line" above three rows marked "Happening now" at once: "Waiting for a runner 31m 30s", "Claude Code is finishing up" and "Testing", with "Pull request opened" already ticked below the first. The overview called the same run "Building now". Nobody could tell whether anything was running. - run-track: a run with a pull request, a push or commits has started, whether or not its claim was recorded, so the builder stage is done and never "Waiting". At most one stage is "now": the furthest; an earlier one is behind it ("Claude Code made the change"). A push while the agent is still in its session is done, not a second "now". - The watch card's kicker reads "<agent> is working" once the track is past the queue, and its headline is the track's sentence, not "Queued". - Stage words a non-technical owner can read: "Waiting for a computer to start it", "The change is ready for checks" (its headline without the #number or fix(...) prefix), "Checking the change — it goes live by itself once the checks pass". - The autopilot button says what a tap does ("Pause after this" / "Keep going on its own") where the caption already says the state; "Follow fleet" is "Use my usual setting", drawn like its sibling. - Timeline rows, "See the change" and "Show all" are 44px tall. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(projects): Priority puts the rows that want you first Under "Sort: Priority" ("Projects with issues first"), Kivvi and Bitbaum said "Needs you: 1 note" and sat 11th and 17th, under a dozen rows that said "Live" (owner's phone, 2026-11-12). The order read only the flags; the row's words come from projectListLine, which also knows unread notes and what is running. The "Show" menu never offered "With a problem" for them either. Priority now ranks by the row's own line: a problem, then something waiting on you ("Needs you", "Didn't start"), then something building, then most recent work. The "With a problem" lens and its count use the same rule, and the hint says "Problems and things waiting on you first, then most recent work". Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(project): one next step, a way forward from past work, one way back What the owner saw on Orangecat's pages on 2026-11-12, and what changed: - Overview "Next step" printed the agent's handoff note word for word: "NOT PUSHED - pre-push hook fails … --no-verify was blocked; push test/box-safe-unit-tests, open PR, enable auto-merge", while Plan named a different next step. It now reads the plan's next step, then the top open goal — Plan's own source — and is hidden while a build runs, where "Building now · View progress" already answers it. - "Past work" listed red "Failed" rows cut mid-word ("Dispatch failed before the prompt reached the agent: Sandbox c…") that led nowhere. Each row now says why in a sentence (explainRunFailure) and opens the run's watch page, where Retry lives. "Saved changes" shows commit headlines without the fix(...) prefix. - On a phone, Workbench was a menu repeating the overview, with every explanation cut by an ellipsis. The overview row goes straight to the agent ("Talk to the agent — Say what to change"); the workbench's own rows fit one line and sit on the 16px margin, not 33px. "The robot" is "Talk to the agent"; "Review it" reads "See it as visitors do". - Review's way back read "← orangecat"; it is the project's name with the same icon link every project page draws. - The top bar said "Projects" on watch and workbench but nothing on the overview and review; every page of one project now names itself. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(project): Story, Feedback and Settings in plain words and calm colour What the owner saw on Orangecat's tabs on 2026-11-12, and what changed: - "Built from" cut package names mid-word ("@bitbaum/g / eo-kit"): the name is sized to itself and may break only after the scope; the version wraps to its own line. - "Profile 10/10" sat above "The story 8 of 10 answered": the bar counts setup checks, so it is called "Setup". The stage chip said "production"; it says "Live" (PROJECT_STAGE_WORD, one word per stage). - "About it" filled a phone screen: four lines, then "Show all". - Feedback: nineteen fixed notes each had a filled "Watch the fix"; on a fixed note it is a secondary button. The quiet moves and "Technical details" are 44px tall. The "--- technical details ---" tail is folded under the note instead of read as part of it. - Radios were the browser's bright blue in both themes; every radio and checkbox takes the text ink token. The live-site panel starts with nothing chosen, not "Take it off the internet". - "Reversible"/"Permanent" are plain words, not green/amber tags; a package behind is neutral unless an update waits on the owner. - Plain words: "Feedback button is on the site", "Fix notes from helper agents without asking me", "Also delete the copy on this computer", "Posting updates on OrangeCat: on", and a two-sentence Flags note. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(activity): show what is running now, and say failures in plain words What the owner saw on /activity on 2026-11-12, on a phone: 23 rows said "Running", one of them for over two hours, on a builder the same page said runs 8 at once; running rows were grey and mixed in with failures. "33 runs need you" counted briefs a newer one replaced and waits he had cancelled himself. Failure lines were the builder's own ("exited (code 129)", "Sandbox cwd does not exist: /home/g/dev/orangecat", "no runner picked it up"), done lines carried CRON_SECRET and commit hashes, and running rows showed raw briefs with claude.ai session links. A grouped row of 8 failures across four projects had one "Run again" that resent only the first, next to a cause (the builder was full) that a retry cannot fix. "See all 33" reloaded the page with the same three groups above the same list. A failed retry hid its reason in a tooltip phones never show. "up from 9 the window before" named no noun. What changed: - An open run silent past RUN_PROGRESS_FRESH_MS (the progress contract's window, read from the run ledger's last event) reads "Stopped answering" and counts as needing you; only runs still heard from are Running. - A "Running now" section opens the page: live dot, project, "Working for 12 min", the brief in plain words; each row opens Watch. The mixed feed no longer repeats them. - "superseded" closes read "Replaced" and cancelled waits "Stopped by you"; neither counts as needing you. Every row counted as needing you has the red dot (Partial had none). The headline drops "anyway" and says "waiting for a computer"; the filter says "Sent, no word back", like the rows. - plainFailure maps exit codes, missing folders, a full builder, no free computer and replaced briefs to plain sentences; plainLine strips links, session ids, hashes, setting names, paths and leading routing notes from every row line. - A full-builder group offers "See what's running" instead of a retry; a group spanning projects names the one run its button resends. A retry's outcome becomes the row's grey line. - The needs-you card is hidden on the "Needs you" filter. - Momentum says "up from 9 runs the 24 hours before". Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(feedback): label Do all, one story per report, shorter "Needs a yes" What the owner saw on /feedback and /my-feedback on 2026-11-12, on a phone: - The most consequential tap in the app, "Do all 109 · starts 106 runs", was an unlabelled round icon in the top bar; its sheet's button said "Do it" and never mentioned that the cloud builder runs 8 at a time. - The same report read "Last try failed" on /feedback and "Fix is live" on /my-feedback; others read "Being implemented" for 21 days. - "Needs a yes" listed all 112 rows (about 9000px), sixty of them "Last try failed · Try again" with the reason only inside the sheet; some thirty titles read "While I was using this page a request fai…", identical. - "Last night Loki built nothing (tonight's plan was not approved)." had no way forward and mixed last night with tonight. - The report sheet had "Watch the fix" and a second "Watch" promising "watch the agent, live" for a run that ended weeks ago, on two rows. - Done rows showed two unlabelled times; the footer said "archived" beside a "Filed away" section and "6d median to confirmed". - /my-feedback was the one page with a blank top bar, and nothing led to it. What changed: - Do all is a full-width labelled button under the sentence; the sheet's button says "Start 106 runs" and, past the builder's limit, says that runs beyond it are turned away and show on Activity. - The reporter view reads the same facts as the owner's recommendation: Loki's page read "not visible" is "Not fixed yet", a partial run "Partly fixed", a live fix nobody could confirm "Fix shipped, being checked"; a finished run whose change has not reached the site after three days is "Stalled". - "Needs a yes" shows 10 with "See all 112"; a retry row says why the last try failed. Report titles drop watch mode's lead-ins (lib/feedback/report-title.ts), on both pages. - The night note reads "the plan was not approved" and links Autopilot settings beside it. - The sheet shows "Watch it work" only while the run is open; afterwards "See what the agent did" sits under More. - Done rows drop the second time when the line carries one; the footer says "filed away" and "usually fixed in about 6 days". - /my-feedback is registered in navigation (no menu seat) so the top bar names it; /feedback links "Reports you sent". Footer links are 44px tall. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(approvals): one primary while locked; package updates in plain words What the owner saw on /approvals, locked, on 2026-11-12: "7 actions waiting for approval, behind your PIN" over a small outlined "Unlock to review" (38px tall), and below it a filled "Update" on a breaking package update — the eye went to the merge, not to the unlock. The card opened on "@bitbaum/chatkit v0.21.2 → v0.23.0 breaking", offered "Not now" beside "Stay on this version" without saying how they differ, and its "Pull request #16" and project links were 16px and 24px tall. The top bar's page action ("Write a report") was 40px. What changed: - Locked, "Unlock to review" is the page's one filled button, 44px tall; the package cards draw their "Update" as secondary there. - The card leads with one sentence from config ("Keller can move to newer versions of 3 shared parts. 2 of them may need changes to the project's code."); package names and versions sit behind "Details". - "Not now" says what it does: "Ask me again in 7 days". - The pull request and project links are 44px tall, and so is the top bar's page action. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(system): alarms in plain words with a way forward; one reading per fact What the owner saw on /system on a phone (2026-11-12): eleven alarms that were the box's raw shell lines ("🧟 STRANDED agent work in loki-wt-scope — unpushed fc/1840a4dd-…", "docker stop <name>", "sudo reboot", "Replace GEMINI_API_KEY in … /opt/<app>/shared/.env"), each with only Dismiss; two disk alarms ("still 93%", "still 91%") above a live reading of 70%; the same branches listed twice for two worktrees of one repository; a 41-day-old "Server size" reading that still promised a Telegram alert; scheduled-job switches drawn "on" for jobs that were off; eleven leftover "smoke-<timestamp> cron" test jobs; a "Health check" section that only said it did not apply; "Recent errors" that was nine heartbeats around one error; and builder words throughout ("claimed", "runner", "Queued — a connected runner … will claim it"). What changed: - config/box-alert-copy.ts turns each known box line (stranded work, new container, critical dependency, disk clean-up, pending reboot, dead API key) into a plain title, one sentence and an "Ask Loki to …" button that opens the chat with the ask and the original line written. The raw line stays behind "Details". Applied when drawn, so the rows already open read plainly too; rows of one kind collapse into the newest (both disk alarms, both worktrees of loki). Intrusion alarms keep their own words and button. The notice still carries no button, because a box line with one would reach the phone, which only an intrusion may. - lib/notify/box.ts keys a line without its numbers, so a repeat updates one row instead of adding one. - Server size: a reading older than six hours no longer draws "blocked" or the Telegram promise; it says Loki stopped checking and offers to restart the check. The current size is no longer listed as an upgrade target. - Scheduled jobs: the shared ui-switch with role="switch", aria-checked and a name, 44px to tap; test artifacts (isPublicTestArtifact) are not listed. - Health check is not drawn where it cannot run; Recent problems lists only errors and warnings, names the source plainly, and offers "Ask Loki to fix this"; nothing wrong draws nothing. - Builds and cost (was "Room for more work"): "How long work waited to start", "On Loki's servers", "started", and the longest wait in the warning colour only past 30 minutes. - What Loki decided: what was asked, a plain status word (EXECUTOR_COPY .decision), project titles; the inject reason is EXECUTOR_COPY.inject .queuedForRunner, "Waiting for a computer to pick it up". - RAM and disk bars warn from 85% and turn red from 95% (was 66/86): a disk two-thirds full is normal and made amber the page's accent. - "More records" names only what is always there; the plan form's Days field stacks like the others; Pause/Carry on everywhere and the alarm's Details button reach 44px. Test: scripts/test/box-alert-copy.ts. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(missions): runs say what they are and open to watch; one progress number What the owner saw (2026-11-12): every mission row showed two progress numbers that disagreed ("0 of 1 goals reported done" beside "25%", "4 of 14" beside "54%"); "Recent runs" was five identical rows, "Running or queued 12.11.2026", that could not be tapped, with a failed one reading "error" and a section link called "Terminal"; "Next move" cut its sentence to one line under the label "Next step" while the handoff further down gave a different next step; the handoff printed agent notes (hashes, branches, paths) in full; the start button said "Sending to the runner…". What changed: - goalsLine() is the one progress measure on the board and the detail page, pluralised ("0 of 1 goal reported done"); the averaged percentage is gone. - lib/missions/run-row.ts: each run row names its task (its result, else its last step, else its kind), says "Working now" / "Waiting to start" / "Stopped with a problem" …, shows a relative time, and opens the run on Watch. The section link is "Watch live" to the project's Watch page. - Next move is one wrapping sentence from one source (the handoff's next step, else the project's, else the first open goal). The handoff's own note shows only when it differs, labelled as the agent's note. - Handoff text goes through plainWords() and is clamped to three lines with More/Less; an empty test report is not drawn. - The start button says "Starting…" (EXECUTOR_COPY.honesty.starting). Tests: scripts/test/missions-projection.ts, missions-attention-board.ts. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(packages): behind count first, install at latest, a way to update What the owner saw (2026-11-12): on /packages the ellipsis took the one fact worth opening a row for ("used by 22 projects, 20 beh…"); on a package page the install command pinned v1.5.2 under "Latest version v1.7.1"; twenty amber "2 minor versions behind" cards each repeated their raw version spec and offered nothing to do, while five identical "Pause vX everywhere" buttons were the page's only actions; a release with no version read "the last release was released … its tag shows here on the next read"; the same action was "Read again" on one page and "Refresh" on the other. What changed: - The list line leads with the behind count ("20 of 22 projects behind · v1.7.1") and drops the warning dot. - installCommand() rewrites a `<name>@<version>` install to the latest version. - "Behind" is a neutral tag; only a breaking bump keeps the warning colour. behindLabel says "2 updates behind" / "1 major update behind". - The raw spec is a hover on the version, not a line of its own. - "Ask Loki to update the N behind" opens the chat with the package, version and projects written. - Pause shows only on the latest version, a failing one, or one already paused. - Release run copy lives in RELEASE_RUN_COPY; a finished run with no version reads "Last release finished 1d ago." - One name for re-reading: "Check again"; its text-link form is 44px tall. Tests: scripts/test/packages.ts, packages-pages.ts, package-releases.ts. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(studio): show the chosen request, one primary action, decisions that say what they do What the owner saw on /feedback/studio on a phone (2026-11-12): tapping a request card seemed to do nothing, because no style marked the chosen card and the detail opened ~1,100px below the list; card titles were cut mid-word by character count ("Checking the partner f"); the detail showed the applicant's own status line to the reviewer; four solid primary buttons sat on one request, and "Record builder decision" sat under a select pre-set to "Approve this builder"; "Revoke guest access" had a 13px checkbox; history dates were US-format with seconds. What changed: - .ui-card-shell[aria-pressed="true"] is raised and outlined; on narrow screens a tap scrolls the detail into view. - Titles are whole, clamped to two lines, with the last update's relative time so identical websites can be told apart. - STUDIO_REVIEW (config/studio.ts) gives the reviewer's next step per status. - "Send reply" is the only primary; other forms are secondary. The partner decision is two buttons, "Approve builder" and "Decline application" (or "Withdraw approval"). Revoking is a danger button, "Stop their link", with its checkbox in ui-checkbox-hit. - History times are relative, with the full date as a hover. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(fill): a link Loki does not know offers the way back to Loki What the owner saw (2026-11-12): /fill without a known form said "Ask Loki again — for example 'set up npm trusted publishing for my package'" with no way to do it from the page. It is now an empty state with one button, "Ask Loki to fill a form", and an example in plain words. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(settings): ask before disconnecting a computer What the owner saw (2026-11-12, Settings → Agent on a phone): every connected computer ("box-runner", "Fleet Runner (local file)") had a red trash icon that revoked its key on one tap, with no question and no undo, named only by a hover title "Revoke token" that a touch screen never shows. One mis-tap disconnected the cloud runner and stopped every agent. Now the icon is named "Disconnect <label>" and only asks: the row turns into "Disconnect box-runner? Agents on it stop until you connect it again." with Disconnect (danger) and Cancel. The icon uses ui-icon-action-danger, which carries the 44px touch floor. Dates read "Added November 12, 2026 · last used 2h ago" instead of US-order numerals. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(settings): AI providers in plain words, raw output behind a disclosure What the owner saw (2026-11-12, Settings → Agent → AI providers): env var names, server paths, install commands, German shell errors, stack-trace fragments and ANSI escape codes as each row's line ("add OPENROUTER_API_KEY to the cloud runner's env (/opt/loki/runner/.env)", "fix: ␛[91mError: ␛[0mInvalid API Key"), uninstalled providers listed as long as working ones, and "This computer · checked 1 day ago" with seven amber rows as if the failures were current. Now the row line is derived from the measured facts in provider-words.ts ("Not set up on Loki's computer", "Signed out. Open it once on your computer to sign in again.", "Its key was refused"), the runner's own text is cleaned of colour codes and kept under a collapsed "Technical details", providers that are not set up fold behind "Show N more not set up", the runners are called "Loki's computer" and "Your computer", and a runner that has not reported for an hour is one sentence saying when it last checked in instead of a list of stale faults. The runner-side nextActionFor is unchanged, so no runner redeploy is needed. Test: scripts/test/provider-words.ts. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(settings): one fact once, a name for every section, plain words What the owner saw on a phone (2026-11-12 audit of /settings): - Projects: all 37 projects twice, under "Your projects" and again under "Team projects" (getOrgProjects includes the caller on purpose). Team now lists only other people's projects, and only when there are any. - Account: "Connected accounts" and AccountKit's "Ways to sign in" both listed how you sign in, and disagreed (Google in one, not the other). On AccountKit the Loki list keeps only the links Loki acts through (GitHub for code, OrangeCat for publishing), titled "Accounts Loki works through"; sign-in lives in the panel. Its disconnect icon gets the 44px floor. - Notifications: the Telegram card said "Connect here" with no connect button when the bot is not set up; it now says "Your messages go to your Telegram chat." and promises connecting only when the button is drawn. The six category toggles were solid primary buttons reading "On"; they are now the ui-switch every other on/off in Settings uses. "The last one went out 11/10/2026, 7:00:04 AM" is in the reader's own locale without seconds. - Billing: the operator, who runs this Loki with no project limit, was told "You are on Free" and urged to "Get more room". They now read "You run this Loki. No limits apply." without the plan pitch, and the Bitcoin/renewal sentence is said once (PRICING_BILLING_NOTE), not twice. - Every section: the top bar and the back control both said "Settings" and sections opened on a sub-heading ("What you have left", "Members"). The open section's name is now its h2; the four sections that drew their own duplicate h2 no longer do. - AI: "Add a provider" twice and "Upgrade plan" duplicating Billing; the button pair is gone (the store link stays in Your providers). The operator's spend list showed codebase slugs ("terminal-next-steps"); config/ai-feature-labels.ts names them ("Next-step suggestions in Terminal"), with a test that every metered feature has a label. - Agent: "Loki dispatches nothing. You type every prompt in /control", "Groq first (~2s, free), local Whisper", "~/.cache/huggingface/". The autopilot and transcription copy is rewritten in plain words, the two autopilot cards align the same way, and the row says the section also holds autopilot. Moving voice transcription to its own tab is deferred. - Voice: "layers on top of the house style … Agents you dispatch" is now "How Loki writes to you. Agents building your projects don't use it." and the presets are one pick-one list with a check (like the digest choice) instead of a 2x2 wrapped grid. - Location: the timezone starts from this device's when none is saved (marked "(this device's)"), the lede drops "scheduled jobs", and "Save current location" is "Save while traveling", which is what it does. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(private): one list of what the PIN protects, one PIN form What the owner saw (2026-11-12): three screens gave three lists of what the PIN protects. Privacy named Crew but not Robots, /unlock named Robots and Commitments but not Crew, the no-PIN page Robots but not Crew. The locked pages showed a different form ("Private Zone / Enter PIN / This section is PIN-protected", nothing while loading, a bare "Network error") from /unlock ("Enter your PIN", shield, lock icon), /unlock's top bar had no name, and Privacy sent people to "Account → Danger zone", which does not exist on AccountKit. Now navigation.ts derives PRIVATE_NAV_ITEMS and PRIVATE_AREAS_PHRASE from the "private" sidebar section, and Privacy, /unlock's list and the no-PIN page all read it (Commitments fold into Money, where they live; counts are plain nouns: "2,805 things", not "entities"). PrivatePinGate renders UnlockForm, named for the page: "Memory is private / Enter your PIN to open it." with a skeleton while loading, "Could not reach Loki. Check your connection and try again." on a network failure, and a 44px "Get help". /unlock's top bar reads "Private" (UNLISTED_PAGE_TITLES). Privacy links "Delete account" in Account settings. The top bar also stops naming the parent ("Home") on a child page that draws its own h1 (/control/import, /control/new-from-scratch), where the bar, the back link and the title were three competing names. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(control): workspace, import and new-project pages for a non-builder What the owner saw (2026-11-12): - /control/workspace: an amber warning box of server words ("Server-owned PTY workspaces", "control plane", "box-runner peek stream", "dispatch") for a switched-off feature, with three inline links in one sentence and "Back to Control". With server workspaces off the page now redirects to /terminal; otherwise it is a neutral callout (new ui-callout, amber is kept for real warnings) with one "Open Terminal" button. The API error strings in runtime.ts / workspace-access.ts are plain words too. - /control/import: "Pick the repos … duplicates by name are silently skipped", a heading icon squashed to 6px, "No repos found" with no next step, a twice-dimmed disabled Import button and "Go to Control →". Now "Choose the code you want Loki to look after", shrink-0 on the icon, "Missing one? Give Loki access on GitHub" under the list and in the empty state, one dimming, 44px Select all / Clear, and Home named from NAV.control. - /control/new-from-scratch: "Leave on Empty and the agent picks the stack" against "Empty — Just a README. Bring your own stack.", template descriptions with shell commands and "ms-scale cold starts", and "No technical decisions required" beside "GitHub repo" and "stack". The bare template is now "Let Loki choose" (recommended in the hint), each template says what it suits, the subtitle is "Loki makes a private place for the code and sets it up.", and native radios and checkboxes take the ink colour instead of the browser's blue. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(auth): offer GitHub once, and say continue on sign-up What a newcomer saw on 2026-11-12: the first sign-in screen offered "Continue with Google or GitHub" and then "Continue with GitHub", two doors to the same place with no way to tell whether they lead to one account. "Create an account" offered "Sign in with a Lightning wallet", telling someone with no account to sign in. The "Create an account" and "Sign in" links under the forms were 18px tall on a phone. What changed: with Loki's own GitHub app mounted, the shared sign-in's button names only the other providers (offerGithubOnce). Only the label changes; the shared service's own chooser still offers GitHub, so no account that came in that way is stranded, and when GitHub is all it publishes nothing is hidden. The sign-up screen's Lightning button reads "Continue with a Lightning wallet". The two hint links carry ui-auth-hint-link, which the coarse-pointer floor sizes to 44px. The label filter belongs in @bitbaum/accountkit's signInMethods for every product that keeps its own GitHub app; it lives here until it moves there. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(public): theme-true download band, readable menus, one count on the roadmap, plain words What a visitor saw on a phone (audit, 2026-11-12), and what changed: - /download in Light: the band stayed black and the accent button (black in Light) vanished into it. Every ui-public-download-* rule now uses surface, text and border tokens; no white/black left in the band. The phone handoff, lede and comparison drop "control plane", "dispatch", "runner", "CLI" and "Open Home"; the desktop-only "After install" steps render only once the downloads are shown, and the edge-to-edge closing line that repeated the handoff is gone. - Light-mode phones got a light status bar over a black page: the theme-color meta now starts dark (the default theme) and follows the resolved theme (ThemeColorSync, themeColorFor). - The menu's Appearance button sat under the floating feedback button, so tapping it opened feedback: it now sits next to its label. Every menu description was cut off with an ellipsis: they wrap to two lines and are shorter ("Talk to Loki with your phone in your pocket"). - Links inside sentences ("whitepaper", "docs") looked like plain words: in prose they are underlined in a token colour. - /roadmap gave 47% shipped, 22 of 59 steps (37%) and bare ring numbers on one screen. The headline is now "16 of 34 items shipped", the steps line says it is the work inside the open items, and rings carry no number (the card's "6/9 steps" is the count). Collapsed changelog months and roadmap step lists show the same rotating chevron as other disclosures. ROADMAP.md summaries say what a person gets instead of paths, class names and shell flags, and a bare address in a line is a link. - /pricing: "Start free. Pay when you need more.", Loki's engine explained once, no "operators", "fleet" or internal screen names; Free no longer claims "nothing held back" above a Team plan with more. - One public name for the machine: PUBLIC_WHERE in executor-copy.ts ("Loki's computers" / "your own computer"), used on the home page, /why, pricing and the whitepaper summary; "runs this week" reads "tasks". - Signed in, the home page still offered "Create an account" and "Start a project" to /sign-up and the footer "Sign in": visitorLink turns those into "Open Loki"; /sign-in no longer links to itself. - Build-path cards said each thing twice ("Do it yourself" / "Build it yourself"): the kicker is gone. The footer's version link duplicated "Fleet Runner releases"; the owner line reads "Loki, run by Cato" as the terms do; BiasLens has its own one-line blurb. "Notes in, fixes out" shows the year and no raw page path. bip-kit's Copy button gets the 44px coarse-pointer floor. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(search): the magnifier searches; asking an agent is last and never on Enter What the owner saw (phone, 2026-11-12): the header magnifier opened a box whose placeholder was cut off ("Type a command (e.g. “code re…"), and anything typed became "Run: <text> / Resolve in natural language & dispatch" as the first row and the Enter default, so a search plus Enter sent the words to an agent as work. With nothing typed it listed 43 projects with their server folders ("/home/g/dev/bitbaum", "no local path"), raw ids as names, then 17 "Switch X to Claude — quits current CLI" rows; the 60-row limit was hit before a single page, so Activity, Prompts and Settings never showed. The "esc" hint showed on a phone. The More sheet and the search sheet also drew the widget's floating feedback button over themselves, a second shape of the header's button. What changed: - Empty list: recents, then the pages in the sidebar's order, then projects named the way a person knows them (projectTitle, with the site's host instead of a folder), then prompts. - Switch-agent rows are gone from search; the project's own screen keeps that control. - Typed text finds first. "Ask Loki to do: “…”" is the last row, says what it does, and Enter only takes it if the arrow keys chose it (enterTarget, tested). - Placeholder "Search projects and pages"; the desktop field no longer says "dispatch"; "esc" is shown from md up only. - The palette panel and the More sheet carry data-fc-place="hidden", as <Modal> does, so the widget does not float its button over them. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(chrome): 44px for the page action and the search mic; tokens, not white What the owner saw (phone, 2026-11-12): the filled page-action circle in the top bar ("New project", "Write a report") was 40px beside 44px search and bell buttons; the search sheet's microphone was 28px, and its background was white at 4%, so on the light theme it had no visible edge. The bell's count was hard-coded `color: white`. On /activity the page's primary circle was a sparkle, where every other page puts "+", and nothing on screen said it meant "Write a report". What changed: - .ui-page-action on a phone is 44px with a 2px transparent border the fill does not paint, so the circle still reads 40px like its neighbours' visible circles. - .ui-palette-mic joins the coarse-pointer 44px floor and is raised with a hairline (tokens), as is the kbd hint; no oklch literal left. - The bell badge uses text-text-inverted on status-negative (also better contrast on the dark theme's lighter red). - "Write a report" uses a page icon (FileText). Not changed: .ui-btn-icon (row "…", bell ×) and the theme button already get 44px under `pointer: coarse`; the audit measured with a mouse pointer. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(bell): plain words, one row per thing, every row opens somewhere What the owner saw (phone, 2026-11-12): the bell listed the server's raw lines as titles: "🧟 STRANDED agent work in loki-wt-scope — unpushed fc/1840a4dd-…", "🐳 NEW CONTAINER", "♻️ REBOOT PENDING for 7 days", "bitbaum: ☠️ SUSPICIOUS PROCESS / pid 951241 running … Kill it: sudo kill -9 951241". Half the rows opened nothing (the box's no-action lines are recorded with no button), and nine near-identical SUSPICIOUS PROCESS rows kept a red "9+" lit. What changed: - The bell leaves out `system_event` rows ("no action needed from you", already listed on /system) and links there in one counted line instead. - Intrusion notices get a plain title ("An unexpected program ran on bitbaum", "Someone signed in to bitbaum with a password") and one sentence; the raw line stays in the body behind "Details" (lib/notify/intrusion-words). Rows recorded the old way read the same in the bell (bellWords). - Rows with the same title fold into one ("9 times · …"), dismissed together; the badge counts the folded rows, and its spoken label says "More than 9" when the badge says "9+". - A row with no link of its own opens /today, where it is listed. Not changed: urgent alerts still never fold into Earlier (design reset rule 11), and the delivery key is untouched, so a login from a second address is still its own phone notice. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * test(widget): the palette and the More sheet may hide the launcher while open The search palette and the More sheet are dialogs; since 285a975e they carry data-fc-place="hidden" as <Modal> does, so the widget stops floating its own button over them (it sat beside the More sheet's close ×, 2026-11-12). The reach check allowed only Modal and the sign-in wall; it now names these two, with why. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(more): say what Unlock opens, mark the row that leaves Loki, show waiting feedback What the owner saw in the More sheet (phone, 2026-11-12): "Private → Unlock" with no hint of what is private; "Bots", which quietly opens orangecat.ch; "Waiting for you → Approvals, Feedback" with no count, while Home said "Feedback to triage 10"; and "Download" in the account menu, which did not say what gets downloaded. What changed: - The lock row names what it opens: "Unlock Memory, People, Crew and 5 more". - A row whose page is on another site says so ("on OrangeCat" and an outside-link icon). - Feedback carries the same new-feedback count the desktop sidebar shows (FeedbackNavCount). Approvals has no count: its list needs the private zone, so a locked phone could not read it. - The download page is called "Desktop app" (NAV.download, the one name every menu reads). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(feedback): the owner gets his own panel inside Loki; one door to it What the owner saw (phone, 2026-11-12): signed in to his own app, the header's spiral opened the visitor's panel — "I own or build this site — sign in with Loki →", "No account? You make one on the way", "Made with Loki →", "Hide this button on this site". The widget knows the owner only by a pass, and on Loki's own origin nothing handed it one. The account menu also opened the same panel a second time ("Report a problem"), next to "Hide feedback button" for a button nobody could point at, and its Appearance control read "☀ Light" while a tap switched to Dark. What changed: - The app layout mints the owner pass for the signed-in person when they may act for Loki's own widget (lib/feedback/own-site-pass, same canActForSite check as /api/widget/owner), and OwnSitePass stores it where the widget reads it (widget/owner-pass storeOwnerPass). The widget then shows the owner's panel, without the sign-in door, "Made with Loki" or "Hide this button". Anyone else gets null, as before. The first time, Watch starts paused: nobody asked for it here, and it is one tap ("Watch again") in the panel. - "Report a problem" is in the account menu only while the top bar has no spiral; the switch says what it switches ("Hide the spiral (feedback) from the top bar"). - Appearance is Light · Dark · Auto, the current one marked (Segmented), instead of a cycle button. Test: scripts/test/own-site-pass.ts (the page and the widget agree on the storage key; minting is gated on the owner; first pass starts paused); phone-chrome.ts updated. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * feat(chrome): the top bar says when an agent is working, and opens it to watch What the owner asked (2026-11-12): "I would like to know if anything is actively running, and I would like to watch it". No icon, tab or More row said whether anything was running; Terminal, the place to watch, was the first row of the fourth More section. What changed: while an agent is working, the top bar on every page shows a screen icon with a green dot (one agent) or a count (several). It opens that session in the terminal, or the terminal's list when there are several; its label says "1 agent working now — watch it". Nothing working, nothing drawn; on /terminal itself it is not shown. It reads /api/sessions/snapshot (the Sessions drawer's DB-only list) once a minute; "working" is the same rule the drawer and the terminal's tabs use (lib/session-list workingNow, tested). Checked against production: the list had one working (solon) and one waiting (orangecat) session, so the bar would show one green dot to Solon. Home's and Activity's own wording of the same question is being fixed in the home and review branches. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(prompts): say what each prompt does in plain words; tell the twins apart What the owner saw on /prompts (phone, 2026-11-12): "Next Best Step" beside "Next best task", and "Test & Fix" beside "Test & fix", with descriptions that did not say how they differ ("Autonomously determine and execute the single highest-impact task right now" / "Autopilot loop — read ground truth … Self-throttles"), and lines he could not judge before tapping Run: "OWASP Top 10", "write a conventional commit, push to origin", "Audit ~/.loki/sessions/<P>.roadmap.md", "Kill switch", "N+1 queries", "prop drilling". What changed: those descriptions say the outcome ("Check the site for the ten most common security holes", "Check the finished work, then save and publish it", "Stop the agent at once — it changes nothing more"), and the two autopilot entries say they are "What autopilot runs on its own", so each twin reads differently from its sibling. Not changed: the names (task titles across the app read the library's name for an autopilot intent, lib/task-title) and the templates themselves (two of them drive the autopilot loop). Saved copies under "Your prompts" are the owner's own rows; they already say "4 copies" and offer "Remove extra copies". Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix: the combined phone audit passes the whole suite Folding nine groups' fixes into one branch (2026-11-12): - getLastRunEventTimes is gone: Activity and Home now share one rule for an unfinished run (lib/open-run-state), so the second lookup the review group added for the same question had no caller. - terminal-clean-browser follows the watch page's new button names ('Pause after this' / 'Keep going on its own'). - widget-kit-browser: the chat chunk measures 41 KB gzipped on chatkit 0.26 (agent mark, paperclip sources, dictation sign-in/busy, no mic where the policy refuses one); the budget moves from 40 to 42. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(voice): one name for talking to Loki, written on the button The chat box had two unlabelled sound icons side by side: the mic, which types your words, and a waveform that starts a spoken conversation. The More menu had a third entry, 'Voice', for the same conversation with the screen off. The owner could not tell them apart (2026-11-12). - The chat's conversation button reads 'Talk' on the button itself. - The /voice page is 'Talk to Loki' in the menu, its title and its start button ('Start talking'); its voice picker is 'Loki's voice'. - The mic is unchanged: it dictates into the box. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(voice): the menu entry is 'Talk', the button's own word 'Talk to Loki' and its one-slip spellings collided with other pages in the search palette (palette-entries: 'tak to loki' found Suggestions). The menu entry is 'Talk', the word on the chat's button; the page title stays 'Talk to Loki'. Suggestions' description no longer says 'takes', which 'tak' landed on. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * test: the Home browser test follows waiting agents into 'Needs you' home-being-built-browser (from #1670) looked for the waiting row under 'Being built'. After the merge it sits in 'Needs you' with its question and the reply field; the test now checks that list, that only the working row is 'Being built', and that the reply still reaches the project's agent. runner-update-hold reads the queue label in this branch's words. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * style: format home-parts after the merge Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * fix(home): keep main's load-failure branch as written; shorten the waiting list call instead home-load-failure pins the shape of Home's no-data branch. Home stays under its 510-line limit by naming the reply handler once. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * chore(deps): @bitbaum/chatkit 0.29.0, the version kivvi and causius canaried The fleet rollout gate held this PR: chatkit 0.26.0 was never deployed on its canaries, which moved straight to 0.29.0. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq * chore(billing): early pass renewals wait for paykit's rollout gate; the rest of this PR lands now @bitbaum/paykit 0.3.0 canaries through OrangeCat, whose live receipt only matches while its newest main commit is the one deployed; OrangeCat's main moves every few minutes, so the gate has held this PR through four sweeps. The renewal change (extendEntitlement) comes back in its own PR. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtUQb9BM11ycpApwGq --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
00a2687419 |
feat(orangecat): a bot walks a live site in Loki's browser and is told, per page, what is wrong (#1696)
The QA half of Cat Bot's parity with Grok Bot (OrangeCat docs/PARITY.md, plan step 1). POST /api/orangecat/site-walk, on the same signed rail and with the same linked-account rule as /api/orangecat/feedback, opens up to three pages at phone size in Loki's own guarded browser (lib/feedback/page-picture: one at a time, private network refused) and answers per page: loaded or not, the words it must show, a sideways scroll, broken pictures, with a picture of a page that failed. Facts only; read-only; a bot files what it found through the feedback door. lib/site-walk: parseWalk and judgePage are pure; runWalk never throws and moves on from a page that is slower than forty seconds. scripts/test/site-walk.ts (13). Run for real against the two live sites from a sandbox browser: a passing page, and a failing one with its 34 KB picture. Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
198d77e523 |
feat(auth): an agent's token opens a browser session, with the token's power and no more (#1679)
* feat(auth): an agent's token opens a browser session, with the token's power and no more A browser cannot send a Bearer header on a page load, so a Viewer seat with a ck_ token was sent to sign-in from /projects, /terminal, the workbench, history and feedback. - POST /api/token-session (Bearer ck_ only) mints a link that opens once, within two minutes. The link carries a random code; the server keeps its SHA-256 (token_sessions, migration 0138). The token is never in the link. - GET /api/auth/loki/token-session (an AccountKit plugin endpoint) opens it: a session for the token's user that ends after an hour, is never refreshed, and is recorded as the token's before its cookie is set. - Such a session reads like the user (pages, GET on the API) and writes only where a token is accepted: the proxy marks its writes and person-only routes read them as signed out. It never reaches tokens, a shell, the password, linked sign-ins or export, nor AccountKit's passkey and second factor endpoints. Revoking or expiring the token signs it out. Tests: scripts/test/token-session.ts (landing paths, the refused routes, the middleware decision, the wiring); scripts/test/token-session-db.ts in test:db (single use, expiry, revoked and expired tokens, hash-only storage). * style(drizzle): format the 0138 snapshot and journal |
||
|
|
6e96590fae |
fix(check): the loop probe asks for a summary unique to the run; the check passes 5 of 5 on the live site (#1692)
* fix(check): the loop probe asks for a summary unique to the run 2026-11-12 18:28: the orangecat probe went into the live Claude session that had written "e2e ok — no changes" at 17:00. The handoff already said it, so Claude left the file as it was, its time stayed 17:00:00, the run's delivery (now the claim time, 18:27:45) was later, and the run sat at Needs you. A token per run makes the agent write, and proves the handoff is this run's. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the loop check passes 5 of 5 on the live site Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
c8713738e4 |
fix(runs): delivery falls back to the claim time, so a finished agent's handoff closes its run while the runner is behind (#1691)
* feat(ops): runs-db runs=open lists every open run, read-only Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(runs): a run's delivery falls back to the claim time, so the agent's own handoff closes it while the runner is behind 2026-11-12 17:00: the orangecat probe was claimed at 16:59:5x, Claude did it and wrote its handoff at 17:00:00, and the runner, still on the morning's code because its update waits on the drain, acked at 17:00:05 without its injection time. deliveredAt was the ack time, the handoff "predated" it, and the run sat at Needs you. The prompt cannot reach the agent before the runner claimed it, so the claim time is a floor that never postdates the injection. Used only when the runner reports none; deliveryStampFor still bounds it. scripts/test/delivery-claim-floor.ts (shows the old stamp leaving the run open and the claim time closing it). Checkpoint updated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
74183f9410 |
fix(runner): a sealed session between tasks does not hold the runner's update; ops: runs-db (#1690)
* fix(check): the loop check prints the agent's screen before it aborts a quiet run 2026-11-12 16:30: the orangecat probe went to Claude Code (Grok's balance was spent, #1689 routed around it), started, and at 16:55 read "Needs you: no output for a while" with a clean checkout. Nothing said what the agent was showing. The check now opens the session's peek stream for twelve seconds and prints the last twenty lines, masked, before the abort. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * feat(ops): runs-db prints a project's last runs and stored handoff, read-only Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(ops): runs-db reads summary as text and finds the project's session row by name Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(runner): a sealed session whose project has no open run does not hold the runner's update The drain counted a sealed session as idle only when its podman relay went quiet. On 2026-11-12 an idle session's relay moved 3 to 10 KB a minute, so every open session counted as working, each deploy's drain waited its six hours behind them, and the runner on the box kept the morning's code all day. That mattered at 17:00: a probe task to orangecat finished in seconds and wrote its handoff at 17:00:00, but the old runner acked delivery at 17:00:05 without its injection time (the fix that sends it is on main and not on the box), so the handoff "predated" its own delivery and the run sat at Needs you. count_agents now reads the open runs from Loki's database, as sealed-builds-ctl.sh stop-idle does: a sealed session older than fifteen minutes whose project or lane has no open run is between tasks. When the database cannot be read, the old rule stands. between_runs is pinned by test-drain-and-restart-runner.sh (51 of 51). Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * revert(check): the loop check's screen look; the peek stream takes a browser session only It answered 401 to the check's agent token (2026-11-12 17:15), so it printed nothing useful. runs-db (sealed-builds.yml) answers the same question from the database: the handoff, its time and the run's delivery stamp. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): Claude did the probe; the late delivery stamp and the drain that never restarts the runner Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
b0c6d58ebe |
fix(dispatch): a chat task does not walk into an agent that has run out; ops: agent-probe asks an agent on the box what it says (#1689)
* feat(ops): agent-probe opens one agent CLI in a sealed container and prints what it says On 2026-11-12 the runner refused claude 16 times between 14:42 and 14:50 UTC and grok once at 15:21, "usage limit is exhausted", and kept no screen to show why. agent-probe (sealed-builds.yml, runs=<agent>) launches the agent as the runner does, with the credentials sandbox.ts passes through (names only), sends "Reply with the single word PONG" and prints the masked screen. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(ops): the PTY probe answers a modern TUI's terminal queries and its trust prompt grok drew nothing until the terminal answered its version query (ESC[>0q), and claude stopped at the trust prompt of the probe's new folder, so the first agent-probe runs (2026-11-12) never reached the composer. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * feat(ops): agent-probe asks one headless turn before the interactive one grok draws nothing in the probe's terminal; a headless turn has no terminal to negotiate and prints a quota wall as plain text. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(dispatch): a task nobody pinned to an agent does not walk into one Loki has just watched run out Live 2026-11-12: the orangecat project's agent was Grok, whose Grok Build balance was used up ("402 Payment Required: Grok Build usage balance exhausted", read with sealed-builds agent-probe), and every chat message to it failed in fifteen seconds while Claude Code on the same builder answered. Kickoff, Implement and the retry already route around a spent agent; the chat's path, injectPrompt with no agent pinned, did not. - lib/dispatch-agent-route: agentAvoidingSpent, the same providerChoiceFor + routeAroundSpent the kickoff uses; anything unreadable keeps the project's agent. Not a preference change. - inject-core: used only when the caller pinned no agent; a rerouted run records reroutedFrom/reroutedBecause for the Watch page; agentNotice in the body. - The chat's dispatch reply says which agent took the task and why. scripts/test/dispatch-agent-route.ts. Checkpoint updated. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
5d057688a1 |
fix(ux): what the signed-in audit found first: a short message wraps, a field vanishes, pages slide on load (#1688)
* feat(fields): sixteen text boxes get the microphone; chatkit 0.25 Fleet experience standard, step 9. The experience audit counted 34 hand-made text areas with no microphone; it now counts 17, and package-plan.json sets the ceiling at today's counts so the number can only fall. - @bitbaum/chatkit 0.22.1 -> 0.25.0. Composer behaviour and the class names Loki overrides are unchanged; LOKI_VOICE keeps the transcribe route's own sentence (showServerDetail), which names the fix. - <TextArea> (components/ui/text-area.tsx): Loki's one adapter over chatkit's DictationField, drawn to match ui-input. Sixteen files use it. One file is exempt with its reason on its first line (URL paths, one per line). - Field takes htmlFor, so its label names the control and a press on it focuses the field. - A signed-out visitor's microphone is the browser's own recogniser (VISITOR_VOICE): the server leg answers 401 without a session, so on /change the mic recorded a whole take and then failed. - The widget chat bundle budget goes 40 -> 41 KB: 41,414 -> 41,614 bytes gzipped, the two new dictation problems a person can act on. The other seventeen wait for props the shared field gains in bitbaum/chatkit#85 (autoFocus, onKeyDown, onBlur/onFocus, name, inputProps). The stylesheet in this commit also carries the public-site rules of the next one. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * feat(public): say it on the first screen; a shorter homepage; a header that stays The way in - The homepage's one action is the shared composer. What a signed-out visitor says is kept in the tab (lib/first-words), shown back on sign-up and handed to the new-project form at the end of onboarding or sign-in. With a sentence carried, onboarding does not ask for a project name, a folder and a GitHub address first. The homepage - 10.66 -> 7.48 phone screens at 390x844, 6.6 -> 5.11 at 1440x900. - Three figures for the three steps, drawn in tokens (LoopFigure). - Three problems on the homepage, all twelve on /why. Where it runs is one sentence and two links. The closing block is the shared FinalCta. - One label for sign-up everywhere: Start a project. Header, menu, footer - The header was sticky in name only: .ui-public-surface was overflow: hidden, which made it the sticky container. overflow-x: clip. - The phone menu takes focus, keeps Tab inside and hands focus back. - The Product menu opens on a press, not on hover. - Navigation and Sign in show from 1120px (was 1280px). - A 2px focus ring, on the public surface and as the app-wide fallback. - A skip link. Four footer groups instead of five. Corners - An unknown address outside the app drew the framework's bare 404 with no way back; the in-app one said Back to Today and went to Loki; the error page printed the raw error; the loading placeholder drew cards on pages that are rows. The share image leads with the headline. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * fix(ux): dates render once; rows say the part that matters; a person's words - APP_LOCALE is a server variable, so a client component formatted dates in the default locale while the server used the configured one: a hydration error on /approvals with APP_LOCALE=de-CH. next.config.ts hands the same value to the browser as NEXT_PUBLIC_APP_LOCALE. - Home's running rows lead with the live step. A phone row holds about thirty characters and every row read 'Next best step · Editing src/app/pa…'. - The workbench's three rows on a phone were each cut before the words that say what the row is for. - Terminal without cloud access, Home's first-run row and the widget row use the person's words (computer, Loki button), not ours (runner, widget). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * docs(ux): the November UX pass, the public surface map, the changelog Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * feat(fields): the remaining text boxes get the microphone; chatkit 0.27 The second step of the fleet's experience standard for Loki. The shared field gained what a form's text area needs in bitbaum/chatkit#85 (0.27.0): autoFocus, onKeyDown, a submit key, a field-level blur, name, inputProps. Sixteen more files move onto <TextArea>; the experience audit goes bareTextareas 17 -> 1 and the ceiling in package-plan.json follows. Kept, file by file: Cmd/Ctrl+Enter saves where Cmd+Enter did (goal and person notes, project description, the idea step), Escape still cancels, Enter still sends an interview answer and confirms a queued prompt, notes still save when focus leaves the field, and an inline editor no longer closes when its microphone is pressed. The studio's forms still read their text by name from the native form. The scheduled job's prompt keeps the mono face and spell-check off. ProjectBriefFill's separate Speak button is the field's own microphone now (the same transcribe route). Left: control/prompt-input.tsx, a prompt box with its own attachments and paste-to-attach. It is a composer, not a form field. Checked: tsc, lint, the design gate, file inputs, 599 unit-test files; in a browser, autofocus, both submit keys, Escape, save on blur and not on the microphone, 44px microphone and 16px text at 390, and the chat and Home composers after the bump. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * test: a git fixture cannot reach the real repository from a hook in a linked worktree A hook run from a linked worktree exports an absolute GIT_DIR, which overrides git -C <sandbox>. dispatch-launch-dir.ts ran its fixture commands with that environment, so a pre-push from a second worktree wrote a test@test init commit onto the branch being pushed and set core.bare = true, a test identity and a hooks path of /dev/null in the real config. Nothing reached the remote; the repository was repaired by hand. worktree-workspace.ts already clears those variables for itself. The unit runner now clears them once for every test, and dispatch-launch-dir.ts does so for a direct run. Checked: with a bogus GIT_DIR inherited, the test passes and the real repository is untouched. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * docs(ux): the text boxes' second step, and what is left Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * chore(deps): chatkit 0.28.1, where a dictated take respects a field's maxLength bitbaum/chatkit#87, found while reviewing this branch's converted fields. 0.28 also draws a visible border on the composer while it has keyboard focus and stops thread-following from scrolling the page up. Checked on 0.28.1: the chat, Home and homepage boxes at 390px in both themes (text goes in, send enables, no sideways scroll, no console errors), tsc, lint, the design gate and the widget size test (41 KB budget holds). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * Revert "feat(fields): thirty-two text boxes get the microphone; chatkit 0.28.1" This reverts commit |
||
|
|
43e1782b22 |
fix(builder): five agent sessions at once, not eight; idle sealed sessions can be stopped to free memory (#1687)
* docs(handoff): #1678 merged; the box still drops requests and Loki's deploys do not land Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): memory ceiling set at 10 GiB; Gemini spending cap in OrangeCat #1672 Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(builder): five agent sessions at once, not eight; idle sealed sessions can be stopped to free memory Measured on the box on 2026-11-12: a sealed session holds about 1 GiB, not the 0.4 GB the cap of eight was sized at. With seven or eight open the builder held 6.3 to 8.3 GiB, the box had 0.6 GiB left, swap was full, and the kernel had stopped 37 processes for memory, live sites and the gateway among them. - AGENT_MAX_OPEN_DEFAULT is 5. LOKI_AGENT_MAX_OPEN raises it where there is room. - sealed-builds-ctl.sh stop-idle (sealed-builds.yml): stops the sealed sessions that relayed less than 512 bytes over two minutes, the line the idle rule already uses for "no work". A working agent prints far more (its spinner alone). runs=dry lists without stopping. idle_sessions is pinned by scripts/hetzner/test-sealed-builds-memory.sh. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(spend): the platform's Gemini key is not used where nothing caps it The audit after the Gemini spend (2026-11-12) found the same platform key in three places with no cap that refuses a call: - Loki's own chat chain called Google whenever GEMINI_API_KEY was in its env. Google is left out of CHAT_CHAIN (UNCAPPED_PAID_PROVIDERS) until Loki has a cap that refuses, like OrangeCat's reserve_vendor_call. - install-builder-agents.sh copied OrangeCat's key into the builder's env for the Antigravity CLI. An agent CLI cannot be capped in code; the builder now uses Gemini only with a key of its own, from a Google project with a per-day request quota. - openclaw-media.yml fell back to OrangeCat's key for the Telegram gateway's image and video reading. No fallback: with no key of its own, media understanding stays off. Keys already copied on the box stop mattering when the platform key is replaced; the new key is never copied anywhere. scripts/test/chat-chain.ts pins all three. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(builder): stop-idle stops only sessions whose project has no open run Bytes are not the signal: on 2026-11-12 eight sealed sessions at their prompt each relayed 3 to 10 KB a minute through podman, so a 512-byte line would have stopped none, and an agent waiting on CI prints nothing at all. A session whose project (or lane) has no open run in Loki's database is between tasks; one that does is kept, and so is any session under fifteen minutes old. between_tasks is pinned by test-sealed-builds-memory.sh. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(builder): between_tasks reads its list without a pipe into grep -q scripts/test/no-grep-q-in-a-pipe.ts: grep -q exits at the first match and can cut off the writer. A here-string has no writer. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the box recovered; spend caps; the owner's key steps Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
54a7024cdc |
fix(queue, runs, chat, ops): an idle run is closed before the next task starts; a blocked pull request is said in the thread; an address to Loki is not the loki project; the builder can be given a memory ceiling (#1678)
* fix(check): the on-demand loop check signs in on the box, and is red when it cannot ask The first run of loki-loop-check.yml (2026-11-12, run 43188095136) printed "down: loki e2e could not mint a session on the box" two seconds in, and the job was green. Three things were wrong: - The deploy ships the runner a fixed list of scripts and nothing under scripts/test, so on the box there was no test to run and no token script. The workflow now carries the check's own files with it. - The check minted an Auth.js session cookie. Sign-in moved to AccountKit on 2026-11-01, where that cookie is no session. It now signs in the way a runner does: scripts/test/mint-check-token.ts mints an agent token for the operator that expires in two hours, the check uses it as a bearer and removes it on exit. The cookie mint stays as the fallback. - A check that could not sign in exited 0. With the verdict asked for, it exits 1, and it says why (long strings masked). scripts/test/loop-check-signs-in.ts pins all of it. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): what production showed after the first fix, and why the check could not sign in Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(check): the loop check prints Loki's own reason for a task that does not start Its first full run on the live site (2026-11-12, run 43191224470) ended "still queued (Queued) after 35 min" and then guessed at the builder's sign-in. The run route already answers the track's sentence for an open run (detail), and the chat's reply says where the task went: the check prints both, right after the dispatch and again when it gives up. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the first full check on the live site, 4 of 5 Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): why the probe did not start, in Loki's own words Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(chat): an address to Loki is not the loki project; the loop check reaches the project it was sent to A project named in a message outranks the selected project, on purpose (lib/loki-fleet-commands). The assistant is called Loki and so is one of the projects, so "Loki, add a dark mode toggle" typed with orangecat selected was sent to the loki project. Found through the loop check on the live site (2026-11-12, run 43198552471): asked for project orangecat, it came back "Sent loki to the cloud runner", because its marker was "[loki-e2e]". Three runs in a row had waited behind the loki project's open run while reporting on a project the probe never reached. - project-mention: withoutAddressTo removes an address to the assistant before matching: the name at the start followed by punctuation, after a greeting, "@loki", or set off by a comma at the end. "Loki's sidebar", "in loki" and a bare "Loki fix the header" still name the project. - loki-loop-e2e: the marker is "[e2e-probe]" and names no project, and the check fails at once when Loki dispatched to another project than the one it asked for. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the probe had been going to the loki project; the routing fix Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(queue): a run that has gone silent gives its project to the waiting message A project's shared session takes one message at a time: the claim gate holds the next one until the run ahead has closed. A run closes when its agent reports. An agent that ended its turn without reporting still has a process at its prompt, and the reaper shelters a run with a live process for up to MAX_RUN_HOURS, so the next message could wait twelve hours behind a session that was doing nothing. On the live site (2026-11-12) messages sent through Loki's chat read "This project is still on an earlier task" and were still queued 25 to 35 minutes later. - lib/orchestration/quiet-lane: the rule, pure. The runner beats while the terminal prints and while the agent waits at a sign-in or an approval. No beat for 20 minutes (twice the window after which every surface says Stalled), not waiting for a person, no command outstanding, and still so 90 seconds after it was first seen: release. The second look covers a runner that could not beat for a while and whose first request back is the claim. - db/queries/quiet-lane: reads those facts for the run at the head of each lane a message waits in, through olderOpenRunSql, and closes it with the reaper's own verdict (partial with the handoff note, else timeout with the sentence), ended at its last beat. No escalation. - claimNextPendingCommand calls it before the gate, so the message is claimed in the request that closed the run. - The waiting sentence carries the bound. A working agent prints, so its beat is seconds old at any age and it keeps its lane. Nothing is closed when nobody is waiting. scripts/test/quiet-lane.ts, and five scenarios in scripts/test/lane-and-reaper.ts against a real Postgres (13 of 13 locally). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(runs): a pull request that cannot merge is said in the thread, with the message that repairs it The fleet's sweep merges a green pull request and leaves a red or conflicted one waiting. A task sent from the chat that ended at such a pull request read "done, it merges on its own" until somebody opened GitHub. - feedback/fix-shipping: PrBlocker, prBlockerFor (a conflict when GitHub says mergeable: false, else the names of the checks that failed; cancelled and still-running are not failures), prBlockerNews (once per commit and reason). - feedback/fix-shipping-refresh: readBlockers on the refresh input; only then are the head commit's check runs and statuses read. - run-follow-notify: the fifteen-minute follower asks, and on news writes one line into the thread the task came from and sends one push. The line ends with the message to send ("<project>: fix the failing checks on <pull request> and push to the same branch."): a message naming a project is a task for it. - Loki does not send the repair itself: no agent run nobody asked for (lib/auto-dispatch). scripts/test/run-follow-notify.ts. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the 11:17 rehearsal failed on a slow box: sign-up 504, 96% memory, a 503 window Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): bots do not answer on the live site (502, 11:39 UTC); OrangeCat #1672; #1678 green Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(queue): only a run whose runner has reported output can be read as having stopped A runner from before the beat existed reports nothing while its agent works. Silence since delivery would have closed such a run after twenty minutes and typed the waiting message into a working session. A run that has never beaten now keeps its lane; one that truly never printed is the reaper's, which closes it as never started from the runner's own unverified ack. scripts/test/quiet-lane.ts, and a sixth scenario in scripts/test/lane-and-reaper.ts (14 of 14 locally). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(ops): the box usage report prints the builder's memory budget and finishes on a slow box On 2026-11-12 the box had 0.6 GiB available and no swap left, and the report was cancelled at its 20-minute limit inside the first du. Each disk walk now gets a minute. A new section prints what the runner unit holds, whether it has a memory ceiling, and which cgroup the sandboxes' processes are in: sandbox.ts relies on the unit's MemoryMax to bound sealed sessions. Read-only, names and sizes only. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): what holds the box's memory, measured; the builder has no ceiling Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(queue): an idle run is closed before the next task starts; the runner's six-hour stop and a turn answered in seconds are read correctly Three faults in the idle rule (#1680), found by an independent review and shown failing first in scripts/test/lane-and-reaper.ts against main (13 passed, 4 failed; 17 of 17 after): - An idle run stopped holding its project but stayed open until the hourly reaper. The next task went into the same session, and its ready handoff closes every delivered open run of the project, so the idle run was recorded as done with the other run's summary. The claim now closes the idle run first, with the reaper's own function and sentence, and only when a task is waiting in that project (db/queries/idle-run-close). - The runner stops beating six hours into a run. Half an hour later the run read as idle while it printed, and the next prompt went into a working session. A last working beat at that horizon is not read as silence (RUN_PROGRESS_HORIZON_SECONDS). - A turn that ended before the runner began reporting on it never had a working beat, read as unknown and held its project for up to twelve hours. Every beat stamps lastBeatAt; a run the runner reports on that has printed no work since delivery is idle after the same half hour. A run with no beat of any size keeps its lane, as before. scripts/test/idle-run-release.ts, scripts/test/lane-and-reaper.ts. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(ops): the box usage report can be asked for memory alone The disk walks took the whole 20 minutes twice on 2026-11-12, on a box that was swapping, when only the memory was wanted. what=memory stops after the memory sections. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * feat(ops): the builder can be given a memory ceiling, read and set from the Sealed builds workflow Measured on the box, 2026-11-12 12:19 UTC: loki-box-runner.service held 6.3 GiB with MemoryHigh and MemoryMax at infinity, every sandbox process is in that unit's cgroup, the box had no swap left, and the kernel had stopped 30 processes for memory since boot: the gateway 15 times, a live site 3 times, a sandbox 3 times. Every site unit has a 1G ceiling; the builder had none, though sandbox.ts relies on the unit's MemoryMax to bound sealed sessions. sealed-builds-ctl.sh gains three modes, run from sealed-builds.yml: - memory: read. What the builder holds, what bounds it, what the box has left. - memory-set, runs="<GiB>": MemoryMax and MemoryHigh one below it, and the builder's processes are marked to give first when the whole box runs out. Refused when the ceiling is below what the builder holds now, because that stops sessions at once; "force" after the number sets it anyway. Nothing is restarted. - memory-clear: undo. Nothing is set by a deploy. It is a decision, applied by a person. scripts/hetzner/test-sealed-builds-memory.sh, in test:ops. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(runs, chat): the blocked pull request notice is said once and its repair reaches the right project; an address to Loki is set off, and is the project when nothing else is From the independent review of this branch, each finding confirmed by a second agent told to refute it. The notice: - It would have repeated every tick. "Already said" lived in the ledger, the ledger is rebuilt on every refresh, and the dispatch card's own refresh does not read blockers. It is kept beside the ledger now (payload.prBlockerSaid, per reason), written once the line is in the thread. - Its repair line named the pull request by link. The link carries the repository owner's name, and a project of that name won the match: the repair for loki went to Bitbaum. The line names the number, opens with "In <project>," and uses a verb the chat's own rule takes as a task, for a conflict as well. The test sends it through projectMentionedIn and looksLikeDispatchTask for four projects and both reasons. - action_required and stale count as failed: neither turns green by waiting. The address: - "ok loki is broken, fix its header", "loki-loop-check is red" and "run the tests on @loki" lost the project; "Loki - add a toggle" kept it. An address is the name set off from the sentence (a comma, a colon, any dash with space around it, "please", "can you"), at the start of any sentence. - "loki: fix the header" is read as an address, so a selected project gets the work; with nothing selected and no other project named, the name is the project (projectNamedByAddress, the last resort of both paths). scripts/test/run-follow-notify.ts, scripts/test/project-mention.ts (114). Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * fix(ops): the builder's ceiling is a ceiling only; docs(handoff): the box's memory, the review's findings, what is ready and not applied memory-set no longer sets MemoryHigh one below the ceiling: at the moment it is set the builder holds close to the ceiling, and a mark under what it holds would slow every session at once. Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi * docs(handoff): the box's memory now holds up OrangeCat merges: Browser smoke is red on main Co-Authored-By: Claude Fable 5.2 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmt4p1jMfJnbJtpeNhi --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6a966ac6ae |
fix(sessions): the session walk says what tab-inject does, and tab-inject says when a task waits (#1674)
Traced 2026-11-12. On the cloud builder tab-inject queues a task that the claim gate holds while an earlier run of the project is open (so it never types into an agent mid-task), but it answered only ok, and the walk said a running session gets the prompt typed into it. A prompt for a plain shell was queued and answered 200, then refused by the runner. - tab-inject: a task held behind an open run answers heldBehind (runId, startedAt, label) and a message, read with findQueueBlockers, the gate's own predicate; a prompt for a shell is 403 before anything is queued - LOOP-WALK: 'give it a task' says it waits its turn; 'type into it' says how to send a message mid-task (bracketed paste, then Enter); open-tabs names are lowercase; the shell refusals are the real statuses - scripts/test/session-walk-truth pins the routes and the text together Claude-Session: https://claude.ai/code/session_019MDtmtCjm3CvrFm3kYaTgy Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
69f2f11b22 |
test(unit): no test can reach the real repository from a push (#1684)
The pre-push hook runs the unit suite with git's hook environment, and from a linked worktree GIT_DIR is absolute; an absolute GIT_DIR overrides 'git -C <sandbox>'. lane-base.ts (new on main today) made its throwaway repo that way. Pushing from a worktree on 2026-11-12, its 'init' commit (author test) replaced every file of the branch being pushed, and its git init and git config set core.bare, core.hooksPath /dev/null and user.name test on the real repository. The push's hook failed, so nothing reached GitHub. worktree-workspace.ts and the shell fixtures each guarded themselves; a new test did not. The runner now strips git's own repository variables (git rev-parse --local-env-vars) from every test it spawns (scripts/test/lib/test-env.ts). scripts/test/test-runner-git-env.ts replays the hazard between two throwaway repositories and checks the guard; run against lane-base.ts, an inherited GIT_DIR got its commit unguarded and nothing guarded. Claude-Session: https://claude.ai/code/session_019MDtmtCjm3CvrFm3kYaTgy Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
7f8e731b08 |
feat(ux): say it on the first screen; a shorter homepage; a header that stays (#1675)
* feat(fields): sixteen text boxes get the microphone; chatkit 0.25 Fleet experience standard, step 9. The experience audit counted 34 hand-made text areas with no microphone; it now counts 17, and package-plan.json sets the ceiling at today's counts so the number can only fall. - @bitbaum/chatkit 0.22.1 -> 0.25.0. Composer behaviour and the class names Loki overrides are unchanged; LOKI_VOICE keeps the transcribe route's own sentence (showServerDetail), which names the fix. - <TextArea> (components/ui/text-area.tsx): Loki's one adapter over chatkit's DictationField, drawn to match ui-input. Sixteen files use it. One file is exempt with its reason on its first line (URL paths, one per line). - Field takes htmlFor, so its label names the control and a press on it focuses the field. - A signed-out visitor's microphone is the browser's own recogniser (VISITOR_VOICE): the server leg answers 401 without a session, so on /change the mic recorded a whole take and then failed. - The widget chat bundle budget goes 40 -> 41 KB: 41,414 -> 41,614 bytes gzipped, the two new dictation problems a person can act on. The other seventeen wait for props the shared field gains in bitbaum/chatkit#85 (autoFocus, onKeyDown, onBlur/onFocus, name, inputProps). The stylesheet in this commit also carries the public-site rules of the next one. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * feat(public): say it on the first screen; a shorter homepage; a header that stays The way in - The homepage's one action is the shared composer. What a signed-out visitor says is kept in the tab (lib/first-words), shown back on sign-up and handed to the new-project form at the end of onboarding or sign-in. With a sentence carried, onboarding does not ask for a project name, a folder and a GitHub address first. The homepage - 10.66 -> 7.48 phone screens at 390x844, 6.6 -> 5.11 at 1440x900. - Three figures for the three steps, drawn in tokens (LoopFigure). - Three problems on the homepage, all twelve on /why. Where it runs is one sentence and two links. The closing block is the shared FinalCta. - One label for sign-up everywhere: Start a project. Header, menu, footer - The header was sticky in name only: .ui-public-surface was overflow: hidden, which made it the sticky container. overflow-x: clip. - The phone menu takes focus, keeps Tab inside and hands focus back. - The Product menu opens on a press, not on hover. - Navigation and Sign in show from 1120px (was 1280px). - A 2px focus ring, on the public surface and as the app-wide fallback. - A skip link. Four footer groups instead of five. Corners - An unknown address outside the app drew the framework's bare 404 with no way back; the in-app one said Back to Today and went to Loki; the error page printed the raw error; the loading placeholder drew cards on pages that are rows. The share image leads with the headline. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * fix(ux): dates render once; rows say the part that matters; a person's words - APP_LOCALE is a server variable, so a client component formatted dates in the default locale while the server used the configured one: a hydration error on /approvals with APP_LOCALE=de-CH. next.config.ts hands the same value to the browser as NEXT_PUBLIC_APP_LOCALE. - Home's running rows lead with the live step. A phone row holds about thirty characters and every row read 'Next best step · Editing src/app/pa…'. - The workbench's three rows on a phone were each cut before the words that say what the row is for. - Terminal without cloud access, Home's first-run row and the widget row use the person's words (computer, Loki button), not ours (runner, widget). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * docs(ux): the November UX pass, the public surface map, the changelog Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * feat(fields): the remaining text boxes get the microphone; chatkit 0.27 The second step of the fleet's experience standard for Loki. The shared field gained what a form's text area needs in bitbaum/chatkit#85 (0.27.0): autoFocus, onKeyDown, a submit key, a field-level blur, name, inputProps. Sixteen more files move onto <TextArea>; the experience audit goes bareTextareas 17 -> 1 and the ceiling in package-plan.json follows. Kept, file by file: Cmd/Ctrl+Enter saves where Cmd+Enter did (goal and person notes, project description, the idea step), Escape still cancels, Enter still sends an interview answer and confirms a queued prompt, notes still save when focus leaves the field, and an inline editor no longer closes when its microphone is pressed. The studio's forms still read their text by name from the native form. The scheduled job's prompt keeps the mono face and spell-check off. ProjectBriefFill's separate Speak button is the field's own microphone now (the same transcribe route). Left: control/prompt-input.tsx, a prompt box with its own attachments and paste-to-attach. It is a composer, not a form field. Checked: tsc, lint, the design gate, file inputs, 599 unit-test files; in a browser, autofocus, both submit keys, Escape, save on blur and not on the microphone, 44px microphone and 16px text at 390, and the chat and Home composers after the bump. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * test: a git fixture cannot reach the real repository from a hook in a linked worktree A hook run from a linked worktree exports an absolute GIT_DIR, which overrides git -C <sandbox>. dispatch-launch-dir.ts ran its fixture commands with that environment, so a pre-push from a second worktree wrote a test@test init commit onto the branch being pushed and set core.bare = true, a test identity and a hooks path of /dev/null in the real config. Nothing reached the remote; the repository was repaired by hand. worktree-workspace.ts already clears those variables for itself. The unit runner now clears them once for every test, and dispatch-launch-dir.ts does so for a direct run. Checked: with a bogus GIT_DIR inherited, the test passes and the real repository is untouched. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * docs(ux): the text boxes' second step, and what is left Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * chore(deps): chatkit 0.28.1, where a dictated take respects a field's maxLength bitbaum/chatkit#87, found while reviewing this branch's converted fields. 0.28 also draws a visible border on the composer while it has keyboard focus and stops thread-following from scrolling the page up. Checked on 0.28.1: the chat, Home and homepage boxes at 390px in both themes (text goes in, send enables, no sideways scroll, no console errors), tsc, lint, the design gate and the widget size test (41 KB budget holds). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmsyW2aAn78GgfRxyn5 * refactor(ux): the text boxes and the chatkit raise leave this pull request The staged rollout gate holds any pull request that raises a shared package until both chatkit canaries serve that exact version. On 2026-11-12 kivvi and causius served chatkit 0.25.0, the gate could not match kivvi's deployment receipt to its current commit, and this pull request raised Loki from 0.22.1 to 0.28.1, so it could not merge. Everything else in the pass needs no package change. This commit undoes the three text-box commits ( |
||
|
|
119a1025a8 |
fix(loki): "I have one" opens the projects an account already belongs to; import stays second (#1683)
QA's Viewer seat owns no project but is a member of qa-agent-walk. Home's
"I have one" opened the GitHub import ("No GitHub account linked yet")
instead of the project it already had.
The /loki seed counts projects shared with the account (listSharedProjects).
With none of its own and some shared, the start chips are New project,
"I have one" (opens /projects, which lists them) and "Import from GitHub".
An account with nothing shared keeps "I have one" as the import.
Test: scripts/test/i-have-one.ts.
|
||
|
|
cacac77ffa |
fix(terminal): say whose cloud builder is off, not "Cloud runner offline" while the fleet's runner is up (#1682)
QA's seat read "Cloud sessions are offline" (and "Cloud runner offline" at 1366) while the runner was up. Presence is read per account: the seat's own private builder was what was off, and the words read as the fleet's runner. - /api/builder/presence answers cloudScope: fleet (the account the box's runner works for), private (its own builder) or none. - /terminal's chip and empty state say "Your cloud builder offline" and that it is separate from the runner that builds Loki's own projects; an account with no cloud builder reads "You can't see this cloud runner". - An account not allowed on the cloud is gated, not offline, even before open-tabs answers. Test: scripts/test/terminal-whose-runner.ts. |
||
|
|
2dc59d1d83 |
fix(home): Home says why it is empty and how to get in, instead of loading forever (#1681)
QA's seat opened /control with a session that could not read Home: the /api/control read answered 401, `data` stayed null, and Home showed its skeleton cards for as long as the page was open. A failed read now shows what happened: a 401 or 403 says the browser is not signed in (or is the wrong account) with a Sign in link back to Home; anything else names the error with Try again. Test: scripts/test/home-load-failure.ts. |
||
|
|
033d3bbb0f |
fix(queue): an idle session does not hold its project's queue, and a queued task says what it waits on (#1680)
* fix(queue): an idle session does not hold its project's queue, and a queued task says what it waits on Grok Bot's dogfood, 12 Nov: two /api/inject prompts to orangecat (08:10 and 09:21 Zurich) sat Queued for over an hour behind "an earlier task" while that session had been idle since 06:17, and the 10:25 answer promised "starts in 5 minutes at the latest". - A beat under 512 bytes is not work (lib/run-progress isWorkingBeat): an idle session trickles 40-96 bytes a minute (#1676), which kept lastProgressAt fresh. A blocked beat still counts. - A delivered run with no working beat for 30 minutes, and not blocked on a question for a person, no longer holds its project's lane (runIdleSql in olderOpenRunSql: the claim gate, the blocker lookup and the reaper read the same definition), and the reaper no longer shelters it because its project's process is alive. Its close says it went quiet. A run that never beat keeps its lane: unknown is not idle. - A queued task names the run it waits behind, when it opened and when its agent last printed work, in Zurich time (inject answer: message and waitingOn; the run's track). The update hold's five-minute bound is not said for a task that waits behind an open run. Tests: scripts/test/idle-run-release.ts; lane-and-reaper gains two real Postgres scenarios (an idle run releases the lane and is closed; a working run and a run asking a person still hold it). * fix(queue): an idle run does not make its project busy either, as in the claim gate |
||
|
|
dcc912e487 |
fix(auth): an agent's token reads its projects, its account and its conversations (#1677)
A Viewer seat sending its ck_ token got 401 from /api/user-projects, /api/me and /api/projects/:id, and could not follow a conversation: the middleware let the Bearer through, but each GET asked for a browser session only. - GET /api/user-projects, /api/user-projects/:id, /api/me, /api/projects/:id resolve the caller with getApiUserId (cookie first, then the token). - The transcript stream takes a token too (getApiActor); a plain shell stays a signed-in person's (mayPeekTab), and the stream stays keyed by the caller. - Scope is the user's own: owned rows, or a project shared through a membership with its role. Writes that change the account or a project stay session-only. Tests: scripts/test/token-session-routes.ts (which handler takes a token, which does not); scripts/test/token-scope.ts in test:db (a seat's token reads its shared project read-only, never the owner's other one; expired and revoked tokens resolve to nobody). |
||
|
|
7ea443c528 |
fix(mcp): session links name their builder, and a dispatch hands back the link (#1673)
loki_sessions and loki_session_read built their links as a bare /terminal?project=, so a phone that last chose 'Your computer' opened the laptop's session of the same name instead of the cloud one (traced 2026-11-12; fixed for the HTTP routes in #1657). Both now use sessionOpenUrl, which names the cloud builder, and loki_dispatch passes on the openUrl inject-core returns, in its text and structured content. Claude-Session: https://claude.ai/code/session_019MDtmtCjm3CvrFm3kYaTgy Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
a1b009f26e |
feat(sessions): a token reads its sessions and what was said in them (#1661)
* feat(sessions): a token reads its sessions and what was said in them An agent that starts Claude Code in a Loki session (tab-inject) could read the screen (#1641) but not the conversation: the parsed transcript was only readable over the cookie-only transcript stream, and since #1644 over OrangeCat's signed rail. - lib/session-reads: the list, one run, or one project with the last things said in its conversation, moved out of the signed route unchanged, so two doors share one copy - GET /api/control/sessions: the same reads with a session or ck_ token (?project=, ?runId=, ?items=), no-store - every row names its session and carries openUrl, the same session in Loki's Terminal on that run (lib/dispatch-card sessionOpenUrl) - the list says it is cut at 25 and carries total, so a cut list is never read as the whole one - LOOP-WALK's Session walk names the read; tests pin both doors to the one lib Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtCjm3CvrFm3kYaTgy * fix(sessions): the conversation read is current, on the session's builder, and never ends a person's view Traced end to end before merge (2026-11-12): - a cached conversation was served forever: after the first read sent peek_stop the runner stopped streaming, so a later read returned the same copy without the agent's answer. The cache now counts only while someone is watching; otherwise the read waits for a frame posted after it asked. - peek_start and peek_stop carried no channel, so the owner's laptop runner could take a read meant for the cloud session (transcript null). They now name the project's builder (projectPreferredChannel). - the read counted its viewer under a key of its own, so its peek_stop could end a person's live view of the same session on a phone. It now shares the Terminal's viewer count (same user, tab and channel). - a cloud link carried no source, so a phone that last chose 'Your computer' opened the laptop's session of the same name. sessionOpenUrl names the cloud builder, and each row's link uses the session's builder. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtCjm3CvrFm3kYaTgy --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6d47eae8a5 |
feat(studio): the studio site can tell who is signed in (#1672)
bitbaum.orangecat.ch is static files with no accounts of its own; a person's account there is their Loki account. Until now its header could not know anybody, and a builder's only way back in was a Loki page that makes a new private link. - GET /api/studio-session answers the studio's origin, with the reader's own session cookie: a name, a handle, a picture, whether they run the studio, and their builder applications by status. No email, no account or application id, no access key. Signed out is an answer (200), with the addresses to sign in and out at. Public on the proxy's list because the proxy's own 401 carries no CORS headers. - GET /studio/return?to=/builders/ is the studio site's sign-in door: behind the proxy, so a signed-out visitor signs in first, then lands on that page of the studio site. The destination is a path on the studio's own origin and nothing else. - /sign-out?then=studio ends on the studio site (/studio/left, public). - One header shape for everything the studio site reads with a session (STUDIO_SESSION_HEADERS); /api/fleet/private uses it. scripts/test/studio-session.ts pins the answer's shape, what it must never carry, the return-path rule against open redirects, the headers, and which of the three routes the proxy guards. Claude-Session: https://claude.ai/code/session_019MDtmsSWTTpVpe4wh3v1sb Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6a05433fe0 |
fix(runs): one status, after the review of #1647: a closed run is over, a held command is Starting (#1671)
An adversarial review of #1647 (an open run's status comes from its track) found five regressions, all live: - A finished run whose command was never claimed (queued for an offline builder, then stopped or reaped) read Queued, not terminal; callers polled it forever. A run that is over now reads its outcome first. - No run event marks a runner's claim, so a command a runner held read Queued, or Needs you: no runner has picked it up. Both status routes now hand the track what the command row knows (the claim; for a prompt typed straight into a live session, that it was submitted), and a claimed, unanswered command is Starting, never below. - The chat card's offline-builder view, with its one-tap Run it in the cloud, was never reached once that status read Needs you. It is again. - A direct-mode run read Queued, then Needs you, with no runner involved. - The run sheet had no words for Starting and Needs you; a blocked agent read "an agent starts on it in a moment". scripts/test/one-run-status.ts, scripts/test/dispatch-card.ts. Claude-Session: https://claude.ai/code/session_019MDtmtHxn2FxY2x8pJ83Xj Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
510d8e2a14 |
fix(runs): whose pull request it is, after the review of #1643 (#1666)
* fix(runs): whose pull request it is, after the review of #1643 A review of the merged attribution change found the remaining ways a run could claim, or act on, a pull request that is not its own: - The fix ledger decided "this run's" by time alone, and on that basis could merge (auto-ship) or put back into draft a pull request somebody opened on another branch, when the handoff named it. auto-ship prOwnership: Loki acts only on a pull request on one of the run's own branches; it reports one as the run's when it is on them, or, for a runner too old to report branches, when the handoff names it. - Evidence recorded before #1643 was never checked again, so run 70d1a78d kept loki#1636. It is checked with GitHub once and removed when foreign; Watch no longer falls back to evidence the ledger called foreign, and other views do not trust unchecked old evidence. - The window had no end, so an earlier run sharing a branch with a later one claimed the later run's pull request. It ends 15 minutes after the run. - Only the ten newest pull requests were scanned; a busy repository pushed the run's own off the page. Pull requests are asked for by head branch. - Legal branch names with # or + were dropped. The rules are git's. - The runner also reports the remote branch a checkout pushes to, skips the repository's default branch whatever it is called, and its exit and shipped beats carry the branch. Runner 0.8.69. scripts/test/run-evidence-ownership.ts. Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtHxn2FxY2x8pJ83Xj * fix(runner): a run closes as shipped only with a pull request opened during it, and only then stops the agent The runner's idle check took any open or merged pull request on the branch the agent sat on. A session that carries on from an earlier run sits on that run's branch, so a read-only probe was closed Done with the earlier run's pull request, and the runner stopped the shared session whatever the server answered (also when the run had already been closed another way). - findShippedPr takes the run's start; a pull request opened before it is not this run's. - The server says closed: true when the beat closed the run; the runner stops the agent only then. Found by a review of the probe path (2026-11-12). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019MDtmtHxn2FxY2x8pJ83Xj --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
00ac95a8a1 |
fix(home): a Being built row that needs you says Needs you once, the question, and takes a reply (#1670)
On a phone the owner read "Waiting for you · Waiting for your answer" on a project's row: the state twice, and nowhere what answer was wanted. The row titled itself with the project, so the question that control-now put into the job's title was never drawn. - The state is the canonical word, CANONICAL_LABEL.needs_you, once — the same vocabulary canonicalStatus() gives every other surface. - Then the question in one line: the session's block reason, else the run's handoff block reason, the session's next, the run's next; never empty. A permission prompt shows what it asks (the run's blockedQuestion, now carried on /api/control and typed on the run payload), a sign-in wait says someone has to sign the agent in. - An agent idle at its prompt waiting for an answer gets a reply field under its row; Send goes to that project's agent through the same /api/inject as the box at the top of Home. A permission dialog or a sign-in is not a typed reply: those rows open the session, as before. Tests: control-now pins the word, the question's sources and when a reply is offered; home-being-built-browser checks the row at 390px in light and dark. |
||
|
|
7dd29e12df |
fix(one-off): a fresh session stays one-off: nothing of the shared session goes in, nothing of it comes back (#1665)
Found by a review of the merged fresh-session change (2026-11-12):
- A retry (automatic after a refusal, or from Watch) re-sent a one-off as an
ordinary message, into the shared session. It is retried as a one-off.
- /api/control closed the project's newest run from the SHARED session's
handoff without checking whether it was a lane run, so a one-off could be
closed with the shared session's summary, announced to its caller, and
left running. A lane run closes only from its own session file.
- A one-off's prompt carried the project's escalation note ("diagnose the
last failure") and, on the local runtime, the shared session's last
handoff and an instruction to update the shared session file.
- A one-off's close advanced or cleared the project's escalation ladder.
- On the local runtime the shared tab's prompt and handshake files were
written for a one-off, even when the request was then refused.
- OrangeCat's separateSession asked for a lane, which quietly queued in the
shared session when no lane was free. It is a fresh session now: a
session of its own, or a refusal with the reason.
scripts/test/one-off-stays.ts.
Claude-Session: https://claude.ai/code/session_019MDtmtHxn2FxY2x8pJ83Xj
Co-authored-by: Claude <noreply@anthropic.com>
|