deepagents-contrib-aws
AWS backend implementations for the deepagents framework.
Installation
pip install deepagents-contrib-aws
This installs both backends (S3Backend and AgentCoreCodeInterpreterSandbox) and all dependencies.
Backends
| Backend | Protocol | Description | Docs |
|---|---|---|---|
| S3Backend | BackendProtocol |
Persists agent workspace files in Amazon S3. Supports ls, read, write, edit, grep, glob, upload_files, download_files. |
docs/s3-backend.md |
| AgentCoreCodeInterpreterSandbox | SandboxBackendProtocol |
Executes Python and shell commands in a managed cloud sandbox via Amazon Bedrock AgentCore Code Interpreter. Native file upload/download. | docs/agentcore-sandbox.md |
Quick Examples
S3Backend
from deepagents_contrib_aws import S3Backend
backend = S3Backend(bucket="my-bucket", prefix="agent/workspace/")
backend.write("/hello.py", "print('hello')")
content = backend.read("/hello.py")
Or configure from environment variables:
export S3_BACKEND_BUCKET=my-bucket
backend = S3Backend.from_env()
See docs/s3-backend.md for full usage, configuration reference, and all operations.
AgentCore Code Interpreter Sandbox
from deepagents_contrib_aws import AgentCoreCodeInterpreterSandbox
with AgentCoreCodeInterpreterSandbox(region_name="us-west-2") as sandbox:
# Python execution (variable state preserved across calls)
sandbox.execute('python3 -c "x = 42"')
result = sandbox.execute('python3 -c "print(x)"')
print(result.output) # "42"
# Shell commands
result = sandbox.execute("echo hello")
print(result.output) # "hello"
Or configure from environment variables:
export AGENTCORE_REGION=us-west-2
sandbox = AgentCoreCodeInterpreterSandbox.from_env()
See docs/agentcore-sandbox.md for full usage, file operations, session lifecycle, and configuration reference.
With deepagents
from deepagents import create_deep_agent
from deepagents_contrib_aws import S3Backend, AgentCoreCodeInterpreterSandbox
# File storage backend
backend = S3Backend.from_env()
agent = create_deep_agent(backend=backend)
# Code execution sandbox
sandbox = AgentCoreCodeInterpreterSandbox.from_env()
agent = create_deep_agent(backend=sandbox)
AWS Credentials
Both backends resolve credentials via the standard boto3 credential chain:
- Environment variables (
AWS_ACCESS_KEY_ID,AWS_SECRET_ACCESS_KEY,AWS_SESSION_TOKEN) - Shared credentials file (
~/.aws/credentials) - AWS SSO (
aws sso login) - IAM role (EC2, ECS, Lambda)
Examples
| Example | Description |
|---|---|
| Product Support Agent | A deep agent with 3 skills (electronics, healthcare, finance) using CompositeBackend — AgentCore for execution, S3 for storage. Fully self-contained with its own pyproject.toml. |
Each example is an independent project — cd into it, run uv sync, configure .env, and go. See the example's own README for setup instructions.
Development
See docs/development.md for setup, testing, linting, building, and contributing guidelines.
# Quick start
uv sync # install dependencies
uv run pytest # run unit tests (102 tests, no AWS credentials needed)
uv run ruff check . # lint
uv build # build package
License
MIT
Metadata
Release files for deepagents-contrib-aws 0.2.3
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| deepagents_contrib_aws-0.2.3.tar.gz | 2.2 MB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| deepagents_contrib_aws-0.2.3-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 2.2 MB
Release files / deepagents_contrib_aws-0.2.3.tar.gz
| Download URL | deepagents_contrib_aws-0.2.3.tar.gz |
|---|---|
| Size | 2.2 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
54bb75a9e1b38d411b19e9ed69436018e7ac914f53adc9344466b84d5c89e9c0
|
|
BLAKE2b-256 checksum How to use checksums |
26ad7ec1f2c7c2df7ab198ef60ccaa85bd66e47cd81313ef006d3472a7d6d64b
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.2
|
Release files / deepagents_contrib_aws-0.2.3-py3-none-any.whl
| Download URL | deepagents_contrib_aws-0.2.3-py3-none-any.whl |
|---|---|
| Size | 10.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7b773f8e54579af0d7b091d9ce93a7b873a0fae22eb1eea661b4280f63985a83
|
|
BLAKE2b-256 checksum How to use checksums |
2b3ea7823f2ceb007dfa632a5bc057548af60f989f6efc7dd4f7c2df1ec87f94
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.9.2
|
Security for deepagents-contrib-aws 0.2.3
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.