Moving also terms_map from JavaLightmodels