Optos are too slow by about four orders of magnitude. You need quite a few MOSFETs in series, and they all need to sync up as well as drive fast enough -- and this generally isn't possible I think.
Avalanche transistors are neat, but a bit too low on peak power: a full 15kV through 330R (IEC 61000-4-2) is 45A and a fraction of a megawatt; even reducing these figures by a few factors of 2 (accounting for air vs. contact method, impedance of the target, etc.), you're well beyond the rating of any avalanche transistor and need either many in parallel, or a whole mess of them synced up and combined with a power combiner. Which will give you a very different output impedance from the electrostatic gun, so it's still not great. (This is feasible for EFT, though -- at a level of say 4kV into 50 ohms, you only need about a hundred avalanche transistors, or a dozen MOSFETs -- or half a dozen SiC, even. In an RF ground-plane setup, driving MOSFETs fast enough, syncing them up, and using power combiners, is perfectly feasible.)
So, the vacuum relay truly is king here.
A spark gap has some possibility I suppose, but it needs to be adjustable -- the tip voltage in general isn't known, and a triggered SG depends critically on its voltage drop to be triggered at all, while avoiding spurious flashover.
For example, a typical test case is probing a lone screw in a plastic enclosure. It doesn't jump to anything, just sits there getting charged up. Either it's discharged between cycles by manual intervention (or auto cycling in the gun, when available and enabled), or it just charges up in one or two cycles and that's basically that.
And an adjustable spark gap just sounds like a HV relay with extra steps. So you might as well do that. But keep in mind the spark gap will have different results from the vacuum switch: it will ALWAYS spark, so loses some voltage that way; and, the spark acts to sharpen the pulse, so use it carefully and account for the structure either side of it, so as to avoid introducing stub lengths or whatever that can propagate the sharpening. Calibrate with a >500MHz scope and adjust output resistance, inductance and damping to keep the leading edge reasonable.
Tim