Generator/validator