politeles commited on
Commit
0aa15b3
·
verified ·
1 Parent(s): 8485674

Update app.py

Browse files

updated HF token in env vars and removed provider to use routing through HF.

Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -38,7 +38,7 @@ def check_reasoning(final_answer,agent_memory):
38
  class BasicAgent:
39
  def __init__(self):
40
  prompt = "You are a general AI assistant. I will ask you a question. Report your thoughts, and finish your answer with the following template: FINAL ANSWER: [YOUR FINAL ANSWER]. YOUR FINAL ANSWER should be a number OR as few words as possible OR a comma separated list of numbers and/or strings. If you are asked for a number, don't use comma to write your number neither use units such as $ or percent sign unless specified otherwise. If you are asked for a string, don't use articles, neither abbreviations (e.g. for cities), and write the digits in plain text unless specified otherwise. If you are asked for a comma separated list, apply the above rules depending of whether the element to be put in the list is a number or a string."
41
- model = InferenceClientModel(model_id="Qwen/Qwen2.5-Coder-32B-Instruct", provider="together")
42
 
43
  self.web_agent = CodeAgent(
44
  model=model,
@@ -53,7 +53,7 @@ class BasicAgent:
53
  )
54
 
55
  self.agent = CodeAgent(
56
- model=InferenceClientModel("deepseek-ai/DeepSeek-R1", provider="together", max_tokens=8096),
57
  tools=[GoogleSearchTool(), VisitWebpageTool()],
58
  managed_agents=[self.web_agent],
59
  additional_authorized_imports=["pandas","json","numpy"],
 
38
  class BasicAgent:
39
  def __init__(self):
40
  prompt = "You are a general AI assistant. I will ask you a question. Report your thoughts, and finish your answer with the following template: FINAL ANSWER: [YOUR FINAL ANSWER]. YOUR FINAL ANSWER should be a number OR as few words as possible OR a comma separated list of numbers and/or strings. If you are asked for a number, don't use comma to write your number neither use units such as $ or percent sign unless specified otherwise. If you are asked for a string, don't use articles, neither abbreviations (e.g. for cities), and write the digits in plain text unless specified otherwise. If you are asked for a comma separated list, apply the above rules depending of whether the element to be put in the list is a number or a string."
41
+ model = InferenceClientModel(model_id="Qwen/Qwen2.5-Coder-32B-Instruct")
42
 
43
  self.web_agent = CodeAgent(
44
  model=model,
 
53
  )
54
 
55
  self.agent = CodeAgent(
56
+ model=InferenceClientModel("deepseek-ai/DeepSeek-R1", max_tokens=8096),
57
  tools=[GoogleSearchTool(), VisitWebpageTool()],
58
  managed_agents=[self.web_agent],
59
  additional_authorized_imports=["pandas","json","numpy"],