- New crates/renamr-core/src/similarity module: a partial port of the
scoring idea behind FileBot's EpisodeMetrics.java - normalizes titles
(lowercase, strips a trailing release-year parenthetical, collapses
punctuation/whitespace) and scores them with a Sorensen-Dice coefficient
over character bigrams. best_title_match() picks whichever candidate is
textually closest to the query, provided it clears a minimum threshold;
ties keep the earlier (i.e. TMDB-ranked) candidate.
- TmdbClient::lookup_episode now uses best_title_match instead of blindly
taking the first search result, so a more popular but differently-named
show can no longer beat an exact-but-lower-ranked match to the top - and
reports NotFound instead of guessing when nothing in the results is a
plausible match at all.
- 7 new tests (5 in similarity, 2 in tmdb) including the concrete regression
case this fixes: searching "Chuck" with TMDB returning "Chucky" ranked
above "Chuck" now correctly picks "Chuck".
- Also fixes a gitignore gap from last delivery: the _to_delete*/ scratch-dir
pattern used to work around this repo's mounted-folder git-lock quirk had
only ever been applied directly on the device, never carried back into the
zip this delivery is built from - so the last delivery's cp -rf silently
reintroduced the untracked-lock-file risk. Fixed in both places now.