Skip to content

docs(plan): define Studio chat transcript and composer - #1880

Merged
samuv merged 5 commits into
mainfrom
plan/studio-chat-transcript-composer
Sep 25, 2026
Merged

samuv merged 5 commits into
mainfrom
plan/studio-chat-transcript-composer

Conversation

@samuv

@samuv samuv commented Sep 24, 2026 •

Copy link
Copy Markdown
Contributor

Tracking: #1847

Summary

Stage: Plan / Interface. This Bounded, Split plan defines seven scenarios and 17 verifiable criteria for Studio's streamed transcript and responsive composer. It covers markdown, code and tool rendering; message status; image attachments and speech fallback under the served CSP; model and permission controls; send, queue, steer, replay, cancel and retry; IME input; long runs; seed prompts; titles; same-tab return notices; and recorded scheduled-delivery notes. Implementation is stacked separately in #1886.

The plan reconciles the Studio parent #1736, design review #1779, ADR 0351, and the merged appearance (#1861/#1873) and shell (#1858/#1869) foundations. Chat uses their 500 px pivot, semantic controls, and shell framing. Those foundation contracts require no amendment. The plan also amends the already-landed Studio bootstrap AC4.6 proof: unmarked studio. account data is cleared before chat renders after a storage failure; marked same-account data and device theme remain. The directing human explicitly authorized that fail-closed amendment.

Contract and decision record

  • Work class: Bounded. Decision record: None; ADR 0351 continues to own the same-origin browser/BFF and published SDK boundary.
  • Plan: docs/acceptance/studio-chat-transcript-composer.md. All human decisions are resolved. Approval baseline remains absent until this Plan / Interface PR merges; the directing human authorized feat(studio): align chat transcript and composer #1886 as a stacked implementation on this unmerged plan.
  • Browser chat URLs keep opaque BFF session IDs; controls keep opaque BFF run IDs. SDK objects, daemon calls, and credentials remain inside the BFF. Sending remains image-only: up to 16 images, 10 MiB each and 20 MiB total, gated by the selected model's image capability.
  • Daemon gRPC/protobuf, exported Go APIs, tool schemas, CLI/config, and the run.started | run.event | run.truncated | run.error SSE union stay unchanged. Additive BFF contract fields are titleRevision/titleProvenance on session summaries and rename responses, and an optional inert delivery annotation on canonical recorded notes. OpenAPI and the generated browser client follow source schemas in implementation.
  • A ?prompt=...&send=1 link requires an explicit Send click. A return notice uses only facts refreshed after the same tab was hidden for at least 20 seconds; it has no persisted marker or reload notice. Idle transcript refreshes include the saved reply and turns from another client, subject to bounded polling.
  • The seed confirmation names the target chat, model, and permission mode. Interactive sign-in leaves the original tab and seed URL in place. A stale peer tab quarantines account data while rechecking authentication. Visible connected inventory polling occurs every 20 seconds without overlapping requests, retains the BFF's 20-page cap, and adds an idle transcript safety check after 60 seconds without a successful check.

Scope and proof

Inline approvals (#1848), delegated activity (#1849), side panels (#1850), and MCP inventory (#1851) remain separate. The plan records the run target, event families, message anchors, preview callbacks, and draft insertion seam they consume. PDF/text sending and remote image embeds remain outside this contract.

The acceptance-plan checker and fixture suite passed; all 17 criteria have verify: targets (with only the checker's generic Go named-test advisory). CGO_ENABLED=0 task docs and git diff --check passed after rebasing onto origin/main c8d1c32d6e07574ab8980e7efbf007a6b4273195. The diff contains only the new plan, its index entry, and the authorized Studio bootstrap AC4.6 amendment. Runtime and browser gates belong to stacked implementation #1886.

The existing event stream identifies scheduled delivery through canonical fenced text, not authenticated origin metadata. Byte-identical user text can receive the same inert note presentation; a stronger provenance claim needs a separate daemon/SDK contract.

@samuv samuv self-assigned this Sep 24, 2026
@samuv samuv changed the title Plan / Interface: Studio chat transcript and composer feat(studio): align chat transcript and composer Sep 24, 2026
@samuv samuv changed the title feat(studio): align chat transcript and composer docs(plan): define Studio chat transcript and composer Sep 24, 2026
@samuv samuv changed the title docs(plan): define Studio chat transcript and composer docs(plan): define Studio chat transcript and composer Sep 24, 2026
@samuv samuv mentioned this pull request Sep 24, 2026
1 of 3 tasks
@samuv
samuv force-pushed the plan/studio-chat-transcript-composer branch from efad4fc to 04eeffc Compare September 24, 2026 16:38
@samuv
samuv added this pull request to stack #1887 September 24, 2026 16:39
@samuv
samuv force-pushed the plan/studio-chat-transcript-composer branch from 04eeffc to e536668 Compare September 25, 2026 07:55
@peppescg

Copy link
Copy Markdown
Contributor

Plan review: #1880

The acceptance criteria are behavioural, and each carries a verify: line. They are consistent with ADR 0351: the browser talks only to the BFF, and the BFF reaches the daemon only through the published SDK. The stacked #1886 exposed a few points that need to be resolved in this Plan/Interface PR.

Needs changes

  1. Move the AC4.6 amendment here. feat(studio): align chat transcript and composer #1886 rewrites docs/acceptance/studio-bootstrap.md AC4.6, a plan that has already landed. Its "first sight of unmarked account data" behaviour changes from keep to clear, and its verify: target changes with it. Under docs/development-process.md §Contract amendments, that change belongs in a Plan/Interface PR, so please move it into this PR. AC4.3 of this plan also currently says clearing happens only "on sign-out or account change", which no longer matches.
  2. AC7.2 covers only half of a scheduled delivery. A delivery starts a real run in the origin chat (internal/app/scheduler_delivery_run.go → StartRunContent), but the plan only requires the delivery note to appear in an idle open chat. The agent's reply to that note is not covered. The same gap applies to turns written from another device. Please specify how the open transcript picks up those turns.

Minor or unspecified

  • Multi-tab account transitions: if tab A reconciles to account Bob, a still-open tab B signed in as Alice can write the single-key studio.chat.folders into Bob's marked storage.
  • send=1 confirm dialog: the plan doesn't say whether the dialog must show the model, permission mode and target session.
  • Seed parameters: the plan doesn't say whether they survive a sign-in redirect.
  • Poll cost: there is no bound on the 20 s return poll. Each poll can make up to maximumInventoryPages SDK list pages per open tab.

@samuv
samuv force-pushed the plan/studio-chat-transcript-composer branch from e536668 to 34e414c Compare September 25, 2026 11:18
Co-Authored-By: Codex <[email protected]>

Signed-off-by: Samuele Verzi <[email protected]>
Co-Authored-By: OpenAI Codex <[email protected]>

Signed-off-by: Samuele Verzi <[email protected]>
Co-Authored-By: OpenAI Codex <[email protected]>

Signed-off-by: Samuele Verzi <[email protected]>
Co-Authored-By: OpenAI Codex <[email protected]>

Signed-off-by: Samuele Verzi <[email protected]>
@samuv
samuv force-pushed the plan/studio-chat-transcript-composer branch from 34e414c to 8298c2d Compare September 25, 2026 12:24
@samuv

samuv commented Sep 25, 2026

Copy link
Copy Markdown
Contributor Author

Addressed in this Plan / Interface PR (head 34e414c9011e0061b60eca62e4caf7df85900fc9):

  • The authorized fail-closed amendment to the already-landed Studio bootstrap AC4.6 and its verify: proof now live in docs(plan): define Studio chat transcript and composer #1880. AC4.3 here explicitly covers first sight of unmarked studio. data, while preserving marked same-account data and device theme. feat(studio): align chat transcript and composer #1886 no longer carries that bootstrap-plan amendment.
  • AC7.2 and the interface section now require an open idle chat to reconcile the full saved transcript in recorded order, including a delivery note, its assistant reply and tool content, and turns written by another client. An advancing inventory timestamp triggers a refetch; the 20-second visible/online poll also performs an unchanged-row safety check after 60 seconds since a successful transcript check. Inventory and transcript requests cannot overlap with another request of the same kind, and the existing BFF cap of 20 pages of 100 rows bounds each inventory fetch.
  • The plan now specifies stale-tab account-data quarantine while authentication is rechecked and records the remaining non-atomic browser-storage marker/write race. The send=1 confirmation names the target chat, model, and permission mode. Interactive sign-in leaves the original tab and seed URL in place rather than relying on return_to.

The plan checker, documentation validation, and plan PR CI passed. The stacked implementation and its proof are in #1886. Both PRs remain open for review.

@samuv
samuv merged commit a6c2c15 into main Sep 25, 2026
31 checks passed
@samuv
samuv deleted the plan/studio-chat-transcript-composer branch September 25, 2026 12:37
@toolhive-release-app toolhive-release-app Bot mentioned this pull request Sep 25, 2026
2 tasks
jbeda added a commit that referenced this pull request Sep 25, 2026
…mit-coauthor-guidance

* origin/main: (32 commits)
  docs: plan optional native Kubernetes execution provider (#1579)
  feat(mecatui): restore session status metrics (#1891)
  docs(plan): bound agent inventory viewport (#1946)
  docs: include user-docs in matlatl and use local documentation links (#1934)
  feat(mecatui): bound sessions inventory (#1944)
  feat(studio): show session delegation activity (#1907)
  docs(plan): define Studio session activity (#1885)
  Release TypeScript SDK v0.4.0 (#1940)
  Release v0.0.41 (#1941)
  docs(mecatui): plan bounded sessions inventory (#1906)
  feat(studio): add exact plan control and authorization review prerequisite (#1909)
  test(app): eliminate real ToolHive probe deadline wait (#1937)
  docs(plan): define Studio chat approvals and exact plan control (#1888)
  test(sdk): enforce SDK/TUI high-level parity (#1471) (#1917)
  docs(plan): propose SDK high-level parity coverage (#1471) (#1916)
  docs: improve gRPC schema table readability (#1842)
  test(app): eliminate real waits in durable learning tests (#1933)
  feat(studio): align chat transcript and composer (#1886)
  docs(plan): define Studio chat transcript and composer (#1880)
  feat: correlate provider requests with the root session (#1883)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants