Synaptic computation underlying probabilistic inference