Repository navigation
Make the Reach operator's display name configurable and fix Podman hosts - #149
Conversation
Fixed operational notices in the Discord edge hardcoded the bot name
"Nadir" and the model name "Qwen". A deployment with a differently named
bot, or a different model behind the conversation binding, showed users
the wrong names.
- Add `agent_display_name` to the Discord policy (default "Nadir"). It is
presentation only: excluded from the compiled Reach policy and its digest.
- Render every fixed notice through it, and say "the model" instead of
naming one.
- Admit an allowlisted DM whose uncached DMChannel has no recipient set.
Without a member cache discord.py leaves `recipient` empty, so every DM
was silently dropped; a non-bot author of a one-to-one DM is the
recipient by construction. A conflicting recipient is still refused.
- reach_operator: accept Podman's bare-hex `{{.Id}}` output alongside
Docker's `sha256:` form, and mount the bounded /tmp with `notmpcopyup`
under Podman so the Core image's own /tmp is not copied into it.
- reach_operator: give the edge build context fixed 0644/0755 modes. COPY
keeps them and the edge runs as the operator's UID, so under a private
umask (077) the image's source was unreadable and the import check failed.
|
Keeping |
zenithruneblade
left a comment
There was a problem hiding this comment.
Recording the maintainer’s approval to integrate this revision. The Primus naming follow-up is tracked in #153.
Returning this PR to draft so the author can mark it ready when they want it reviewed for merge. The follow-up remains in the conversation.
|
Updated this branch with the latest dev branch, and it should be good for the merge now. |
Change and scope
The Discord operator edge hardcodes the bot name "Nadir" and the model name "Qwen" in its fixed operational notices (refusals, timeouts, permission errors). Running the profile with a differently named bot, or a different model behind the conversation binding, shows users the wrong names.
agent_display_nameto the Discord policy, defaulting toNadir, so existing policies behave the same. It is presentation only: it is excluded from the compiled Reach policy and its digest and grants no identity or authority. Single-line printable text, at most 80 characters.DMChannelhas norecipient. Without a member cache discord.py builds the DM channel from the message alone and leavesrecipientunset, so every DM from an allowlisted user was silently dropped. A non-bot author of a one-to-oneDMChannelis the recipient by construction; a conflicting recipient is still refused, and the reply path still verifies the channel's recipients before sending.reach_operator.pyon Podman hosts:{{.Id}}as bare hex while Docker printssha256:…, sobuildrefused every Podman build withoperator_image_identity. Both forms are now accepted./tmpinto a--tmpfsmount by default. The Core check image keeps its uv cache in/tmp(~690 MB), which overflows the bounded 256 MB tmpfs, so the worker failed to start. The mount now usesnotmpcopyupunder Podman; Docker is unchanged.COPYkeeps those modes, while the edge runs as the operator's UID rather than the image's owner. Under a private umask (077) the edge's source was unreadable and the import check failed (No module named 'lychd.interface'). The copied context now gets fixed 0644/0755 modes.Not changed here: the conversation profile's model binding. #150 makes that configurable; the two are independent and merge cleanly in either order.
Verification
test_discord_policy.py); every notice renders the configured name and names no model (test_discord_live.py); uncached DM admission (test_nadir_dialogue.py); Podman tmpfs option, bare/prefixed image IDs and umask-independent build context (test_reach_operator.py).pytest tests/unit/interface tests/unit/cli tests/unit/compositionsagainst this branch and against unmodifieddev, both with--basetempoutside any Git checkout: identical failure set (15 failed in both, all intest_reach_portability.pyandtest_reach_research_image.py, which need the research container setup), 12 more passing here.ruff checkandruff format --checkclean on changed files.reach_probe.pyturn passed only after the three harness fixes.Documentation and delivery claims
docs/compositions/reach/operator.md: documentsagent_display_name.examples/reach/policy.toml: shows the setting with its default.Author review