For a system which undergoes electron or energy transfer in a polar solvent, we define the diabatic states to be the initial and final states of the system, before and after the nonequilibrium transfer process. We consider two models for the system-solvent interactions: A solvent which is linearly polarized in space and a solvent which responds linearly to the system. From these models, we derive two new schemes for obtaining diabatic states from ab initio calculations of the isolated system in the absence of solvent. These algorithms resemble standard approaches for orbital localization, namely, the Boys and Edmiston-Ruedenberg ͑ER͒ formalisms. We show that Boys localization is appropriate for describing electron transfer ͓Subotnik et al., J. Chem. Phys. 129, 244101 ͑2008͔͒ while ER describes both electron and energy transfer. Neither the Boys nor the ER methods require definitions of donor or acceptor fragments and both are computationally inexpensive. We investigate one chemical example, the case of oligomethylphenyl-3, and we provide attachment/detachment plots whereby the ER diabatic states are seen to have localized electron-hole pairs.