67 lines
3.4 KiB
YAML
67 lines
3.4 KiB
YAML
# Shop search-repair configuration.
|
|
# YAML is the source of truth; SearchRepairConfig intentionally contains no PHP defaults.
|
|
parameters:
|
|
retriex.search_repair.config:
|
|
strict_requested_accessory_code_repair: true
|
|
prefer_prompt_anchored_model_for_requested_accessory_code: true
|
|
|
|
direct_product_attribute_lookup:
|
|
enabled: true
|
|
min_query_tokens_after_cleanup: 2
|
|
# Query repair must stay on the requested product/accessory type for
|
|
# direct attribute lookups. It may relax comparative constraints, but it
|
|
# must not expand to unrelated RAG model/device candidates.
|
|
# Direct product/accessory stop terms are resolved from
|
|
# config/retriex/vocabulary.yaml view search_repair.direct_product_attribute_stop_terms.
|
|
# A local stop_terms list may still be added here as an explicit project override.
|
|
comparative_constraint_patterns:
|
|
- '/\b(?:länger|laenger|kürzer|kuerzer|größer|groesser|kleiner|über|ueber|unter|mindestens|maximal|maximum|minimum|ab|bis|mehr\s+als|weniger\s+als)\s+(?P<value>\d+(?:[,.]\d+)?\s*[\p{L}µ°%]*)\b/iu'
|
|
|
|
requested_accessory_code_fallback_query_templates:
|
|
- '{term} {code}'
|
|
# Requested-accessory code terms are resolved from
|
|
# config/retriex/vocabulary.yaml view search_repair.requested_accessory_code_terms.
|
|
# Local requested_accessory_code_fallback_terms and
|
|
# requested_accessory_code_context_prefix_terms lists may still be added here as
|
|
# explicit project overrides.
|
|
requested_accessory_code_proximity_window: 1600
|
|
|
|
specific_model_candidate_patterns:
|
|
- '/\b([A-Za-zÄÖÜäöüß][A-Za-zÄÖÜäöüß®\-]*(?:\s+[A-Za-zÄÖÜäöüß0-9][A-Za-zÄÖÜäöüß0-9®\-]*){0,3}\s+\d{2,5}(?:\s+[A-ZÄÖÜ]{1,8})?)\b/u'
|
|
# Model-candidate exclude terms are resolved from
|
|
# config/retriex/vocabulary.yaml view search_repair.model_candidate_exclude_terms.
|
|
# A local model_candidate_exclude_terms list may still be added here as an
|
|
# explicit project override.
|
|
|
|
limits:
|
|
top_product_log_limit: 3
|
|
|
|
# Character codes preserve the previous PHP trim charlist:
|
|
# space, tab, LF, CR, NUL, vertical tab, double quote, single quote,
|
|
# backtick, dot, comma, semicolon, colon, hyphen.
|
|
sanitize_trim_character_codes: [32, 9, 10, 13, 0, 11, 34, 39, 96, 46, 44, 59, 58, 45]
|
|
product_key_separator: '|'
|
|
|
|
scores:
|
|
candidate_digit: 4
|
|
candidate_word_count_cap: 4
|
|
specificity_boost: 3
|
|
primary_query_overlap_threshold: 0.9
|
|
prompt_match_weight: 3
|
|
primary_query_match_weight: 2
|
|
repair_signal_match_weight: 4
|
|
primary_result_order_bonus: 1
|
|
token_intersection_score: 2
|
|
numeric_token_match_score: 4
|
|
|
|
patterns:
|
|
model_candidate: '/\b([A-Za-zÄÖÜäöüß][A-Za-zÄÖÜäöüß®\-]*(?:\s+[A-Za-zÄÖÜäöüß][A-Za-zÄÖÜäöüß®\-]*){0,2}\s+\d{2,5}[A-Za-z0-9\-]*)\b/u'
|
|
accessory_candidate_template: '/\b((?:{terms})\s+\d{1,5}[A-Za-z0-9\-]*)\b/iu'
|
|
requested_accessory_code: '/\b(?:indikator(?:typ)?|indicator(?:\s*type)?|reagenz|reagent)\s*([A-Za-z]{0,3}\s*\d{1,5}[A-Za-z0-9\-]*)\b/iu'
|
|
accessory_or_bundle_template: '/\b({terms})\b/iu'
|
|
model_like: '/\b[A-Za-zÄÖÜäöüß][A-Za-zÄÖÜäöüß®\-]*(?:\s+[A-Za-zÄÖÜäöüß][A-Za-zÄÖÜäöüß®\-]*){0,2}\s+\d{2,5}[A-Za-z0-9\-]*\b/u'
|
|
specificity_boost_template: '/\b(?:{terms})\b/iu'
|
|
contains_digit: '/\d/u'
|
|
whitespace_collapse: '/\s+/u'
|
|
tokenize_cleanup: '/[^\p{L}\p{N}\s\-]+/u'
|