simplify writer spec setup
cleanup sorted index when erasing a model