Planning to Adapt