Commit
·
13cd04c
1
Parent(s):
f3ac4ce
sdf
Browse files
agent.py
CHANGED
@@ -177,7 +177,7 @@ def build_graph(provider: str = "huggingface"):
|
|
177 |
repetition_penalty=1.03,
|
178 |
|
179 |
)
|
180 |
-
llm = ChatHuggingFace(llm=llm
|
181 |
else:
|
182 |
raise ValueError("Invalid provider. Choose 'google', 'groq' or 'huggingface'.")
|
183 |
# Bind tools to LLM
|
@@ -217,7 +217,7 @@ def build_graph(provider: str = "huggingface"):
|
|
217 |
builder.add_edge("tools", "assistant")
|
218 |
|
219 |
# Compile graph
|
220 |
-
return builder.compile()
|
221 |
|
222 |
# test
|
223 |
if __name__ == "__main__":
|
|
|
177 |
repetition_penalty=1.03,
|
178 |
|
179 |
)
|
180 |
+
llm = ChatHuggingFace(llm=llm)
|
181 |
else:
|
182 |
raise ValueError("Invalid provider. Choose 'google', 'groq' or 'huggingface'.")
|
183 |
# Bind tools to LLM
|
|
|
217 |
builder.add_edge("tools", "assistant")
|
218 |
|
219 |
# Compile graph
|
220 |
+
return builder.compile(recursion_limit=50)
|
221 |
|
222 |
# test
|
223 |
if __name__ == "__main__":
|