Repository navigation
Description
Problem
A Gamma Reader conversation grows by design: it is titled, renamed, kept in history, restored with its draft, and meant to be returned to for weeks. Every turn sends the entire history to the model (create-reader-agent.ts:106 — messages: [...session.messages], no trimming, no accounting), and the web app never counts what that costs against the model's window: the only token references in features/conversation/features/agent are internal parameters (maxTokens in vision/title calls, a pagination cursor).
So the wall arrives unannounced. When a long conversation crosses the model's context window, every follow-up fails with a provider error string — and then fails again on retry, because retry resends the same overflowing history. There is no repair path in the product: the history menu offers Rename and Delete only (conversation-history.tsx), messages cannot be trimmed, and the assistant cannot be asked for a handoff exactly when one is needed, because past the wall it answers nothing in that conversation. The reader's only move is to abandon the thread and re-establish context by hand in a new conversation.
This is the candor gap #38 named for storage, in the assistant's memory: the product knows the model's window (its model list carries it), knows the history's size, and says nothing until the conversation dies.
Proposal
- Show context pressure where the reader writes: a quiet indicator near the composer as the conversation's history approaches the model's window ("context is filling up"), the same candor the composer already practices elsewhere.
- Add Continue in a new conversation (exact label) to the conversation's actions: the assistant writes a summary of the thread while it still can, and the new conversation opens with that summary and the same document attachments — the endorsed assistant-mediated path (Give conversations an export path — weeks of questions and answers live and die with the browser profile #50's close rationale), made into an affordance instead of reader folklore.
- The old conversation stays intact and readable; continuing is a fork forward, not a delete.
Goal
After this, a weeks-long companion conversation never bricks silently: the reader sees it filling before the wall, and one action steps them into a fresh conversation that carries the thread and the documents — instead of an error and a manual restart.
Verification
grep -rqiE "continue in|continued from" ui-packages/web/src/features/conversation
pnpm --filter @gamma-reader/web test --silent
pnpm checkRefs
- ui-packages/web/src/features/agent/create-reader-agent.ts:106 — full history on every turn, no accounting
- ui-packages/web/src/features/conversation/ — no token or context-window visibility anywhere (verified by search); history actions are Rename and Delete only
- Give conversations an export path — weeks of questions and answers live and die with the browser profile #50 (closed, not planned) — the close rationale endorses assistant-mediated paths; this issue turns that exact path (a written summary) into the repair affordance
- Show storage durability and pressure before the browser can evict the reader's library #38 — the same candor class for storage: warn before the reader loses what they built
- Let readers regenerate an assistant reply in place instead of retyping the question #42 — message-level retry; this is conversation-level survival
Activity
bencode commentedon Oct 2, 2026
Independent review — posted by the scheduled issue-reviewer loop (a session separate from the one that files these issues), under the maintainer's standing instruction to evaluate, sharpen, or retire
source:scheduledproposals.Evidence audit (against
main@d94348b): all citations confirmed.messages: [...session.messages](create-reader-agent.ts:106), no trimming or accounting.maxTokens: 200in title generation) — no context-window visibility anywhere.contextWindow(visible incore/byok/runtime.ts:53's default shape).lintpassed;verifyfails today → stays open.Verdict: valid, keep open — the best problem statement in the queue. It names the exact failure mode (retry cannot repair, assistant cannot be asked for a handoff past the wall), and "Continue in a new conversation" correctly turns #50's close rationale (assistant-mediated summaries) into an affordance rather than folklore.
Two implementation notes (non-blocking): (1) the pressure indicator should degrade gracefully when a model's window is unknown (custom BYOK entries) rather than guess; (2) the summary-writing step spends tokens when context is already scarce — the proposal's ordering (indicator before the wall, action available early) is the right mitigation, worth preserving verbatim in any implementation.
bencode commentedon Oct 2, 2026
Progress note — the first half of this issue shipped in #74 (
19cf67c):conversation/token-usage.tsnow tracks a conversation's context size against the model'scontextWindow, giving the pressure indicator the Proposal asked for. Still open on this issue: the Continue in a new conversation repair affordance (summary handoff + document attachments) — the Verification anchor targets that half and correctly still fails. No action taken; recording where the implementation stands so the remaining scope is unambiguous.bencode commentedon Oct 13, 2026
Independent review — posted by the scheduled issue-reviewer loop (a session separate from the one that files these issues), under the maintainer's standing instruction.
Verdict: superseded — closing as not planned. The problem premise of this issue is no longer true on main:
composer/token-usage-status.tsxshowsContext: X of Y tokens (Z%)by the composer.2fc0e56, merged as part off10f772): the conversation's command palette now has compact — "Summarize earlier messages to free up context".create-reader-agent.tsgainstransformContext: projectContext(...), so a compacted conversation is sent as its summary plus the kept messages; the reader still sees every message, with an "Earlier messages summarized" divider that opens the summary (conversation-messages.tsx).token-usage.tscounts the projected context, so the pressure indicator reflects what is actually sent after compaction.Honest residual delta: what this issue proposed and main does not have is the specific fork affordance — a Continue in a new conversation action that seeds a new conversation with the summary and the same attachments. The Verification grep (
continue in|continued frominfeatures/conversation) accordingly still finds nothing, which is why this closes as not planned rather than implemented: the goal the fork served — a weeks-long conversation never bricks silently — is now met in place by indicator + compact, a mechanism that loses nothing the reader can see. If the fork itself is still wanted as a product affordance, that is a fresh design call for the maintainer, not an open defect.Evidence re-checked on
f10f772; lint ✓; verify ✗ (anchor phrase absent, as expected for an unbuilt fork). @bencode — reopen if you want the fork affordance anyway.