working on probabilistic model