feat : file agent imrprovement

This commit is contained in:
martin legrand 2025-03-26 12:21:03 +01:00
parent 8922350379
commit 7d67ae2562
2 changed files with 7 additions and 7 deletions

BIN
media/exemples/brooo.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 147 KiB

View File

@ -27,13 +27,13 @@ class FileAgent(Agent):
exec_success = False
prompt += f"\nWork directory: {self.work_dir}"
self.memory.push('user', prompt)
self.wait_message(speech_module)
animate_thinking("Thinking...", color="status")
answer, reasoning = self.llm_request()
exec_success, _ = self.execute_modules(answer)
answer = self.remove_blocks(answer)
self.last_answer = answer
while exec_success is False:
self.wait_message(speech_module)
animate_thinking("Thinking...", color="status")
answer, reasoning = self.llm_request()
exec_success, _ = self.execute_modules(answer)
answer = self.remove_blocks(answer)
self.last_answer = answer
return answer, reasoning
if __name__ == "__main__":