fix javascript bug causing low-quality phrases
prettier index with algorithm explanation