Spaces:
Runtime error
Runtime error
Commit
·
8c3956a
1
Parent(s):
34a6661
rollback tools declare
Browse files
app.py
CHANGED
@@ -75,17 +75,17 @@ chat = AzureChatOpenAI(
|
|
75 |
)
|
76 |
llm = chat
|
77 |
|
78 |
-
|
79 |
|
80 |
-
|
81 |
-
|
82 |
-
|
83 |
-
|
84 |
-
|
85 |
|
86 |
-
|
87 |
|
88 |
-
tools = load_tools(["Vector Database Search","Wikipedia Search","Python REPL","llm-math"], llm=llm)
|
89 |
|
90 |
embeddings = OpenAIEmbeddings(deployment="model_embedding", chunk_size=15)
|
91 |
|
|
|
75 |
)
|
76 |
llm = chat
|
77 |
|
78 |
+
llm_math = LLMMathChain.from_llm(llm)
|
79 |
|
80 |
+
math_tool = Tool(
|
81 |
+
name ='Calculator',
|
82 |
+
func = llm_math.run,
|
83 |
+
description ='Useful for when you need to answer questions about math.'
|
84 |
+
)
|
85 |
|
86 |
+
tools = [DB_Search(), duckduckgo_tool, python_tool, math_tool]
|
87 |
|
88 |
+
# tools = load_tools(["Vector Database Search","Wikipedia Search","Python REPL","llm-math"], llm=llm)
|
89 |
|
90 |
embeddings = OpenAIEmbeddings(deployment="model_embedding", chunk_size=15)
|
91 |
|