Extending the spectrum into UV and IR is interesting an I’d love to try making a flourescent BSDF but I’m not sure whether it breaks some Cycles rules, since it is direction-dependent.
@kram1032 said it better than I could regarding how to create dispersion. The plan is to not split the ray but to evaluate all wavelengths while using the path of the first ray. This will mean noisy dispersion if 0 roughness is used, but if there’s overlap in the paths of each wavelength then you’ll progressively get more and more benefit from the multiple-wavelength sampling.