Metadata-Version: 2.5
Name: deepagents-sbx
Version: 0.1.0
Summary: Docker Sandboxes (sbx) microVM sandbox backend for Deep Agents
Project-URL: Homepage, https://github.com/restuhaqza/deepagents-sbx
Project-URL: Repository, https://github.com/restuhaqza/deepagents-sbx
Project-URL: Issues, https://github.com/restuhaqza/deepagents-sbx/issues
Author: restuhaqza
License-Expression: MIT
License-File: LICENSE
Keywords: ai-agents,deepagents,docker-sandboxes,langchain,microvm,sandbox,sbx
Classifier: Development Status :: 3 - Alpha
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: 3.13
Classifier: Programming Language :: Python :: 3.14
Classifier: Topic :: Software Development :: Libraries :: Python Modules
Requires-Python: >=3.12
Requires-Dist: deepagents>=0.7.19
Provides-Extra: code
Requires-Dist: deepagents-code>=0.1.77; extra == 'code'
Provides-Extra: dev
Requires-Dist: deepagents-code>=0.1.77; extra == 'dev'
Requires-Dist: mypy>=1.11; extra == 'dev'
Requires-Dist: pytest-asyncio>=0.24; extra == 'dev'
Requires-Dist: pytest>=8; extra == 'dev'
Requires-Dist: ruff>=0.7; extra == 'dev'
Description-Content-Type: text/markdown

# deepagents-sbx (Python)

Docker Sandboxes (`sbx`) microVM sandbox backend for
[Deep Agents](https://github.com/langchain-ai/deepagents).

This package implements
[`BaseSandbox`](https://reference.langchain.com/python/deepagents/backends/sandbox/BaseSandbox)
on top of a Docker Sandboxes microVM — its own kernel plus a private Docker
daemon — so agents run arbitrary code behind a hard isolation boundary.

## Install

```bash
pip install deepagents-sbx            # backend only
pip install "deepagents-sbx[code]"    # + Deep Agents Code provider
```

Requires **Python 3.12+** and the free
[`sbx` CLI](https://docs.docker.com/ai/sandboxes/) installed and logged in
(`sbx login`).

## Use

```python
from deepagents import create_deep_agent
from deepagents_sbx import SbxSandbox

with SbxSandbox(memory="4g") as backend:          # creates + auto-removes
    agent = create_deep_agent(model="anthropic:...", backend=backend)
    agent.invoke({"messages": [{"role": "user", "content": "Run the test suite"}]})
```

Bind-mount a host project (mounted at the same absolute path inside the VM):

```python
with SbxSandbox(workspace="/path/to/project") as backend:
    ...
```

## Deep Agents Code

Installing the `code` extra registers the `sbx` provider:

```bash
dcode --sandbox sbx
```

See the [repository README](https://github.com/restuhaqza/deepagents-sbx) for
the full architecture, API mapping, and testing strategy.

## License

MIT
