Fix shorten parsing and logic

Shorten only at word boundaries
Also, we currently do not correctly parse shortenTo. Incidentally, although the
documentation mentions that flags can be specified, no attempt is made to parse
them. We still don't know how to use them (since shortens automatically get the
SHORT_NAME flag) but that's a separate issue.

Auditors: blackmad, nsanch
Add distance buckets to scoring

Auditors: nsanch, blackmad