term frequency bug fixed