Strands Agents
You write the tools and the prompt; the model runs the loop and decides when it is finished
What is Strands Agents?
Strands Agents takes the opposite bet from the graph frameworks. You supply a system prompt and a handful of ordinary functions marked as tools, and the model decides which to call, in what order, and when to stop. A first agent is a few lines rather than a wiring diagram — and when a run goes somewhere odd there is no graph to point at, so you read the trace instead. Around that loop sit the pieces a long-running agent needs: hooks that fire at every step so you can log or refuse a tool call, conversation managers that trim or summarise history before it reaches the model's limit, and ways to hand one agent to another as a tool.
What can you do with Strands Agents?
- Turn a function into a tool with one decorator — Mark an ordinary function as a tool and the model can call it. The argument definition is generated from the type hints, so there is no separate schema to keep in step.
- Bring in tools from MCP servers — Point the agent at an MCP server and its tools sit alongside the ones you wrote, with no adapter code in between.
- Stop a tool call before it runs — Hooks fire at each stage of the loop, so you can record what is about to happen, rewrite the arguments, or refuse it outright.
- Keep a long conversation inside the window — Conversation managers drop or summarise older turns as the history grows, instead of letting a run fail once the model's input limit is reached.
- Let one agent call another — An agent can be handed to a second agent as a tool, or several can be run as a swarm that splits one task between them.
- See every decision as a trace — The loop emits OpenTelemetry spans, so the same tooling you already use for services shows which tools ran, in what order, and what they cost.
Before you choose Strands Agents
- The two languages are not at parity: the interrupt that pauses a run for a person's approval is documented for Python, with the TypeScript version listed as still to come.
- The defaults lean towards AWS — Amazon Bedrock is the assumed model provider and the deployment guides walk through Lambda, Fargate and EKS — although other providers and hosts are supported.
Frequently asked questions
Is Strands Agents free for commercial use?
Strands Agents is released under the Apache-2.0 licence — OSI-approved open source, which permits commercial use.
How can Strands Agents be deployed?
Strands Agents is available as Self-hosted / Runs locally.
Documentation
Reproduced from the strands-agents/harness-sdk README, published under Apache-2.0. Read the original ↗
Strands Agents is a simple yet powerful SDK that takes a model-driven approach to building and running AI agents. From simple conversational assistants to complex autonomous workflows, from local development to production deployment, Strands Agents scales with your needs.
This monorepo contains the Python SDK, TypeScript SDK, documentation site, and supporting packages:
| Directory | Description |
|---|---|
strands-py/ | Python SDK: agent loop, model providers, tools (PyPI · releases) |
strands-ts/ | TypeScript SDK: agent loop, model providers, tools (npm · releases) |
site/ | Source for the strandsagents.com documentation site (Astro/Starlight) |
team/ | Governance and cross-SDK process docs (tenets, decisions, PR & compatibility guidelines, and designs/ proposals) |
Why Strands
Build an agent harness. Control it end-to-end.
- Build your way. Any model, any cloud. Context management, execution limits, and observability built in before you write a line of config. Swap backends when you scale; your code stays the same.
- Model agnostic. First-class support for Amazon Bedrock, Anthropic, OpenAI, and Gemini, plus many more providers and custom ones.
- Stay in control. The agent loop traces every decision by default. Hooks let you intercept any step to log it, validate it, or redirect it.
- Deliver outcomes that work. Guardrails catch mistakes before they run. Steering handlers let agents correct themselves instead of failing silently.
MCP, streaming, multi-agent patterns, and structured output are all built in.
Quick Start
Both SDKs default to the Amazon Bedrock model provider, so you’ll need AWS credentials configured and model access enabled for Claude Sonnet. The Quickstart Guide covers configuring other providers (Anthropic, OpenAI, Gemini, Ollama, and more).
Python
Requires Python 3.10+:
pip install strands-agents strands-agents-tools
from strands import Agent
from strands_tools import calculator
agent = Agent(tools=[calculator])
agent("What is the square root of 1764")
The Python SDK README covers tools, model providers, MCP, and bidirectional streaming.
TypeScript
Requires Node.js 20+:
npm install @strands-agents/sdk
import { Agent } from '@strands-agents/sdk'
const agent = new Agent()
const result = await agent.invoke('What is the square root of 1764?')
console.log(result)
More in the TypeScript SDK README, including Zod-typed tools, structured output, and multi-agent patterns.
Documentation
For detailed guidance & examples, explore our documentation:
- User Guide
- Quick Start Guide
- Agent Loop
- Examples
- API Reference: Python · TypeScript
- Production & Deployment Guide
The docs themselves live in this monorepo under site/, and doc PRs are welcome alongside code changes.
Development
Git operations (commits, branches, PRs) are done from the repo root. Each package has its own toolchain:
Python SDK (strands-py/):
cd strands-py
pip install hatch
hatch test # run unit tests
hatch fmt # format & lint
TypeScript SDK (strands-ts/):
npm ci # install from repo root
npm run build # build
npm test # run unit tests
Documentation site (site/):
cd site
npm install
npm run dev # local dev server at http://localhost:4321/
Stay in touch with the team
Come meet the Strands team and other users on Discord
Security
See CONTRIBUTING for more information.