# ipybox

A unified, sandboxable execution environment that runs Python code, shell commands and programmatic MCP tool calls together in a stateful IPython kernel.

ipybox executes code blocks containing any mix of Python code, shell commands and programmatic MCP tool calls inside a stateful IPython kernel. Kernels can be sandboxed with filesystem and network restrictions enforced at the OS level, and it generates Python APIs for MCP server tools automatically, so those tools can be called like ordinary functions from code.

It supports application-level approval of individual tool calls and shell commands during execution, and runs locally, giving code protected access to local data and tools rather than routing everything through a remote sandbox. This is a complete rewrite; the previous generation is maintained on an older branch.

It is a general-purpose building block: the Freeact agent is one example of a general-purpose agent built on top of it.

Website: https://gradion-ai.github.io/ipybox/
