Add opt-in approximate matching and upgrade recommendations
A per-pair "Approximate matching" setting adds a second pass for slave files the strict rules could not place. It searches the same album with disc folders (Disc 02, CD2, ...) ignored, then the top-level folder, and scores titles by edit distance and word containment against a configurable threshold (default 85%), with a small track-number bonus. Guards against false matches: version words (live, remix, reprise, instrumental, ...) must agree, near-tied candidates are left unmatched, and approximate matches always go to manual review, never auto-link. Each match records a human-readable reason. Review now flags matches where the master copy is better as upgrades, with an Upgrades filter and count and an "Upgrade to master copy" action. The redundant "master is lossless" warning note is dropped. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
5b088bb4a6
commit
381b804742
12 files changed
+552
-51
No files matched your search
@@ -280,6 +280,12 @@ func (e *Engine) NormalizePair(p *store.Pair) ([]string, error) {
|
||||
if p.RetentionDays < 0 || p.ScanIntervalMinutes < 0 || p.SettleMinutes < 0 {
|
||||
return nil, errors.New("intervals must not be negative")
|
||||
}
|
||||
if p.ApproxThreshold == 0 {
|
||||
p.ApproxThreshold = 85
|
||||
}
|
||||
if p.ApproxThreshold < 60 || p.ApproxThreshold > 100 {
|
||||
return nil, errors.New("approximate match threshold must be between 60 and 100 percent")
|
||||
}
|
||||
if p.ScanIntervalMinutes > 0 && p.ScanIntervalMinutes < 5 {
|
||||
return nil, errors.New("scan interval must be 0 (manual) or at least 5 minutes")
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user