refactor: Split conversational.py into modular structure #64

Merged
shoko merged 2 commits from fix/issue-63 into main 2026-04-14 05:57:16 +02:00
Showing only changes of commit b1ddad0808 - Show all commits

View File

@@ -894,6 +894,10 @@ class ConversationalAgent:
result = resp result = resp
# Initialize thinking to None to handle cases where API response
# doesn't have the expected message structure (intermittent issue)
thinking = None
if result.get("choices") and len(result.get("choices", [])) > 0: if result.get("choices") and len(result.get("choices", [])) > 0:
choice = result["choices"][0] choice = result["choices"][0]
if "message" in choice: if "message" in choice: