feat : task complexity routing

This commit is contained in:
martin legrand
2025-03-26 10:54:25 +01:00
parent 32bc096d9a
commit 757a9b1e3e
3 changed files with 136 additions and 20 deletions
+3 -2
View File
@@ -103,13 +103,14 @@ class Interaction:
self.current_agent.memory.push('user', self.last_query)
self.current_agent.memory.push('assistant', self.last_answer)
self.current_agent = agent
#self.last_answer, _ = agent.process(self.last_query, self.speech)
self.last_answer, _ = agent.process(self.last_query, self.speech)
def show_answer(self) -> None:
"""Show the answer to the user."""
if self.last_query is None:
return
self.current_agent.show_answer()
if self.current_agent is None:
self.current_agent.show_answer()
if self.tts_enabled and self.last_answer:
self.speech.speak(self.last_answer)