Skip to content

Title sessions in the Claude and Codex apps by item ID and title - #237

Merged
dinoderek merged 1 commit into
mainfrom
feat/session-titles
Nov 13, 2026
Merged

dinoderek merged 1 commit into
mainfrom
feat/session-titles

Conversation

@dinoderek

Copy link
Copy Markdown
Owner

Objective

Sessions show a readable title in the Claude and Codex apps: t<n> · <task title>, or p<n> · <plan title> for a planner. Today a Claude session shows as <repo>-<task>, and a Codex thread's title holds only IDs (p12 > t63). {name} still means <repo>-<task> (the tmux window, branch and run ID).

Gates

Lane Result Evidence
./dev test (every required lane) PASS local run on 26ac3ef: format, vet, lint, unit, coverage, file-length, imports, versions, docs-check and harness-names all PASS; the reviewer reran it and got the same
  • New or changed tests:
    • internal/session/title_test.go: the title format, whitespace and control characters folded, the 60-character cut, and the fallback to the name
    • internal/harness/claude/agents_test.go TestFindAgent: a session is found by its window name or title, else by its worktree (so a rename in the app still finds it)
    • internal/hosts/launch_test.go: {title} is quoted for the shell and falls back to the name
    • internal/hostops/spawn_test.go: spawn cleans the title, records it in run.json and launches with it
    • internal/controlrun/coordinator_test.go: the planner's dispatch carries p<n> · <title>
    • internal/harness/codex/label_test.go: the labeller uses the run's title
  • Not run, with reason: none

Rulings

None.

Review

  • Fresh reviewer: Claude Code, Opus subagent; Verdict: APPROVED
  • Declined findings (all optional):
    • Old hosts refuse dispatches while an upgrade is half done, because control-spawn rejects unknown fields and Title is a new field. The coordinator already posts a notice and retries until the host is upgraded, and engine upgrade upgrades every host in one run.
    • Doc note that Claude status still works without -n: not added. docs/harnesses.md is at its word budget, and the findAgent doc comment already says it.
    • A t<n> assertion in a task-dispatch test: not added. Tasks and planners go through the same launch call, and session.Title has its own unit tests.
    • Two Claude sessions in one worktree after a rename: not handled. It needs a manual session in an executor's worktree plus a rename in the app; the name and title matches come first.
  • Review hard: internal/harness/claude/claude.go (findAgent, the status lookup now that the name changes), internal/hostops/spawn.go (the title cleaned again on the host)

Deviations

None. Operator follow-up after merge: run engine upgrade, then change the Claude launch line in hosts.toml to -n {title} --remote-control {title} and copy the file to every host. A host still on the old engine rejects {title}, so upgrade first.

🤖 Generated with Claude Code

The coordinator sends each spawn the item's title, t<n> · <title> (p<n>
for a planner); the host cleans it, records it in run.json and expands it
as the launch line's {title}. Claude's status finds a session by that title
or the window's name, else by its worktree. The Codex labeller titles a
joined thread with it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@dinoderek
dinoderek merged commit 72bf75a into main Nov 13, 2026
1 check passed
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.

1 participant