Skip to content

Let the caller set the tab title at launch (--title) #2289

Closed

Description

@BenNewman100

Follow-up to #2061, which put the document's name first in the tab title.

The agent that launches a session knows what the review is for. The page knows only the file
name and the repo. Letting the caller set the title at launch is the flexible fix: a user can
give their agent a naming rule ("name the tab after the OpenSpec change"), or let it use
judgement, and the resolver never has to learn anyone's conventions.

Where the file name and repo aren't enough today:

  • Same-named files. OpenSpec changes, ADR folders and per-feature docs reuse names. Three
    open reviews of proposal.md from three changes each read proposal.md · acme/payments.
  • annotate-last. Every session reads Last message · acme/payments.
  • Code review. packages/review-editor/App.tsx still sets <repo> · Code Review, so two
    reviews of the same repo (say, a PR and the local diff) share one title.

Proposal

An optional --title <text> on annotate, annotate-last and review that replaces the
whole tab title:

plannotator annotate openspec/changes/add-refunds/proposal.md --title "add-refunds proposal"
Launch Tab title
without --title proposal.md · acme/payments
with --title "add-refunds proposal" add-refunds proposal
  • Absent: nothing changes; documentTabTitle builds the title as it does today.
  • Present: the text is the tab title, exactly as given, with no document name or repo added.
    The caller can include the repo itself if it wants it. The server passes the text through
    /api/plan (and the review equivalent).
  • Present: the desktop header shows the same text beside the logo, in place of the file name,
    so the page and its tab agree.
  • The agent-facing tool definitions (the hook and the plugin hosts) expose it as an optional
    title field, so an agent can name a review without the user asking.

Related: the owner in the default title

The default title spends most of a tab's width on the repo owner. In Firefox, for example, a
tab shows about 25 characters, so idea.md · BenNewman100/plannotator renders as idea.md · BenNewman100/plan….
The repo name alone (idea.md · plannotator) keeps the part that tells tabs apart. Happy to
split this into its own issue if you'd rather.

Questions

  1. Would you take a caller-set title?
  2. Which hosts should take it in a first pass: just the CLI, or the tool definitions too?

Happy to send the PR once the shape is agreed.


Drafted by Ben's agent at his request.

Activity

  1. added a commit that references this issue on Nov 4, 2026
    46553ed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions