fix(archivar): correct Coroutine-Bug root cause — _llm_raw_sync→async _llm_raw, direct await
OllamaLLMClient.generate() is async def — run_in_executor cannot correctly execute async functions. The coroutine was never awaited. Also fix Move-Request parser: native button '1️⃣ Rüber' was not matched against '1️⃣' — fell through to 'stay' instead of 'move'. - classifier.py: _llm_raw_sync → async _llm_raw, await generate() - router.py: remove run_in_executor, direct await _llm_raw() - adapter.py: normalize MOVE_REQ choice (extract leading digit/emoji)
This commit is contained in:
@@ -743,6 +743,11 @@ class RocketChatAdapter(BasePlatformAdapter):
|
||||
if choice.startswith("MOVE_REQ:") and "::" in choice:
|
||||
_, choice = choice.split("::", 1)
|
||||
choice = choice.strip()
|
||||
# Normalisiere: "1️⃣ Rüber" → "1️⃣", "2 Hier" → "2"
|
||||
if choice and choice[0] in "123":
|
||||
choice = choice[0]
|
||||
elif choice and choice[:2] in ("1️⃣", "2️⃣", "3️⃣"):
|
||||
choice = choice[:2]
|
||||
# Altes Format: "1"/"2"/"3" = numerische Antwort
|
||||
# Neues Format: "1️⃣", "2️⃣", "3️⃣" = Emoji-Nummern
|
||||
elif choice in ("1", "2", "3") or choice in ("1️⃣", "2️⃣", "3️⃣"):
|
||||
|
||||
Reference in New Issue
Block a user