Skip to content
This repository was archived by the owner on Feb 5, 2026. It is now read-only.

Commit 95f1648

Browse files
Claude Code Sandboxclaude
andcommitted
docs: update SKILL.md with MCP tools as preferred path (KP-28)
- Add MCP Tools section as primary/fast path (~60ms) - Document all 5 MCP tools with examples - Add MCP setup instructions (pip install, config) - Move code generation to "Fallback" section - Update metadata tags to include mcp, low-latency, tool-calling Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 2e8ea07 commit 95f1648

1 file changed

Lines changed: 79 additions & 27 deletions

File tree

SKILL.md

Lines changed: 79 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,65 +1,112 @@
11
---
22
name: keep-protocol
3-
description: Signed Protobuf packets over TCP for AI agent-to-agent communication. Lightweight ed25519-authenticated protocol with discovery, routing, anti-spam fees, and memory sharing. Agents discover each other, coordinate tasks, and barter knowledge — no HTTP, no accounts, just keypairs.
4-
metadata: {"openclaw":{"emoji":"🦀","tags":["agent-coordination","protobuf","tcp","ed25519","moltbot","openclaw","swarm","intent","signing","decentralized","discovery","routing","barter"]}}
3+
description: Signed Protobuf packets over TCP for AI agent-to-agent communication. Now with MCP tools for sub-second latency! Lightweight ed25519-authenticated protocol with discovery, routing, and memory sharing.
4+
metadata: {"openclaw":{"emoji":"🦀","tags":["agent-coordination","protobuf","tcp","ed25519","mcp","low-latency","tool-calling","discovery","routing","barter"]}}
55
---
66

77
# keep-protocol
88

99
**Lightweight signed TCP + Protobuf protocol for agent coordination.**
1010

11-
Agents send `Packet`s to a TCP endpoint (default `localhost:9009` or relay).
11+
Agents send `Packet`s to a TCP endpoint (default `localhost:9009`).
1212
Unsigned or invalid sig = silent drop. Valid ed25519 sig = routed, logged, replied.
1313

14-
## Key Features
14+
## Preferred: MCP Tools (Fast Path)
1515

16-
- **ed25519 authentication** + integrity on every packet
17-
- **Agent discovery** — find who's online: `dst="discover:agents"`
18-
- **Agent-to-agent routing** — send directly: `dst="bot:alice"`
19-
- **Memory barter** — share knowledge via the `scar` field
20-
- **fee + ttl** for anti-spam economics
21-
- **Protobuf** for efficient, typed messages
16+
If your environment has keep-protocol MCP configured, use these tools directly for **sub-60ms latency**:
17+
18+
| Tool | Purpose |
19+
|------|---------|
20+
| `keep_send(dst, body)` | Send a signed packet to another agent |
21+
| `keep_discover(query)` | Get server info, stats, or agent list |
22+
| `keep_discover_agents()` | List all connected agent identities |
23+
| `keep_listen(timeout)` | Register and receive incoming messages |
24+
| `keep_ensure_server()` | Auto-start server if not running |
25+
26+
### MCP Examples
27+
28+
**Send a message to another agent:**
29+
```
30+
Use tool: keep_send
31+
dst: "bot:alice"
32+
body: "Hello from MCP!"
33+
```
34+
35+
**Discover connected agents:**
36+
```
37+
Use tool: keep_discover_agents
38+
Result: ["bot:alice", "bot:weather", "bot:planner"]
39+
```
40+
41+
**Get server info:**
42+
```
43+
Use tool: keep_discover
44+
query: "info"
45+
Result: {"version": "0.5.0", "agents_online": 3, "uptime_sec": 12345}
46+
```
47+
48+
This is **100x faster** than code generation (~60ms vs ~100s).
2249

23-
## Installation
50+
### MCP Setup
2451

2552
```bash
26-
docker run -d -p 9009:9009 ghcr.io/clcrawford-dev/keep-server:latest
53+
pip install keep-protocol[mcp]
2754
```
2855

29-
Python SDK: `pip install keep-protocol`
56+
Add to your MCP config:
57+
```json
58+
{
59+
"mcpServers": {
60+
"keep-protocol": {
61+
"command": "keep-mcp",
62+
"env": {
63+
"KEEP_HOST": "localhost",
64+
"KEEP_PORT": "9009",
65+
"KEEP_SRC": "bot:my-agent"
66+
}
67+
}
68+
}
69+
}
70+
```
3071

31-
## Discovery
72+
## Fallback: Code Generation
3273

33-
Find out what's running and who's connected:
74+
If MCP tools are not available, generate Python code using the SDK:
3475

35-
```text
36-
Use keep-protocol to discover agents: send signed Packet to localhost:9009 dst 'discover:agents' src 'bot:me'
76+
### Installation
77+
78+
```bash
79+
# Server (Docker)
80+
docker run -d -p 9009:9009 ghcr.io/clcrawford-dev/keep-server:latest
81+
82+
# Python SDK
83+
pip install keep-protocol
3784
```
3885

86+
### Discovery
87+
88+
Find out what's running and who's connected:
89+
3990
```python
4091
from keep import KeepClient
4192

4293
client = KeepClient("localhost", 9009)
43-
info = client.discover("info") # {"version": "0.3.0", "agents_online": 3, ...}
94+
info = client.discover("info") # {"version": "0.5.0", "agents_online": 3, ...}
4495
agents = client.discover_agents() # ["bot:alice", "bot:weather", ...]
4596
```
4697

47-
## Agent-to-Agent Routing
98+
### Agent-to-Agent Routing
4899

49100
Send messages directly to other connected agents:
50101

51-
```text
52-
Use keep-protocol to coordinate with another agent: dst 'bot:alice' body 'plan the sailing trip' src 'bot:me'
53-
```
54-
55102
```python
56103
with KeepClient(src="bot:planner") as client:
57104
client.send(body="register", dst="server", wait_reply=True)
58105
client.send(body="coordinate task", dst="bot:weather-agent")
59106
client.listen(lambda p: print(f"From {p.src}: {p.body}"), timeout=30)
60107
```
61108

62-
## Memory Barter
109+
### Memory Barter
63110

64111
Share institutional knowledge between agents using the `scar` field:
65112

@@ -71,10 +118,15 @@ client.send(
71118
)
72119
```
73120

74-
## MCP Integration
121+
## Key Features
75122

76-
Wrap keep-protocol as MCP tools for AI agent platforms.
77-
See `examples/mcp_keep_adapter.py` for tool definitions.
123+
- **ed25519 authentication** + integrity on every packet
124+
- **MCP tools** for sub-60ms latency (vs 100s+ with code gen)
125+
- **Agent discovery** — find who's online
126+
- **Agent-to-agent routing** — send directly to `bot:alice`
127+
- **Memory barter** — share knowledge via the `scar` field
128+
- **fee + ttl** for anti-spam economics
129+
- **Protobuf** for efficient, typed messages
78130

79131
**Repo:** https://github.com/CLCrawford-dev/keep-protocol
80132

0 commit comments

Comments
 (0)