Configurable display names for agents and the operator #2

Open
polpot wants to merge 2 commits from polpot/chattr:agent-display-names into main
Contributor

Two related, optional, fully backward-compatible features for human-friendly names. Stable identity/routing keys are untouched throughout (registration, DM lookup, status hooks, sockets, message history, the /ws/operator endpoint) — these are display-only.

Agents — display_name

  • nullable agents.display_name column
  • POST /agents/register accepts optional display_name (COALESCE so a reconnect without it never wipes an existing label)
  • PATCH /agents/:name to set/clear it
  • plugin sends CHATTR_DISPLAY_NAME on register when set
  • UI renders "Display (handle)" with the handle as a muted suffix

Operator — configurable name

  • OPERATOR_NAME = import.meta.env.VITE_OPERATOR_NAME || "operator"; used for every operator display string (headers, DM/member labels, search, reaction tooltips). Defaults to "operator", so no behaviour change unless VITE_OPERATOR_NAME is set.

No pressure — merge or close as you like.

Two related, optional, fully backward-compatible features for human-friendly names. Stable identity/routing keys are untouched throughout (registration, DM lookup, status hooks, sockets, message history, the /ws/operator endpoint) — these are display-only. **Agents — display_name** - nullable `agents.display_name` column - `POST /agents/register` accepts optional `display_name` (COALESCE so a reconnect without it never wipes an existing label) - `PATCH /agents/:name` to set/clear it - plugin sends `CHATTR_DISPLAY_NAME` on register when set - UI renders "Display (handle)" with the handle as a muted suffix **Operator — configurable name** - `OPERATOR_NAME = import.meta.env.VITE_OPERATOR_NAME || "operator"`; used for every operator display string (headers, DM/member labels, search, reaction tooltips). Defaults to "operator", so no behaviour change unless `VITE_OPERATOR_NAME` is set. No pressure — merge or close as you like.
Agents can now carry a human-friendly display label separate from their
handle. `name` stays the stable identity/routing key (registration, DM
lookup, status, sockets, history are untouched); `display_name` is a
nullable label rendered as "Display (handle)" in the operator UI.

- schema: nullable agents.display_name
- POST /agents/register accepts optional display_name (COALESCE so a
  reconnect without it never clears an existing label)
- PATCH /agents/:name to set/clear it
- plugin sends CHATTR_DISPLAY_NAME on register when set
- UI shows the display name with the handle as a muted suffix

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
polpot changed title from Add optional display_name for agents to Configurable display names for agents and the operator 2026-06-09 00:55:24 +02:00
The human operator was hardcoded as "operator" throughout the UI. Add
OPERATOR_NAME = import.meta.env.VITE_OPERATOR_NAME || "operator" and use it
for every operator display string (message headers, DM/member labels,
search captions, reaction tooltips). Defaults to "operator" so behaviour is
unchanged unless VITE_OPERATOR_NAME is set. The /ws/operator endpoint and
internal identifiers are untouched — this is display-only.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This pull request can be merged automatically.
You are not authorized to merge this pull request.
View command line instructions

Checkout

From your project repository, check out a new branch and test the changes.
git fetch -u agent-display-names:polpot-agent-display-names
git switch polpot-agent-display-names

Merge

Merge the changes and update on Forgejo.

Warning: The "Autodetect manual merge" setting is not enabled for this repository, you will have to mark this pull request as manually merged afterwards.

git switch main
git merge --no-ff polpot-agent-display-names
git switch polpot-agent-display-names
git rebase main
git switch main
git merge --ff-only polpot-agent-display-names
git switch polpot-agent-display-names
git rebase main
git switch main
git merge --no-ff polpot-agent-display-names
git switch main
git merge --squash polpot-agent-display-names
git switch main
git merge --ff-only polpot-agent-display-names
git switch main
git merge polpot-agent-display-names
git push origin main
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
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: asbjornenge/chattr#2
No description provided.