DEV Community

Cover image for Strands Agents in Action: Making AI Practical and Tool-Aware
Girish Mukim
Girish Mukim

Posted on

Strands Agents in Action: Making AI Practical and Tool-Aware

In today’s world, AI is no longer just about generating text. It’s about taking action, making decisions, and bridging the gap between knowledge and execution. While large language models like those on Amazon Bedrock excel at understanding and generating language, they are limited to providing text-based responses. Strands Agents represent the next frontier: intelligent agents that combine the reasoning power of LLMs with the ability to interact with tools, systems, and data.

By embedding tool-awareness directly into the agent, Strands Agents empower developers to build applications that not only respond to queries but also perform meaningful work, whether that’s performing calculations, reading and writing files, or managing time-sensitive operations. They are a paradigm shift in how AI can act as a true assistant in real-world workflows, blending insight with action.

Architecture Overview

The architecture of a Strands Agent can be visualized as a three-step workflow:

User Query – The process starts when a user sends a request or question to the agent.

Strands Agent SDK – The SDK receives the query and decides how to handle it. It determines whether the LLM alone can answer the query or if a tool should be invoked.

LLM and Tools – If a tool is required (e.g., a calculator or file editor), the SDK calls it and integrates its output with the model’s reasoning.

Result from SDK – Finally, the combined response is returned to the user, often including both model reasoning and tool results in a coherent answer.

This architecture allows developers to build intelligent agents that can reason, compute, and act on external data, making Strands Agents a powerful extension of Amazon Bedrock LLMs or any other LLMs for that matter.

Theory isn't enough

Understanding the concepts behind Strands Agents is important, but real mastery comes from getting your hands dirty. In this section, we’ll guide Windows users through installing the Strands Agent SDK and its tools, so you can start building intelligent, tool-enabled applications right away.

Step 1: Install the packages

pip install strands-agents strands-agents-tools boto3

  • strands-agents → core framework
  • strands-agents-tools → optional tools (calculator, time, etc.)
  • boto3 → needed to connect to Amazon Bedrock

You can check strands-agents and strands-agents-tools version.

pip show strands-agents

Name: strands-agents
Version: 1.4.0
Summary: A model-driven approach to building AI agents in just a few lines of code
Home-page: https://github.com/strands-agents/sdk-python
Author:
Author-email: AWS <opensource@amazon.com>
License: Apache-2.0
Location: C:\Users\AppData\Roaming\Python\Python313\site-packages
Requires: boto3, botocore, docstring-parser, mcp, opentelemetry-api, opentelemetry-instrumentation-threading, opentelemetry-sdk, pydantic, typing-extensions, watchdog
Required-by: strands-agents-tools
Enter fullscreen mode Exit fullscreen mode

pip show strands-agents-tools

Name: strands-agents-tools
Version: 0.2.3
Summary: A collection of specialized tools for Strands Agents
Home-page: https://github.com/strands-agents/tools
Author:
Author-email: AWS <opensource@amazon.com>
License: Apache-2.0
Location: C:\Users\AppData\Roaming\Python\Python313\site-packages
Requires: aws-requests-auth, botocore, dill, markdownify, pillow, prompt-toolkit, pyjwt, readabilipy, rich, slack-bolt, strands-agents, sympy, tenacity, tzdata, watchdog
Required-by:
Enter fullscreen mode Exit fullscreen mode

Step 2: Create a minimal agent

File: agent_basic.py

from strands import Agent
from strands.models import BedrockModel

# Connect to Amazon Bedrock model (Nova Lite here, but you can use Claude/Sonnet/etc.)
model = BedrockModel(model_id="amazon.nova-lite-v1:0", region_name="us-east-1")

# Create an agent with ONLY the model (no tools yet)
agent = Agent(model=model)

# Send a simple question
response = agent("Hello! Can you introduce yourself in one line?")
print(response)

Enter fullscreen mode Exit fullscreen mode

Output

C:\Users\aws_strands_agent>agent_basic.py
Hello! I'm an AI designed to assist with a wide range of tasks, from answering questions to providing information and support.Hello! I'm an AI designed to assist with a wide range of tasks, from answering questions to providing information and support.
Enter fullscreen mode Exit fullscreen mode

This is the most basic working Strands Agent:

  • It calls Amazon Bedrock Nova Lite.
  • Responds to your input.
  • No multi-agent or tools yet.

Step 3: Add a simple tool

With preliminary testing out of the way, let's look at how tools can be used using Strands agent. We are still sticking to a single agent. No multi-agent audacious exploration as yet.

*File: agent_with_tool.py *

from strands import Agent
from strands.models import BedrockModel
from strands_tools import calculator

# Create Bedrock model
model = BedrockModel(
    model_id="amazon.nova-lite-v1:0",
    region_name="us-east-1"
)

# Create agent with calculator tool
system_prompt = """You are a simple, dedicated calculator. Your sole purpose is to perform mathematical calculations.

Instructions:
1.  Identify: Check if the user's input contains a clear mathematical operation or request for a calculation.
2.  Use Tool: If the input is a calculation, you must use the provided `calculator` tool to solve it. Do not perform the calculation yourself.
3.  Respond Directly: Your output must be the input from user and final numerical result of the calculation. Do not add any extra text, explanations, or conversational filler.
4.  Handle Non-Calculations: If the user's input is not a request for a calculation, you must respond with a single, polite message stating that you can only perform mathematical operations.
5.  Be Concise: Your responses should be as brief and to the point as possible."""

agent = Agent(model=model, system_prompt=system_prompt, tools=[calculator])

# Run the agent with event trace to get detailed results
result = agent("What is 23 * 17?")

# The result is an AgentResult object with 'final_output' and 'events' attributes

print("\n\nFinal Answer:", result)
Enter fullscreen mode Exit fullscreen mode

Output:

C:\Users\aws_strands_agent>agent_with_tool.py
<thinking>The user has requested a simple multiplication operation. I can use the calculator tool to perform this operation.</thinking>

Tool #1: calculator
23 * 17 = 391

Final Answer: 23 * 17 = 391
Enter fullscreen mode Exit fullscreen mode

Keep Strands Agent Library up-to-date

Strands Agents are evolving rapidly, with new features, tools, and bug fixes released frequently. To take full advantage of the latest capabilities, it’s important to keep your installation up-to-date.

Before upgrading, it’s useful to preview what changes an update would bring.

pip install strands-agents --upgrade --dry-run

Requirement already satisfied: strands-agents in c:\users\appdata\roaming\python\python313\site-packages (1.4.0)
Collecting strands-agents
  Downloading strands_agents-1.6.0-py3-none-any.whl.metadata (12 kB)
--
--
Downloading strands_agents-1.6.0-py3-none-any.whl (186 kB)
Would install strands-agents-1.6.0
Enter fullscreen mode Exit fullscreen mode

pip install strands-agents-tools --upgrade --dry-run

Requirement already satisfied: strands-agents-tools in c:\users\appdata\roaming\python\python313\site-packages (0.2.3)
Collecting strands-agents-tools
  Downloading strands_agents_tools-0.2.5-py3-none-any.whl.metadata (41 kB)
--
--
Downloading strands_agents_tools-0.2.5-py3-none-any.whl (277 kB)
Downloading aiohttp-3.12.15-cp313-cp313-win_amd64.whl (449 kB)
Downloading multidict-6.6.4-cp313-cp313-win_amd64.whl (45 kB)
Downloading yarl-1.20.1-cp313-cp313-win_amd64.whl (86 kB)
Downloading aiohappyeyeballs-2.6.1-py3-none-any.whl (15 kB)
Downloading aiosignal-1.4.0-py3-none-any.whl (7.5 kB)
Downloading frozenlist-1.7.0-cp313-cp313-win_amd64.whl (43 kB)
Downloading propcache-0.3.2-cp313-cp313-win_amd64.whl (40 kB)
Would install aiohappyeyeballs-2.6.1 aiohttp-3.12.15 aiosignal-1.4.0 frozenlist-1.7.0 multidict-6.6.4 propcache-0.3.2 strands-agents-tools-0.2.5 yarl-1.20.1
Enter fullscreen mode Exit fullscreen mode

These commands will show the latest version pip would install without actually upgrading.

You can quickly verify your currently installed versions.

pip show strands-agents | findstr Version
pip show strands-agents-tools | findstr Version

C:\Users\aws_strands_agent>pip show strands-agents | findstr Version
Version: 1.4.0

C:\Users\aws_strands_agent>pip show strands-agents-tools | findstr Version
Version: 0.2.3
Enter fullscreen mode Exit fullscreen mode

Now let's upgrade

pip install --upgrade strands-agents strands-agents-tools

Requirement already satisfied: strands-agents in c:\users\appdata\roaming\python\python313\site-packages (1.4.0)
Collecting strands-agents
  Using cached strands_agents-1.6.0-py3-none-any.whl.metadata (12 kB)
Requirement already satisfied: strands-agents-tools in c:\users\appdata\roaming\python\python313\site-packages (0.2.3)
Collecting strands-agents-tools
  Using cached strands_agents_tools-0.2.5-py3-none-any.whl.metadata (41 kB)
--
--
Installing collected packages: propcache, multidict, frozenlist, aiohappyeyeballs, yarl, aiosignal, aiohttp, strands-agents, strands-agents-tools
  Attempting uninstall: strands-agents
    Found existing installation: strands-agents 1.4.0
    Uninstalling strands-agents-1.4.0:
      Successfully uninstalled strands-agents-1.4.0
  Attempting uninstall: strands-agents-tools
    Found existing installation: strands-agents-tools 0.2.3
    Uninstalling strands-agents-tools-0.2.3:
      Successfully uninstalled strands-agents-tools-0.2.3
Successfully installed aiohappyeyeballs-2.6.1 aiohttp-3.12.15 aiosignal-1.4.0 frozenlist-1.7.0 multidict-6.6.4 propcache-0.3.2 strands-agents-1.6.0 strands-agents-tools-0.2.5 yarl-1.20.1
Enter fullscreen mode Exit fullscreen mode

Verify upgraded versions again -

C:\Users\aws_strands_agent>pip show strands-agents | findstr Version
Version: 1.6.0

C:\Users\aws_strands_agent>pip show strands-agents-tools | findstr Version
Version: 0.2.5
Enter fullscreen mode Exit fullscreen mode

Keeping the SDK current ensures you have access to the latest tools, bug fixes, and improvements. It also guarantees that your scripts leveraging events, tool calls, or advanced integrations will work as intended, without running into errors due to outdated APIs.

Additional Resources

To help you get the most out of Strands Agents, there are several resources that provide documentation, examples, and best practices. One of the most comprehensive references is the official Strands Agents examples page:

Strands Agents Examples – Explore ready-to-run scripts, sample agent configurations, and tool usage examples.
https://strandsagents.com/latest/documentation/docs/examples/

Closing Thoughts

Strands Agents aren’t just about AI that talks—they’re about AI that acts. By combining LLM reasoning with built-in tools, these agents can perform tasks, fetch data, and make your workflows smarter.

Don’t just read about it - try the SDK, experiment with the calculator, file, or time tools, and see how quickly you can turn ideas into action. Strands Agents make AI interactive, practical, and ready for real-world use.

For learning AWS cloud and AI, follow me on YouTube

Top comments (0)