We moved our heavier grader checks to Modal because validating one training task had become dozens of expensive runs. The work arrived in bursts, and running those bursts locally made even a high-end Mac struggle.

Imagine extracting a task from a large Go server. Building the program takes minutes. You also have a grader to build, a workload to run, and state to clean up afterward. Now do that for the reference solution, the starter code, several valid alternatives, and a collection of deliberately broken implementations.

Then change the grader and do it again.

That was the problem we needed to solve. Modal gave us a practical way to start temporary workers, run the checks in parallel, collect the evidence, and release the compute while we figured out the next change.

You have to test the grader, too

A passing reference solution tells you surprisingly little about whether a grader is fair. You also need to know whether it rejects incorrect implementations and accepts correct solutions that look different from your own.

An illustrative validation round might look like this:

Implementation Runs What you want to establish
Reference solution 1 The known-good implementation earns full credit.
Starter code 1 The unsolved starting point earns the expected baseline score.
Valid alternatives 8 Different correct approaches still pass.
Deliberately broken variants 30 Each relevant defect is detected.
Total 40 One round of evidence about the grader.

These are full grading runs, not forty small unit tests. For a storage engine, a run may compile the candidate and grader, inject crashes, simulate torn writes and storage faults, measure throughput, and reset the environment.

Cheap unit tests still belong in the local development loop. You don't need to rebuild an entire server for every assertion. But those tests cannot replace checking the grader against complete candidate implementations.

The iterations matter as much as the first batch. In one of our rounds, a grader change made the known-good reference score 32%. Checking it first caught the regression before we spent more time interpreting failures from the other candidates.

Why not just get a bigger machine?

You can. A large machine can be a good choice if you keep it busy, want a stable hardware target, or benefit from persistent caches and easy interactive debugging.

Our workload looked more like this: inspect a failure, think, edit, launch a batch, read the results, think again. A server sized for the largest batch would spend part of that cycle waiting for us.

It also has a fixed ceiling. On CPU capacity alone, a machine with 64 genuinely comparable cores could fit sixteen four-core jobs. Memory, disk bandwidth, and other shared resources can lower that number. Running everything together may also change the throughput each job observes.

Temporary workers let the batch grow beyond one host's capacity, within the provider's limits. To make the arithmetic concrete: forty twenty-minute grades take 13 hours and 20 minutes in sequence. Ten-way concurrency would reduce that to roughly 80 minutes, before startup, queuing, and variation between runs. That's an illustration, not a measured speedup from our project.

The economic question is utilization. A continuously busy dedicated server may be cheaper. A worker that exists only while a batch is running can be a better fit when the expensive work is intermittent. AWS can do this too; autoscaling, Batch, and Fargate are alternatives to leaving a large instance running all month.

What Modal changed for us

We kept the grading command and moved its execution into disposable remote environments. Modal's Sandbox API provides the lifecycle: create an environment, execute commands, retrieve outputs, and terminate it.

The useful unit of work became one candidate, one grading attempt, one collected result. Our laptop could coordinate the work without also compiling and running every candidate.

In our initial four-worker trial, the grades started about 45 seconds after launch, including source upload. The two reference runs then spent about 16 and 24 minutes grading. Startup mattered, but the workload was long enough to amortize it.

This pattern shows up elsewhere. In its engineering write-up, Ramp describes preparing repository environments ahead of time and restoring snapshots for its background coding agent. Fast execution depends partly on moving setup out of the critical path. Modal's Applied Compute case study describes a related workload: bursty CPU-heavy rollouts and parallel grading. That's a vendor account of a customer's system, rather than an independent performance comparison.

One detail worth getting right: the 5,000-container figure is listed on Modal's Team plan, not its Starter plan, and it is not a promise of 5,000 dedicated physical machines. The current pricing page lists 100 containers for Starter and 5,000 for Team. We did not need anything close to that scale. Modal pricing

What the runs cost

Our heavier checks requested four Modal CPU cores and 12 GiB of memory. At the published Sandbox rates checked on November 16, 2026, that allocation works out to approximately:

Sandbox lifetime Estimated CPU and memory cost
15 minutes $0.21
20 minutes $0.29
30 minutes $0.43

The calculation uses $0.00003942 per core-second and $0.00000667 per GiB-second. These are Sandbox rates, not the lower standard compute rates. Modal's CPU units are physical cores; don't compare them directly with another provider's vCPU count. Modal pricing

Our local compute ledger totaled about $54 at the time of writing. That included full grades, targeted checks, and setup probes. A recent round was approximately $6.35, but it mixed full runs with shorter checks; it wasn't forty identical twenty-minute grades. Forty of those would be about $11.41 at the allocation above.

These are estimates, not an invoice or a comparison against an equivalent month of dedicated-server usage. They exclude plan fees and other charges. Startup and idle sandbox time count, and actual resource use can affect billing. Modal bills CPU and memory using the greater of the reservation and actual usage for each resource. Sandbox resource billing

The decision shouldn't depend on introductory credits. The useful question is whether the normal cost of a complete validation round is worth the turnaround time it buys.

What moving to Modal doesn't fix

Your environment still has to work remotely. Our first runtime refused a temporary filesystem mount needed by the workload. We had to use a VM-backed runtime with the required capability. Packaging dependencies, choosing a compatible runtime, transferring source, and deciding what can be cached are real engineering work.

Cloud compute doesn't make throughput tests deterministic. We observed different CPU models in the worker pool. A reference solution that passed locally failed a throughput threshold on one remote host. Giving attempts separate sandboxes doesn't establish that each has an exclusive physical machine or identical performance.

For timing checks, record the hardware, run a baseline in the same attempt on the same host, use repeated measurements, and inspect the margin across representative machines. Even a speedup ratio can vary by CPU: the optimization and the baseline may benefit differently from the hardware. Validate against the actual grading environment when you can; matching a CPU model alone doesn't prove equivalence.

Fresh workers don't automatically make a trustworthy grader. We explicitly blocked outbound network access for these runs; Modal allows public outbound access by default. Fresh writable state helps avoid contamination, but shared writable volumes or caches can reintroduce it. Keep candidate state separate, and protect the grader and expected results from the candidate. Modal networking controls and our earlier note on grading boundaries explain the distinction.

Remote failures need evidence. Save the exit status, logs, score, input version, grader version, and timing information before destroying the worker. Otherwise, a disposable environment can take your best debugging clues with it. Distinguish an infrastructure failure from an incorrect candidate instead of recording both as zero.

Parallelism needs a budget. Cap concurrent workers, set a maximum lifetime for every attempt, and terminate workers even when collection fails. Review a small batch before launching the rest. A mistake that was merely slow locally can become expensive when replicated fifty times.

Other providers worth looking at

Modal is the option we used. These are other ways to get temporary execution capacity, with different amounts of orchestration and isolation work left to you. We haven't benchmarked them against this workload.

Option What makes it relevant
E2B Agent execution environments built around a Firecracker microVM per session, with sandbox network controls.
Daytona Programmable development sandboxes with container and VM options, snapshots, and filesystem persistence across stops.
Fly Machines Direct API control over VM creation, resources, placement, and destruction; useful when you want to build your own orchestration.
Runpod Serverless Containerized workers for handler-based jobs. Its Flex workers scale to zero; evaluate the execution model against your grading command.
Coiled Batch Runs scripts and containerized jobs across cloud machines in parallel; jobs don't have to be written in Python.
AWS Batch with Fargate Managed container jobs with queues and automatic compute provisioning, with more explicit AWS infrastructure configuration.

For this kind of work, I'd compare the required runtime capabilities, isolation boundary, startup time with the real image, concurrency limits, artifact collection, and total cost per completed round. A cheap CPU rate isn't enough if the grader cannot run correctly in the environment.

My recommendation

Keep the small, fast checks local. Move the expensive candidate matrix to disposable workers when contention or serial execution starts slowing down the feedback loop. Run the reference first, then a small selection of valid and broken controls, then the wider batch.

Choose a dedicated machine when steady utilization and hardware control justify it. Choose temporary capacity when you need a lot of compute briefly and very little while you're deciding what to do next.

For us, Modal made it practical to run more of the checks that a grader needed. That's also why I wouldn't strip useful context out of a training environment just to make a local batch fit. Improve the execution setup while preserving what the task is meant to test.

The goal is to finish each round with evidence you can trust—and release the machines while you think about what that evidence means.