run_python_code_in_sandboxLABSCO SUMMARY
Code execution that is not on your laptop.
The value is the boundary: the model writes Python and it runs in a Modal sandbox, so what it produces is executed and returned without touching your filesystem — and the same account gives it FLUX image generation.
What it is
Two tools that execute on Modal rather than on your machine: Python in a sandboxed environment, and image generation with the FLUX model. Both run against the Modal account you are logged into.
What you get
- Python executed in a sandbox, off your own machine
- Images generated with the FLUX model
Requirements
A Modal account with the Modal CLI configured and logged in — the work runs on that account. UV launches it as uvx modal-mcp-toolbox, and any MCP-capable client will do.
Setup effort
One command — uvx modal-mcp-toolbox
USE CASES
Running code the model just wrote
Execute it in a sandbox and read the output, rather than pasting it into a terminal on your own machine.
Doing a calculation properly
Anything where the arithmetic or the parsing has to be exactly right goes through the interpreter instead of through the model's head.
Generating an image in the conversation
Ask for the picture and get it back from FLUX without leaving the client.
2 tools
Listed in project docs. Your client may show a different list.
generate_flux_imageBEFORE YOU INSTALL
What to know first
Tools you get
2 tools named in the project's documentation.
Requires
uvx on PATH
INSTALLATION
Connect your client
Server setup
Goose
uvx modal-mcp-toolboxMCP Clients
Claude Desktop
{
"mcpServers": {
"modal-toolbox": {
"command": "uvx",
"args": [
"modal-mcp-toolbox"
]
}
}
}