Function findSimilar

  • Returns strings from choices that are similar to input using the Levenshtein distance.

    Parameters

    • input: string

      The input string to compare against.

    • choices: string[]

      The choices to find similar strings from.

    • options: FindSimilarOptions = {}

      Additional options.

    Returns string[]

    Up to options.maxResults strings from choices that are similar to input.