Skip to main content
Build on the main Sandboxes jobs: agent execution, testing and evaluation, and data processing. The recipes below cover individual steps you can combine into those workflows. Each includes setup instructions, a complete program, expected output, and guidance for handling failures and saved state.

Prepare and reuse

Prepare once, reuse safely

Python SDK · Read the same prepared input in two independent runs.

Build and refresh a custom environment

CLI · Build an image, reuse it, and rebuild after a change.

Run and observe

Stream a build or test run

REST SSE · Watch test output, reconnect, and check the result.

Interact with a process

REST · Send two lines to a child and collect its response.

Generate and download a binary artifact

Python SDK · Download a gzip file and check its contents and digest.

Test and recover

Try two coding fixes

Python SDK · Compare two patches and continue from the passing one.

Verify with networking disabled

REST · Read prepared input in an operation with networking disabled.

Run a bounded evaluation batch

REST with Python · Separate passing tests, failing tests, and cancelled work.

Recover from a known-good image

Python SDK · Correct a failed check and retry from the saved image.

Framework integration status

The Mini-SWE-Agent adapter currently has an SDK compatibility issue: ContreeEnvironment uses removed configuration imports and an incompatible client interface. Its example stops with RuntimeError.
Use the recipes above to implement execution, file transfer, and state reuse directly. Before adopting the Mini-SWE-Agent adapter, check its integration page for a compatible adapter and SDK version pair. Start with Set up access, then read Execution lifecycle for the shared state model.