MCPcopy Create free account
hub / github.com/codemix/graph / step5b

Function step5b

packages/text-search/src/stemmer.ts:282–287  ·  view source on GitHub ↗

* Step 5b: Remove trailing 'll' if measure > 1

(word: string)

Source from the content-addressed store, hash-verified

280 * Step 5b: Remove trailing 'll' if measure > 1
281 */
282function step5b(word: string): string {
283 if (word.endsWith("ll") && hasMeasureGreaterThan1(word.slice(0, -1))) {
284 return word.slice(0, -1);
285 }
286 return word;
287}
288
289/**
290 * Stem a word using the Porter stemming algorithm.

Callers 1

stemFunction · 0.85

Calls 2

hasMeasureGreaterThan1Function · 0.85
endsWithMethod · 0.45

Tested by

no test coverage detected