Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
51 changes: 51 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,7 @@ Strands Agents Tools is a community-driven project that provides a powerful set
- 🐝 **Swarm Intelligence** - Coordinate multiple AI agents for parallel problem solving with shared memory
- 🔄 **Multiple tools in Parallel** - Call multiple other tools at the same time in parallel with Batch Tool
- 🔍 **Browser Tool** - Tool giving an agent access to perform automated actions on a browser (chromium)
- 📈 **Diagram** - Create AWS cloud diagrams, basic diagrams, or UML diagrams using python libraries

## 📦 Installation

Expand Down Expand Up @@ -128,6 +129,7 @@ Below is a comprehensive table of all available tools, how to use them with an a
| workflow | `agent.tool.workflow(action="create", name="data_pipeline", steps=[{"tool": "file_read"}, {"tool": "python_repl"}])` | Define, execute, and manage multi-step automated workflows |
| batch| `agent.tool.batch(invocations=[{"name": "current_time", "arguments": {"timezone": "Europe/London"}}, {"name": "stop", "arguments": {}}])` | Call multiple other tools in parallel. |
| browser | `browser = LocalChromiumBrowser(); agent = Agent(tools=[browser.browser])` | Web scraping, automated testing, form filling, web automation tasks |
| diagram | `agent.tool.diagram(diagram_type="cloud", nodes=[{"id": "s3", "type": "S3"}], edges=[])` | Create AWS cloud architecture diagrams, network diagrams, graphs, and UML diagrams (all 14 types) |

\* *These tools do not work on windows*

Expand Down Expand Up @@ -450,6 +452,55 @@ response = agent("discover available agents and send a greeting message")
# - send_message(message_text, target_agent_url) to communicate
```

### Diagram

```python
from strands import Agent
from strands_tools import diagram

agent = Agent(tools=[diagram])

# Create an AWS cloud architecture diagram
result = agent.tool.diagram(
diagram_type="cloud",
nodes=[
{"id": "users", "type": "Users", "label": "End Users"},
{"id": "cloudfront", "type": "CloudFront", "label": "CDN"},
{"id": "s3", "type": "S3", "label": "Static Assets"},
{"id": "api", "type": "APIGateway", "label": "API Gateway"},
{"id": "lambda", "type": "Lambda", "label": "Backend Service"}
],
edges=[
{"from": "users", "to": "cloudfront"},
{"from": "cloudfront", "to": "s3"},
{"from": "users", "to": "api"},
{"from": "api", "to": "lambda"}
],
title="Web Application Architecture"
)

# Create a UML class diagram
result = agent.tool.diagram(
diagram_type="class",
elements=[
{
"name": "User",
"attributes": ["+id: int", "-name: string", "#email: string"],
"methods": ["+login(): bool", "+logout(): void"]
},
{
"name": "Order",
"attributes": ["+id: int", "-items: List", "-total: float"],
"methods": ["+addItem(item): void", "+calculateTotal(): float"]
}
],
relationships=[
{"from": "User", "to": "Order", "type": "association", "multiplicity": "1..*"}
],
title="E-commerce Domain Model"
)
```

## 🌍 Environment Variables Configuration

Agents Tools provides extensive customization through environment variables. This allows you to configure tool behavior without modifying code, making it ideal for different environments (development, testing, production).
Expand Down
12 changes: 9 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -91,9 +91,15 @@ agent_core_code_interpreter = [
"bedrock-agentcore==0.1.0"
]
a2a_client = ["a2a-sdk[sql]>=0.2.11"]
diagram = [
"matplotlib>=3.5.0,<4.0.0",
"graphviz>=0.20.0,<1.0.0",
"networkx>=2.8.0,<4.0.0",
"diagrams>=0.23.0,<1.0.0",
]

[tool.hatch.envs.hatch-static-analysis]
features = ["mem0_memory", "local_chromium_browser", "agent_core_browser", "agent_core_code_interpreter", "a2a_client"]
features = ["mem0_memory", "local_chromium_browser", "agent_core_browser", "agent_core_code_interpreter", "a2a_client", "diagram"]
dependencies = [
"strands-agents>=1.0.0",
"mypy>=0.981,<1.0.0",
Expand All @@ -112,7 +118,7 @@ lint-check = [
lint-fix = ["ruff check --fix"]

[tool.hatch.envs.hatch-test]
features = ["mem0_memory", "local_chromium_browser", "agent_core_browser", "agent_core_code_interpreter", "a2a_client"]
features = ["mem0_memory", "local_chromium_browser", "agent_core_browser", "agent_core_code_interpreter", "a2a_client", "diagram"]
extra-dependencies = [
"moto>=5.1.0,<6.0.0",
"pytest>=8.0.0,<9.0.0",
Expand Down Expand Up @@ -196,4 +202,4 @@ name = "cz_conventional_commits"
tag_format = "v$version"
bump_message = "chore(release): bump version $current_version -> $new_version"
version_files = ["pyproject.toml:version"]
update_changelog_on_bump = true
update_changelog_on_bump = true
Loading
Loading