Spaces:
Sleeping
Sleeping
Update agent.py
Browse files
agent.py
CHANGED
@@ -20,9 +20,9 @@ langsmith_api_key = os.getenv("LANGSMITH_API_KEY")
|
|
20 |
langsmith_tracing = os.getenv("LANGSMITH_TRACING")
|
21 |
|
22 |
llm = ChatOpenAI(
|
23 |
-
base_url="https://
|
24 |
-
api_key=os.getenv("
|
25 |
-
model="
|
26 |
temperature=1
|
27 |
)
|
28 |
|
@@ -104,10 +104,10 @@ gaia_agent = builder.compile() # converts my builder into a runnable agent by u
|
|
104 |
class LangGraphAgent:
|
105 |
def __init__(self):
|
106 |
self.api_keys = [
|
107 |
-
os.getenv("
|
108 |
-
os.getenv("
|
109 |
-
os.getenv("
|
110 |
-
os.getenv("
|
111 |
]
|
112 |
self.key_index = 0
|
113 |
print("LangGraphAgent initialized.")
|
@@ -119,7 +119,7 @@ class LangGraphAgent:
|
|
119 |
llm = ChatOpenAI(
|
120 |
base_url="https://openrouter.ai/api/v1",
|
121 |
api_key=api_key,
|
122 |
-
model="
|
123 |
temperature=1
|
124 |
)
|
125 |
llm_with_tools = llm.bind_tools(tools)
|
|
|
20 |
langsmith_tracing = os.getenv("LANGSMITH_TRACING")
|
21 |
|
22 |
llm = ChatOpenAI(
|
23 |
+
base_url="https://api.groq.com/openai/v1",
|
24 |
+
api_key=os.getenv("GROQ_API_KEY"),
|
25 |
+
model="openai/gpt-oss-120b", # Model must support function calling in OpenRouter
|
26 |
temperature=1
|
27 |
)
|
28 |
|
|
|
104 |
class LangGraphAgent:
|
105 |
def __init__(self):
|
106 |
self.api_keys = [
|
107 |
+
os.getenv("GROQ_API_KEY"),
|
108 |
+
os.getenv("GROQ_API_KEY_1"),
|
109 |
+
os.getenv("GROQ_API_KEY_2"),
|
110 |
+
os.getenv("GROQ_API_KEY_3")
|
111 |
]
|
112 |
self.key_index = 0
|
113 |
print("LangGraphAgent initialized.")
|
|
|
119 |
llm = ChatOpenAI(
|
120 |
base_url="https://openrouter.ai/api/v1",
|
121 |
api_key=api_key,
|
122 |
+
model="openai/gpt-oss-120b",
|
123 |
temperature=1
|
124 |
)
|
125 |
llm_with_tools = llm.bind_tools(tools)
|