Command Palette

Search for a command to run...

UnylyUnyly
Назад к скиллам

agent-protocol

БесплатноЗапускает вложенные скриптыНе проверен

Agent-to-agent communication protocol. Enables skills to communicate via events, build workflow chains, and orchestrate without human intervention.

modbenderот modbender★ 21 звезда на GitHub

Об этом скилле

Agent-to-Agent Protocol

A foundational communication layer for Clawdbot skills and agents.

Enable your agents to talk to each other, build automated workflows, and orchestrate complex multi-step tasks without human intervention.

Vision

Research-Agent finds article
    ↓ publishes "research.found"
Summary-Agent subscribes to events
    ↓ generates digest
    ↓ publishes "summary.ready"
Notification-Agent subscribes
    ↓ posts to Telegram/Discord

Architecture

1. Event Bus (File-based Message Passing)

  • Agents publish events to ~/.clawdbot/events/
  • Events are JSON files with schema validation
  • Persistent, debuggable, auditable
  • Automatic cleanup of processed events

2. Workflow Engine

  • Define pipelines in JSON or YAML
  • Conditional routing based on event data
  • Error handling, retries, fallbacks
  • Cron integration for scheduled execution

3. Shared Context

  • Agents read/write to shared memory space
  • Context passing between workflow steps
  • State persistence across agent invocations

4. Agent Registry

  • Discover available agents/skills
  • Capability advertisement
  • Permission management

Core Concepts

Events

Events are the fundamental unit of communication:

{
  "event_id": "evt_20260128_001",
  "event_type": "research.article_found",
  "timestamp": "2026-01-28T23:00:00Z",
  "source_agent": "research-agent",
  "payload": {
    "title": "ETH 2.0 Upgrade Complete",
    "url": "https://example.com/article",
    "importance": 9,
    "summary": "Major Ethereum upgrade..."
  },
  "metadata": {
    "session_id": "main",
    "requires_action": true
  }
}

Workflows

Workflows define how agents respond to events:

{
  "workflow_id": "research-to-telegram",
  "name": "Research → Summary → Notification",
  "trigger": {
    "event_type": "research.article_found",
    "conditions": {
      "payload.importance": { "gte": 7 }
    }
  },
  "steps": [
    {
      "agent": "summary-agent",
      "action": "summarize",
      "input": "{{payload}}",
      "output_event": "summary.ready"
    },
    {
      "agent": "notification-agent",
      "action": "notify",
      "input": "{{previous.summary}}",
      "channels": ["telegram"]
    }
  ]
}

Quick Start

1. Installation

cd /root/clawd/skills/agent-protocol
python3 scripts/setup.py

2. Start Event Bus

python3 scripts/event_bus.py start

3. Publish Your First Event

python3 scripts/publish.py \
  --type "test.hello" \
  --source "my-agent" \
  --payload '{"message": "Hello, world!"}'

4. Subscribe to Events

python3 scripts/subscribe.py \
  --types "test.hello" \
  --handler "./my_handler.py"

5. Define a Workflow

cp examples/simple-workflow.json config/workflows/my-workflow.json
python3 scripts/workflow_engine.py --validate

Event Types (Conventions)

Standard Event Types

  • research.article_found - Research agent found relevant content
  • research.topic_suggested - New research topic suggested
  • summary.ready - Summary generated
  • analytics.insight - Personal analytics insight
  • sports.goal_scored - Sports ticker goal event
  • sports.match_started - Match started
  • notification.sent - Notification delivered
  • workflow.started - Workflow execution started
  • workflow.completed - Workflow completed
  • workflow.failed - Workflow failed

Event Naming Convention

<domain>.<action_past_tense>

  • Use lowercase, underscores
  • Domain: broad category (research, sports, notification)
  • Action: what happened (article_found, goal_scored)

Workflow Examples

Example 1: Research → Notification

{
  "workflow_id": "eth-news-alert",
  "trigger": {
    "event_type": "research.article_found",
    "conditions": {
      "payload.keywords": { "contains": ["ethereum", "ETH"] },
      "payload.importance": { "gte": 8 }
    }
  },
  "steps": [
    {
      "agent": "notification-agent",
      "action": "send_telegram",
      "input": {
        "message": "🚨 Important ETH News!\n{{payload.title}}\n{{payload.url}}"
      }
    }
  ]
}

Example 2: Sports Goal → TTS Announcement

{
  "workflow_id": "goal-announcement",
  "trigger": {
    "event_type": "sports.goal_scored",
    "conditions": {
      "payload.team": { "eq": "Barcelona" }
    }
  },
  "steps": [
    {
      "agent": "tts-agent",
      "action": "announce",
      "input": {
        "text": "Goal for Barcelona! {{payload.scorer}} scores! {{payload.score}}"
      }
    }
  ]
}

Example 3: Daily Analytics → Research Topics

{
  "workflow_id": "analytics-to-research",
  "trigger": {
    "event_type": "analytics.daily_report",
    "schedule": "0 9 * * *"
  },
  "steps": [
    {
      "agent": "analytics-a
Полный SKILL.md на GitHub

Установить agent-protocol в Claude Code и Claude Desktop

Зарегайся, чтобы установить скилл

Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.

  • Открой команду установки в одну строку
  • Сохраняй скиллы в синхронизируемую библиотеку
  • Уведомления, когда скиллы обновляются
Зарегаться бесплатноУ меня уже есть аккаунт

Разрешённые инструменты

Инструменты, которые скиллу разрешено вызывать.

Без ограничений — скилл может использовать любой инструмент.

Вложенные файлы

DIAGRAMS.mdREADME.mdSUMMARY.mdTEST.mdconfig.example.jsonconfig/protocol.jsondocs/ARCHITECTURE.mddocs/INTEGRATION.mdexamples/conditional-workflow.jsonexamples/handler-example.pyexamples/integration-sports-ticker.pyexamples/multi-step-workflow.jsonexamples/simple-workflow.jsonexamples/sports-tts-workflow.jsonpackage.jsonscripts/__init__.pyscripts/event_bus.pyscripts/protocol.jsscripts/publish.pyscripts/setup.pyscripts/subscribe.pyscripts/workflow_engine.py

FAQ

Что делает скилл agent-protocol?

Agent-to-agent communication protocol. Enables skills to communicate via events, build workflow chains, and orchestrate without human intervention.

Как установить скилл agent-protocol?

Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.

Скилл agent-protocol запускает скрипты?

Да, скилл несёт исполняемые скрипты. Проверь исходник перед установкой.

Похожие скиллы

Сравнить agent-protocol с