adjust rate function for additional params