Skip to main content

Module suggest

Module suggest 

Source

Functionsยง

closest_match
Find the closest match to target from candidates using Levenshtein distance. Returns Some(name) only when the best candidate is within max(target.len() / 3, 1) edits - enough to catch typical typos without surfacing wild guesses.
levenshtein ๐Ÿ”’
Computes the Levenshtein edit distance between two strings.