You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Mention autocomplete never offers remotely-hosted agents (shared relay agent eligibility is unreachable) #3971
Setup: An ACP agent hosted on machine A (via buzz-acp with NIP-OA owner attestation), and Buzz Desktop on machine B owned by the same user. The agent is a member of a shared channel, publishes a kind-0 profile, appears in the member list with the agent chip ("managed by you"), is registered in the relay agent directory, and advertises respond_to=anyone.
Bug: The @ mention autocomplete on machine B never offers the agent, so there is no way to send it a p-tag mention from the UI. The members panel shows it; the composer refuses to.
Root cause: In desktop/src/features/messages/lib/useMentions.ts, addCandidate drops any candidate flagged isAgent that is not in the local managed-agent list:
if (!isAgentIdentityInManagedList(candidate, managedAgentPubkeys)) {
return;
}
This runs beforeshouldHideAgentFromMentions, whose mentionableAgentPubkeys set (built from relayAgentIsSharedWithUser — directory agents with respond_to=anyone/allowlist sharing a channel) is meant to make exactly these agents mentionable. Because the earlier filter only consults the local list, that machinery is unreachable dead code for any agent hosted on another machine.
Suggested fix: let mentionable relay agents through the first filter:
if (
!isAgentIdentityInManagedList(candidate, managedAgentPubkeys) &&
!mentionableAgentPubkeys.has(pubkey)
) {
return;
}
Impact: Any multi-device / team setup where an agent runs on one machine and users chat from another. Current workarounds are thread replies (reply p-tags the parent author) or agent-side content-matching rules instead of real mentions.
Confirmed on a hosted community relay (0.5.x): a custom agent that is a channel member and shows in the members panel is never offered by the @ mention autocomplete on another user's machine — the user can only tag agents managed by their own desktop. Verified relay-side that the sent messages contained no p tag for the agent, so the mention never existed as far as delivery is concerned. CLI workaround (explicit --mention pubkey) produces a correct p tag, which then runs into #1743 if the agent's runtime is offline.
Activity
igor commentedon Jul 31, 2026
Confirmed on a hosted community relay (0.5.x): a custom agent that is a channel member and shows in the members panel is never offered by the @ mention autocomplete on another user's machine — the user can only tag agents managed by their own desktop. Verified relay-side that the sent messages contained no p tag for the agent, so the mention never existed as far as delivery is concerned. CLI workaround (explicit --mention pubkey) produces a correct p tag, which then runs into #1743 if the agent's runtime is offline.
fix(mobile): resolve hand-typed member mentions at send time
fix(mobile): resolve hand-typed member mentions at send time