diff --git a/src/documents/search/_fields.py b/src/documents/search/_fields.py index 002a4836d..b5194ce81 100644 --- a/src/documents/search/_fields.py +++ b/src/documents/search/_fields.py @@ -6,7 +6,7 @@ from whoosh_compat import SubpathSpec # Internal-only schema fields with no query-syntax meaning of their own # (sort shadow fields, bigram CJK fields, simple_title/simple_content, -# autocomplete_word, notes_text) are NOT represented here — they are +# autocomplete_word, notes_text) are NOT represented here, they are # declared in _schema.py's field_descriptors(). # # analyzer/pattern_normalizer are deliberately left at FieldSpec's default diff --git a/src/documents/search/_registry.py b/src/documents/search/_registry.py index b7628db54..19332e575 100644 --- a/src/documents/search/_registry.py +++ b/src/documents/search/_registry.py @@ -64,7 +64,7 @@ def get_field_registry(language: str | None) -> FieldRegistry: """Build (or return the cached) FieldRegistry for the given search language. Cached keyed by language, rebuilt on the same trigger register_tokenizers() - uses (settings.SEARCH_LANGUAGE change) — a fresh call with a new language + uses (settings.SEARCH_LANGUAGE change). A fresh call with a new language builds and caches a new registry rather than mutating the old one. """ if language in _registry_cache: diff --git a/src/documents/search/_schema.py b/src/documents/search/_schema.py index 34f1ee40e..21889b12f 100644 --- a/src/documents/search/_schema.py +++ b/src/documents/search/_schema.py @@ -76,7 +76,7 @@ def _public_field_descriptors() -> list[FieldDescriptor]: ), ) if field.name == "notes": - # Plain-text companion for snippet generation — tantivy's + # Plain-text companion for snippet generation: tantivy's # SnippetGenerator does not support JSON fields. Schema-only, # no query-syntax meaning, not in PUBLIC_FIELDS. descriptors.append(