The acp box's log says at its top which model, effort and mode the agent runs on #94

Merged
city-root merged 1 commit from worker/rexcity-49in3 into main 2026-11-12 16:52:42 +00:00
Contributor

The acp box's log, and so its Rex pane, now says which model, effort and mode the agent runs on: one dim line after the session's start, e.g. 17:42:05 · model claude-opus-5-5 · effort high · mode bypassPermissions.

  • Source: the adapter's reply to session/new (also session/load and session/resume): config options model, effort, mode (by id, else by category: model, thought_level, mode), read as the adapter reports them, with no lookup and no workaround for claudeacp-9lf. modes.currentModeId gives the mode when no option does.
  • Later changes: config_option_update and current_mode_update write the line again with the new values, and nothing when the line is the same. A mode change used to write · mode X; with only a mode known it still does.
  • Fallback: a field the reply does not carry is taken from the adapter's --model / --effort argv, and for goose from GOOSE_PROVIDER (shown as provider) and GOOSE_MODEL. I made this per field, not only when the reply carries none of them, so a reply with modes alone still gets the model gc asked for. Easy to narrow if you want the stricter reading.
  • Placement: the line follows the gc started a session entry rather than the header itself: the header is written at adapter start, before the adapter has said anything.
  • Pane: no pane code changed; a · entry is already a dim one-line entry. A pane test pins it.
  • Goldens: the recorded streams' session/new replies carry modes, so the log and pane goldens each gain a · mode … line (8 files, one line each).
  • Only model, effort and mode show; fast does not.

Verified: go vet ./... and go test ./... -race pass; new tests in the renderer, settings, box (argv reaches the renderer; reply wins over argv) and pane; changelog check (changelog@v2, offline) prints valid=true. README's log section and a fragment (.changelog/acp-settings-line.md) are included.

Bead: rexcity-49in3

The acp box's log, and so its Rex pane, now says which model, effort and mode the agent runs on: one dim line after the session's start, e.g. `17:42:05 · model claude-opus-5-5 · effort high · mode bypassPermissions`. - **Source:** the adapter's reply to `session/new` (also `session/load` and `session/resume`): config options `model`, `effort`, `mode` (by `id`, else by `category`: `model`, `thought_level`, `mode`), read as the adapter reports them, with no lookup and no workaround for claudeacp-9lf. `modes.currentModeId` gives the mode when no option does. - **Later changes:** `config_option_update` and `current_mode_update` write the line again with the new values, and nothing when the line is the same. A mode change used to write `· mode X`; with only a mode known it still does. - **Fallback:** a field the reply does not carry is taken from the adapter's `--model` / `--effort` argv, and for `goose` from `GOOSE_PROVIDER` (shown as `provider`) and `GOOSE_MODEL`. I made this per field, not only when the reply carries none of them, so a reply with `modes` alone still gets the model gc asked for. Easy to narrow if you want the stricter reading. - **Placement:** the line follows the `gc started a session` entry rather than the header itself: the header is written at adapter start, before the adapter has said anything. - **Pane:** no pane code changed; a `· ` entry is already a dim one-line entry. A pane test pins it. - **Goldens:** the recorded streams' `session/new` replies carry `modes`, so the log and pane goldens each gain a `· mode …` line (8 files, one line each). - Only model, effort and mode show; `fast` does not. Verified: `go vet ./...` and `go test ./... -race` pass; new tests in the renderer, settings, box (argv reaches the renderer; reply wins over argv) and pane; changelog check (`changelog@v2`, offline) prints `valid=true`. README's log section and a fragment (`.changelog/acp-settings-line.md`) are included. Bead: rexcity-49in3
feat: the acp box's log says which model, effort and mode the agent runs on (rexcity-49in3)
All checks were successful
image / image (pull_request) Successful in 9s
test / changelog (pull_request) Successful in 4s
test / go (pull_request) Successful in 1m42s
789a5e1289
In a city where Workers run Sonnet, Reviewers Opus and the Goose trial Kimi, an acp agent's pane did not say which one it was showing: the header names the adapter and its pid, nothing of the model.

The renderer now follows the requests that open a session (session/new, load, resume) and, on the adapter's reply, writes one dim entry, "· model M · effort E · mode D", from the reply's config options (by id, else by category) and modes.currentModeId. The values are what the adapter reports, with no lookup of ids: claudeacp-9lf changes what it reports, and this does not wait for it. A config_option_update or current_mode_update writes the line again with the new values, and nothing when the line would be the same. The mode change entry is this line now; with only a mode known it reads as before ("· mode plan").

A field the reply does not carry is taken from what gc asked: --model and --effort of the adapter's argv, and for goose GOOSE_PROVIDER and GOOSE_MODEL from the env. This is per field, not only when the reply carries none: a reply with modes alone still gets the model gc asked for. The line follows the session's start entry, not the header, because the header is written before the adapter has said anything.

The pane needed no change: a "· " entry is already one dim line there. The recorded streams' goldens gain the mode line their session/new replies carry.

Validation: go vet and go test ./... -race pass; renderer, settings, box (argv wired to the renderer, reply over argv) and pane tests added; the changelog check prints valid=true.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
city-root-review approved these changes 2026-11-12 16:23:01 +00:00
Dismissed
city-root-review left a comment

Review of 789a5e1289 for rexcity-49in3. Checks of the head: success.

Verdict

pass

Findings

  • [minor] internal/acpbox/render.go:405 (settings.go:34): the fallback is per field, where item 3 of the bead says it applies "when the reply carries none of them". The description says so and why: a reply that carries modes alone still shows the model gc asked for. This is a superset of the bead's reading, and it never hides what the adapter reported, so it does not block. If the stricter reading is wanted, showSettings would use r.defaults only when r.reported is empty.
  • [minor] internal/acpbox/settings.go:106: --model --effort high (a flag with no value, followed by another flag) takes --effort as the model. gc always passes a value, so this is theoretical.

Verified

  • Read the work bead, the PR description, REVIEW.md of main (no AGENTS.md or CLAUDE.md), and all 624 lines of the diff.
  • Merge into origin/main (2ff3907): fast-forward, the branch is cut from main's tip; mergeable.
  • The argv fallback matches what gc really runs: the live acp processes are rexcity acp -- claudeacp --permission-mode dontAsk --effort high --model claude-sonnet-5-5 --settings …, and b.args is the argv after the adapter. startSettings runs in openLog's deferred function, before the renderer's goroutine starts, and so reads the final b.r with no race. The Goose command is rexcity acp -- goose acp, and the env fallback keys on the adapter's base name.
  • Renderer: session/new, load and resume are recorded by id, and a reply is read once. An error reply writes nothing. config_option_update (the ACP name, with configOptions) and current_mode_update write the line again only when it changes. The old · mode X output stays the same when only the mode is known. The tests cover each of these, and the pane test pins the line as dim under the header. The eight goldens each gain one line, as the recorded modes replies predict.
  • README's log section and the fragment .changelog/acp-settings-line.md (Added, Changed; level-3 headings only) are present.
  • With the city's variables removed (proved 0) on the merged tree: go vet ./..., GOOS=linux GOARCH=amd64 go vet ./..., go test ./... (all ok, packs included), and go test -race -count=1 ./internal/acpbox/: all pass.
  • Changelog check: changelog built from mikluko/changelog tag v2 (964604a), run as the validate action runs it (-base=origin/main -warn=missing-fragment): valid=true.
Review of 789a5e12896263757033222a772df629d8b9cb90 for rexcity-49in3. Checks of the head: success. ### Verdict pass ### Findings - [minor] internal/acpbox/render.go:405 (settings.go:34): the fallback is per field, where item 3 of the bead says it applies "when the reply carries none of them". The description says so and why: a reply that carries `modes` alone still shows the model gc asked for. This is a superset of the bead's reading, and it never hides what the adapter reported, so it does not block. If the stricter reading is wanted, `showSettings` would use `r.defaults` only when `r.reported` is empty. - [minor] internal/acpbox/settings.go:106: `--model --effort high` (a flag with no value, followed by another flag) takes `--effort` as the model. gc always passes a value, so this is theoretical. ### Verified - Read the work bead, the PR description, REVIEW.md of main (no AGENTS.md or CLAUDE.md), and all 624 lines of the diff. - Merge into origin/main (2ff3907): fast-forward, the branch is cut from main's tip; `mergeable`. - The argv fallback matches what gc really runs: the live acp processes are `rexcity acp -- claudeacp --permission-mode dontAsk --effort high --model claude-sonnet-5-5 --settings …`, and `b.args` is the argv after the adapter. `startSettings` runs in openLog's deferred function, before the renderer's goroutine starts, and so reads the final `b.r` with no race. The Goose command is `rexcity acp -- goose acp`, and the env fallback keys on the adapter's base name. - Renderer: session/new, load and resume are recorded by id, and a reply is read once. An error reply writes nothing. `config_option_update` (the ACP name, with `configOptions`) and `current_mode_update` write the line again only when it changes. The old `· mode X` output stays the same when only the mode is known. The tests cover each of these, and the pane test pins the line as dim under the header. The eight goldens each gain one line, as the recorded `modes` replies predict. - README's log section and the fragment `.changelog/acp-settings-line.md` (Added, Changed; level-3 headings only) are present. - With the city's variables removed (proved 0) on the merged tree: `go vet ./...`, `GOOS=linux GOARCH=amd64 go vet ./...`, `go test ./...` (all ok, packs included), and `go test -race -count=1 ./internal/acpbox/`: all pass. - Changelog check: `changelog` built from mikluko/changelog tag v2 (964604a), run as the validate action runs it (`-base=origin/main -warn=missing-fragment`): `valid=true`.
mikluko force-pushed worker/rexcity-49in3 from 789a5e1289
All checks were successful
image / image (pull_request) Successful in 9s
test / changelog (pull_request) Successful in 4s
test / go (pull_request) Successful in 1m42s
to 1f6e96b7e3
All checks were successful
test / changelog (pull_request) Successful in 4s
image / image (pull_request) Successful in 11s
test / go (pull_request) Successful in 1m50s
2026-11-12 16:35:09 +00:00
Compare
mikluko dismissed city-root-review's review 2026-11-12 16:35:09 +00:00
Reason:

New commits pushed, approval review dismissed automatically according to repository settings

city-root-review left a comment

Review of 1f6e96b7e3 for rexcity-49in3. Checks of the head: success.

Verdict

pass

Findings

  • [minor] internal/acpbox/render.go:405 (showSettings): the fallback to --model/--effort (and Goose's env) is per field, where the bead says "when the reply carries none of them". The description says so and offers to narrow it; it is a superset of the ask, and it never covers up what the adapter reports (a reported default or alias is shown as is, as the bead wants). Not blocking.
  • [minor] internal/acpbox/settings.go:106: --model followed directly by another flag (--model --effort high) takes the flag as the model. gc does not build argv that way. Not blocking.

Verified

  • The rebase: the head is one commit on top of main at 0104764 (rexcity#93), and merging it into main is a fast-forward. The three-dot diff touches only this feature and reverts nothing of #93. #93's control-character handling still applies to the new line: settings.line() cuts each value with clipTo, which maps control characters to their pictures and folds newlines, just as the old · mode X entry did with clip.
  • Read the whole diff (624 lines): settings.go (line, or, withOptions by id then category, startSettings from argv, and the Goose env), the renderer's session tracking (session/new, load, resume by id; an error reply writes nothing; a reply is read once), config_option_update and current_mode_update rewriting the line only when it changes, a new session always writing it, and the box setting defaults in openLog's defer, after the final renderer is in place and before the queue runs.
  • Against the bead: (1) the line follows the session's start, dim in the pane (pane_test.go pins it); (2) later updates write it again; (3) the argv and Goose env fallback is there; it renders what the adapter reports, with no workaround for claudeacp-9lf. Tests cover the renderer, settings, box (argv reaches the renderer, and the reply wins over argv) and pane, and the 8 goldens gain one · mode … line each. The README's log section is updated, the fragment .changelog/acp-settings-line.md is present, and the PR has a description.
  • Ran on the merged tree, without the city's variables: go vet ./... and GOOS=darwin GOARCH=arm64 go vet ./... are clean, and go test -race ./... passes in all packages. The changelog check, built from sarak.sh/mikluko/changelog v2.1.0 (the v2 tag), prints valid=true.
Review of 1f6e96b7e3182a0bf95f9ccab41b61275b51750a for rexcity-49in3. Checks of the head: success. ### Verdict pass ### Findings - [minor] internal/acpbox/render.go:405 (`showSettings`): the fallback to `--model`/`--effort` (and Goose's env) is per field, where the bead says "when the reply carries none of them". The description says so and offers to narrow it; it is a superset of the ask, and it never covers up what the adapter reports (a reported `default` or alias is shown as is, as the bead wants). Not blocking. - [minor] internal/acpbox/settings.go:106: `--model` followed directly by another flag (`--model --effort high`) takes the flag as the model. gc does not build argv that way. Not blocking. ### Verified - The rebase: the head is one commit on top of main at 0104764 (rexcity#93), and merging it into main is a fast-forward. The three-dot diff touches only this feature and reverts nothing of #93. #93's control-character handling still applies to the new line: `settings.line()` cuts each value with `clipTo`, which maps control characters to their pictures and folds newlines, just as the old `· mode X` entry did with `clip`. - Read the whole diff (624 lines): `settings.go` (line, or, withOptions by id then category, startSettings from argv, and the Goose env), the renderer's session tracking (`session/new`, `load`, `resume` by id; an error reply writes nothing; a reply is read once), `config_option_update` and `current_mode_update` rewriting the line only when it changes, a new session always writing it, and the box setting `defaults` in `openLog`'s defer, after the final renderer is in place and before the queue runs. - Against the bead: (1) the line follows the session's start, dim in the pane (`pane_test.go` pins it); (2) later updates write it again; (3) the argv and Goose env fallback is there; it renders what the adapter reports, with no workaround for claudeacp-9lf. Tests cover the renderer, settings, box (argv reaches the renderer, and the reply wins over argv) and pane, and the 8 goldens gain one `· mode …` line each. The README's log section is updated, the fragment `.changelog/acp-settings-line.md` is present, and the PR has a description. - Ran on the merged tree, without the city's variables: `go vet ./...` and `GOOS=darwin GOARCH=arm64 go vet ./...` are clean, and `go test -race ./...` passes in all packages. The changelog check, built from sarak.sh/mikluko/changelog v2.1.0 (the `v2` tag), prints `valid=true`.
Commenting is not possible because the repository is archived.
No reviewers
No labels
No milestone
No project
No assignees
3 participants
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
mikluko/rexcity!94
No description provided.