Exchange interactions in two-state systems: rare earth pyrochlores