Duplicate and near-duplicate documents waste a RAG index and crowd out diverse results. How shingles, Jaccard similarity, MinHash signatures and LSH banding find near-duplicates in pure Python, and why two versions of a policy with different numbers must…