Hermes Agent bdd7ebb006 fix: OOM-safe SQL filtering + relevance scoring for /api/chat
Problem: On every chat request, ALL 1015 aussteller + 1861 neuheiten rows
were loaded into Python (2876 rows × full-text processing). Multiple
concurrent requests caused OOM kills (exit 137).

Fix:
- SQL LIKE filtering with parameterized queries (WHERE ... OR ... LIMIT 30)
- Relevance scoring in SQL: longer search terms = higher weight
- Tokenization: re.findall strips punctuation ('kosmos?' → 'kosmos')
- Stopword filtering removes noise ('die', 'hat', etc.)
- Removed duplicate 'gibt' in stopwords

Verified: Kosmos, Asmodee (6 Stände), Pegasus (3 Stände), Flip & Write
2026-06-18 14:56:37 +02:00
S
Description
BSN Community Chatbot — Multi-Channel Intake System
159 MiB
Languages
Python 95.3%
HTML 4.4%
CSS 0.2%