ammr commited on
Commit
587e270
·
verified ·
1 Parent(s): cce3585

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -6
app.py CHANGED
@@ -4,7 +4,7 @@ import requests
4
  import inspect
5
  import pandas as pd
6
 
7
- from smolagents import InferenceClientModel
8
 
9
  # (Keep Constants as is)
10
  # --- Constants ---
@@ -25,13 +25,9 @@ class BasicAgent:
25
  class myAgent:
26
  def __init__(self):
27
  print("myAgent initialized.")
28
- llm = HuggingFaceEndpoint(
29
- repo_id="Qwen/Qwen2.5-Coder-32B-Instruct",
30
- huggingfacehub_api_token=HUGGINGFACEHUB_API_TOKEN,
31
- )
32
 
33
  self.agent = CodeAgent(
34
- model=InferenceClientModel(llm=llm),
35
  tools=[DuckDuckGoSearchTool()],#, WikipediaSearchTool(), SpeechToTextTool(), ExcelToTextTool()],
36
  add_base_tools=True,
37
  additional_authorized_imports=['pandas','numpy','csv']
 
4
  import inspect
5
  import pandas as pd
6
 
7
+ from smolagents import CodeAgent, InferenceClientModel
8
 
9
  # (Keep Constants as is)
10
  # --- Constants ---
 
25
  class myAgent:
26
  def __init__(self):
27
  print("myAgent initialized.")
 
 
 
 
28
 
29
  self.agent = CodeAgent(
30
+ model=InferenceClientModel(provider='novita'),
31
  tools=[DuckDuckGoSearchTool()],#, WikipediaSearchTool(), SpeechToTextTool(), ExcelToTextTool()],
32
  add_base_tools=True,
33
  additional_authorized_imports=['pandas','numpy','csv']