Name | ipybox JSON |
Version |
0.6.6
JSON |
| download |
home_page | None |
Summary | Python code execution sandbox based on IPython and Docker |
upload_time | 2025-09-14 09:57:45 |
maintainer | None |
docs_url | None |
author | None |
requires_python | <3.14,>=3.11 |
license | None |
keywords |
|
VCS |
|
bugtrack_url |
|
requirements |
No requirements were recorded.
|
Travis-CI |
No Travis.
|
coveralls test coverage |
No coveralls.
|
# ipybox
mcp-name: io.github.gradion-ai/ipybox
<p align="left">
<a href="https://gradion-ai.github.io/ipybox/"><img alt="Website" src="https://img.shields.io/website?url=https%3A%2F%2Fgradion-ai.github.io%2Fipybox%2F&up_message=online&down_message=offline&label=docs"></a>
<a href="https://pypi.org/project/ipybox/"><img alt="PyPI - Version" src="https://img.shields.io/pypi/v/ipybox?color=blue"></a>
<a href="https://github.com/gradion-ai/ipybox/releases"><img alt="GitHub Release" src="https://img.shields.io/github/v/release/gradion-ai/ipybox"></a>
<a href="https://github.com/gradion-ai/ipybox/actions"><img alt="GitHub Actions Workflow Status" src="https://img.shields.io/github/actions/workflow/status/gradion-ai/ipybox/test.yml"></a>
<a href="https://github.com/gradion-ai/ipybox/blob/main/LICENSE"><img alt="GitHub License" src="https://img.shields.io/github/license/gradion-ai/ipybox?color=blueviolet"></a>
<a href="https://pypi.org/project/ipybox/"><img alt="PyPI - Python Version" src="https://img.shields.io/pypi/pyversions/ipybox"></a>
</p>
`ipybox` is a lightweight and secure Python code execution sandbox based on [IPython](https://ipython.org/) and [Docker](https://www.docker.com/). You can run it locally on your computer or remotely in an environment of your choice. `ipybox` is designed for AI agents that need to execute code safely e.g. for data analytics use cases or executing code actions like in [`freeact`](https://github.com/gradion-ai/freeact/) agents.
<a href="https://glama.ai/mcp/servers/@gradion-ai/ipybox">
<img width="380" height="200" src="https://glama.ai/mcp/servers/@gradion-ai/ipybox/badge" alt="ipybox MCP server" />
</a>
<p align="center">
<img src="docs/img/logo.png" alt="logo">
</p>
## Features
- Secure code execution inside Docker containers
- [Restrict network access](https://gradion-ai.github.io/ipybox/examples/#restrict-network-access) with a configurable firewall
- Stateful code execution with IPython kernels
- Stream code execution output as it is generated
- Install Python packages at build time or runtime
- Return plots generated with visualization libraries
- Exposes an [MCP server](https://gradion-ai.github.io/ipybox/mcp-server/) interface for AI agent integration
- [Invocation of MCP servers](https://gradion-ai.github.io/ipybox/mcp-client/) via generated client code
- Flexible deployment options, local or remote
- `asyncio` API for managing the execution environment
## Documentation
- [User Guide](https://gradion-ai.github.io/ipybox/)
- [API Docs](https://gradion-ai.github.io/ipybox/api/execution_container/)
## MCP server
`ipybox` can be installed as [MCP server](https://gradion-ai.github.io/ipybox/mcp-server/).
```json
{
"mcpServers": {
"ipybox": {
"command": "uvx",
"args": ["ipybox", "mcp"]
}
}
}
```
## Python example
Install `ipybox` Python package:
```bash
pip install ipybox
```
Execute code in an `ipybox` container:
```python
import asyncio
from ipybox import ExecutionClient, ExecutionContainer
async def main():
async with ExecutionContainer(tag="ghcr.io/gradion-ai/ipybox") as container:
async with ExecutionClient(port=container.executor_port) as client:
result = await client.execute("print('Hello, world!')")
print(f"Output: {result.text}")
if __name__ == "__main__":
asyncio.run(main())
```
Raw data
{
"_id": null,
"home_page": null,
"name": "ipybox",
"maintainer": null,
"docs_url": null,
"requires_python": "<3.14,>=3.11",
"maintainer_email": null,
"keywords": null,
"author": null,
"author_email": "Martin Krasser <martin@gradion.ai>, Christoph Stumpf <chris@gradion.ai>",
"download_url": "https://files.pythonhosted.org/packages/78/6f/98edd5feb39d52e8a3ce8d79ee85518eac13af3c109b4ac200e0ca22ca96/ipybox-0.6.6.tar.gz",
"platform": null,
"description": "# ipybox\n\nmcp-name: io.github.gradion-ai/ipybox\n\n<p align=\"left\">\n <a href=\"https://gradion-ai.github.io/ipybox/\"><img alt=\"Website\" src=\"https://img.shields.io/website?url=https%3A%2F%2Fgradion-ai.github.io%2Fipybox%2F&up_message=online&down_message=offline&label=docs\"></a>\n <a href=\"https://pypi.org/project/ipybox/\"><img alt=\"PyPI - Version\" src=\"https://img.shields.io/pypi/v/ipybox?color=blue\"></a>\n <a href=\"https://github.com/gradion-ai/ipybox/releases\"><img alt=\"GitHub Release\" src=\"https://img.shields.io/github/v/release/gradion-ai/ipybox\"></a>\n <a href=\"https://github.com/gradion-ai/ipybox/actions\"><img alt=\"GitHub Actions Workflow Status\" src=\"https://img.shields.io/github/actions/workflow/status/gradion-ai/ipybox/test.yml\"></a>\n <a href=\"https://github.com/gradion-ai/ipybox/blob/main/LICENSE\"><img alt=\"GitHub License\" src=\"https://img.shields.io/github/license/gradion-ai/ipybox?color=blueviolet\"></a>\n <a href=\"https://pypi.org/project/ipybox/\"><img alt=\"PyPI - Python Version\" src=\"https://img.shields.io/pypi/pyversions/ipybox\"></a>\n</p>\n\n`ipybox` is a lightweight and secure Python code execution sandbox based on [IPython](https://ipython.org/) and [Docker](https://www.docker.com/). You can run it locally on your computer or remotely in an environment of your choice. `ipybox` is designed for AI agents that need to execute code safely e.g. for data analytics use cases or executing code actions like in [`freeact`](https://github.com/gradion-ai/freeact/) agents.\n\n<a href=\"https://glama.ai/mcp/servers/@gradion-ai/ipybox\">\n <img width=\"380\" height=\"200\" src=\"https://glama.ai/mcp/servers/@gradion-ai/ipybox/badge\" alt=\"ipybox MCP server\" />\n</a>\n\n<p align=\"center\">\n <img src=\"docs/img/logo.png\" alt=\"logo\">\n</p>\n\n## Features\n\n- Secure code execution inside Docker containers\n- [Restrict network access](https://gradion-ai.github.io/ipybox/examples/#restrict-network-access) with a configurable firewall\n- Stateful code execution with IPython kernels\n- Stream code execution output as it is generated\n- Install Python packages at build time or runtime\n- Return plots generated with visualization libraries\n- Exposes an [MCP server](https://gradion-ai.github.io/ipybox/mcp-server/) interface for AI agent integration\n- [Invocation of MCP servers](https://gradion-ai.github.io/ipybox/mcp-client/) via generated client code\n- Flexible deployment options, local or remote\n- `asyncio` API for managing the execution environment\n\n## Documentation\n\n- [User Guide](https://gradion-ai.github.io/ipybox/)\n- [API Docs](https://gradion-ai.github.io/ipybox/api/execution_container/)\n\n## MCP server\n\n`ipybox` can be installed as [MCP server](https://gradion-ai.github.io/ipybox/mcp-server/).\n\n```json\n{\n \"mcpServers\": {\n \"ipybox\": {\n \"command\": \"uvx\",\n \"args\": [\"ipybox\", \"mcp\"]\n }\n }\n}\n```\n\n## Python example\n\nInstall `ipybox` Python package:\n\n```bash\npip install ipybox\n```\n\nExecute code in an `ipybox` container:\n\n```python\nimport asyncio\nfrom ipybox import ExecutionClient, ExecutionContainer\n\nasync def main():\n async with ExecutionContainer(tag=\"ghcr.io/gradion-ai/ipybox\") as container:\n async with ExecutionClient(port=container.executor_port) as client:\n result = await client.execute(\"print('Hello, world!')\")\n print(f\"Output: {result.text}\")\n\nif __name__ == \"__main__\":\n asyncio.run(main())\n```\n",
"bugtrack_url": null,
"license": null,
"summary": "Python code execution sandbox based on IPython and Docker",
"version": "0.6.6",
"project_urls": null,
"split_keywords": [],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "18d2adebf6bb66550441c5c20d0da12e5f9c094784f3ebdd5e4dda7227971c14",
"md5": "7d504d70d28492af885921cd42827349",
"sha256": "24d3843a50f1602c33df2cfc5fbd934eeb70684a591a7dc43ea8d72c5522ea09"
},
"downloads": -1,
"filename": "ipybox-0.6.6-py3-none-any.whl",
"has_sig": false,
"md5_digest": "7d504d70d28492af885921cd42827349",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.14,>=3.11",
"size": 31476,
"upload_time": "2025-09-14T09:57:43",
"upload_time_iso_8601": "2025-09-14T09:57:43.867569Z",
"url": "https://files.pythonhosted.org/packages/18/d2/adebf6bb66550441c5c20d0da12e5f9c094784f3ebdd5e4dda7227971c14/ipybox-0.6.6-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "786f98edd5feb39d52e8a3ce8d79ee85518eac13af3c109b4ac200e0ca22ca96",
"md5": "34f767a9b5996695ea08cb945aae301f",
"sha256": "a5c18962d0489667a2161eacc8dd0c2e8dd59f258bb0f08d32a8ae2b2e29a809"
},
"downloads": -1,
"filename": "ipybox-0.6.6.tar.gz",
"has_sig": false,
"md5_digest": "34f767a9b5996695ea08cb945aae301f",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "<3.14,>=3.11",
"size": 24364,
"upload_time": "2025-09-14T09:57:45",
"upload_time_iso_8601": "2025-09-14T09:57:45.454928Z",
"url": "https://files.pythonhosted.org/packages/78/6f/98edd5feb39d52e8a3ce8d79ee85518eac13af3c109b4ac200e0ca22ca96/ipybox-0.6.6.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-09-14 09:57:45",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "ipybox"
}