Snapshotable
Snapshot, merge, and replica creation for bandits, independent of their input shape.
S is the snapshot type. PerArmBandit uses List<R> with one Result per arm, including com.eignex.kumulant.bandit.univariate.Exp3Bandit's exponential weights. Workers can send snapshots to a coordinator without sharing live accumulators. Each implementation documents merge approximations and state omitted from its snapshots.
Inheritors
Functions
create
Spawn a fresh bandit with the same configuration; state resets to the prior seed. The random source is replaced; pass the source you want the new bandit to use for exploration (which is independent of merging in another snapshot's state).
Useful when a worker accepts a stream of snapshots to apply sequentially: create(random).also { it.merge(snapshot) }.