What is Shadow mode?
Shadow mode (shadow testing) is a way to test a new model in production by running it on the same live inputs as the current model and recording its outputs, without ever letting them control the machine.
How it works
The current model, the primary, keeps driving the robot. The candidate runs alongside it, usually in a background thread or process, and receives a copy of the same observations. Its actions go to a log, not to the motors. After enough samples you compare the two: how often they agree, how far apart their actions are and how long each one takes.
For a classifier, agreement means picking the same class. For a policy with continuous actions, it means the distance between the two actions stays small.
Why it matters in production
Offline tests use recorded data, and recorded data is never quite the field. Shadow mode tests the candidate on today's lighting, today's objects and today's hardware, on the machines that will run it, with no risk to the work being done.
It also catches problems a benchmark misses, such as a candidate that is accurate but too slow for the control loop on the robot's actual GPU.
What to watch for
The candidate competes for compute. If it shares a GPU with the primary it can slow the primary down, so run it on a sample of inputs and drop samples when the machine is busy. Collect enough samples to mean something, across different times and tasks. Disagreement is not always bad, since a better model is supposed to disagree sometimes, so look at where it disagrees and not only how often.
Shadow mode tests decisions, not consequences. Because the candidate never acts, you cannot see what would have happened next. That is why a passed shadow test is followed by a phased rollout, not a fleet-wide switch.
How PhysicalFleet handles it
PhysicalFleet's model.shadow step installs a candidate next to the current model, runs it on the same live inputs without acting, and passes or fails it on agreement and latency. A model.promote step then switches to it atomically and is usually rolled out in phases behind the health gate.
Is shadow mode the same as A/B testing?
No. In an A/B test both versions act on real work and you compare outcomes. In shadow mode only the current version acts, and the candidate's outputs are recorded and compared without affecting the machine.
How long should a shadow test run?
Long enough to see a representative mix of tasks and conditions and a minimum number of compared samples. For robots that usually means at least a full shift rather than a few minutes.
Can shadow mode slow down the robot?
It can if the candidate competes for the same GPU or CPU. Running it in the background on a sample of inputs, and dropping samples when the machine is busy, keeps the primary model's timing intact.
From the lab bench. To the entire fleet.
Connect your first machine in minutes, develop it in the lab and run your whole fleet in production from one place.
Free for up to 3 machines · Then pay as you go