fix(desktop): allow mentioning invocable external relay agents - #3472
Open
scoop wants to merge 1 commit into
Open
fix(desktop): allow mentioning invocable external relay agents#3472scoop wants to merge 1 commit into
scoop wants to merge 1 commit into
Conversation
Attested agents without a local managed-agent record were hard-dropped from mention candidates, so externally-hosted agents (relay directory, kind:10100) could not be mentioned by anyone — including their owner. Accept agents present in mentionableAgentPubkeys alongside managed ones. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01TS2Hjgy6RXd6TeaVi5oTLw Signed-off-by: Patrick Lenz <plenz@topmedia.de>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Attested agents (kind:0 with a valid NIP-OA
authtag) that have no local managed-agent record are hard-dropped from mention candidates inuseMentions—isAgentIdentityInManagedListonly passes non-agents and desktop-managed agents. Since managed-agent records are never minted from relay events (by design — no local secret), an externally-hosted agent can never be mentioned by anyone, including its owner, even when its kind:10100 directory entry makes it invocable for the current user.This surfaced the moment we added an NIP-OA owner attestation to a self-hosted buzz-acp agent: it went from mentionable (as a plain member) to invisible in the picker, while remaining a channel member and answering CLI-authored mentions fine.
Fix: accept candidates that are in
mentionableAgentPubkeys(relay-directory agents invocable for the current user — same setshouldHideAgentFromMentionsalready consults) alongside desktop-managed ones. Non-invocable directory agents stay hidden exactly as before.Related issue
None found — closest context is the kind:10100 invocability model in
agentAutocompleteEligibility.ts.Testing
tsc --noEmitcleanrespond_to=allowlist, kind:10100 published withrespond_to_allowlistcontaining the owner): before the patch the agent never appears in the mention picker; after the patch it autocompletes and mentions dispatch end-to-end (agent replies via the harness)desktop-release-buildrecipe) verified interactively on macOS🤖 Generated with Claude Code