Hierarchical Models for Generalization Gradients: A Bayesian Approach