Spaces:
Sleeping
Sleeping
biblioteca excel
Browse files- agent.py +6 -3
- requirements.txt +2 -1
agent.py
CHANGED
@@ -11,7 +11,11 @@ import glob
|
|
11 |
|
12 |
class Agent:
|
13 |
def __init__(self):
|
|
|
14 |
print("Initializing Agent....")
|
|
|
|
|
|
|
15 |
|
16 |
print("--> Audio Agent")
|
17 |
self.audio_agent = create_react_agent(
|
@@ -31,7 +35,7 @@ class Agent:
|
|
31 |
|
32 |
print("--> Supervisor")
|
33 |
self.supervisor = create_supervisor(
|
34 |
-
model=init_chat_model("openai:gpt-4o-mini"
|
35 |
agents=[self.web_search_agent, self.audio_agent],
|
36 |
tools=[bird_video_count_tool,chess_image_to_fen_tool,chess_fen_get_best_next_move_tool,
|
37 |
get_excel_columns_tool, calculate_excel_sum_by_columns_tool,execute_python_code_tool,
|
@@ -45,7 +49,7 @@ class Agent:
|
|
45 |
|
46 |
|
47 |
def __call__(self, question: str, task_id: str, task_file_name: str) -> str:
|
48 |
-
print(f"Agent
|
49 |
|
50 |
file_prefix = ""
|
51 |
if task_file_name:
|
@@ -64,7 +68,6 @@ class Agent:
|
|
64 |
]
|
65 |
}
|
66 |
)
|
67 |
-
print('........ Versão: Teste Geral, .....')
|
68 |
print(f"Resposta LLM: {response}")
|
69 |
# Extrair o conteúdo das mensagens do tipo AIMessage
|
70 |
final_content = ""
|
|
|
11 |
|
12 |
class Agent:
|
13 |
def __init__(self):
|
14 |
+
|
15 |
print("Initializing Agent....")
|
16 |
+
print("**************************************************************************************")
|
17 |
+
print('........ Versão: Sem Temperature no supervisor, tratamento da abertura do excel , .....')
|
18 |
+
print("**************************************************************************************")
|
19 |
|
20 |
print("--> Audio Agent")
|
21 |
self.audio_agent = create_react_agent(
|
|
|
35 |
|
36 |
print("--> Supervisor")
|
37 |
self.supervisor = create_supervisor(
|
38 |
+
model=init_chat_model("openai:gpt-4o-mini"),
|
39 |
agents=[self.web_search_agent, self.audio_agent],
|
40 |
tools=[bird_video_count_tool,chess_image_to_fen_tool,chess_fen_get_best_next_move_tool,
|
41 |
get_excel_columns_tool, calculate_excel_sum_by_columns_tool,execute_python_code_tool,
|
|
|
49 |
|
50 |
|
51 |
def __call__(self, question: str, task_id: str, task_file_name: str) -> str:
|
52 |
+
print(f"Agent received question({task_id}) (first 50 chars): {question[:50]}...")
|
53 |
|
54 |
file_prefix = ""
|
55 |
if task_file_name:
|
|
|
68 |
]
|
69 |
}
|
70 |
)
|
|
|
71 |
print(f"Resposta LLM: {response}")
|
72 |
# Extrair o conteúdo das mensagens do tipo AIMessage
|
73 |
final_content = ""
|
requirements.txt
CHANGED
@@ -9,4 +9,5 @@ wikipedia-api
|
|
9 |
yt-dlp
|
10 |
ipython
|
11 |
opencv-python
|
12 |
-
google-generativeai
|
|
|
|
9 |
yt-dlp
|
10 |
ipython
|
11 |
opencv-python
|
12 |
+
google-generativeai
|
13 |
+
openpyxl
|