move sorting into risemodel