Forking
Freestyle VM Forking opens up a series of usecases, this goes over it.
Forking a Freestyle VM is not just a filesystem copy. It is a full copy of the entire VM. That means if you have a running process, it will keep going!
We use this capability in our dev server offering to get instant previews by forking already running dev servers rather than starting new ones from scratch.
How it Works
When you fork a VM, we are using a Copy on Write system to make it happen almost instantly. This means the original and the forked VM share the same memory pages until one of them modifies a page, at which point a copy is made. This allows us to create a full copy of the VM, including its memory and state, so fast.
Why this is Cool
Making VM forking so fast and efficient means that your AI can try all of its ideas easily, and iterate on them in multiple directions without having to recreate the state of the base VMs from scratch — which might not be possible.
Here's a few use cases this opens up:
- Top K Sampling: From the current state, if your Agent has 3 (or 300) directions it could go in, you can fork the VM for each direction and explore them in parallel.
- Multiple Browser Paths: If you want to examine multiple parts of a website but know each action you take has side effects, you can fork the VM at different points to isolate and analyze each path independently.
- A/B Testing: Instantly create multiple versions of your application to test different features or configurations without any downtime.
- Rapid Prototyping: Quickly spin up new instances of your environment to test changes or new ideas without affecting the original.
If you're interested in where we see this going, we designed this functionality when thinking about The Future of AI Coding Agents.