Fast and Easy Levenshtein distance using a Trie

(stevehanov.ca)

32 points | by sebg 3 days ago

2 comments

  • dvh 15 minutes ago
    I made myself plugin that shows new news in wikipedia's current event page and I was using levenshtein originally (they often edit couple of words in article over span of few days so I compare each new article with previous ones for similarity) but after few days it became too slow (~20s) because O(m*n), so I switched to sorensen-dice instead which is O(m+n) and it's much faster and works very similar way, even tho they do slightly different thing.
  • fergie 38 minutes ago
    Very cool and satisfying.