feat(archivar): Booster-Gewichtung verstärkt — FAISS + Keywords

Booster-Strategie: IMMER aktiv (nicht nur bei Konflikten)
- router.py: Konfliktbedingung entfernt, Booster auf alle FAISS-Treffer
- booster.py: Boost +0.05→+0.10, zusätzlich +0.05 pro weiterem unique Keyword
- config.py: FAISS_AUTO_ROUTE 0.85→0.70

Kombiniert semantische Breite (FAISS) mit präziser Keyword-Diskriminierung.
Ziel: granulare Raum-Entscheidungen bei überlappenden Themen.
This commit is contained in:
Bernd (Hermes)
2026-06-18 07:55:14 +02:00
parent 97d59f5272
commit d005eb769d
3 changed files with 42 additions and 25 deletions
+6 -12
View File
@@ -343,18 +343,12 @@ class BidirectionalRouter:
boosted = faiss_hits
booster_applied = False
if self._booster is not None:
# Nur boosten wenn Top-2 knapp beieinander liegen
if (
len(faiss_hits) >= 2
and (faiss_hits[0][1] - faiss_hits[1][1]) < FAISS_CONFLICT_DIFF
):
boosted = self._booster.boost(text, faiss_hits)
booster_applied = True
logger.debug(
"FAISS Booster applied: diff=%.3f < %.3f",
faiss_hits[0][1] - faiss_hits[1][1],
FAISS_CONFLICT_DIFF,
)
# Boosten immer anwenden, nicht nur bei Konflikten
boosted = self._booster.boost(text, faiss_hits)
booster_applied = True
logger.debug(
"FAISS Booster applied: always active",
)
top_room_id, top_score = boosted[0]