adds indexing and eager loading to improve load speed