Spaces:
Sleeping
Sleeping
Update agent.py
Browse files
agent.py
CHANGED
|
@@ -11,11 +11,18 @@ from langchain_huggingface import HuggingFaceEndpoint, ChatHuggingFace
|
|
| 11 |
HUGGINGFACEHUB_API_TOKEN = getenv("HUGGINGFACEHUB_API_TOKEN")
|
| 12 |
|
| 13 |
# Making the agent
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 14 |
llm = HuggingFaceEndpoint(
|
| 15 |
-
repo_id="
|
| 16 |
-
huggingfacehub_api_token=HUGGINGFACEHUB_API_TOKEN,
|
| 17 |
)
|
| 18 |
|
|
|
|
| 19 |
chat = ChatHuggingFace(llm=llm, verbose=True)
|
| 20 |
tools = [add,
|
| 21 |
substract,
|
|
|
|
| 11 |
HUGGINGFACEHUB_API_TOKEN = getenv("HUGGINGFACEHUB_API_TOKEN")
|
| 12 |
|
| 13 |
# Making the agent
|
| 14 |
+
#llm = HuggingFaceEndpoint(
|
| 15 |
+
# repo_id="Qwen/Qwen2.5-Coder-32B-Instruct",
|
| 16 |
+
# huggingfacehub_api_token=HUGGINGFACEHUB_API_TOKEN,
|
| 17 |
+
#)
|
| 18 |
+
|
| 19 |
+
|
| 20 |
+
|
| 21 |
llm = HuggingFaceEndpoint(
|
| 22 |
+
repo_id="https://api-inference.huggingface.co/models/Meta-DeepLearning/llama-2-7b-chat-hf",
|
|
|
|
| 23 |
)
|
| 24 |
|
| 25 |
+
|
| 26 |
chat = ChatHuggingFace(llm=llm, verbose=True)
|
| 27 |
tools = [add,
|
| 28 |
substract,
|