File size: 468 Bytes
9c91bee
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
# 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()