fixing rerank rendering code