mirror of
https://github.com/bitbaum/loki.git
synced 2026-12-04 08:47:02 +01:00
e52c65af80f19f4e36668d6c50a6061ba80dc8ed
2925
Commits
| Author | SHA1 | Message | Date | |
|---|---|---|---|---|
|
|
e52c65af80 |
feat(loki): suggested replies on every Loki chat — one tap sends the likely next message (#1115)
Adopts @bitbaum/chatkit 0.6.0 (bitbaum/chatkit#13, merged as 163c879). - askLoki/runLokiTurn take `replies`: the model is asked for chatkit's quick_replies block, and it is taken out of every model reply as it arrives (loop rounds, retries, gateway and Groq fallbacks), so it never reaches a work note, the grounding verifier, or the stored answer. Replies return separately as body.replies. - /loki: the messages route asks for replies and stores them in meta.replies; the thread shows them under the latest answer with chatkit's ChatReplies (the separate follow-ups call is now only the fallback for an answer that came without them). - Terminal Loki rail: ChatThread gets onReply; replies hidden under a summary that already carries its own "→" steps. - Floating assistant: /api/loki takes `replies`; buttons under the last answer. - The live preview is stripped once, in useLokiStream, for every surface; plainTextForSpeech drops the block so it is never read aloud. MCP, voice and prompt runs do not ask for replies, and a stray block is still removed from their text. Fixes found on the way: - Floating assistant printed answers as raw text (asterisks, bare [F1] handles): now rendered as markdown with resolved citations; multi-line user turns keep their line breaks. - /loki follow-up taps were sent on "Auto" instead of the model the operator last chose; the terminal rail's replies reuse its last choice. Claude-Session: https://claude.ai/code/session_01Mg5wrkfw95JWfmAz8yRT1j Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
07b1fdee80 |
feat(loki-chat): a site conversation arrives as context, one primary control, a thread keeps its project (#1114)
From the owner's phone on /loki (2026-10-09): "Continue in Loki" from the
widget pasted the whole site conversation into the composer as raw "Me: … /
Loki: …" text, the model chip read "A…" and the project "kes…", a white
Talk pill outshone the send arrow beside it, and an unexplained dot sat in
the row.
- Site hand-off (lib/loki/site-handoff.ts, use-site-handoff.ts,
SiteHandoffCard): ?q= in the widget's format is parsed into turns and
shown where a thread would be — your words a pill, Loki's prose, a
remark with its rule — above an EMPTY composer ("What should Loki do
with this?"). "Take it from here" sends it on in one tap; whatever is
typed is sent with the conversation attached once as a text file.
The chats list steps aside while it is shown.
- One primary control: with an empty box, Talk takes the send slot (the
same filled circle, a waveform) and the dead send arrow hides; typing
brings Send back.
- The builder-honesty chip became a dot on the project pill (its words in
the title); the pill's × is desktop-only (change scope by tapping it).
The model chip has room to say "Auto".
- A thread opened by its link (?c=, Back) keeps its project — it read
"No project — answers only" unless tapped in the list
(initialLokiSelection).
- Tests: loki-site-handoff (agrees with widget/continue.ts byte for
byte), loki-thread-scope. Seen on a local stack at 390×844.
Claude-Session: https://claude.ai/code/session_011L2dmcydDLYAiNQwK4XcF4
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
8757d532b6 |
feat(widget): fixes go as one change, watch sees what taps do, ◎ shows Loki (#1112)
The owner, on loki.orangecat.ch from a phone (2026-10-09): "if it proposes
five fixes and I click fix, where is it going? … how do I keep track?",
"I don't know when it's noticing something", "it should be easy to draw
its attention", and the panel still had a lot going on.
- Suggested changes are ONE decision (widget/suggestions.ts): every row
ticked, a tap unticks, "Build these 3 as one change →" files one note —
one agent, one PR, one row in Your changes. It used to be a Build per
row: N runs queued in the project's one lane with nothing saying so.
The owner's builds start without a confirmation card ("Edit first"
opens it); a visitor's still confirm.
- Your changes: one summary line that opens ("1 building · 1 in line ·
1 live"); each row is its own link. A change waiting behind another
reads "In line" (owner-view.ts), not "Starting".
- Watch sees what a tap DID: for 1.5 s after a tap on a button or link it
waits for the page to change, ask the server or navigate, notes which
("↳ It asked the server"), and says at once — after one tap, not three
— when nothing visibly happened.
- ◎ beside the launcher while watching: point at anything on the page,
the panel opens with it attached.
- Phone sheet (widget/sheet.ts): drag the top up for full screen, down to
peek at the page, further to put it away.
- Shorter greeting.
- Tests: widget-suggestions, widget-sheet, widget-changes (summary, In
line), widget-thoughts (results); watch-browser covers the tap results
and the one-change build. Unit 360/360; watch/embed/host-avoid browser
suites pass locally.
Claude-Session: https://claude.ai/code/session_011L2dmcydDLYAiNQwK4XcF4
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
c40abffc50 |
feat(voice): make no-screen mode pleasant to leave on — studio voice, music bed, earcons, talk-over (#1113)
A voice is a serial channel at ~150 words a minute, and an AI voice that talks too much is the fastest way to make someone take the headphones out. This round is the art and science of that channel: - Studio voice. /api/voice/speak reads short pieces through Groq's Orpheus endpoint (lib/voice/tts.ts); lib/voice/speaker.ts cuts a briefing at sentence ends (speak-chunks, ≤200 chars), fetches one piece ahead of the one playing, decodes into the soundscape, and hands the rest to the phone's own voice on any failure (then stops asking for two minutes). Six voices + "phone" in config/no-screen.ts. - Music the phone composes (hooks/use-soundscape.ts, numbers in lib/voice/soundscape.ts): six chords in D on detuned sine+triangle pairs through a drifting low-pass and a feedback delay, nothing above F#4, level 0.09 at rest and 0.025 under the voice. No file, no licence, no stream. - Earcons: rising for finished, falling for failed, a knock for something that needs you, a blip when a take is sent, low falling/rising for the line dropping and returning. Each under 0.6 s; a test pins that. - One output: the whole graph leaves through one MediaStream that the media-session <audio> plays, so lock-screen controls and screen-off playback follow the platform's rules for a track; direct output is the fallback (and the public demo's mode). Never both. - Talk-over: while Loki speaks the analyser keeps running; a burst above 2.5× the room's bar for 350 ms cancels the voice and hands over the mic. - Fewer, better sentences (lib/voice/announce.ts, pure, tested): coalesced by kind, urgency first, two or three phrasings rotated by a counter, "details" on request, and an "only what needs me" mode that holds finished runs for one sentence every five minutes. A dropped line is said once, and once when it is back. - Settings on the start screen, kept per device (voice, music, talk-over, mode). - /no-screen: a "Hear twenty seconds of it" demo on the visitor's own phone and a section on why it is pleasant. - Essays, anyone first: a ```deep fence renders as a closed <details> (components/thoughts/DeepBlock.tsx); the fleet-in-your-ear essay is rewritten that way, style guide updated. ROADMAP + CHANGELOG. Claude-Session: https://claude.ai/code/session_01YKx4TPejLvFR9Uj4xrTf6Y Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com> |
||
|
|
5bc05bbef4 |
feat: the first day is the whole product — three ways in, /build, your website in onboarding, Loki on it, help when a build stalls, and the owner's phone fixes (#1110)
* feat(widget): the owner's way into Loki — Continue in Loki, an advisor that knows whose site it is, a header that fits a phone On 2026-10-09 the owner of heidi.orangecat.ch opened the widget on their phone and asked for one new page. The widget treated them as a stranger: it told them which heading to insert and to "keep the structure in a data file (JSON/YAML)", wrote five invented sentences in the site's own language, and answered "switch to Loki so I can develop it there with either chat or terminal" with the same advice a third time. The owner's sign-in lived only behind "Watch". Once signed in, Review + Stop watching pushed ✕ off the right edge of the screen. - widget/continue.ts + src/lib/widget/continue.ts: the thread as one message (newest kept, ≤1800 chars) and where it lands in Loki. - GET /api/widget/continue: signs the person in if needed, checks getProjectAccess on the widget's project, resolves the project key and redirects into /loki?project=&q= or /terminal?project=&view=terminal; a stranger goes back to the site with #loki-owner-denied. - widget/conversation.ts: "Continue in Loki · Chat → · Terminal →" under the composer for the owner; one sign-in link for anyone else after their first message; "This is my site — sign in with Loki →" under Loki's greeting, on the first screen. The owner pass travels with each question. - /api/widget/advise + advisor.ts: the pass is verified as ingest verifies it; with it the advisor knows the person OWNS the site and Build this builds. For everyone, four hands-off rules: never explain how to edit the site, never write its content, a build request becomes the one change to tap, and "take this into Loki" is answered with where that control is. - widget/theme.ts: the header's text column shrinks before the actions do; Stop watching stays on one line; the continue row wraps on a phone. - widget/main.ts: the owner is not offered to hide their own tool. - scripts/test/widget-continue.ts (new), widget-advise.ts: pinned. - docs/architecture/feedback-widget.md: the row and the route. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * feat(widget): the loop closes on the site — Your changes, a live announcement, an honest Follow link "On it — Loki tells you when" was the end of the widget's story, and on the site Loki never told anyone: the telling went to push and Telegram, the page the owner came back to said nothing, and "Follow the build" toured the unchanged page with "let me show you what changed". - widget/changes.ts: "Your changes" above the thread for the owner — the project's recent changes with one word each (Building · On its way · Live · Needs you …), See it → once live, Open in Loki → when something needs them, asked for on arrival and every 30 s while something moves. A change this browser saw building that is now live is announced once: in the thread when the panel is open, beside the launcher (bubble + unread) when it is not. - POST /api/widget/owner/changes: the one read with the owner pass. Same attachFeedbackWork the inbox uses, then src/lib/feedback/owner-view.ts writes the owner's words; the work view never leaves the server. No valid pass → no rows. - /feedback/<id>/watch-fix lands on the inbox row while the change is still being built; the walkthrough only once it is live. - The owner's repeated note keeps its follow link. - widget/continue-row.ts, widget/greeting.ts: split out of createConversation (the lint rule caps it at 510 lines; CI caught it at 543). - scripts/test/widget-changes.ts (new); widget-continue.ts updated. - docs/architecture/feedback-widget.md. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * fix(widget): the owner's door is not an .act — the embed test counts those widget-embed-browser asserts exactly one "as written" link (.act) under the visitor's last message; the sign-in door under the greeting shared the class and made it two. Its own class, same look. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * feat(public): three ways in — build it yourself, with a partner, or let the studio — and every stranger's door ends at /build The ways to get something built were scattered: the landing page offered only "Start a project", hiring the studio was a word in the nav, the partner directory was reachable from OrangeCat's careers page and nowhere here, and a stranger who watched a fix land on someone else's site was sent to a bare homepage. "Start a project" at the bottom of six marketing pages went to sign-IN, and so did a stranger arriving with a brief. - src/config/build-paths.ts: the one list — yourself (sign-up), with a partner (bitbaum.orangecat.ch/partners/), the studio (the commission config's hire address) — plus buildPageHref/fromHost. - /build (public, allowlisted): the invitation, naming the site the person came from (validated host only) and the three doors (BuildPaths cards). - Landing: the "Three ways in" section after "Who it is for"; the closing line and FinalCta name the other two ways; FinalCta → sign-up. - /change and /take send a signed-out person to sign-up with the brief kept. - Widget: "Made with Loki — build something of your own →" as the last line for anyone who is not the owner (/build?from=<host>); the tour's "Get this for your site" lands on /build naming the site; the concierge gets the same door (appended last — the test addresses the others by index). - scripts/test/build-paths.ts pins all of it. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * fix(widget): /api/widget/continue is public — it signs the person in itself Live, the merged route answered a bare 401: the session middleware caught it before the route could send the person to sign-in. Same list entry as /api/widget/owner, pinned by widget-continue.ts. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * test(audit): /build is measured by the responsive audit A new page has to be a decision — measured, or excluded with a reason. Measured: it is a public page a stranger lands on from a phone. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * fix(widget): yours means yours, a review that picks three, the composer above the keyboard From the owner's phone on 2026-10-09: - "Your changes" listed a stranger's "so nice picture!" as the owner's own request. The strip now shows what the owner asked for and what Loki filed itself; visitors' notes are counted ("3 notes from visitors, in Loki →"). - Review answered with five nits (alt text, a renamed button, a table) and five identical buttons. The rubric now asks for at most three changes a visitor would notice or that fix something broken, and says none is fine. - With the keyboard open the box being typed into sat half behind it; it scrolls into view once the keyboard has settled. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * feat: the first day is the whole product — your website in onboarding, Loki on it, help doors when a build stalls, the terminal hand-off with its text, a launcher that stays in the corner From the owner's phone on 2026-10-09, and the three follow-ups named then: - Onboarding asks for the website (optional). A project created with one (`liveUrl` on POST /api/user-projects) gets its widget token at once, so the token's origin is the site's; the new step "Put Loki on your site" shows the one line to paste, lets an agent add it when there is a repo, and opens the site with the owner pass (`openSiteUrl` on the token route). Finishing lands on the project, not Control. A refused project no longer advances the step in silence. - A stalled build and a failed kickoff offer the other two ways to get it built — find a partner, hire the studio — from the same list as the landing page (GetHelpLine), the studio with the brief. - "Continue in Loki → Terminal" carries the thread: /terminal?q= prefills the rail's composer as an unsent draft, and opens the rail sheet on a phone (the same path ?explain=1 takes). - The launcher stays in the corner: a near slot over plain text beats a free slot mid-page (heidi.orangecat.ch: the site's own bar took one corner and the launcher floated beside a heading). A near sheet still sends it climbing. - Page checks: a small-caps label by design is not a defect, 11.84px is not under 12, and one kind of finding is one card (the signature drops counts and examples; "30 pieces" then "6 pieces" were two cards). Tests: onboarding-site-step.ts (new), widget-placement.ts, widget-watch.ts, widget-continue.ts, build-paths.ts; all widget browser suites pass locally. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * refactor(widget): keepInViewOnFocus lives in dom.ts — createConversation back under the 510-line cap after the merge Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * fix(widget): import keepInViewOnFocus — the panel threw at mount and boot swallowed it An unimported identifier compiles fine with esbuild and fails at run time; boot's catch hid it, so the launcher rendered and the panel never opened. Caught by widget-embed-browser. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
be5752994c |
feat(widget): one integrated panel — watch says what it sees, in Loki's own spiral (#1111)
* feat(widget): watch says what it sees, in Loki's own spiral
From the owner's phone on heidi.orangecat.ch (2026-10-09): "It's not clear
what it thinks when it watches", and the logo is barely used.
- What Loki sees: one row under the panel header ("Watching · 2 pages,
1 tap · nothing wrong so far") that opens into the trail worded as notes
— pages opened, taps, what the page sent, what it noticed. Each settled
page now records a `look` step even when clean, so "looked, all fine"
is visible instead of silent. widget/thoughts.ts (pure) +
thoughts-view.ts.
- The status light is the logo's spiral, generated from
src/config/brand-mark.ts into widget/brand-mark.generated.ts (the widget
may not import src/). It turns slowly while watching, spins while Loki
thinks (header and the pending answer), and goes still and grey when
paused — in the launcher, the panel header and the walkthrough card.
- Loki's answers render paragraphs, bullets, headings and bold
(widget/rich-text.ts) from text nodes — "* The headline …" no longer
shows its asterisks.
- Tests: widget-thoughts, widget-rich-text, widget-brand-mark (drift);
watch/embed/host-avoid browser suites pass locally.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011L2dmcydDLYAiNQwK4XcF4
* feat(widget): one surface, not a stack of boxes and buttons
"No Frankenstein elements. Integrated experience. Not a bunch of big
unaligned buttons" (owner, 2026-10-09). The panel had grown one bordered
control at a time; this is a layout pass over all of it, with one rule:
at most one filled accent button per region, every other action is
quiet text aligned in its row.
- Header: who and where, and ✕. Review and Stop watching are gone from
it — Review is the conversation's first suggestion, and watching is
shown AND paused from the notes row (Pause / Resume), status and its
control together. A visitor keeps one quiet "Watch".
- Notes and Your changes are hairline strips, not nested cards.
- Thread: Loki's words are prose on the panel; yours are a pill.
Noticed/sent remarks carry a left rule instead of a box.
- Suggested changes: a hairline list, "Build this →" as accent text at
each row's end (was five filled buttons down the right edge). "Fix
this →" and "Why does it matter?" sit on one baseline.
- Composer: ONE card — About tabs (underlined when chosen), the words,
screenshots, then tools left and Build it / Ask Loki right, compact.
- Starters and links share one pill style; buttons are compact; the
ghost button has no frame.
- Tests follow the moved controls (watch-browser: Review via the
starter, Pause/Resume via the notes row; theme test checks the new
rules). watch/embed/host-avoid browser suites pass locally.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_011L2dmcydDLYAiNQwK4XcF4
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
d5c6153b5c |
feat(voice): no-screen mode — run the fleet by ear (#1109)
One tap at /voice opens the microphone and reads the briefing; from then on the loop is listen → transcribe → act → speak → listen, with the phone in a pocket. Twelve spoken commands (status, what's waiting, approve/reject by number, tell <project> to …, what failed, pause/resume, say that again, quiet, help, end) go through the seams the screen already uses — decideAction, injectPrompt, fleet-pause, askLoki — so the page and the headphones cannot disagree. Between turns the phone polls /api/voice/snapshot every 20 s and announces the diff: a run finished or failed, a new approval, the builder offline or back, a project starting work. Bounded to five per poll. - config/no-screen.ts: the vocabulary SSOT, read by the parser, the spoken help and the public page; the test feeds every example phrase through the parser. - lib/voice/commands.ts: an explicit grammar (pure, 35 checks). A bare "yes" is not an approval, a bare "stop" is "be quiet", a sentence naming no project is a question. - lib/voice/briefing.ts: the fleet as sentences, and the snapshot diff (pure, 12 checks). lib/voice/fleet-snapshot.ts reads the same tables as Control; approvals ride only with the private zone open. - hooks/use-voice-conversation.ts: say() for unasked lines (now while listening, queued while busy, held for one listen after an interruption) and idle: "listen" so silence re-arms instead of pausing. The Loki page's Talk button is unchanged. - hooks/use-media-session.ts: a generated silent loop holds the media session so the headphone button is the orb tap; next = briefing. - lib/fleet-pause.ts: resumeFleetProjects, the mirror of pause. - /no-screen public page (nav, matcher, audit lists, copy-truth), the sidebar entry under Command, the demo-sandbox classification. - content/thoughts/the-fleet-in-your-ear.md with a committed SVG, a sequence diagram and the seam table; ROADMAP + CHANGELOG entries. Not yet verified on a locked iPhone in a pocket; the page, the essay and the roadmap say so. Claude-Session: https://claude.ai/code/session_01YKx4TPejLvFR9Uj4xrTf6Y Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com> |
||
|
|
6af0b11f5f |
fix(control,loki): an agent waiting on you says so, and Loki stops answering in fragments (#1108)
From a phone session on Skif (2026-10-09), where every surface told a
different story about one idle agent:
- Control: a live session whose agent wrote `status: blocked /
awaiting_user` fell through to "Agent idle" and was counted idle, so
the hero read "0 awaiting input". New `awaiting_you` state ("Waiting
for you"), counted as awaiting input, selected first.
- Terminal sheet: the same session read "Agent went quiet · Open
Terminal — or Retry". When the agent's own handoff (written during
this run) says it is blocked on you, the sheet now says "Your turn",
shows its `next:` line, and drops Retry.
- Loki answers ended mid-clause (~230 chars each): llm.ts reported
`cutOff` from finish_reason and the loop ignored it. A cut-off answer
now gets one retry with a larger budget; if it is still cut off, it
says so.
- Citations: the sheet dropped answer sources, so each [F1] vanished and
left "pickup ." — sources now travel with the message.
- The sheet shows "12s · Running list projects" instead of a bare
"Working on it".
- Hero copy pointed to a "Needs you" panel "below"; the queue is "To
review", above.
- Project rows: bulk checkboxes only after "Select"; the bare "On" chip
reads "Autopilot".
Claude-Session: https://claude.ai/code/session_011L2dmcydDLYAiNQwK4XcF4
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
6c6380efb7 |
feat(widget): the owner's way into Loki — Continue in Loki, an advisor that knows whose site it is, a header that fits a phone (#1107)
* feat(widget): the owner's way into Loki — Continue in Loki, an advisor that knows whose site it is, a header that fits a phone On 2026-10-09 the owner of heidi.orangecat.ch opened the widget on their phone and asked for one new page. The widget treated them as a stranger: it told them which heading to insert and to "keep the structure in a data file (JSON/YAML)", wrote five invented sentences in the site's own language, and answered "switch to Loki so I can develop it there with either chat or terminal" with the same advice a third time. The owner's sign-in lived only behind "Watch". Once signed in, Review + Stop watching pushed ✕ off the right edge of the screen. - widget/continue.ts + src/lib/widget/continue.ts: the thread as one message (newest kept, ≤1800 chars) and where it lands in Loki. - GET /api/widget/continue: signs the person in if needed, checks getProjectAccess on the widget's project, resolves the project key and redirects into /loki?project=&q= or /terminal?project=&view=terminal; a stranger goes back to the site with #loki-owner-denied. - widget/conversation.ts: "Continue in Loki · Chat → · Terminal →" under the composer for the owner; one sign-in link for anyone else after their first message; "This is my site — sign in with Loki →" under Loki's greeting, on the first screen. The owner pass travels with each question. - /api/widget/advise + advisor.ts: the pass is verified as ingest verifies it; with it the advisor knows the person OWNS the site and Build this builds. For everyone, four hands-off rules: never explain how to edit the site, never write its content, a build request becomes the one change to tap, and "take this into Loki" is answered with where that control is. - widget/theme.ts: the header's text column shrinks before the actions do; Stop watching stays on one line; the continue row wraps on a phone. - widget/main.ts: the owner is not offered to hide their own tool. - scripts/test/widget-continue.ts (new), widget-advise.ts: pinned. - docs/architecture/feedback-widget.md: the row and the route. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * feat(widget): the loop closes on the site — Your changes, a live announcement, an honest Follow link "On it — Loki tells you when" was the end of the widget's story, and on the site Loki never told anyone: the telling went to push and Telegram, the page the owner came back to said nothing, and "Follow the build" toured the unchanged page with "let me show you what changed". - widget/changes.ts: "Your changes" above the thread for the owner — the project's recent changes with one word each (Building · On its way · Live · Needs you …), See it → once live, Open in Loki → when something needs them, asked for on arrival and every 30 s while something moves. A change this browser saw building that is now live is announced once: in the thread when the panel is open, beside the launcher (bubble + unread) when it is not. - POST /api/widget/owner/changes: the one read with the owner pass. Same attachFeedbackWork the inbox uses, then src/lib/feedback/owner-view.ts writes the owner's words; the work view never leaves the server. No valid pass → no rows. - /feedback/<id>/watch-fix lands on the inbox row while the change is still being built; the walkthrough only once it is live. - The owner's repeated note keeps its follow link. - widget/continue-row.ts, widget/greeting.ts: split out of createConversation (the lint rule caps it at 510 lines; CI caught it at 543). - scripts/test/widget-changes.ts (new); widget-continue.ts updated. - docs/architecture/feedback-widget.md. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z * fix(widget): the owner's door is not an .act — the embed test counts those widget-embed-browser asserts exactly one "as written" link (.act) under the visitor's last message; the sign-in door under the greeting shared the class and made it two. Its own class, same look. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01N1Yw4cCwXWRP2S5Hj62u2Z --------- Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
17e63d1396 |
feat(widget): one designed piece — the launcher is the status, Loki stops crying wolf, the panel fits (#1106)
Found by using the live widget on loki.orangecat.ch as owner, not by tests: - The composer overflowed in every real browser: with a mic present, Record + Screenshots + Send as feedback pushed Ask Loki out of the 372px panel (the test browser has no mic, so nothing caught it). Tools are icons at rest, the row wraps; widget-embed-browser now fakes a mic and fails at 1200/390/320 if the panel scrolls sideways or any button sits outside it (proven against the #1099 CSS: 6 failures). - The top bar covered the site's own navigation. For the owner the LAUNCHER is now the status: "Loki · watching", an unread count of what Loki said while the panel was closed, the newest remark in a bubble beside it. The bar is the fallback, shown only when neither launcher nor panel can be seen. - Loki cried wolf on Loki's own page: "15 links have no name" (innerText is "" under content-visibility:auto, and ?? never fell back) and "25 tap targets too small" (WCAG 2.5.8's spacing exception ignored). Now 0 and 1 (a really crowded 154x16 link); examples name a link's address instead of "a". Pinned by fixtures that fail with the old code. - A remark arriving mid-tap moved the button away (it happened live): the thread follows new messages only if you were at the bottom or acted yourself; opening the panel lands on the newest message. - "On it" was a dead end: owner builds now return followUrl (Loki's Watch the fix page for that item) and the receipt says "Follow the build →". widget/README.md now opens with the design model and the rules that resolve its trade-offs. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
8b3e635ddb |
feat(alerts): page once when a service is stuck repeating the same error (#1105)
Every host check asked "is X down?"; none asked "is X stuck doing the same failing thing?" — and a stuck loop looks healthy to all of them. loki-calendar-drain retried one unbookable event every 15 s from 2026-09-21 to 2026-10-08 (38,851 failures, a free-tier model call on each) and nothing said a word. host-check.sh now groups the last hour's error-shaped journal lines by unit + digit-folded text; >= 120 repeats is a loop. One message per unit (alert_once backoff, daily), N loops in a tick = one digest. Heartbeats don't count. Dry-run on the box's real journal: catches the calendar loop in 23 of 24 hours, one other hit (orangecat-2-app), no noise. 6 new tests; the suite's journalctl stub now serves -o json. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
b83353bd66 |
chore(preview): log which model wrote an unreadable preview answer (#1104)
The first live 'Show me' on a 120-item page returned nothing usable twice, while the same prompt sent straight to Gemini parsed. The owner only sees "couldn't show that"; the log now names the link that answered and the start of what it wrote. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
54364444d7 |
fix(monitor): a dead API key pages within the hour — and a muted link can page again (#1103)
orangecat's GROQ_API_KEY was revoked for days (2026-10-08): voice input failed, the Cat's chat quietly answered from other vendors, and nothing paged. Why the existing watch missed it: ai-provider-check.sh set a failing link 'bad' and never 'ok', and alert_transition pages only on a flip — so groq/openai/gpt-oss-20b, bad since 2026-09-14 (rate limits), was muted for good when the key died. Links below the threshold in a readable window now recover (an unreadable journal still recovers nothing), and a 401/403 is reported as 'API KEY REJECTED' with what to do, not a bare count. New api-key-check.sh asks the vendors directly, hourly, with no traffic and no tokens: every DISTINCT key in every app's env file — /opt/*/shared/.env AND /opt/*/app/.env, the layout orangecat uses and a shared/-only rollout missed. 401/403 = dead (page once, naming the apps and a working key of the vendor); anything else = no verdict. OpenRouter is asked on /key (its /models says 200 for a dead key). Keys are fingerprinted, never printed or put in a URL. Its first real run found a SECOND dead key (evig), since replaced. Tests: 26 + 18, both mutation-proved; wired into test:ops. Alerts documented. Claude-Session: https://claude.ai/code/session_01Nx1u7uUWsgi3MagxbmQmPN Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com> |
||
|
|
6f63fd2516 |
fix(calendar): a booking that keeps failing stops and says so (#1102)
One approved event had its date only in the action's description. The date rescue never read the description, and a failed booking went straight back into a queue the drain polls every 15 s: 38,851 failures between 2026-09-21 and 2026-10-08, a model call on every pass against the shared free tier, and no word to the operator that it was never booked. - The rescue now receives the row's description (drain + in-process executor), so a date written there books. - After MAX_BOOKING_ATTEMPTS (3) failures the row goes approved -> expired and the operator gets ONE Telegram "⚠️ Not booked" with the details and the reason (registered in telegram-notifications.md). - scripts/test/booking-attempts.ts pins both halves (mutation-checked). Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
fa8dbfe140 |
fix(terminal): tab layout and names survive reload; rename keeps spaces; launcher closes on its card (#1101)
Found by driving the live page in a browser after #1093: - useLocalStorageState hydrated once but kept writing the CURRENT value to the CURRENT key. The terminal keys tab layout and names per builder and first renders as "cloud" before the saved source resolves to "local", so every load reset loki:terminal-tab-layout:local and copied the cloud alias under the local key. Persisting is now allowed only for a key whose own stored value has been read, and hydration re-runs when the key changes (canPersist/readStored, tested, mutation-checked). - Renaming a tab swallowed spaces ("main loki" -> "mainloki"): a key typed into the rename input bubbled to the tab's own Space-to-select handler. Only the tab itself handles it now. - Leaving the rename box untouched stored the (capped) label as a permanent alias. - The "Start an agent" panel's Cancel floated detached to the right of its card; the close control now sits on the card. Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
61c240ea24 |
feat(watch): Share in the walkthrough's header from the first beat (#1100)
Operator, 2026-10-08: watched all fourteen beats, saw no way to send them, copied the address bar (the plain page — the tour token leaves it on start) and asked how sharing could work at all. Share was only on the last card. It now sits in the header for the whole walkthrough; where the clipboard is refused the link appears, selected, under the header (once). Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
1d2523625c |
feat(widget): feedback back in front; Loki speaks up when something is wrong; Stop watching is one tap (#1099)
After #1092 feedback was hidden (Send to builder only appeared after asking Loki), the page / whole site / element choice had become a toggle chip, stopping Watch was only "Pause" on the top bar, and Loki only counted what it saw. - About: This page / Whole site / An element is one segmented control again, and the composer has Send as feedback (straight to the confirmation, no AI) beside Ask Loki. - Watch speaks up: every notice (failed request, slow answer, the site's console error, slow load, a freeze after a tap, content jumping), every automatic fix, and the page checks after each page settles become a "Loki noticed" message in the conversation, in plain words naming the tap that led there, with Fix this (the request written out) and Why does it matter (asks the advisor with the session). Rule-based (explainNotice / explainChecks) - no background model call - and said once per visit. - The bar says what Loki noticed, with Show (open the conversation) and Stop watching / Watch again; the header has Review + Stop watching, or Watch again. Stopped, nothing is recorded and nothing is said. Tests: widget-watch 12 cases (explainers), widget-thread (noticed restore), widget-watch-browser 50/50 (remark in words + Fix this, no repeat after reload, header Stop watching records and says nothing - fails with the guard removed), widget-embed-browser 47/47 (element feedback straight to the builder, no AI call). Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
3f12af42e1 |
fix(feedback): /feedback 500ed whenever a run was queued behind another (#1098)
findQueueBlockers reads a raw db.execute row, which is not run through the schema: started_at comes back as a string, but was typed Date, and applyRunContext called .toISOString() on it. Every inbox load with a queued-behind run threw (479 times since 12:54 UTC). Coerce at the query, and type the raw column honestly. The two other raw Date columns (robots.updated_at, people.last_interaction) already coerce. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
6e7d534ced |
chore(deps): bump the minor-and-patch group across 1 directory with 19 updates (#1084)
Bumps the minor-and-patch group with 19 updates in the / directory: | Package | From | To | | --- | --- | --- | | [@bitbaum/ai-kit](https://github.com/bitbaum/ai-kit) | `1.18.0` | `1.20.1` | | [drizzle-orm](https://github.com/drizzle-team/drizzle-orm) | `0.45.2` | `0.45.3` | | [lucide-react](https://github.com/lucide-icons/lucide/tree/HEAD/packages/lucide-react) | `1.41.0` | `1.52.0` | | [react](https://github.com/react/react/tree/HEAD/packages/react) | `19.2.8` | `19.3.0` | | [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) | `19.2.18` | `19.3.0` | | [react-dom](https://github.com/react/react/tree/HEAD/packages/react-dom) | `19.2.8` | `19.3.0` | | [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) | `19.2.7` | `19.3.0` | | [shadcn](https://github.com/shadcn-ui/ui/tree/HEAD/packages/shadcn) | `4.21.0` | `4.21.2` | | [shiki](https://github.com/shikijs/shiki/tree/HEAD/packages/shiki) | `4.4.3` | `4.5.0` | | [tailwind-merge](https://github.com/dcastil/tailwind-merge/tree/HEAD/packages/tailwind-merge) | `3.6.0` | `3.7.0` | | [ws](https://github.com/websockets/ws) | `8.21.3` | `8.22.0` | | [@types/ws](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/ws) | `8.18.1` | `8.18.2` | | [zod](https://github.com/colinhacks/zod) | `4.5.4` | `4.6.5` | | [@types/node](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/node) | `26.4.1` | `26.6.4` | | [@types/react](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react) | `19.2.18` | `19.3.0` | | [@types/react-dom](https://github.com/DefinitelyTyped/DefinitelyTyped/tree/HEAD/types/react-dom) | `19.2.7` | `19.3.0` | | [drizzle-kit](https://github.com/drizzle-team/drizzle-orm) | `0.31.10` | `0.31.11` | | [eslint](https://github.com/eslint/eslint) | `10.10.0` | `10.12.0` | | [prettier](https://github.com/prettier/prettier) | `3.9.6` | `3.9.9` | | [tsx](https://github.com/privatenumber/tsx) | `4.23.13` | `4.23.15` | | [pg](https://github.com/brianc/node-postgres/tree/HEAD/packages/pg) | `8.23.0` | `8.23.1` | Updates `@bitbaum/ai-kit` from 1.18.0 to 1.20.1 - [Commits](https://github.com/bitbaum/ai-kit/compare/v1.18.0...v1.20.1) Updates `drizzle-orm` from 0.45.2 to 0.45.3 - [Release notes](https://github.com/drizzle-team/drizzle-orm/releases) - [Commits](https://github.com/drizzle-team/drizzle-orm/compare/0.45.2...0.45.3) Updates `lucide-react` from 1.41.0 to 1.52.0 - [Release notes](https://github.com/lucide-icons/lucide/releases) - [Commits](https://github.com/lucide-icons/lucide/commits/1.52.0/packages/lucide-react) Updates `react` from 19.2.8 to 19.3.0 - [Release notes](https://github.com/react/react/releases) - [Changelog](https://github.com/react/react/blob/main/CHANGELOG.md) - [Commits](https://github.com/react/react/commits/v19.3.0/packages/react) Updates `@types/react` from 19.2.18 to 19.3.0 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react) Updates `react-dom` from 19.2.8 to 19.3.0 - [Release notes](https://github.com/react/react/releases) - [Changelog](https://github.com/react/react/blob/main/CHANGELOG.md) - [Commits](https://github.com/react/react/commits/v19.3.0/packages/react-dom) Updates `@types/react-dom` from 19.2.7 to 19.3.0 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom) Updates `shadcn` from 4.21.0 to 4.21.2 - [Release notes](https://github.com/shadcn-ui/ui/releases) - [Changelog](https://github.com/shadcn-ui/ui/blob/main/packages/shadcn/CHANGELOG.md) - [Commits](https://github.com/shadcn-ui/ui/commits/shadcn@4.21.2/packages/shadcn) Updates `shiki` from 4.4.3 to 4.5.0 - [Release notes](https://github.com/shikijs/shiki/releases) - [Commits](https://github.com/shikijs/shiki/commits/v4.5.0/packages/shiki) Updates `tailwind-merge` from 3.6.0 to 3.7.0 - [Release notes](https://github.com/dcastil/tailwind-merge/releases) - [Commits](https://github.com/dcastil/tailwind-merge/commits/tailwind-merge@3.7.0/packages/tailwind-merge) Updates `ws` from 8.21.3 to 8.22.0 - [Release notes](https://github.com/websockets/ws/releases) - [Commits](https://github.com/websockets/ws/compare/8.21.3...8.22.0) Updates `@types/ws` from 8.18.1 to 8.18.2 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/ws) Updates `zod` from 4.5.4 to 4.6.5 - [Release notes](https://github.com/colinhacks/zod/releases) - [Commits](https://github.com/colinhacks/zod/compare/v4.5.4...v4.6.5) Updates `@types/node` from 26.4.1 to 26.6.4 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/node) Updates `@types/react` from 19.2.18 to 19.3.0 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react) Updates `@types/react-dom` from 19.2.7 to 19.3.0 - [Release notes](https://github.com/DefinitelyTyped/DefinitelyTyped/releases) - [Commits](https://github.com/DefinitelyTyped/DefinitelyTyped/commits/HEAD/types/react-dom) Updates `drizzle-kit` from 0.31.10 to 0.31.11 - [Release notes](https://github.com/drizzle-team/drizzle-orm/releases) - [Commits](https://github.com/drizzle-team/drizzle-orm/compare/drizzle-kit@0.31.10...drizzle-kit@0.31.11) Updates `eslint` from 10.10.0 to 10.12.0 - [Release notes](https://github.com/eslint/eslint/releases) - [Commits](https://github.com/eslint/eslint/compare/v10.10.0...v10.12.0) Updates `prettier` from 3.9.6 to 3.9.9 - [Release notes](https://github.com/prettier/prettier/releases) - [Changelog](https://github.com/prettier/prettier/blob/main/CHANGELOG.md) - [Commits](https://github.com/prettier/prettier/compare/3.9.6...3.9.9) Updates `tsx` from 4.23.13 to 4.23.15 - [Release notes](https://github.com/privatenumber/tsx/releases) - [Changelog](https://github.com/privatenumber/tsx/blob/master/release.config.cjs) - [Commits](https://github.com/privatenumber/tsx/compare/v4.23.13...v4.23.15) Updates `pg` from 8.23.0 to 8.23.1 - [Changelog](https://github.com/brianc/node-postgres/blob/master/CHANGELOG.md) - [Commits](https://github.com/brianc/node-postgres/commits/pg@8.23.1/packages/pg) --- updated-dependencies: - dependency-name: "@bitbaum/ai-kit" dependency-version: 1.20.1 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: "@types/node" dependency-version: 26.6.4 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: "@types/react" dependency-version: 19.3.0 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: "@types/react" dependency-version: 19.3.0 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: "@types/react-dom" dependency-version: 19.3.0 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: "@types/react-dom" dependency-version: 19.3.0 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: "@types/ws" dependency-version: 8.18.2 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: drizzle-kit dependency-version: 0.31.11 dependency-type: direct:development update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: drizzle-orm dependency-version: 0.45.3 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: eslint dependency-version: 10.12.0 dependency-type: direct:development update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: lucide-react dependency-version: 1.52.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: pg dependency-version: 8.23.1 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: prettier dependency-version: 3.9.9 dependency-type: direct:development update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: react dependency-version: 19.3.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: react-dom dependency-version: 19.3.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: shadcn dependency-version: 4.21.1 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: shiki dependency-version: 4.5.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: tailwind-merge dependency-version: 3.7.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: tsx dependency-version: 4.23.15 dependency-type: direct:development update-type: version-update:semver-patch dependency-group: minor-and-patch - dependency-name: ws dependency-version: 8.22.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch - dependency-name: zod dependency-version: 4.6.5 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: minor-and-patch ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
a61c3eaf59 |
chore(deps): whenkit 0.3.2 — the date box matches a native input's height (#1097)
Loki's dense ui-input-tight fields stay the same height as their neighbours, and the box keeps its layout if an app class sets display:block on it. Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
a6d03a6712 |
fix(preview): ask for the owner's language beside the owner's words (#1096)
The system-prompt rule (#1095) still lost to an all-Italian outline on farmaciadelparco. The instruction now closes the prompt, quoting the owner's request so the model can see which language it is. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
375af60b56 |
fix(widget): "This is my site" signs a signed-out owner in and brings them back (#1094)
Shipped in #1092 and found on the live probe: a signed-out owner got a bare 401 (the proxy gates /api/*), and even past it the route sent redirect_url while sign-in reads callbackUrl, so they would have landed on Loki's home page instead of their site. The route is now on the proxy's public list (it requires a session itself before minting anything) and uses sign-in's own parameter. owner-note-builds pins both; it fails against the #1092 route. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
c36ca8429b |
fix(preview): the summary speaks the owner's language, the page keeps its own (#1095)
Live on farmaciadelparco the preview card said 'Aggiunto un riquadro verde…' to an owner who asked in English: the prompt's 'write new text in the page's language' covered the summary too. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
8ca728a649 |
feat(studio): the private link comes back — mailed at intake, on a later address, and on request (#1091)
* feat(studio): the private link comes back — mailed at intake, on a later address, and on request A studio request's only credential is its private link; a closed tab was a lost request. Now the link is mailed to the address given at intake, or added later through a `set_contact` guest action; and `/api/studio-recover` hands the address fresh links to every open request under it (the old links die), answering identically whether or not the address is known. Keys are never stored or logged — email.ts records recipient and subject. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> * fix(demo): classify /api/studio-recover for the demo sandbox; the rotation rejects a demo owner Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> --------- Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com> |
||
|
|
a25cba7451 |
feat(terminal): drag, pin and group tabs; readable names; the miss screen stops repeating the strip (#1093)
Tabs can be arranged: drag one onto another, or Alt+Shift+Left/Right; a pin sends a tab to the front; "Group by project" keeps one project's lanes together with a divider between groups. The arrangement is a view preference kept per builder in the browser; the runner still owns which sessions exist. Names read as names: the 32-hex run suffix some dispatches append no longer hides the part that tells tabs apart (the full name stays in the tooltip), long names truncate, and parallel lanes carry a short run id so two of them differ. The "No session named X" screen listed every running session a second time under the tab strip it sat beneath, with raw ids and a paragraph of explanation. The strip is the one place to choose; the screen now says what is true in one line and offers the two things to do. Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
6bf344efb6 |
feat(watch): "Not quite" and "Show me" on the walkthrough; done fixes keep Watch + Share (#1090)
* feat(watch): "Not quite" and "Show me" on the walkthrough; done fixes keep Watch + Share Operator, 2026-10-08: "do 1 and 2" — say a fix is not quite right from the walkthrough itself, and see an idea on the live page before it is built. - Not quite (owner + reporter, never a shared link): typed or spoken (the widget's mic), filed as a follow-up on the same page. The owner's starts the fix at once via startOwnerBuild, now shared with Report's owner-pass path (lib/feedback/owner-build.ts); the reporter's goes to the inbox. - Show me: /api/widget/preview turns the words into a few edits from a closed vocabulary (style, text, hide, insert, css) against the page outline; widget/preview.ts sanitizes them (tag/attribute allow-list, no url()/@import/expression, no handlers or javascript: links), applies them in the owner's browser only and undoes them exactly. "Build this" sends the words plus what the preview showed. Charged to the owner's AI budget, rate-limited, never available to a viewer ticket. - Done fixes keep "Watch the fix" + Share on the row; the last card gets "Copy page link" for sharing the site without a walkthrough. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test(owner-build): read the shared owner-build module, and pin that 'Not quite' uses it Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
6be6045295 |
feat(widget): one conversation with Loki; Watch in the header (#1092)
* feat(widget): one conversation with Loki; Watch is in the header for anyone who owns the site The panel was three tools sharing a box: Request a change (a form), Ask Loki (an advisor) and Chat, behind tabs and scope chips, each with a history that vanished on close - and Watch could only be switched on by arriving through one link on the project page in Loki, so an owner simply visiting their site never saw it. Now: - One thread (widget/conversation.ts). Type, speak, paste a screenshot or point at an element; Loki answers about this page (one tap: whole site). Every suggested change, and your own message as written, has Send to builder / Build this, which opens a confirmation card in the thread; the receipt (building / track link) lands in the thread. - The thread is kept per tab (widget/thread.ts, validated on restore), so it survives the site's own page loads. - Watch in the header: Review for the owner; for anyone else an explainer with "This is my site - sign in with Loki", via GET /api/widget/owner, which checks ownership of the widget's project and returns to the same page with a pass. The return URL must be on the project's own site (ownerReturnUrl), so the route cannot hand a pass to someone else's page; a non-owner lands back with a plain explanation. - data-fc-modes now only picks who answers: advisor (default), the studio concierge (chat), or none (report). The owner always gets the advisor. - widget/loki-api.ts holds the two calls; advise.ts and chat.ts are gone. Tests: widget-thread (new), owner-note-builds (return-URL guard), widget-embed-browser 41/41, widget-watch-browser 40/40, widget-host-avoid-browser 24/24. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * test(widget): style guard follows the panel's real controls; comment no longer reads as an import Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
656f643b4e |
chore(hetzner): drop surf-your-life embed-backfill timer (#1089)
It needs a paid OPENAI_API_KEY the box does not have, answered 503 every night and paged as a failed unit. Background AI spend is off fleet-wide (the ai-digest row above was dropped for the same reason). Already disabled on the box; this stops a reinstall from bringing it back. Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
f6b9dd701f |
fix(hetzner): a sleeping app naps cleanly; ivy-health checks what Loki runs (#1087)
* fix(hetzner): a sleeping app naps cleanly; ivy-health checks what Loki runs Sleep-when-idle stops the app with SIGTERM when its proxy idles out, and Node exits 143. Without SuccessExitStatus systemd recorded that as Result=exit-code, so every nap read as `failed` and paged Telegram as "DOWN" quoting the boot banner, then "RECOVERED" on the next visit — ~10 sites flapping all day, burying real alerts. The generated app unit now counts 143/SIGTERM as a clean stop; the test pins it (mutation-checked). ivy-health.sh was box-only and still checked fleetcrown-app/-bridge and the retired OpenClaw gateway, paging "DEGRADED (restart failed)" every 4h for units that no longer exist. Versioned here, now heals postgres and the loki-* units and probes loki-app /api/health; installed on the box. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * docs(telegram): register ivy-health.sh as a sender Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * chore(hetzner): ivy-health history without the retired name Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
9cf0711167 |
fix(widget): a site's widget works on every address apps.conf lists for it (#1088)
A token's origins list is written at install time; apps.conf (the hosting
SSOT) can gain addresses later. Any address added outside Loki's attach
flow was missing from the token, so /api/widget-boot answered
{active:false} there while the site's other address rendered the widget:
xhiva.orangecat.ch (apps.conf) vs the long preview host (token).
One rule, src/lib/widget/origin.ts, now used by boot, ingest, chat, advise
and transcribe (it was copied into five routes): an origin passes when the
token lists it, or when it is another apps.conf address of a site the token
already lists. Never another site's. Empty list still means any origin;
a missing Origin still passes only on boot.
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
|
||
|
|
83199d1c68 |
fix(watch): a shared walkthrough never quotes the reporter's words (#1086)
The first live share (farmaciadelparco) opened by quoting the request
verbatim to whoever got the link: its typos and the owner's private
ambition ('...if we are to become the biggest pharma retailer in
switzerland'). A request is often a stranger's, sometimes rough, sometimes
private. A viewer now gets a neutral opening, the live change and the
note's plain sentence; the test pins that the request never reaches them.
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
|
||
|
|
3e4bc7ff38 |
feat(terminal): the switcher names the agent that is running; tabs can be started, renamed and closed (#1085)
The agent switcher, the Claude | Terminal toggle and the chat view all keyed off the project's saved preference, not the CLI running in the tab. A Claude- preferring project with Cursor live labelled the switcher "Claude", offered a chat view Cursor never writes a transcript for, and treated picking Claude as "already active" - a no-op. The live CLI now decides; preference only answers when nothing is running. A failed switch or close is shown instead of swallowed. The agent tab strip gets what the shell workspace's already had: + starts a session in place (the existing launcher), double-click or F2 renames (a display name per builder; the session id never changes), and x closes with an armed "Close?" second press because it ends a running agent. /api/control/close-tab now honours the builder being viewed instead of always routing to cloud. Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
c48ffba2ae |
feat(watch): share a fix's walkthrough with anyone; a cleaner last card (#1083)
* feat(watch): share a fix's walkthrough with anyone; a cleaner last card
"How can I share these?" (operator, 2026-10-08). A walkthrough is not a
video: it is a signed ticket in the live page's fragment that the widget
plays on the real site. Owner tickets last a day and carry the maintainer's
reasoning, so there was nothing safe to hand on.
- Share: a long-lived share token (own HMAC domain, 90 days) behind the
public /w/<token>, which mints a fresh VIEWER ticket on every open and
redirects to the live page. The viewer's story is the request and the
live demonstration in plain words: no reasoning, PR or reporter
screenshot. Share buttons in Loki's inbox (next to Watch the fix) and on
the walkthrough's last card (share sheet, else clipboard, else the link).
- Same walkthrough for everyone: planned steps are kept per fix, audience
and page outline, so a link passed around doesn't re-plan per viewer
(or spend the owner's AI budget per viewer).
- The last card: one short question and one decision with Share beside it,
Replay and the code change as quiet links, close as an x in the corner.
It no longer repeats the agent's change log, and firstSentence no longer
cuts at an abbreviation ("...115/115 browser checks incl.").
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
* style(docs): format the share sentence
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
---------
Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
|
||
|
|
2c9001d77d |
feat(forms): dates read in words — all date fields use whenkit's DateInput (#1082)
* feat(forms): dates read in words — all date fields use @bitbaum/whenkit's DateInput Eleven raw <input type="date"> fields (events, goals, commitments, subscriptions, crew assignments, interactions, location) showed the browser's bare "tt.mm.jjjj" box. They now render whenkit's DateInput, a drop-in with the same props and onChange(event): the tag changes and nothing else. The visible box carries the SAME ui-input* classes, so each field keeps its place in the layout, and the real input stays on top — picker, keyboard, min, onBlur/onKeyDown inline editing all unchanged. src/components/ui/date-input.tsx is the one place Loki imports it from (and the one place the stylesheet is imported). Migrated with whenkit's scripts/migrate-date-inputs.mjs, which changes only the tag and one import. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> * chore(deps): whenkit 0.3.1 — the date icon scales with the field's text Loki's dense ui-input-tight fields (12px) are not made taller by a fixed 20px icon. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Sonnet 5.5 <noreply@anthropic.com> |
||
|
|
90d42d4478 |
chore(deps): bump @modelcontextprotocol/sdk from 1.29.0 to 1.32.1 (#1061)
Bumps [@modelcontextprotocol/sdk](https://github.com/modelcontextprotocol/typescript-sdk) from 1.29.0 to 1.32.1. - [Release notes](https://github.com/modelcontextprotocol/typescript-sdk/releases) - [Commits](https://github.com/modelcontextprotocol/typescript-sdk/compare/v1.29.0...1.32.1) --- updated-dependencies: - dependency-name: "@modelcontextprotocol/sdk" dependency-version: 1.32.1 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
7bdb7cd61b |
chore(deps): bump proxy-addr from 2.0.7 to 2.0.8 (#1058)
Bumps [proxy-addr](https://github.com/jshttp/proxy-addr) from 2.0.7 to 2.0.8. - [Release notes](https://github.com/jshttp/proxy-addr/releases) - [Changelog](https://github.com/jshttp/proxy-addr/blob/master/HISTORY.md) - [Commits](https://github.com/jshttp/proxy-addr/compare/v2.0.7...v2.0.8) --- updated-dependencies: - dependency-name: proxy-addr dependency-version: 2.0.8 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
0e52732f88 |
chore(deps-dev): bump sharp from 0.35.4 to 0.35.5 (#1057)
Bumps [sharp](https://github.com/lovell/sharp) from 0.35.4 to 0.35.5. - [Release notes](https://github.com/lovell/sharp/releases) - [Commits](https://github.com/lovell/sharp/compare/v0.35.4...v0.35.5) --- updated-dependencies: - dependency-name: sharp dependency-version: 0.35.5 dependency-type: direct:development ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
b04bf56675 |
chore(deps): bump dompurify from 3.4.14 to 3.4.16 (#991)
Bumps [dompurify](https://github.com/cure53/DOMPurify) from 3.4.14 to 3.4.16. - [Release notes](https://github.com/cure53/DOMPurify/releases) - [Commits](https://github.com/cure53/DOMPurify/compare/3.4.14...3.4.16) --- updated-dependencies: - dependency-name: dompurify dependency-version: 3.4.16 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
f1f6a4f7a3 |
chore(deps): bump ip-address from 10.5.0 to 10.7.2 (#969)
Bumps [ip-address](https://github.com/beaugunderson/ip-address) from 10.5.0 to 10.7.2. - [Release notes](https://github.com/beaugunderson/ip-address/releases) - [Commits](https://github.com/beaugunderson/ip-address/compare/v10.5.0...v10.7.2) --- updated-dependencies: - dependency-name: ip-address dependency-version: 10.7.2 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
83d0d3a626 |
chore(deps): bump fast-uri from 3.1.6 to 3.1.8 (#968)
Bumps [fast-uri](https://github.com/fastify/fast-uri) from 3.1.6 to 3.1.8. - [Release notes](https://github.com/fastify/fast-uri/releases) - [Commits](https://github.com/fastify/fast-uri/compare/v3.1.6...v3.1.8) --- updated-dependencies: - dependency-name: fast-uri dependency-version: 3.1.8 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
1ee5fec1f4 |
chore(deps): bump undici from 7.29.0 to 7.30.0 (#967)
Bumps [undici](https://github.com/nodejs/undici) from 7.29.0 to 7.30.0. - [Release notes](https://github.com/nodejs/undici/releases) - [Commits](https://github.com/nodejs/undici/compare/v7.29.0...v7.30.0) --- updated-dependencies: - dependency-name: undici dependency-version: 7.30.0 dependency-type: indirect ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> |
||
|
|
edb1249552 |
feat(watch): Review: Loki judges what you just did on your site (#1081)
* feat(watch): Review — Loki judges what you just did on your site and suggests what to improve Watch mode only acted when something broke. It now also notices what a demanding reviewer would (4xx, slow requests, console errors, slow loads, main-thread freezes, layout shift, pauses between steps) plus measured page checks (unnamed controls, unlabeled fields, tiny tap targets, missing alt, broken images, sideways scroll, h1/lang). The pill counts them; Review sends the session to Ask, which judges it through errors, design, engineering, process and product - every point cited from the session - and each change is one tap from a request that carries the watched steps. The trail now survives page loads within a tab, so a multi-page site reads as one visit. No model runs until Review is pressed. The report POST is now one helper (widget/send-report.ts) shared by Send and the automatic fix. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> * fix(watch): Review never blames the site for Loki's own work; plain-text answers Found by looking at the 390px render, not by the tests: - opening Loki's own Review panel scored a 0.27 layout shift against the site (Chrome reports shadow-DOM sources with a null node) - only shifts pinned on a site node count now; - the widget's own boot registered as 'the page froze 369ms' - a freeze now counts only when it overlaps the second after a tap on the site; - the review asked for **bold** lenses and the widget shows text, so clients saw literal asterisks - plain-text rubric + plainAnswer() on every reply; - '404 in 0.0s' - duration only when slow. The browser test now proves the detectors fire on real jank (a Load more that freezes and pushes content down) AND stay quiet for Loki's own panel. The 'typed values never leave the page' checks were vacuous (fill() never taps the field) - they tap the filled field now and fail under mutation. Docs: the architecture table described Watch as 'still a seam'. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com> |
||
|
|
57cf15e6ba |
fix(deploy, projects): a hung page check no longer holds a deploy for 45 minutes; a closed run no longer reads "Building now" (#1079)
Deploy (every fleet site, via selfhost-deploy.yml): - page-check.mjs gets one 90s deadline for the whole look. On a host that accepts and never answers, goto gave up at 45s and the next call waited on the pending navigation forever; farmaciadelparco's deploys #3 and #4 sat in "Look at the live page before the deploy" until the job's 45m limit. Verified against a never-answering socket: records "did not load" at 90s and exits 0; a normal page still checks in ~3s. - timeout-minutes on both page-check steps as the backstop. Project page: - deriveBuildStatus: agent_running=t is a live process, not a live build. After a run closes Claude Code idles at its prompt, so the page said "Building now · An agent is working" beside "Finished · PR #1 merged". Building now needs an open run, or a prompt given after the last close. Claude-Session: https://claude.ai/code/session_014d9r6dNr1vW789Q75hPcHF Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
cfadec06b5 |
fix(watch): keep the model-JSON reader out of the browser bundle — main failed to build (#1080)
#1077's narration hook imported lib/watch-narration, which imported
lib/ai/model-json → lib/agent/llm → db → postgres. Turbopack then tried to
bundle `fs`, `net`, `tls` and `perf_hooks` for the browser and the
production build failed, so Deploy has been red on main since
|
||
|
|
af1463e5a5 |
feat(watch): Loki narrates the build live, steer or autopilot from one card; readable screen; no false "Session ended" (#1077)
* fix(watch, terminal): readable live screen, a "What's going on?" button, no false "Session ended"
What the operator saw on a phone, 2026-10-07:
- Watch's "screen" was every spinner frame glued together ("Actioning…●✢4*✶75✻
✻Actioning…5✻…"). A peek is the PTY's byte buffer; deleting the escape codes
kept every redraw. renderTerminalText now replays CR / cursor moves / erase
sequences into the lines the terminal actually shows, and the live line names
the real step ("Running 1 shell command…", "Writing src/app/page.tsx")
instead of Claude Code's decorative spinner word.
- "Open the full terminal" opened a blurred page under a sheet saying "Session
ended — its agent terminal is gone" while it was still connecting to a
healthy session. Connecting no longer reads as gone (presentTerminalRun takes
the real state), the sheet no longer opens by itself over the session, and
the genuinely-lost case names a way forward with a button.
- New: "What's going on?" — under the terminal on phones, in the Loki panel
header, and as the primary button on Watch (opens Terminal with ?explain=1).
Loki answers for a non-programmer: anything waiting on you first, what is
being built and how far along, an honest "Autopilot:" line saying whether it
carries on without you, and up to three one-tap things to tell it next.
- Watch said "Working · 1 min" three times with two spinners; the activity
fold now says when the run started. The kickoff card's four-line "Working"
paragraph with its own spinner is one aligned line, and the pending step's
dot lines up with the icons.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ReWfUGdbNX6X67XDrbF8dg
* refactor(terminal): "What's going on?" state, button and Loki sheet in their own module
TerminalSurface crossed the 510-line function ratchet (533). The explain
request, the sheet that carries its answer and the button now live in
TerminalExplain.tsx; the rail takes them as one `explain` prop.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ReWfUGdbNX6X67XDrbF8dg
* feat(watch): Loki narrates the build live; steer it or let autopilot drive, from one card
"Not enough magic" (operator, 2026-10-07). Watch showed a terminal's worth
of facts; a person watching wants to know what is being made for them and
whether they need to do anything.
- While an agent works, Loki reads its screen every ~30s (only when it has
moved) and writes one plain headline in the owner's terms — "Adding the
Team page in three languages" — with a line on what it means. Earlier
headlines stack under it as the story so far. lib/watch-narration (pure,
tested) + POST /api/projects/[id]/watch/narrate (AI-budget gated,
rate-limited, degrades to the agent's own step line, never an error).
- "It needs you" appears only when the screen shows a question or a stop
the agent cannot fix, with one tap to answer.
- The two ways to drive it, on the same card: a "Tell it something" box that
steers the running session (tab-inject), and the project's real autopilot
switch with one line saying what each state does.
- The old live message (typing dots, raw-screen fold, two links) is replaced
by the card; "Look closer" opens the terminal with the explanation asked.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01ReWfUGdbNX6X67XDrbF8dg
---------
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
33eec2a538 |
feat(change): a free consultation before your site is rebuilt (#1076)
Naming your own website on /change used to go straight from an address to "Build a new version". Now the address alone opens a consultation first: Loki reads the live page the way a new visitor and Google do and says, in plain words, what is costing the owner visitors, what is worth fixing and what is already right, with the proof it saw and how Google shows them today. Every finding is a fix they keep or drop, and the build can be nothing more than "fix these" (plus their own words, now optional). - config/site-consult.ts: SSOT for the 19 checks: area, severity, owner copy, business reason, and the agent instruction a chosen fix becomes - lib/site-consult: SSRF-guarded single-page fetch (every redirect hop re-validated, DNS must be public; private-address guard ported from OrangeCat), a regex page reader, and pure rules. No model: the page is anonymous and must not spend the shared AI quota - POST /api/site-consult: public, rate-limited, cached, findings only - the build brief carries the chosen fixes as check ids, so the instruction an agent reads comes from config, never from the browser - typing just an address no longer lands in "what should change" Claude-Session: https://claude.ai/code/session_01X9tyuAD9YxN1gDFFUMAf6n Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
6bf6142b63 |
feat: live-fix messages open "Watch the fix"; late at night Control says go to sleep, autopilot has it (#1078)
Fix walkthroughs:
- New /feedback/<id>/watch-fix mints a fresh owner tour ticket on every
open and lands on the live page's walkthrough (inbox when there is no
live page or no access). A ticket lasts a day; a Telegram message lasts
forever, so messages carry this address, not a ticket.
- notifyFixShipped: push, Telegram and the in-app alert for a live fix now
link the walkthrough ("▶ Watch the fix") instead of the bare page.
- getFeedbackWithProject returns the project's liveUrl.
Late night:
- lib/late-night: 23:00–05:00 local, one "night" key per evening, copy.
- LateNightAutopilot on Control: autopilot off → "Hand it to autopilot and
go to sleep" with one tap to turn it on; on → "Autopilot is on — go to
sleep". "Not tonight" hides it until the next evening.
Claude-Session: https://claude.ai/code/session_014d9r6dNr1vW789Q75hPcHF
Co-authored-by: Claude <noreply@anthropic.com>
|
||
|
|
2f9a13ebfa |
chore(register): add farmaciadelparco (#1075)
Co-authored-by: Cato <catomean@users.noreply.github.com> |
||
|
|
c65ead0f6b |
feat(feedback): Watch the fix tells the story; the reporter gets their own (#1074)
The walkthrough could only show WHERE a change was: it had the report, the handoff's one line and a PR title. The owner asked for how it was solved, why so, what the alternatives were and who it helps. - Design note: every fix prompt asks the agent for a `## Walkthrough` section in the PR description (problem, change, why, considered, helps, where, a plain line for the reporter). fix-note.ts holds the field list once, rendering both the instruction and the parser; the fix ledger keeps the parsed note on FixShipping.pr.note. - Chapters: buildTourBeats turns report + screenshot + note + live steps into a ~60s story. The widget plays it with Back / Pause / Next, reading time scaled to each caption, the reporter's own screenshot as the before picture, and no second click when going back. - Reporter audience: tour tokens carry an audience inside the signed payload (owner tokens unchanged, so old links still work; reporter tokens last 7 days). /my-feedback offers "Watch your fix" on a live fix. The reporter's story keeps their words, the live demo and the plain line — no reasoning, PR or repository. Claude-Session: https://claude.ai/code/session_01MqXhtjrmVb4vKE6oKSyHVg Co-authored-by: Claude <noreply@anthropic.com> |
||
|
|
227c7529f6 |
fix(watch): "Chat" and "Watch it" open the agent's conversation, one tap from its terminal (#1073)
* fix(watch): "Chat" and "Watch it" open the agent's conversation, one tap from its terminal The Watch panel's Chat button opened the general Loki chat, which knows nothing about the run, and "Watch it" landed on whichever terminal view localStorage remembered. The terminal page already shows the same session as the agent's conversation or its raw PTY behind one switch; nothing deep-linked to it. - /terminal accepts ?view=chat|terminal; the link wins over the remembered view without overwriting it until the reader flips the switch. - withTerminalView() in lib/fleet-context builds those links. - Feedback Watch: Chat -> the run's conversation, Terminal -> the raw PTY. - Loki dispatch card "Watch it" opens the conversation. - Watch it work: "Follow <agent> live" beside "Open the full terminal". Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014d9r6dNr1vW789Q75hPcHF * fix(terminal): read ?view= in useTerminalView so TerminalSurface stays under max-lines-per-function Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_014d9r6dNr1vW789Q75hPcHF --------- Co-authored-by: Claude <noreply@anthropic.com> |