一键导入
a2a-agent-register
Register agents with LiteLLM A2A Gateway. Use when setting up new agents, updating agent capabilities, or configuring agent permissions.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Register agents with LiteLLM A2A Gateway. Use when setting up new agents, updating agent capabilities, or configuring agent permissions.
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
| name | a2a-agent-register |
| description | Register agents with LiteLLM A2A Gateway. Use when setting up new agents, updating agent capabilities, or configuring agent permissions. |
Register collective agents with the LiteLLM A2A gateway for standardized inter-agent communication.
# Environment
LITELLM_HOST="${LITELLM_HOST:-localhost}"
LITELLM_PORT="${LITELLM_PORT:-4000}"
LITELLM_MASTER_KEY="${LITELLM_MASTER_KEY:-}"
| Agent | A2A Name | Role | Skills |
|---|---|---|---|
| Steward | steward | Orchestrator | orchestrate, monitor-health |
| Triad | triad | Deliberation | deliberate, vote, ratify |
| Examiner | examiner | Questioner | question, probe-assumptions |
| Explorer | explorer | Intelligence | discover, scan, report |
| Sentinel | sentinel | Safety | review, flag-risks |
| Coder | coder | Implementation | implement, test, deploy |
# Register Steward
curl -X POST "http://${LITELLM_HOST}:${LITELLM_PORT}/key/generate" \
-H "Authorization: Bearer ${LITELLM_MASTER_KEY}" \
-H "Content-Type: application/json" \
-d '{
"key_alias": "a2a-steward",
"duration": "30d",
"agent": "steward",
"agent_permissions": ["a2a:send", "a2a:receive"]
}'
#!/bin/bash
# Register all collective agents
AGENTS=("steward" "triad" "examiner" "explorer" "sentinel" "coder")
for agent in "${AGENTS[@]}"; do
echo "Registering $agent..."
curl -X POST "http://${LITELLM_HOST}:${LITELLM_PORT}/key/generate" \
-H "Authorization: Bearer ${LITELLM_MASTER_KEY}" \
-H "Content-Type: application/json" \
-d "{
\"key_alias\": \"a2a-${agent}\",
\"duration\": \"30d\",
\"agent\": \"${agent}\",
\"agent_permissions\": [\"a2a:send\", \"a2a:receive\"]
}"
done
echo "All agents registered"
# List all registered agents
curl "http://${LITELLM_HOST}:${LITELLM_PORT}/agents" \
-H "Authorization: Bearer ${LITELLM_MASTER_KEY}"
Each agent has an A2A Agent Card:
{
"name": "steward",
"description": "Orchestrator of The Collective",
"url": "http://localhost:4000/a2a/steward",
"skills": [
{"id": "orchestrate", "name": "Orchestrate Collective"},
{"id": "monitor-health", "name": "Monitor Agent Health"}
],
"capabilities": {
"streaming": true,
"pushNotifications": true
}
}
from litellm import a2a_register_agent
# Register agent with LiteLLM
response = a2a_register_agent(
agent_name="steward",
agent_url="http://localhost:8000/a2a/steward",
metadata={
"role": "orchestrator",
"skills": ["orchestrate", "monitor-health"]
}
)
print(response)
# Check if agent is registered
curl "http://${LITELLM_HOST}:${LITELLM_PORT}/agents" | jq '.[] | select(.name=="steward")'
# Verify master key
curl "http://${LITELLM_HOST}:${LITELLM_PORT}/key/info" \
-H "Authorization: Bearer ${LITELLM_MASTER_KEY}"
Register agents to enable A2A communication.
Manages Redis cache TTLs for AgeMem working memory, calculating expiration times based on memory type, importance, access patterns, and Ebbinghaus decay.
Reviews and organizes memories, promoting episodic to semantic storage, archiving outdated information, and maintaining memory health. Use periodically or when memory optimization is needed.
Manages memory lifecycle operations including promotion from episodic to semantic, archiving outdated memories, and maintaining memory state transitions per AgeMem policy.
Discovers and maintains relationships between memories across tiers (episodic, semantic, procedural), enabling unified retrieval and knowledge graph navigation.
Calculates and assigns importance scores to memories based on content analysis, user signals, access patterns, and emotional salience. Use when adding new memories or re-evaluating existing ones.
Send agent-to-agent (A2A) messages via Redis pub/sub with optional ACP WebSocket delivery. Use when agents need to communicate, broadcast to the triad, or check agent health. Compatible with the npm OpenClaw gateway.