Refactor and initial shareable indices changes.