change GenerativeBayes to be cloneable