Repository navigation
fix(agents): show native agent pictures in the Solo agent picker - #1258
Conversation
Native agents' pictures were dropped when the agent service projected identities into LocalAgent, so session.agentChoices had no avatar for them and the Solo follow-up assistant picker fell back to initials. Carry the picture through and use it as the choice avatar, preferring it over older legacy library artwork. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Signed-off-by: Salman Mohammed <smohammed@squareup.com>
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: fe40e536d7
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| /** Its profile picture, an HTTPS image URL. */ | ||
| picture?: string; |
There was a problem hiding this comment.
Update the documented artwork ownership
The canonical docs/agents.md contract still defines LocalAgents as containing only { pubkey, name, relayUrl, owner } and states that createAgentLibrary is the sole owner of agent artwork. This change makes picture part of that contract and lets native custody override library artwork, so leaving the documentation unchanged gives future consumers and cleanups incorrect ownership guidance. Update the LocalAgents schema and shared artwork precedence alongside this field.
AGENTS.md reference: AGENTS.md:L76-L79
Useful? React with 👍 / 👎.
…tars-missing-ed41d1
kalvinnchau
left a comment
There was a problem hiding this comment.
🤖 Review by Hobbes, Kalvin's AI agent.
No actionable regressions or security defects established in the five-file change. Independent reviews covered native picture propagation, picker consumers, refresh/cache invalidation, owner/relay filtering, URL handling and image sinks.
Reviewed fe40e53. Current head f29ac89 merges main; verified that its PR patches against merge base 330e60b are identical to the reviewed patches apart from hunk line numbers.
Non-blocking existing behavior: clearing a migrated agent's picture can retain inherited persona artwork in the picker (src/features/agents/choices.ts:126–127), while the Agents card shows initials. Making native picture authoritative even when absent would align the views but also remove fallback artwork from failed imports. This predates the change; source-traced, not runtime-reproduced.
Validation: git diff --check passed on the original reviewed candidate. Added tests were inspected but not executed. Package tests, typecheck, browser image rendering/fallback and native IPC were not run. Approval reflects source review, not end-to-end validation; full package checks and UI validation remain recommended before merge.
…ui-polish * buzz-app/main: fix(agents): show native agent pictures in the Solo agent picker (#1258) Signed-off-by: Taylor Ho <taylorkmho@gmail.com>
…lation * origin/main: (139 commits) feat(agents): let plugins read each agent's sessions (#1111) chore(deps): upgrade vitest to 5.0.4 (#1272) feat(plugins): reload folder plugins from the CLI (#1265) add channel shared sessions discovery and retrieval (#1254) polish Solo activity layout and fold previous steps (#1257) fix(agents): clarify model defaults and provider actions (#1177) fix(messages): stop the channel timeline jumping back when agents or search read old messages (#1256) Add Close other tabs to the tab menu (#1127) chore(deps): upgrade virtua to 0.53.5 and port its scroll patch (#1269) Auto-tag Berd drafts with a chosen default agent (#1139) test: delete styling, markup and call-count trivia tests (#1255) fix(hooks): preserve recovery ownership on lefthook 2.2.2 (#1174) fix(deps): upgrade vulnerable tls and editor dependencies (#1267) chore(terminal): upgrade xterm with compatible navigation (#1268) feat(goose): show goose and provider marks on agent cards (#1260) fix(agents): show native agent pictures in the Solo agent picker (#1258) test(agents): fix main typecheck — add effort to Goose fixture (#1262) fix(messages): reject unclaimed file and link drops app-wide (#1075) feat(channels): create and read system channels (#965) Refine message layout and bubble reading widths (#1218) ...


Problem
In the Solo tab, the Choose follow-up assistant picker showed initials for agents instead of their pictures. The Agents page showed those pictures correctly.
The picker reads avatars from
session.agentChoices. WhenAgentsService.local()turned native identities intoLocalAgent, it kept onlypubkey,name,relayUrlandowner, so thepicturewas dropped. After v1 agents were removed, the legacy library no longer supplies artwork for these agents, so the picker had no avatar to show.Change
LocalAgentgains an optionalpicture, andAgentsService.local()keeps it.createAgentChoicesuses a native agent'spictureas its choiceavatar. It takes priority over legacy library artwork, because native custody holds the current picture.Display still goes through
avatarMedia/avatarSource, so the existing HTTPS/data-URL validation is unchanged.Testing
choices.test.tscase: a native agent's picture becomes its avatar and wins over older library artwork; an agent with no picture gets no avatar. It fails without the fix.service.test.ts: thelocal()projection now keepspicture. It fails without the fix.vitest run src/features/agents/choices.test.ts src/features/agents/service.test.ts src/features/sessions/: 417 passed.tsc --noEmitand biome are clean.localAgentActivitynative fixture, given a pack picture. Before the fix the picker showed the initial "L"; after it, the picker showed the pack art.No browser journey was added. The unit tests cover the changed contract, and image rendering in
AgentChoiceis existing behavior.Remaining
🤖 Generated with Claude Code