Skip to content

[Feature]: Mobile chat polish pack: model picker favorites, reasoning gating, context usage, link previews, math, streaming reveal #100699

Description

@steipete

Summary

Polish pack for the mobile chat experience (iOS and Android): model picker favorites/recents, per-model reasoning-effort gating, a context-window usage indicator, opt-in link previews, math rendering, and streaming text reveal polish — shipped as a sequence of small independent PRs.

Problem to solve

The mobile chat surfaces are functional but lack several quality-of-life refinements users expect from modern chat clients:

  • The model picker treats all models equally; frequently used models require scrolling on every switch.
  • The thinking-level control is shown regardless of whether the selected model supports configurable reasoning effort, which is confusing when it has no effect.
  • There is no visibility into how full the session context window is, so long sessions hit compaction or truncation without warning.
  • Bare URLs in the transcript render as plain links with no preview affordance.
  • LaTeX math in assistant responses renders as raw TeX source.
  • Streamed prose appears in raw chunks without any reveal polish.

Proposed solution

A sequence of small, independently reviewable PRs, one per item and platform:

  1. Model picker favorites + recents — pin/unpin favorites and recents-first ordering, persisted per platform (UserDefaults / DataStore).
  2. Per-model reasoning-effort gating — hide or disable the thinking-level control when the selected model does not support it, driven by gateway model metadata; if the capability flag is missing from the model catalog schema, add it additively first.
  3. Context-window usage indicator — a subtle composer indicator of tokens used vs. the model context window, based on what the gateway exposes per session; scope an additive RPC field first if nothing suitable exists.
  4. Link previews in transcript — OpenGraph title/image cards for bare URLs, fetched client-side with a small bounded cache. Product call: previews load on tap-to-expand only — no ambient network fetches from message content (see Security: Indirect prompt injection via URL link preview metadata #22060 for the injection/exfiltration concern that motivates this default).
  5. Math rendering (iOS/shared renderer) — LaTeX display/inline math in the shared chat renderer, extending the existing block-segmenter pipeline; Android math rendering is a noted follow-up, not in scope here.
  6. Streaming text reveal polish (iOS/shared renderer) — word-paced fade-in for streaming prose; code and tables continue to render plain until complete; respects Reduce Motion.

Each PR carries tests along established seams, i18n sync when strings change, and license files for any newly bundled dependency.

Alternatives considered

  • One large PR: harder to review and revert; the items are independent by design.
  • Ambient (automatic) link-preview fetches: rejected for privacy and prompt-injection exposure; tap-to-expand keeps network activity user-initiated.
  • Server-side rendering of previews/math: heavier gateway surface for what is client presentation concern.

Impact

  • Affected: iOS and Android app users in chat
  • Severity: quality-of-life; individually small, collectively a noticeable experience gap
  • Frequency: daily (model switching, long sessions, links and math in responses)
  • Consequence: extra taps to switch models, confusing no-op controls, surprise context compaction, raw TeX in transcripts

Evidence/examples

Comparable behavior in mainstream chat/LLM clients (favorites/recents in model pickers, context usage meters, tap-to-expand link cards, LaTeX rendering). Related: #22060 (link-preview metadata injection risk), #64607 (inline media display for channel surfaces — different surface, complementary).

Additional information

Gateway/protocol changes (capability flag, usage stats) are additive only, per the gateway protocol compatibility rules. Android math rendering is explicitly a follow-up.

Metadata

Metadata

Assignees

No one assigned

    Labels

    P3Low-priority cleanup, docs, polish, ergonomics, or speculative work.clawsweeper:needs-maintainer-reviewClawSweeper marked this issue as needing maintainer review before automation.clawsweeper:needs-product-decisionClawSweeper marked this issue as needing a product or behavior decision.clawsweeper:no-new-fix-prClawSweeper does not recommend queueing a new automated fix PR for this issue.enhancementNew feature or requestimpact:ux-frictionUser-facing flow adds avoidable confusion or support burden without fully blocking progress.issue-rating: 🌊 off-meta tidepoolIssue quality rating does not apply to this item.maintainerMaintainer-authored PRmaturity:stableIssue affects a taxonomy feature currently scored M4/M5.

    Type

    No type

    Fields

    Priority

    None yet

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions