added basic prediction implementation
implemented rank queries