interface EditCosts {
    accentCosts?: number;
    baseCost?: number;
    capsCosts?: number;
    firstLetterPenalty?: number;
    nonAlphabetCosts?: number;
}

Properties

accentCosts?: number

The cost to add / remove an accent This should be very cheap, it helps with fixing accent issues.

Default

1
baseCost?: number

This is the base cost for making an edit.

Default

100
capsCosts?: number

The cost to change capitalization. This should be very cheap, it helps with fixing capitalization issues.

Default

1
firstLetterPenalty?: number

The extra cost incurred for changing the first letter of a word. This value should be less than 100 - baseCost.

Default

4
nonAlphabetCosts?: number

This is the cost for characters not in the alphabet.

Default

110