Augmentation-Adapted Retriever Improves Generalization of Language Models as Generic Plug-In