chore(project): lower duplicate hash threshold to 4 in example env

The distance histogram over a real ~65k-pair table is flat-to-rising from
distance 1 and nearly doubles at 10 — the 8-10 band is dominated by
coincidental matches, not duplicates. Default the example to 4 (the valley
minimum) to keep the genuine-duplicate signal and cut the pairs to cluster.
This commit is contained in:
2026-06-22 22:09:04 +03:00
parent 6834b916cd
commit 6fe6e4cd55
+6 -3
View File
@@ -131,9 +131,12 @@ IMPORT_PATH=/data/import
# Maximum perceptual-hash distance (Hamming, out of 64 bits) for two files to be # Maximum perceptual-hash distance (Hamming, out of 64 bits) for two files to be
# treated as duplicate candidates. Lower = stricter (fewer, more confident # treated as duplicate candidates. Lower = stricter (fewer, more confident
# matches); higher = looser (catches more re-encodes/resizes but risks false # matches); higher = looser (catches more re-encodes/resizes but risks false
# positives). Used only by the dedup tool's pairs rebuild — see the dedup CLI / # positives). On real libraries the distance histogram climbs steeply in the 810
# `docker compose run --rm dedup`. Default 10. # band — coincidental "vaguely similar" pairs, not duplicates — so 4 keeps the
DUPLICATE_HASH_THRESHOLD=10 # genuine-duplicate signal without that noise (and far fewer pairs to cluster).
# Used only by the dedup tool's pairs rebuild — see the dedup CLI /
# `docker compose run --rm dedup`. Code default is 10.
DUPLICATE_HASH_THRESHOLD=4
# --------------------------------------------------------------------------- # ---------------------------------------------------------------------------
# Static SPA # Static SPA