ABVM commited on
Commit
3f1dcb6
·
verified ·
1 Parent(s): 0f5b0a9

Update agent.py

Browse files
Files changed (1) hide show
  1. agent.py +15 -9
agent.py CHANGED
@@ -13,14 +13,19 @@ from vision_tool import image_reasoning_tool
13
 
14
  #token=os.getenv("HF_API_TOKEN")
15
 
16
- OPENROUTER_API_KEY = os.getenv("OPENROUTER_API_KEY")
17
- if not OPENROUTER_API_KEY:
18
- raise EnvironmentError("OPENROUTER_API_KEY environment variable not set")
 
 
 
 
 
 
19
 
20
  common = dict(
21
- api_base="https://openrouter.ai/api/v1",
22
- api_key=OPENROUTER_API_KEY,
23
- extra_body={"usage": {"include": True}}
24
  )
25
  class GaiaAgent:
26
  def __init__(self):
@@ -28,9 +33,10 @@ class GaiaAgent:
28
  #token = os.getenv("HF_API_TOKEN")
29
  #print("DEBUG: HF_API_TOKEN is", token[:6]+ "...")
30
  self.model = OpenAIServerModel(
31
- #max_tokens = 8096,
32
- temperature = 0.5,
33
- model_id = 'qwen/qwen-2.5-coder-32b-instruct:free',
 
34
  #custom_role_conversions=None,
35
  #provider="hf-inference",
36
  #token=token,
 
13
 
14
  #token=os.getenv("HF_API_TOKEN")
15
 
16
+ #OPENROUTER_API_KEY = os.getenv("OPENROUTER_API_KEY")
17
+ #if not OPENROUTER_API_KEY:
18
+ #raise EnvironmentError("OPENROUTER_API_KEY environment variable not set")
19
+
20
+ #common = dict(
21
+ #api_base="https://openrouter.ai/api/v1",
22
+ #api_key=OPENROUTER_API_KEY,
23
+ #extra_body={"usage": {"include": True}}
24
+ #)
25
 
26
  common = dict(
27
+ api_base = "https://generativelanguage.googleapis.com/v1beta/openai/",
28
+ api_key = os.getenv("GEMINI_API_KEY"),
 
29
  )
30
  class GaiaAgent:
31
  def __init__(self):
 
33
  #token = os.getenv("HF_API_TOKEN")
34
  #print("DEBUG: HF_API_TOKEN is", token[:6]+ "...")
35
  self.model = OpenAIServerModel(
36
+ max_tokens = 8096,
37
+ temperature = 0.5,
38
+ model_id = "gemini-2.0-flash",
39
+ #model_id = 'qwen/qwen-2.5-coder-32b-instruct:free',
40
  #custom_role_conversions=None,
41
  #provider="hf-inference",
42
  #token=token,