feat : improve chrome path check + no query refusal on complex task

This commit is contained in:
martin legrand
2025-04-16 13:59:11 +02:00
parent 4342677344
commit a3ca718131
3 changed files with 21 additions and 20 deletions
-7
View File
@@ -402,8 +402,6 @@ class AgentRouter:
if confidence < 0.4:
self.logger.info(f"Low confidence in complexity estimation: {confidence}")
return "LOW"
if complexity == "HIGH" and len(text) < 64:
return None # ask for more info
if complexity == "HIGH":
return "HIGH"
elif complexity == "LOW":
@@ -440,11 +438,6 @@ class AgentRouter:
text = self.lang_analysis.translate(text, lang)
labels = [agent.role for agent in self.agents]
complexity = self.estimate_complexity(text)
if complexity == None and self.asked_clarify == False:
self.asked_clarify = True
pretty_print(f"Humm, the task seem complex but you gave very little information. can you clarify?", color="info")
return None
self.asked_clarify = False
if complexity == "HIGH":
pretty_print(f"Complex task detected, routing to planner agent.", color="info")
return self.find_planner_agent()