mmichiels13's picture
test.py
9c91bee verified
raw
history blame contribute delete
468 Bytes
# test_search.py
from smolagents import DuckDuckGoSearchTool
def test_search():
print("Testing DuckDuckGo search functionality...")
try:
search_tool = DuckDuckGoSearchTool()
result = search_tool("Python programming language")
print(f"Search successful! Found: {result[:150]}...")
return True
except Exception as e:
print(f"Search failed: {e}")
return False
if __name__ == "__main__":
test_search()