Shortest Path Based Decision Making Using Probabilistic Inference