Token导航 LogoToken导航

Agent Skill · 研究检索

amq-cli(AMQ CLI 搜索)

amq-cli 用于查找、检索和筛选相关信息,适合在 Codex、Claude、Cursor、Gemini CLI 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

amq-cli 是研究检索类 Agent Skill,可用宿主为 Codex、Claude、Cursor、Gemini CLI,通过GitHub 仓库获取,权限为执行命令;许可证为 MIT,第三方扫描有未通过项,按安装量在研究检索类的 73,675 个 Skill 里排第 41,613。

总安装 1,152周安装 49GitHub Stars 48下载 404核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:amq-cli(AMQ CLI 搜索)
来源仓库:https://github.com/avivsinai/agent-message-queue
仓库路径:skills/amq-cli
安装命令:
npx skills add https://github.com/avivsinai/agent-message-queue --skill amq-cli
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/avivsinai/agent-message-queue --skill amq-cli

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

amq-cli 是基于文件的消息队列工具,专为 Agent 间协调通信而设计,管理对话而非任务计划。适用于消息路由、回复处理和生命周期事件传递等跨代理通信场景。需提前安装 amq 二进制文件并通过环境变量 AM_ROOT 和 AM_ME 配置路由树与身份。

安装后可通过 curl 脚本获取,但需注意消息错配风险,确保环境变量设置正确。amq-cli 属于研究检索类 Skill,可作为该场景下的辅助能力补充。

来源仓库内路径:skills/amq-cli

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 Codex、Claude、Cursor、Gemini CLI;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 npx skills add https://github.com/avivsinai/agent-message-queue --skill amq-cli;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要执行命令,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

amq-cli 怎么安装?

在终端执行 npx skills add https://github.com/avivsinai/agent-message-queue --skill amq-cli。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

amq-cli 支持哪些 AI 工具?

公开资料标注支持 Codex、Claude、Cursor、Gemini CLI。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

amq-cli 需要什么权限?

权限级别是执行命令。安装流程涉及命令执行,可能通过 npx skills add https://github.com/avivsinai/agent-message-queue --skill amq-cli;npx skills add avivsinai/agent-message-queue --skill "amq-cli" 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

amq-cli 是免费的吗?

来源标注的许可证是 MIT。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

amq-cli 用的人多吗?

公开数据是累计安装 1,152 次,近一周安装 49 次,下载 404 次,GitHub 48 星。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

amq-cli 安全吗?

第三方扫描有未通过项,风险较高。除非你确认过源码,否则不建议直接安装到常用环境。

值得选的地方和要先想清楚的地方

值得选的地方

  • 同时适配 4 种工具,换客户端不用重新找替代品。
  • 3 个目录同时收录,说明这个 Skill 流传比较广。
  • 许可证明确为 MIT,商用和分发边界好判断。

先想清楚的地方

  • 需要执行命令,装到常用环境前要先评估影响面。
  • 第三方扫描存在提醒项或未通过项,需要人工逐条确认。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 Codex,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。

不太适合

  • 不能接受 Skill 在你机器上执行命令的人。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
amq-cli

AMQ CLI 搜索 · 本页

1,15248执行命令MIT未通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

AMQ CLI Skill

File-based message queue for agent-to-agent coordination.

AMQ manages the conversation, not the task plan. Use it for messaging, routing, replies, and adapter-emitted lifecycle events; keep work decomposition and execution in the orchestrator above it.

Prerequisites

Requires amq binary in PATH. Install:

curl -fsSL https://raw.githubusercontent.com/avivsinai/agent-message-queue/main/scripts/install.sh | bash

Environment Rules

AMQ primarily uses two env vars for routing: AM_ROOT (which mailbox tree) and AM_ME (which agent). Getting these wrong means messages go to the wrong place or silently disappear, so it matters to let the CLI handle them rather than guessing.

Inside coop exec — everything is pre-configured. Just run bare commands:

amq send --to codex --body "hello"     # correct
amq send --me claude --to codex ...    # wrong — --me overrides the env
./amq send ...                         # wrong — use amq from PATH

The reason: coop exec sets AM_ROOT and AM_ME precisely for the session. Passing --me overrides the env, and passing --root intentionally overrides the current root (the CLI will note that on stderr if it differs from AM_ROOT). Prefer bare commands unless you mean to target a different root.

Outside coop exec — resolve the root from config, don't hardcode it:

eval "$(amq env --me claude)"          # reads .amqrc chain, sets both vars

# Or pin per-command without polluting the shell (useful in scripts):
AM_ME=claude AM_ROOT=$(amq env --json | jq -r .root) amq send --to codex --body "hello"

Why not hardcode? The root path depends on the config chain (project .amqrc → AMQ_GLOBAL_ROOT → ~/.amqrc). Hardcoding skips this and breaks when the project moves or config changes.

Global fallback: Orchestrator-spawned agents often start outside the repo root where no project .amqrc exists. Set AMQ_GLOBAL_ROOT or ~/.amqrc so amq env and amq doctor still resolve the correct queue.

Session pitfall: coop exec defaults to --session collab (i.e., .agent-mail/collab). Outside coop exec, the base root is .agent-mail (no session suffix). These are different mailbox trees — don't mix them up.

Root Resolution Truth-Table

ContextCommandAM_ROOT resolves to
Outside coop execamq env --me clauderesolved base root from project .amqrc, detected .agent-mail, AMQ_GLOBAL_ROOT, or ~/.amqrc
Outside coop exec, no project .amqrcamq env --me claudedetected .agent-mail in the current tree, otherwise AMQ_GLOBAL_ROOT or ~/.amqrc
Outside coop exec, isolated sessionamq env --session auth --me claude<resolved-base-root>/auth
Inside coop exec (no flags)automatic.agent-mail/collab (default session)
Inside coop exec --session Xautomatic.agent-mail/X

Task Routing

Before diving in, match the task to the right workflow — this avoids wasted effort:

Your taskWhat to do
"spec", "design with", "collaborative spec"Use /amq-spec instead — it has structured phase-by-phase guidance for parallel-research workflows.
Send a message, review request, questionUse amq send (see Messaging below)
Swarm / agent teamsRead references/swarm-mode.md, then use amq swarm
Received message with labels workflow:specFollow the spec skill protocol: do independent research first, then engage on the spec/<topic> thread — don't skip straight to implementation.

Quick Start

# One-time project setup
amq coop init

# Per-session (one command per terminal — defaults to --session collab)
amq coop exec claude -- --dangerously-skip-permissions  # Terminal 1
amq coop exec codex -- --dangerously-bypass-approvals-and-sandbox  # Terminal 2

Without --session or --root, coop exec defaults to --session collab.

Statusline (Claude Code)

To show the current AMQ session in your Claude Code status bar, add this snippet to your statusline script (e.g., ~/.claude/statusline.sh):

# AMQ session segment — try CLI first, fall back to env vars for older amq versions
amq_session=""
if _amq_out=$(amq env --session-name 2>/dev/null) && [ -n "$_amq_out" ]; then
    amq_session="$_amq_out"
elif [ -n "$AM_ROOT" ] && [ -n "$AM_BASE_ROOT" ] && [ "$AM_ROOT" != "$AM_BASE_ROOT" ]; then
    amq_session=$(basename "$AM_ROOT")
fi
if [ -n "$amq_session" ]; then
    output+=$(printf " | \033[33mamq:%s\033[0m" "$amq_session")
fi

amq env --session-name (v0.27+) prints the session name and exits 0 (empty when not in a session). The env-var fallback covers older versions. amq env --json also includes session_name.

To also set the terminal tab title (works in Ghostty, iTerm2, Terminal.app):

# Set tab title to "repo | amq:session" — re-asserts on each statusline refresh.
# Manual titles (e.g. Ghostty's prompt_tab_title) take priority and won't be overwritten.
tab_title="$repo_name"
[ -n "$amq_session" ] && tab_title+=" | amq:${amq_session}"
printf '\033]0;%s\007' "$tab_title" > /dev/tty 2>/dev/null

Integration & Ops Quick Reference

# Global fallback for orchestrator-spawned agents
export AMQ_GLOBAL_ROOT="$HOME/.agent-mail"

# Symphony hooks
amq integration symphony init --me codex
amq integration symphony emit --event after_run --me codex

# Cline Kanban bridge
amq integration kanban bridge --me codex
amq integration kanban bridge --me codex --workspace-id my-workspace

# Runtime diagnostics
amq doctor --ops
amq doctor --ops --json

Delivery Receipts

AMQ records delivery outcomes in consumer-local receipt files. The main stages are:

  • drained — a consumer successfully ingested the message
  • dlq — the message was moved to the dead letter queue during ingest

Use these when you need confirmation rather than just fire-and-forget messaging:

# Block on delivery for a single-recipient send
amq send --to codex --body "please review" --wait-for drained --wait-timeout 60s

# Query receipt history later
amq receipts list --me codex --msg-id <msg_id>
amq receipts wait --me codex --msg-id <msg_id> --stage drained --timeout 60s

amq read, amq drain, and amq monitor all apply the same strict header validation. Messages in inbox/new that are corrupt or have malformed headers are moved to DLQ and produce a dlq receipt.

Session Layout

By default, the root is .agent-mail (from .amqrc or auto-detect). Use --session to create isolated subdirectories:

.agent-mail/              ← default root (configurable in `.amqrc`)
.agent-mail/auth/         ← isolated session (via --session auth)
.agent-mail/api/          ← isolated session (via --session api)
  • amq coop exec claude → AM_ROOT=.agent-mail/collab (default session)
  • amq coop exec --session auth claude → AM_ROOT=.agent-mail/auth

The main env vars are AM_ROOT (where) + AM_ME (who). coop exec may also set AM_BASE_ROOT for cross-session resolution. The CLI enforces correct routing — just run amq commands as-is. Default .agent-mail/<session> layouts are recognized even without .amqrc; custom root names still need config or explicit flags/env.

Cross-Project Routing

Send messages to agents in other projects via --project or inline @project:session syntax. Requires peer configuration in .amqrc.

When to use --session vs --project: --session = same project, different session. --project = different project. Change one dimension at a time.

Peer setup

Add project and peers to your .amqrc:

{
  "root": ".agent-mail",
  "project": "my-project",
  "peers": {
    "infra-lib": "/Users/me/projects/infra-lib/.agent-mail"
  }
}

Both projects must register each other as peers for round-trip messaging.

Sending cross-project

# Flag syntax
amq send --to codex --project infra-lib --body "hello from here"

# Inline syntax (terser)
amq send --to codex@infra-lib:collab --body "inline syntax"

# Same session name as source (default when --session omitted)
amq send --to codex --project infra-lib --body "delivers to same session"

Replies route automatically

When you receive a cross-project message, reply_project is set in the header. amq reply routes back automatically — no --project flag needed:

amq reply --id <msg_id> --body "got it"  # routes back via reply_project

Thread naming

  • Same project P2P: p2p/claude__codex
  • Cross-project P2P: p2p/projA:collab:claude__projB:collab:codex
  • Topical (cross-project): use same thread ID across projects, e.g., decision/release-v0.24

For full details, see references/cross-project.md.

Cross-project identity (IMPORTANT)

When you receive a message where from matches your own handle (e.g., from: "claude" and you are claude), check from_project and reply_project. If either is present and names a different project, this is NOT an echo — it is a legitimate cross-project message from a different agent instance with the same handle. Process it normally.

AM_ROOT scoping after cross-project sends

After sending a cross-project message (via --project), your AM_ROOT still points to YOUR project. To send to your own partner (same project), use plain amq send --to codex — do NOT use --project. The --project flag is ONLY for sending to agents in OTHER projects.

Decision Threads

Decentralized decision protocol using existing AMQ primitives (no new CLI commands).

  • Thread: decision/<topic>
  • Kind: decision for all messages
  • Labels: decision:proposal, decision:objection, decision:support, decision:final; plus project:<name> for cross-project decisions
  • Context on proposals: {"proposal_id": "...", "question": "...", "options": [...], "required_projects": [...], "deadline": "..."}

Process: Propose → Review/Object → Resolve objections → Close when all required projects responded and no unresolved blocking objections.

amq send --to codex --project infra-lib --kind decision \
  --labels "decision:proposal,project:my-project,project:infra-lib" \
  --thread "decision/api-v2" \
  --context '{"proposal_id":"api-v2","question":"Adopt new API?","required_projects":["my-project","infra-lib"]}' \
  --body "Proposal: migrate to API v2. All tests green."

Session-Aware Routing

Users refer to sessions using many words: "session", "stream", "squad", "team", "workspace", "channel", or just a bare name. When the user mentions sending to or talking to an agent in a named context (e.g., "ask codex on stream1", "send to the auth team", "talk to codex in squad-api"), you must discover sessions before routing.

Important: Do not confuse sessions with projects. "Project" in AMQ means a different repo/codebase (cross-project routing via --project). Sessions are isolated mailbox trees within the same project (via --session). If the user says "the infra project", that likely means --project infra, not --session infra.

# Step 1: Discover active sessions and agents
amq who --json
# Returns: [{"name":"collab","agents":[...]},{"name":"stream1","agents":[...]},{"name":"auth","agents":[...]}]

# Step 2: Match the user's name against session names in the output, then send
amq send --to codex --session stream1 --body "Message for stream1"

Recognition patterns — any of these mean "route to a specific session":

  • Explicit: "on stream1", "via auth", "in the api session", "the infra squad"
  • Bare name: user just says "stream1" or "auth" — could be a session or an agent handle
  • Colloquial: "team", "squad", "stream", "workspace", "channel" followed by a name

Note: The agent@name inline syntax (e.g., codex@infra) is for cross-project routing, not cross-session. For same-project session routing, always use --session <name> explicitly.

Rules:

  1. When the user names something that could be a session, always run amq who --json first to check if it matches a known session name
  2. If the name matches a session, use --session <name> on the send command
  3. If it matches both a session and an agent handle, prefer the session interpretation when the user's phrasing implies a group/context ("on X", "in X", "the X team"), and the agent interpretation when it implies a person ("ask X", "tell X")
  4. If the target session differs from your current session ($AM_ROOT basename), use --session <name>
  5. Never guess — if the name doesn't appear in amq who --json output, tell the user (it may need coop exec --session <name> to initialize)
  6. For cross-project routing (different repo), use --project instead — see Cross-Project Routing section

Messaging

amq send --to codex --body "Message"              # Send (uses AM_ROOT/AM_ME from env)
amq drain --include-body                          # Receive (one-shot, silent when empty)
amq reply --id <msg_id> --body "Response"          # Reply in thread
amq watch --timeout 60s                           # Block until message arrives
amq list --new                                    # Peek without side effects

Send with metadata

amq send --to codex --subject "Review" --kind review_request --body @file.md
amq send --to codex --priority urgent --kind question --body "Blocked on API"
amq send --to codex --labels "bug,parser" --context '{"paths": ["src/"]}' --body "Found issue"

Send file paths, not file contents. When attaching source code, configs, or large text for review, send the file path in the message body, not the contents inline. The receiver can open the file with their local tools. If the receiver cannot access that worktree, send a short diff instead of the full source.

Filter

amq list --new --priority urgent
amq list --new --from codex --kind review_request
amq list --new --label bug

Priority Handling

PriorityAction
urgentInterrupt current work, respond now
normalAdd to TODOs, respond after current task
lowBatch for session end

Message Kinds

KindReply KindDefault Priority
review_requestreview_responsenormal
questionanswernormal
decision—normal
todo—normal
status—low
brainstorm—low

References

For detailed protocols, read the reference file FIRST, then follow its instructions:

平台分布

Claude Code

27.38%
按下载量换算111

Codex

23.35%
按下载量换算94

OpenCode

17.07%
按下载量换算69

Antigravity

14.24%
按下载量换算58

Gemini CLI

7.63%
按下载量换算31

windsurf

3.33%
按下载量换算13

安全审计

Gen Agent Trust Hub

未通过

Socket

通过

Snyk

未通过

权限和风险

执行命令

安装流程涉及命令执行,可能通过 npx skills add https://github.com/avivsinai/agent-message-queue --skill amq-cli;npx skills add avivsinai/agent-message-queue --skill "amq-cli" 联网下载 Skill 或依赖。用户安装前应确认命令来源、仓库内容和执行环境。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在提醒或未通过项,安装前请自行复核。

继续浏览同类 Skills