- biome.json: migrated (noPlaywrightMissingAwait and noIdenticalTestTitle left nursery), and
Markdown formatting and linting stay off so specs keep their hand wrapping.
- The 2.6 formatter output for 35 files, mostly re-wrapped test.each calls.
- Fixes for the new diagnostics: a guardedContent helper and explicit guards instead of unsafe
optional chaining in tests, Math.max in ChangesReviewGuide, a describeFrame rename for the
Playwright describe rule, awaited dispose()/close() promises in e2e, textContent where the
rendered text is not needed, and the dictation test reads the new line's own element.
- apps/website/src/styles.css: contextual icon, link, paragraph and image rules move after the
plainer rules for the same elements, so specificity never descends. Equal-specificity rules keep
their relative order (the tree-row/ft-row selector list is split around the hint hover rule) and
the chat paragraph rules move together with their phone overrides; computed styles of every
element on all 15 pages are unchanged.
Co-authored-by: OLavrik <Olya_lavrik@inbox.ru>
* refactor(scripts): parse boundary and binary-seam imports with oxc-parser
* fix(scripts): fail on oxc parse errors and parse JavaScript sources as JSX
* fix(scripts): parse .cjs and .cts sources as CommonJS in the boundary scan
---------
Co-authored-by: danyaberezun <danya.berezun@gmail.com>
* feat(pi-ask-user-question): add the portable ask_user_question package with a dialog fallback
* feat(pi-ask-user-question): add the terminal questionnaire window and transcript renderers
* test(pi-ask-user-question): drive the terminal and dialog paths in the parity gate and a real session
* docs(pi-ask-user-question): add the package spec, README and first changeset
* refactor(ui): move AttentionLine into @thinkrail/ui for extension cards
* refactor(web): pass the ask card its host actions through ToolRenderProps.interaction
* refactor(ask-user-question): move the questionnaire card into its ThinkRail extension
* docs(web): point the ask card references at the ask-user-question extension
* feat(extension-api): let server extensions take per-session host services
* feat(server): flatten per-session factories of registry extensions
* docs(extensions): document per-session factories of registry extensions
* feat(ask-user-question): add the server half and register it with a session seam
* fix(server): keep registry extension tools ahead of same-name user packages
* feat(server): run ask_user_question through the extension and delete the host tool
* test(server): cover the ask-user-question switch, its reload and a same-name package
* docs(workflow): ask the round in plain chat when ask_user_question is absent
* docs: describe the shipped ask-user-question extension across the spec graph and README
* test(artifacts): answer a scripted ask_user_question through the packaged host
* fix(server): track only ask calls the extension announces, in our argument shape
* fix(web): let the ask card answer only the question the host is waiting for
* docs: record the announced-call ask lifecycle and the accepting card state in the specs
* fix(pi-ask-user-question): end the turn as abandoned when Stop closes a built-in asker
* refactor(ask-user-question): key the web on one tool-name constant and drop a duplicate result guard
* fix(ask-user-question): keep the card from claiming attention for a call the host is not waiting on
* fix(server): acknowledge an ask answer by its persisted details, not the rebuilt envelope (#936)
* refactor(extensions): run interactive tools through a tool-agnostic host contract keyed by toolCallId
The host's answer mailbox, restart repair, session state, wire method and web
interaction props were keyed on the ask_user_question name, and the core
imported texts, an envelope builder and the card from the extension. Make the
seam real: the mailbox (agent/toolResponses) tracks announced calls by id with
opaque responses; the enabled registry extensions declare which tools wait for
a person (ServerExtension.interactiveTools, with describeResponse for the
wording of a response delivered after a restart) and which renderers take an
interaction (ToolRegistrationOptions.interactive). needsInput becomes
{ kind: "tool-response", toolCallId }, session.answerQuestion becomes
session.respondToTool (protocol 92), the late reply is a tool-response custom
message (legacy ask-user-answers transcripts still read), and the pending
marker { kind: "ack" } plus its guard live in contracts. The ask types,
constants and guards leave contracts; the card type-imports them from its pi
package, which the boundary check now allows for a web half (value imports
stay rejected). The plan page renders the awaiting call through the tool
registry, and the web registry is populated at bootstrap so the plan panes
never read a transcript before it. Deleting the extension leaves the core
building; built-in extensions keep winning a same-name collision while enabled.
* fix(web): keep answering questions against a pre-v93 host for one compatibility window
The UI ships independently of the host, so a client at v93 can welcome a host
that still emits needsInput.kind "question" and only knows
session.answerQuestion. Read that state as the awaiting call, send the retired
method below TOOL_RESPONSE_PROTOCOL_VERSION through one transport helper the
chat and the plan page share, and keep the host's side of the window too: the
request registry forwards session.answerQuestion to the same delivery so an
already-loaded older client still answers.
---------
Co-authored-by: rsolmano <rinat.suleimanov@jetbrains.com>
* feat(web): translate the interface and let users add their own languages
* test(i18n): pass the translator in tests main added for usage counters and hydration
* fix(server): reattach the locale watchers when Linux drops them with a deleted folder
* fix(resource-renderers): retranslate the editor's comment controls without remounting
* fix(resource-renderers): install the current comment label when the editor mounts late
* fix(server): poll the locales folder instead of watching it
* fix(server): catch permission repairs and mtime-preserving rewrites in the locales poller
* fix(locales): let plural forms show or omit the count and fill missing forms from _other
* fix(i18n): stop terminal-group labels rendering their raw key and split the Done status from the Done action
* fix(web): translate default chat, terminal, Changes, diff and plan tab names at render instead of storing them
* fix(i18n): translate theme names, the default workspace, thinking levels and the remaining UI labels
* fix(chat): word the round closer, failure notices and durations at render instead of storing English text
* fix(chat): export the plan Markdown in the interface language
* fix(desktop): translate the native startup and update error dialogs
* fix(i18n): keep extension notices' text, report untitled sessions without an English title, and word the default workspace everywhere
* docs(specs): record that stored names carry no translated text and the plural-form rules
---------
Co-authored-by: danyaberezun <danya.berezun@gmail.com>
* refactor(web): extract the file and diff renderers into @thinkrail/resource-renderers
* docs(specs): mark the resource-renderers spec active
* refactor(web): pass renderer host markdown and code as values, preferences separately
* perf(web): subscribe review-draft scratch per slot so a keystroke re-renders only its composer
* perf(web): build Monaco file options only when their inputs change
* fix(web): keep the rendered markdown diff on screen while a refreshed merge is pending
* refactor(web): drop leftovers of the renderer extraction
* docs(specs): describe the static renderer host, per-slot review drafts, and fix drift from the move
---------
Co-authored-by: danyaberezun <danya.berezun@gmail.com>
* feat(extensions): enforce browser and server package boundaries
* refactor(ui): extract shared primitives and extension contracts
* refactor(visualize): compose the renderer through its web extension
* fix(web): migrate new main components to the extracted UI SDK
* fix(extensions): preserve resource UI and compiler census after extraction
* test(extension-api): scope browser guards to repository-relative paths
* fix(web): use native paths in build-time token checks
* fix(web): import quit hint class helper from shared UI
* docs(specs): record the extensions strategy — portable pi packages and ThinkRail extensions
* docs(specs): publish pi packages under the @thinkrail.ai npm scope
* feat(pi-visualize): add publishable @thinkrail.ai/pi-visualize with TUI rendering and a validator seam
* ci(pi-packages): add the vanilla-parity gate for published pi packages
* ci(release): add Changesets and the pi-package publish workflow
* docs(pi-extensions): describe the parity gate and the release flow
* ci(release): tag only after a real publish
* fix(pi-visualize): keep TUI rows within the viewport and render commented sources
* ci(release): tag once every version is on npm and make the bootstrap publish work
* ci(release): report readyToTag=false on the pending-changesets exit
* docs(pi-visualize): switch the terminal renderer decision to lovely-mermaid
* feat(pi-visualize): draw and validate diagrams with lovely-mermaid
* chore(desktop): upgrade Electrobun to 2.0.1
* chore: align the Bun toolchain and types to 1.4.0
* refactor(desktop): replace handwritten types with the official SDK
* refactor(desktop): use framework builds and isolate artifact tests
* ci: expose the expanded macOS app for private signing
* docs(ci): align signing ownership with the private pipeline
* docs(testing): record artifact collector contract ownership
* docs(ci): preserve private action ownership after rebase
* feat(host): embed pi-delegation/pi-subagents in the engine host
Contracts: DelegationRunDetails/DelegationRunStatus mirrored DTOs, the
subagent-completion custom message (tag, pairing, shared guard,
customMessageText), subagent.getTranscript keyed (workspace, parent, child)
with live registry status; protocol 51. Server: per-workspace
DelegationService cache, liveParentContext projection, delegation store under
the data dir, child-dispose cascade on removeSession awaited by workspace
archival, curated child extension set. CLI: bundles the extensions into the
binary (named pi-web-access factory for the child set). Squashed from
subagent-research-planning (layer 2/3).
* fix(host): bind the live runtime resolver into delegation services
Review finding on #303: the per-workspace DelegationService captured the
ModelRuntime active at first-chat time, so a Central connect/disconnect
(new runtime generation) never reached later children. The service now
binds getPiRuntime itself (pi-delegation's provider-function binding,
resolved per createChild); delegationServiceFor/subagentsExtensionFor go
synchronous. Pinned by a generation-flip test verified to fail on the old
binding.
* fix(host): review round 2 — strict details validation, parent-generation children, mirror pins
- contracts: isDelegationRunDetails (closed status union, numeric usage
fields, durationMs) is the one shape check for untrusted wire details;
isSubagentCompletionMessage narrows through it (#303 review finding —
the old guard accepted status:"done" with usage:{}). Pinned.
- server: liveParentContext carries entry.generation.runtime, so a child
runs on its parent's RETAINED runtime generation — a Central-only-model
chat still delegates after a disconnect (#303 review follow-up). The
flip pin now covers both directions: old parent stays on its generation,
a new parent picks up the new one. Verified to fail without the fix.
- server: mirror pins — the completion tag equals pi-subagents'
SUBAGENT_COMPLETION_MESSAGE and contracts' DelegationRunDetails stays
mutually assignable with pi-delegation's original (drift now breaks a
test, not a client).
* fix(host): review round 3 — teardown ordering for the delegation store + structured transcript-not-found
The delete transaction awaits its child cascade before publishDeleted, and
workspace archival drains a per-workspace registry of pending disposeSession
cascades before removing the delegation store — cascades, not delete
transactions, so archival stays unblocked by a delete wedged mid-trash. Both
pinned via a test-gated child turn (no sleeps; deterministic in both
directions). subagent.getTranscript's permanent miss is now
CodedError(SUBAGENT_TRANSCRIPT_NOT_FOUND) on the wire, and the parent server
SPEC declares the agent → persistence edge the delegation embedding added.
* fix(host): review round 3 — child transcripts read through pi's canonical entry projection
readChildTranscript's private message-entry loop missed that compaction is an
entry TYPE, not a message role: a compacted child's transcript lost its
compactionSummary marker. Entries now project through buildSessionContext —
the same path a live session.messages takes — then filter via the shared
isTranscriptMessageRole, mirroring getSessionMessages. Pinned by appending a
compaction entry to a finished child and asserting the summary survives the
read.
* docs: record ThinkRail delegation embedding
* docs: align delegation boundary surfaces
* fix(desktop): register subagent web access factory
* fix(host): await background subagents on shutdown
* docs(agent): align delegation dependencies
* fix(contracts): validate optional delegation fields
---------
Co-authored-by: rsolmano <rinat.suleimanov@jetbrains.com>
* todo: Promote the approved desktop architecture
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_44fa5c64dcc4
* todo: Implement the Electrobun package and runtime
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_95ec4db0a29a
* todo: Add packaging and desktop coverage
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_7ab33dbfe2ca
* todo: Run all gates and review the final diff
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_1a397cf79389
* todo: Record and promote the approved menu design
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_d74f3263a760
* todo: Implement the native application menu
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_14f62292581a
* todo: Add regression coverage
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_bba36e4af871
* todo: Run gates and review the complete diff
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_1f0975890932
* todo: Record and validate the approved design
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_882644532c0b
* todo: Promote the decision across owning specs
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_90686630ca71
* todo: Add code-level boundary enforcement for launchers
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_fec4bc0ec29e
* todo: Run gates and review the complete change
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_0b7d16b32cba
* todo: Validate the latest main integration
ThinkRail-Todo: 01a0247a-cd52-785c-917b-106f5a75dfc8/t_04a51b278128
* test(e2e): reveal recalled turn after settlement
---------
Co-authored-by: danyaberezun <danya.berezun@gmail.com>