AGENT SKILL

amq-remote

Let the owner reach this running agent from Buzz, on the phone or in Buzz Desktop. Use when the user types /amq-remote (Claude Code) or $amq-remote (Codex), /amq-remote --native, /amq-remote off, or /amq-remote status, or asks to control this session from Buzz. Not for AMQ messaging between agents (use amq-cli).

License 许可
Apache-2.0
最近更新
2026-11-11
Stars
★ 1.6k
Forks
468

01 前言 Front Matter

name
amq-remote
version
0.138.0
metadata
{ "compatibility": "claude-code, codex-cli", "short-description": "Reach this agent from Buzz" }
description
Let the owner reach this running agent from Buzz, on the phone or in Buzz Desktop. Use when the user types /amq-remote (Claude Code) or $amq-remote (Codex), /amq-remote --native, /amq-remote off, or /amq-remote status, or asks to control this session from Buzz. Not for AMQ messaging between agents (use amq-cli).

03 SKILL.md 正文

AMQ Remote

/amq-remote gives this session its own private Buzz channel. One Buzz agent per machine, "AMQ Remote @ <machine>", imported once, makes the channel, adds the owner and mentions them. The owner writes in that channel from the Buzz phone app or Buzz Desktop. Several sessions can be connected at once; each has its own channel. The same session connecting again gets its own channel back. A resumed session gets its channel back by itself unless the owner turned it off: a pi session within about 35 s; on macOS, a Claude mailbox seat started directly by amq coop exec claude within about 35 s; any other Claude session at its first approval dialog. A Codex session needs $amq-remote again. A different session never gets another session's channel. A session that already has its own Buzz agent keeps its DM.

In Codex the skill is invoked as $amq-remote (Codex does not register / commands for skills); the commands below are the same. Codex runs sandboxed: attach writes ~/.amq/remote, so the first attach may be refused until the user reruns it with approval — ask for that one approval, do not work around it.

  • Default (AMQ mailbox). Each message the owner writes in the channel (or DM) arrives as an AMQ message from buzz in this agent's inbox. This agent answers with amq reply --id <id>, and that reply is shown there. A reply with --kind status shows as progress; any other reply is the final answer. No Stop hook and no wake are needed. Noticing the message is this agent's own business (a wake, a built-in consumer, monitor, or the next drain).
  • --native. For a session that is not on AMQ: each message is typed into this exact conversation, and the harness's own final answer goes back. On Claude Code it needs the AMQ Stop hook.

Run the steps in order. When a step says to stop, show the user the command's own message. Do not work around a refusal.

/amq-remote (connect)

  1. Tools. Run command -v amq-remote amq-acp. If either is missing, tell the user to run brew install avivsinai/tap/amq, then stop.

  2. Connect.

    • Default: run amq-remote attach --self --json. It uses AM_ROOT and AM_ME. If it says this session is not an AMQ participant, offer --native.
    • --native: use $AM_ROOT when set, else $HOME/.amq/remote/root (create it private with (umask 077 && mkdir -p "$HOME/.amq/remote/root")). Run amq-remote attach --self --native --root "$ROOT" --json.
    • If it exits 6 and names amq-remote claude install-stop-hook (Claude Code with --native), tell the user this adds one Stop hook to ~/.claude/settings.json ($CLAUDE_CONFIG_DIR/settings.json when set); it always exits 0, and amq-remote claude uninstall-stop-hook removes it. Ask once, run it, then run the attach again.
    • Any other failure: show its message and stop.
  3. Tell the owner only what is still needed. The JSON has name, label, agent, helper, machine, draft, reused, agent_name when the session has its own agent, machine_name when there is a machine agent, and, when the machine agent serves the session, channel, channel_name, and channel_error and channel_retry when the channel is uncertain or failed, and approval_reviewer when a Codex thread runs Codex's automatic approvals reviewer. Attach already waited up to 15 s for the channel. Say "Connected: <label>." and then exactly one of, the first that applies:

    • agent is running: "DM <agent_name> in Buzz." Nothing else is needed.
    • agent is idle: "DM <agent_name> in Buzz; Buzz starts it on the next message."
    • machine is running and channel is active: "Open the <channel_name> channel in Buzz." Nothing else is needed.
    • machine is running and channel is creating: "Buzz is making the channel; it appears within a minute."
    • machine is not missing and the JSON has unproven: "The machine agent makes a channel only for a session proven live, and this session is not (<unproven>)."
    • machine is offline or idle and channel is uncertain or failed: "Start <machine_name> in Buzz Desktop (Agents, the agent, Start)." Then show the channel state and channel_error, and say that nothing is done about it while the machine agent is stopped.
    • channel is uncertain: "Buzz did not confirm the channel (<channel_error>). AMQ keeps looking for it and will not make a second one. If it never appears, run amq-remote channel reset <name>."
    • channel is failed: show channel_error, then "AMQ tries again in 10 minutes" when channel_retry is true, else "Run amq-remote channel reset <name>."
    • agent is offline and machine is missing: "DM <agent_name> first; if it does not answer within a minute, start it in Buzz Desktop (Agents, the agent, Start)."
    • machine is missing: this machine's one-time setup. Run amq-acp setup --machine --out "$HOME/Downloads/AMQ Remote machine.agent.json" once, and show its printed steps as they are (Buzz Desktop: Agents, then + then Import, pick that file, then Start, and turn on Auto-start). Every later session then gets its channel by itself.
    • machine is offline or idle: "Start <machine_name> in Buzz Desktop (Agents, the agent, Start); it then makes this session's channel." If the JSON has warning, show it too. If it has approval_reviewer, say: "Buzz gets no Codex approvals: Codex's automatic reviewer answers them (approvals_reviewer = <approval_reviewer>)." It is the owner's setting; do not change it.
  4. Claude Code only: the approval hook (default and --native, after a successful attach). Read approval_hook from the attach JSON: ok, missing, stale, disabled or unreadable. An older amq-remote gives no approval_hook: then run amq-remote doctor --json and use its hooks row for this session's settings file (approval: installed is ok, missing is missing; approval_form stale is stale), or with an even older doctor treat a native_capability failure that names the PermissionRequest hook as missing and anything else as ok.

    • ok: nothing to do.
    • disabled: say that this session's Claude settings set disableAllHooks, so approvals stay in the terminal unless a project or managed setting turns hooks on.
    • unreadable: say that the Claude settings file cannot be read, and that amq-remote doctor names it and the reason.
    • stale: say the installed hook is an older form, then run amq-remote claude install-approval-hook, which replaces only that entry. You may offer amq-remote doctor --fix as a question (it also installs the other hooks, the login service and the machine agent's import file); never run it without a yes.
    • missing: tell the user: "This adds one approval hook. The first approval dialog of each Claude Code session on this machine connects that session to its own Buzz channel, even one that never ran /amq-remote: an AMQ session gets its own binding (the mailbox one /amq-remote writes), any other session a native binding, where chat needs /amq-remote --native. Every dialog of the session then shows there; ✅ allows, ❌ denies, first answer wins. /amq-remote off stops it for that session, and amq-remote claude uninstall-approval-hook removes the hook." Ask once, then run amq-remote claude install-approval-hook.

    Codex needs no hook: its approvals reach Buzz only for a session on the Codex app-server (the --native Codex path below); a plain codex TUI session answers approvals in the terminal.

  5. Add one line for the carrier:

    • Default: "Buzz messages arrive in this agent's AMQ inbox. Stop in Buzz stops waiting; a delivered message may still be acted on."
    • Claude in mailbox mode: "In Buzz, a line starting with / is typed into the session like Remote Control; it waits while a dialog is open."
    • --native: "A message sent while this session is busy waits. Buzz Stop cannot interrupt a Claude turn."
    • Claude with the hook installed: "Every approval dialog of this session shows in its Buzz channel with its options. ✅ or ❌, or a reply with the option number, answers it. The first answer, in Buzz or in the terminal, wins."
    • Claude in a machine agent channel: "The channel also shows each turn this session finishes; type mirror off there, or run /amq-remote mirror off, to stop it."
    • Codex on the app-server: the same line, unless the JSON has approval_reviewer (then the reviewer line above replaces it). A plain codex TUI session: "Approvals stay in the terminal."

Codex with --native: attach needs CODEX_THREAD_ID and a thread loaded in the Codex app-server daemon. A session started with plain codex is not in the daemon; start it with codex app-server daemon start, then codex --remote unix://. Run amq-remote and amq-acp outside Codex's sandbox (request escalation): the sandbox blocks the daemon socket, and amq-acp setup writes files outside the workspace.

Answering a Buzz message (default mailbox)

A message from buzz with subject "Buzz DM" is the owner writing from Buzz, in this session's channel or its agent's DM. Do the work, then answer with amq reply --id <that message id>. Use --kind status for an interim update. Keep the final answer short; it is read in a chat.

An image the owner sent arrives as a line [image: <absolute path>]: open that file to see it. [image not attached: <reason>] means the image did not arrive; say so in the answer and ask the owner to send it again if it matters.

/amq-remote off

Run amq-remote detach --self and show its output. The session keeps running. Its channel stops taking messages now, and the machine agent then archives it; a session with its own agent has that agent archive itself, and its DM answers "Not connected". When this session connects again, the same channel or agent comes back.

/amq-remote mirror on|off|status

Run amq-remote mirror <on|off|status> --self and show its output. It is the same switch as typing mirror on or mirror off in the session's channel: while it is off, the machine agent posts no turn of this session, and turns that end while it is off are not posted later. Only a Claude, Codex or pi session the machine agent serves has a mirror.

/amq-remote status

Run amq-remote bindings and show its output. It lists the machine agent and each connected session as live or unknown with its own agent (running, idle, offline or missing) and its channel, prunes the sessions proven ended, and names, once, old per-session agents the owner should delete in Buzz Desktop.

Status line

amq-remote statusline prints 📡 buzz while this session is connected, 📡 buzz (mirror off) while its mirror is off, and nothing otherwise. It always exits 0, reads only the binding files, and --plain drops the emoji. AMQ never edits the user's statusLine setting; if the user asks for it, show them the line to add to their own Claude Code status-line script, where $input holds the JSON the script read from stdin:

seg=$(amq-remote statusline <<<"$input" 2>/dev/null); [ -n "$seg" ] && out+=" | $seg"

Any other harness that runs a command in its status line passes the session id: amq-remote statusline --session <id>.

Trust limits

The Buzz agent's identity belongs to Buzz Desktop. Its grant has no kind limit and no expiry. Archiving the agent does not invalidate a copied key and grant; only removing the agent's relay access does that. Buzz "owner only" also admits the owner's other agents. See the amq-acp README.

04 同仓库更多 Skills

hashgraph-online
hashgraph-online/awesome-codex-plugins

deja-search

deja-vu memory — search the user's past AI coding sessions with the deja CLI. Holds what they already settled and never wrote into the repo (naming rules, banned or already-tried tools, required checks before merge, preferred values, who owns what). Use before your first edit in a task, before you call a change done or ready to merge, before you recommend a tool, library, design or reviewer, before re-debugging an error that may already be solved, when they say 'didn't we fix this before', 'what did we decide about X' or 'I already have that', and before telling them something on this machine does not exist.

★ 1.6k
hashgraph-online
hashgraph-online/awesome-codex-plugins

deja-reflect

End-of-session reflection and memory curation with deja-vu. Review what was decided, what commands broke and what repaired them, and record durable project rules or decisions with deja remember so the next session starts with them.

★ 1.6k
hashgraph-online
hashgraph-online/awesome-codex-plugins

revid

Make, edit, export and post AI videos with Revid (revid.ai) through the Revid MCP server. Use whenever the user wants a short-form or long-form video made (from an idea, a script, a URL, an article, a PDF, a tweet, a product page, their own clips, or a song), wants to find what is going viral on TikTok, YouTube, Instagram or X before making something, wants to edit or re-export an existing Revid project, generate a standalone AI image or clip, make a series episode, or publish and schedule a finished video to connected social accounts. Covers setup (hosted MCP with OAuth, or an API key), the 36 tools, credits, polling and the rules for publishing. Routes to the more specific revid-* skills when one fits.

后端与接口图像与多媒体
★ 1.6k
hashgraph-online
hashgraph-online/awesome-codex-plugins

review-study

Review a QuestionPunk survey before launch for wording, answer choices, branching, and missing settings. Use for check my survey or review this draft before publishing.

★ 1.6k
hashgraph-online
hashgraph-online/awesome-codex-plugins

manage-study

Find QuestionPunk studies, check status, publish an explicitly requested draft, or retrieve its participant link. Use for find my survey, publish this study, or how many people responded.

★ 1.6k
hashgraph-online
hashgraph-online/awesome-codex-plugins

create-study

Create a saved QuestionPunk survey draft from a research brief or edit specified questions. Use for requests such as make a customer feedback survey or shorten my onboarding study.

★ 1.6k