tweaked sprinkle index logic to improve response time