From 75cd929cda68bacfd6a42074f7beea22a4ef0595 Mon Sep 17 00:00:00 2001 From: Adrian Sampson Date: Wed, 22 Sep 2010 20:16:45 -0700 Subject: [PATCH] fix "featuring" string heuristic, tweak thresholds --- beets/autotag/__init__.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/beets/autotag/__init__.py b/beets/autotag/__init__.py index 66fc47d96..ce3cbde23 100644 --- a/beets/autotag/__init__.py +++ b/beets/autotag/__init__.py @@ -55,8 +55,8 @@ RECOMMEND_STRONG = 'RECOMMEND_STRONG' RECOMMEND_MEDIUM = 'RECOMMEND_MEDIUM' RECOMMEND_NONE = 'RECOMMEND_NONE' # Thresholds for recommendations. -STRONG_REC_THRESH = 0.03 -MEDIUM_REC_THRESH = 0.2 +STRONG_REC_THRESH = 0.04 +MEDIUM_REC_THRESH = 0.25 REC_GAP_THRESH = 0.25 # Parameters for string distance function. @@ -66,9 +66,10 @@ SD_END_WORDS = ['the', 'a', 'an'] SD_PATTERNS = [ (r'^the ', 0.1), (r'[\[\(]?(ep|single)[\]\)]?', 0.0), - (r'[\[\(]?(featuring|feat|ft)[\. :]', 0.3), + (r'[\[\(]?(featuring|feat|ft)[\. :].+', 0.1), (r'\(.*?\)', 0.3), (r'\[.*?\]', 0.3), + (r'(, )?(pt\.|part) .+', 0.2), ] # Autotagging exceptions.