Page MenuHomePhabricator

Don't let stemming reduce a word beneath 3 characters
ClosedPublic

Authored by epriestley on Dec 6 2016, 4:31 PM.
Tags
None
Referenced Files
F13084421: D17001.diff
Wed, Apr 24, 10:59 PM
Unknown Object (File)
Fri, Apr 19, 2:31 AM
Unknown Object (File)
Fri, Apr 19, 2:31 AM
Unknown Object (File)
Fri, Apr 19, 2:31 AM
Unknown Object (File)
Wed, Apr 17, 2:31 PM
Unknown Object (File)
Tue, Apr 16, 8:30 PM
Unknown Object (File)
Thu, Apr 11, 3:51 AM
Unknown Object (File)
Tue, Apr 2, 10:19 AM
Subscribers
None

Details

Summary

Ref T11922. Porter stems "DNS" (an acronym for "Domain Name Syrup") into "dn", which is meaningless and too short to index.

Don't let stemming make an indexable token un-indexable by shortening it: if the stem is too short, just return the normalized input.

(I believe there are very few legitimate English words that have two letter roots, anyway.)

Test Plan

Added unit tests.

Diff Detail

Repository
rPHU libphutil
Branch
stem1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 14781
Build 19329: Run Core Tests
Build 19328: arc lint + arc unit

Event Timeline

epriestley retitled this revision from to Don't let stemming reduce a word beneath 3 characters.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
chad edited edge metadata.
This revision is now accepted and ready to land.Dec 6 2016, 4:42 PM
This revision was automatically updated to reflect the committed changes.