A community-supported supercharged document management system: scan, index and archive all your documents
Python aiangulararchivingdjangodmsdocument-managementdocument-management-systemllmmachine-learningocroptical-character-recognitionpdf
lazy load fuzzy only when required
jonaswinkler96d7114fa7d2
diff --git a/src/documents/matching.py b/src/documents/matching.pyindex 21102bc98..edbbdc1b8 100644--- a/src/documents/matching.py+++ b/src/documents/matching.py@@ -1,7 +1,6 @@import loggingimport re-from fuzzywuzzy import fuzzfrom documents.models import MatchingModel, Correspondent, DocumentType, Tag@@ -123,6 +122,8 @@ def matches(matching_model, document):return bool(match)elif matching_model.matching_algorithm == MatchingModel.MATCH_FUZZY:+ from fuzzywuzzy import fuzz+match = re.sub(r'[^\w\s]', '', matching_model.match)text = re.sub(r'[^\w\s]', '', document_content)if matching_model.is_insensitive: