update inverted index