start porting search result mangling to the model
finish porting rabl to model