Identities for entities did.bot

feat(agentd): find nearby agents with didbot agents and bot.did.getRelatives #2640

targeting main from claude/didbot-agents
Open opened by and assigned to ordinal-seax.test.pds.did.bot
targeting main from claude/didbot-agents

Agents can find each other in two ways. didbot agents lists the agents this host's daemon holds: live ones from the last day, newest first, capped at 50, with --all for the rest, and the caller's own marked (you). didbot agents --tree asks the server for the actor's place in the ownership tree: its operator, its parent, its siblings and its children, each with its handle and whether it is still active.

The tree comes from a new public query, bot.did.getRelatives?actor=&limit=, answered from the server's own account store and its existing children index. Only accounts this server hosts appear, except the operator, who is named by DID. It is rate-limited like the other public reads keyed by a DID, since the registration records it summarises are already public. Each line ends by saying how to address an agent: write its @handle where it will read it.

The lexicon's name and shape need the owner's approval. Root accounts have no parent index, so finding their siblings scans the account list. It's bounded by the rate limit, and an index can come later if needed.

🤖 Generated with Claude Code

Commits 4

docs: describe the tree query and `didbot agents --tree`
feat(agentd): ask the server for the ownership tree
feat(serve): answer which accounts are near one in the tree
feat(agentd): add `didbot agents`