Safe code execution. Branch from any checkpoint, explore paths in parallel, pick the winner. Built for agents that think ahead.
Think MCTS for code. Explore, evaluate, backtrack, expand.
Agent explores a solution tree. Each node is a code state. Need to branch, evaluate multiple children, backtrack to promising nodes. More info
Path failed. Tests red. Environment broken. Sequential agents restart from scratch. More info
Need to try 10 different approaches from the same starting point. Sequential = 10x slower. More info
Containers can't branch state. ConTree can.
| Capability | Docker | Kubernetes | ConTree |
|---|---|---|---|
| Isolation level | Namespace (kernel shared) | Namespace (kernel shared) | VM (hardware boundary) |
| State branching | Manual commit required | Not supported | Automatic per execution |
| Instant rollback | Recreate container | Redeploy pod | Switch image reference |
| Filesystem inspection | Requires running container | Requires running pod | API without execution |
| Execution history | External logging | External logging | Built-in with resources |
| Scalability | Manual orchestration | Minutes to scale pods | Thousands concurrent instantly |
What people build with ConTree.
Coding agents, deep research agents, data analysis agents. Any agent that needs to execute code, run tools, or explore solutions. More info
Run untrusted code safely. Analyze third-party scripts. Test without risk to your infrastructure. More info
Students run untrusted code. Need isolation, instant reset, and execution history. More info
Four endpoints. Import, upload, execute, retrieve.
POST /images/importPull OCI image rootfs from any registry. Returns a UUID for the base snapshot.
POST /filesUpload input files (scripts, data). Content-addressed by SHA256 for deduplication.
POST /instancesExecute command with image, files, env vars, stdin. Returns operation ID immediately.
GET /operations/{id}Poll for stdout/stderr, exit code, resource usage. Result includes new image UUID for branching.
Your agent writes code you haven't reviewed. That's fine.
How tree search agents use ConTree.
Generate 5 candidate solutions from checkpoint. Run tests on each branch in parallel. Keep top 2. Expand further. Repeat until solved.
Same prompt, N completions. Fork from identical state. Run all in parallel. Score outputs. Return the best.
Uncertain which approach works? Run both from same checkpoint. First success wins. Discard the other.
Think Git, but for execution environments.
Container security relies on kernel namespaces and syscall filtering. A kernel vulnerability can bypass all of it. ConTree uses microVMs with separate kernels per execution, providing hardware-level isolation that survives kernel exploits.
No. ConTree is designed for batch execution, not hosting services. Executions have no inbound network access. Outbound may be restricted or allowed depending on deployment configuration.
The filesystem. After each execution, modified files are captured into a new image. Process memory, running services, and network state are not preserved. Think of it as committing your working directory after each command.
Use the Inspect API. After execution completes, the result contains a new image UUID.
Call GET /inspect/{uuid}/list?path=/output to list files,
then GET /inspect/{uuid}/download?path=/output/result.json to retrieve them.
Configurable per request via the timeout field. If not specified,
a system default applies. Executions that exceed the timeout are terminated and
marked with timed_out: true in the result.
Captured and returned in the operation result. Output is base64-encoded if it contains binary data, otherwise ASCII. Configurable truncation limit (default 1MB, max 10MB) prevents memory issues with verbose programs.
Yes. Call DELETE /operations/{id} to cancel a pending or running operation.
The operation state will change to cancelled.
Each completed operation includes: user/system CPU time, max RSS (memory), block I/O, page faults, context switches, wall-clock elapsed time, and exit code/signal.