FIX Bug in prompt learning after disabling adapter (#1502)
There was a big that after using the disable_adapter context, the
prepare method was not correctly restored, meaning that generations were
incorrect once the context was exited. This is now fixed.