Name normalization and dedupe
CI / ci (push) Successful in 1m32s
CI / ci (pull_request) Successful in 1m33s

Add harness.Normalize (lowercase, fold accents, strip punctuation, drop
filler words, collapse whitespace), harness.Similar (token-set Jaccard
similarity, threshold 0.85) and a Deduper built from the Regulars, Quest
log, pending suggestions and passed names that answers IsDuplicate.

Maestro task: f046ec6c-dbe2-4b12-bc95-3081c07714eb

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-05 08:37:18 -04:00
co-authored by Claude Opus 5.5
parent 6ff6443db7
commit 1e0b1fc75e
3 changed files with 235 additions and 0 deletions
+7
View File
@@ -164,6 +164,13 @@ automatic** (D-021).
last 60 passed Side quests and the plans of the last four ISO weeks. A
character budget trims the oldest plans first, then the oldest passes;
Regulars and the Quest log are never trimmed.
- **Name dedupe** (`harness.Normalize`, `harness.Similar`, `harness.Deduper`):
a dinner name is normalized by lowercasing, folding accents, stripping
punctuation, dropping filler words (easy, best, homemade, quick, simple,
the, a, recipe, classic) and collapsing whitespace. Two names are the same
dinner when the token-set (Jaccard) similarity of their words is at least
0.85. A `Deduper` over the Regulars, Quest log, pending suggestions and
passed names rejects a suggestion that repeats any of them.
## Recipe grounding