A Stochastic Approach to Dialog Management