BEACON: Bayesian Optimal Stopping for Efficient LLM Sampling