Use when measuring or improving agent quality and performance — set up evaluators, online monitoring, CI/CD quality gates, observability, or cost optimization. Triggers on: "evaluate my agent", "add evaluator", "measure quality", "quality gate", "run evals", "agent too slow", "why is it slow", "reduce latency", "set up observability", "CloudWatch dashboard", "how much does my agent cost", "cost optimization", "logs not showing up", "logs missing", "spans not found", "eval failing", "eval error", "dev traces", "local traces", "agentcore dev traces", "traces to CloudWatch". Not for debugging errors or crashes — use agents-debug. Slow but correct routes here; broken routes to debug.
$npx -y skills add aws/agent-toolkit-for-aws --skill agents-optimizeInstalls into the current project.
Run `npx skills use "https://github.com/aws/agent-toolkit-for-aws" --skill "aws/agent-toolkit-for-aws/agents-optimize"` and follow the generated skill instructions now. Read its complete output, redirecting it to a temporary file first if necessary. Resolve relative paths from the supporting-files directory it provides.
Use the skills in "https://github.com/aws/agent-toolkit-for-aws" that are relevant to the current task. Run `npx skills add "https://github.com/aws/agent-toolkit-for-aws"` and select the relevant skills, then follow their instructions.