Spaces:
Sleeping
Sleeping
Commit
·
c9cd3b9
1
Parent(s):
4b09d90
no tools
Browse files
app.py
CHANGED
|
@@ -23,10 +23,11 @@ class BasicAgent:
|
|
| 23 |
print("BasicAgent initialized.")
|
| 24 |
llm = init_chat_model(temperature=0, model=os.getenv("MODEL_ID"), api_key=os.getenv("API_KEY"), base_url=os.getenv("API_BASE"))
|
| 25 |
|
| 26 |
-
api_wrapper = WikipediaAPIWrapper(top_k_results=1, doc_content_chars_max=100)
|
| 27 |
-
wiki = WikipediaQueryRun(api_wrapper=api_wrapper)
|
| 28 |
|
| 29 |
-
self.agent = create_react_agent(llm, tools=[wiki, DuckDuckGoSearchResults()])
|
|
|
|
| 30 |
|
| 31 |
def __call__(self, question: str) -> str:
|
| 32 |
print(f"Agent received question (first 50 chars): {question[:50]}...")
|
|
|
|
| 23 |
print("BasicAgent initialized.")
|
| 24 |
llm = init_chat_model(temperature=0, model=os.getenv("MODEL_ID"), api_key=os.getenv("API_KEY"), base_url=os.getenv("API_BASE"))
|
| 25 |
|
| 26 |
+
# api_wrapper = WikipediaAPIWrapper(top_k_results=1, doc_content_chars_max=100)
|
| 27 |
+
# wiki = WikipediaQueryRun(api_wrapper=api_wrapper)
|
| 28 |
|
| 29 |
+
# self.agent = create_react_agent(llm, tools=[wiki, DuckDuckGoSearchResults()])
|
| 30 |
+
self.agent = create_react_agent(llm, tools=[])
|
| 31 |
|
| 32 |
def __call__(self, question: str) -> str:
|
| 33 |
print(f"Agent received question (first 50 chars): {question[:50]}...")
|