Spaces:
Sleeping
Sleeping
Delete agents.py
Browse files
agents.py
DELETED
|
@@ -1,14 +0,0 @@
|
|
| 1 |
-
from langchain.agents import initialize_agent, AgentType, Tool
|
| 2 |
-
from langchain.memory import ConversationBufferMemory
|
| 3 |
-
|
| 4 |
-
def get_conversation_memory():
|
| 5 |
-
return ConversationBufferMemory(memory_key="chat_history", return_messages=True)
|
| 6 |
-
|
| 7 |
-
def init_multi_agent(tools, llm, memory):
|
| 8 |
-
return initialize_agent(
|
| 9 |
-
tools=tools,
|
| 10 |
-
llm=llm,
|
| 11 |
-
agent=AgentType.CONVERSATIONAL_REACT_DESCRIPTION,
|
| 12 |
-
memory=memory,
|
| 13 |
-
verbose=True
|
| 14 |
-
)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|