Adaptive Motion Generation Using Uncertainty-Driven Foresight Prediction