add index creation to seeding tasks; general refactoring