Skip to content

Latest commit

 

History

History
42 lines (25 loc) · 1.23 KB

README.md

File metadata and controls

42 lines (25 loc) · 1.23 KB

Ruby

MiniLevenshtein

Simple, fast, levenshtein distance and similarity ratio for Ruby

Synopsis

MiniLevenshtein.edit_distance("levenshtein", "levenstien") # => 3

MiniLevenshtein.similarity("levenshtein", "levenstien") # 0.857142...

Why?

While there are many levenshtein distance implementations for Ruby, none provided a means to adjust edit scoring to make the calcuations suitable for a similarity ratio.

See Also

Credits

Ruby Bindings

Delon Newman [email protected]

Original C Code

(see ext/mini_levenshtein/levenshtein.c for more)

License

The gem is available as open source under the terms of the GPL.