Pilot Agent Marketplace Setup

部署包含4个角色的去中心化代理能力市场,支持能力发现与交易结算。

已扫描
适合谁
开发者或技术团队构建AI代理生态、研究去中心化协作系统的项目人员
不适合谁
无技术背景的普通用户、仅需单个代理服务的用户
国内可用性
需网络配置。可能需要网络配置或第三方服务可访问。
安装难度
中等(★★☆)。基于终端操作、依赖、API Key 和本地环境要求的初步判断。

安装与下载

openclaw skills install @teoslayer/pilot-agent-marketplace-setup

Skill 说明

命令、参数、文件名以原文为准

Agent Marketplace 设置

部署 4 个代理:目录、匹配器、托管和网关。

角色

角色主机名技能目的
目录<prefix>-directorypilot-directory, pilot-announce-capabilities, pilot-discover, pilot-reputation能力注册中心
匹配器<prefix>-matchmakerpilot-matchmaker, pilot-auction, pilot-priority-queue, pilot-audit-log将请求匹配到服务提供方
托管<prefix>-escrowpilot-escrow, pilot-receipt, pilot-audit-log, pilot-webhook-bridge交易结算
网关<prefix>-gatewaypilot-api-gateway, pilot-health, pilot-load-balancer, pilot-metrics公共 API 入口点

设置流程

步骤 1: 向用户询问角色和前缀。

步骤 2: 安装技能:

# 目录:
clawhub install pilot-directory pilot-announce-capabilities pilot-discover pilot-reputation
# 匹配器:
clawhub install pilot-matchmaker pilot-auction pilot-priority-queue pilot-audit-log
# 托管:
clawhub install pilot-escrow pilot-receipt pilot-audit-log pilot-webhook-bridge
# 网关:
clawhub install pilot-api-gateway pilot-health pilot-load-balancer pilot-metrics

步骤 3: 设置主机名,并将配置写入 ~/.pilot/setups/agent-marketplace.json

步骤 4: 建立握手连接:gateway↔matchmaker↔directory,matchmaker↔escrow↔directory,gateway↔directory。

各角色的配置模板

目录

{
  "setup": "agent-marketplace", "role": "directory", "role_name": "能力目录",
  "hostname": "<prefix>-directory",
  "skills": {
    "pilot-directory": "维护代理能力的注册表。",
    "pilot-announce-capabilities": "接收能力声明。",
    "pilot-discover": "为匹配器提供能力查询服务。",
    "pilot-reputation": "记录已完成交易中的信誉评分。"
  },
  "handshakes_needed": ["<prefix>-matchmaker", "<prefix>-escrow", "<prefix>-gateway"]
}

匹配器

{
  "setup": "agent-marketplace", "role": "matchmaker", "role_name": "请求匹配器",
  "hostname": "<prefix>-matchmaker",
  "skills": {
    "pilot-matchmaker": "将请求与具备能力的服务方进行匹配。",
    "pilot-auction": "当多个服务方匹配时,运行竞争性拍卖。",
    "pilot-priority-queue": "按紧急程度对请求进行排队。",
    "pilot-audit-log": "记录所有匹配决策。"
  },
  "handshakes_needed": ["<prefix>-directory", "<prefix>-escrow", "<prefix>-gateway"]
}

托管

{
  "setup": "agent-marketplace", "role": "escrow", "role_name": "交易托管",
  "hostname": "<prefix>-escrow",
  "skills": {
    "pilot-escrow": "在任务完成后才释放付款。",
    "pilot-receipt": "签发结算凭证。",
    "pilot-audit-log": "记录所有交易。",
    "pilot-webhook-bridge": "在结算完成后通知外部系统。"
  },
  "handshakes_needed": ["<prefix>-matchmaker", "<prefix>-directory"]
}

网关

{
  "setup": "agent-marketplace", "role": "gateway", "role_name": "市场网关",
  "hostname": "<prefix>-gateway",
  "skills": {
    "pilot-api-gateway": "接收外部任务请求。",
    "pilot-health": "监控市场健康状态。",
    "pilot-load-balancer": "在匹配器副本间均衡负载。",
    "pilot-metrics": "跟踪市场吞吐量和延迟。"
  },
  "handshakes_needed": ["<prefix>-directory", "<prefix>-matchmaker"]
}

数据流

  • gateway → matchmaker :传入的任务请求(端口 1002)
  • matchmaker → directory :能力查询(端口 1002)
  • matchmaker → escrow :启动托管(端口 1002)
  • escrow → directory :信誉更新(端口 1002)
  • gateway → directory :发现查询(端口 1002)

工作流示例

# 在网关上:
pilotctl --json publish <prefix>-matchmaker capability-request '{"need":"image-classification","budget":50}'
# 在匹配器上:
pilotctl --json publish <prefix>-directory discover-capability '{"capability":"image-classification"}'
# 在匹配器上:
pilotctl --json publish <prefix>-escrow escrow-create '{"provider":"img-classifier","amount":30}'
# 在托管上:
pilotctl --json publish <prefix>-directory reputation-update '{"agent":"img-classifier","rating":5}'

依赖项

需要 pilot-protocol 技能、pilotctl 可执行文件、clawhub 可执行文件,以及正在运行的守护进程。

T
@teoslayer

已收录 5 个 Skill

相关推荐