원클릭으로
create-capability-agent
// Scaffold a new A2A capability agent with Python application, Dockerfile, requirements.txt, and CDK stack following the project's established patterns
// Scaffold a new A2A capability agent with Python application, Dockerfile, requirements.txt, and CDK stack following the project's established patterns
Scaffold a new local tool for the voice agent pipeline with capability-based registration, executor function, ToolDefinition, and tests
Run an ECS scaling validation test with parallel monitoring, baseline enforcement, and automated result documentation
Sets up Daily.co phone number and webhook for PSTN dial-in. Guides through API key verification, phone number purchase, pinless dial-in configuration, and secrets sync. Use after deploying infrastructure, when setting up a phone number, or when configuring dial-in.
Scaffolds a new A2A capability agent with Python application, Dockerfile, requirements.txt, and CDK stack. Use when adding a new remote tool or service that the voice agent discovers via CloudMap.
Scaffolds a new local tool for the voice agent pipeline with capability-based registration, executor function, and tests. Use when adding a tool that runs inside the voice agent container and may need transport or SIP session access.
Deploys optional A2A capability agents (Knowledge Base, CRM) that extend the voice agent with new skills. Explains the A2A architecture, enables the capability registry, deploys agent stacks, and verifies discovery. Use after the core deployment and Daily setup are complete.
| name | create-capability-agent |
| description | Scaffold a new A2A capability agent with Python application, Dockerfile, requirements.txt, and CDK stack following the project's established patterns |
Scaffold all the files needed for a new A2A capability agent in the voice agent platform. This includes:
backend/agents/{name}/main.py)backend/agents/{name}/requirements.txt)backend/agents/{name}/Dockerfile)infrastructure/src/stacks/{name}-agent-stack.ts)index.ts, instantiation in main.ts)Use this skill when you need to create a new capability agent that will be discovered via CloudMap and invoked over the A2A protocol by the voice agent.
Read docs/guides/adding-a-capability-agent.md for the complete developer guide. All templates below are derived from that guide and the shipped KB and CRM agent implementations.
Ask the user for:
inventory-agent). This becomes the directory name and CloudMap service name.@tool docstring, which is critical for LLM tool selection)mkdir -p backend/agents/{name}/tests/
Follow the template in docs/guides/adding-a-capability-agent.md (Step 2). Key requirements:
from strands.multiagent.a2a import A2AServer (NOT A2AStarletteApplication)from strands.models import BedrockModel (NOT from strands.models.bedrock)_get_task_private_ip() function (required boilerplate for Agent Card URL)@tool docstrings -- the voice agent's LLM uses these for tool selectiondict (JSON-serializable)DirectToolExecutor and swap it after creating the server:
server.request_handler.agent_executor = DirectToolExecutor(my_tool)
main(): pre-initialize boto3 clients and optionally probe the Strands agentBase dependencies (always required):
strands-agents[a2a]>=1.27.0
requests>=2.31.0
Add boto3>=1.34.0 if calling AWS services. Add cachetools>=5.3.0 if implementing result caching.
Also create requirements-test.txt for test dependencies:
-r requirements.txt
pytest>=8.0.0
pytest-asyncio>=0.23.0 # if using DirectToolExecutor or async tests
requests-mock>=1.11.0 # if the agent makes HTTP calls
Use the exact template from docs/guides/adding-a-capability-agent.md (Step 4). Critical requirements:
python:3.12-slimcurl (required for health check)appuser (non-root)/.well-known/agent-card.json (NOT /health)["python", "main.py"]Create infrastructure/src/stacks/{name}-agent-stack.ts following the template in docs/guides/adding-a-capability-agent.md (Step 5). Key patterns:
VoiceAgentConfig from ../configSSM_PARAMS from ../ssm-parametersCapabilityAgentConstruct from ../constructsssm.StringParameter.valueFromLookup (synth-time)ssm.StringParameter.valueForStringParameter (deploy-time)ecr_assets.DockerImageAsset with Platform.LINUX_AMD64CapabilityAgentConstruct with agent-specific configcontainerImage.repository.grantPull(agent.taskDefinition.executionRole!)Add export to infrastructure/src/stacks/index.ts:
export { MyAgentStack, MyAgentStackProps } from './{name}-agent-stack';
Add instantiation to infrastructure/src/main.ts:
const myAgentStack = new MyAgentStack(app, 'VoiceAgentMyAgent', {
env, config,
description: 'Voice Agent POC - My Capability Agent',
tags: { Project: config.projectName, Environment: config.environment, Phase: '<next>' },
});
myAgentStack.addDependency(ecsStack);
Current phases: KB agent = Phase 9, CRM agent = Phase 10. Use the next available phase number.
Create backend/agents/{name}/tests/__init__.py (empty) and backend/agents/{name}/tests/test_{name}.py.
Follow the patterns established by the existing agent tests:
backend/agents/crm-agent/tests/test_crm_client.py -- CRM client HTTP interactions (uses requests-mock)backend/agents/crm-agent/tests/test_tools.py -- Tool functions with mocked clientbackend/agents/knowledge-base-agent/tests/test_knowledge_base.py -- KB search tool + DirectToolExecutor (uses pytest-asyncio)Key patterns:
main.py (it reads env vars at module level)DirectToolExecutor tests, use @pytest.mark.asyncioRun tests:
cd backend/agents/{name} && pip install -r requirements-test.txt && pytest tests/ -v
Before finishing, verify all items from the checklist in docs/guides/adding-a-capability-agent.md:
_get_task_private_ip(), unique tool names, dict returns, Dockerfile health check, curl installed, non-root user, requests in requirements, strands-agents[a2a]>=1.27.0, ECR pull grant, ecsStack dependency.