Run enterprise grade agent systems in your cloud with the AgentOS. Join the waitlist.
from agno.agent import Agent
from agno.models.ibm import WatsonX
from agno.tools.duckduckgo import DuckDuckGoTools
agent = Agent(
model=WatsonX(id="meta-llama/llama-3-3-70b-instruct"),
tools=[DuckDuckGoTools()],
show_tool_calls=True,
markdown=True,
)
agent.print_response("Whats happening in France?", stream=True)
Create a virtual environment
Terminal
and create a python virtual environment.python3 -m venv .venv
source .venv/bin/activate
Set your API key
export IBM_WATSONX_API_KEY=xxx
export IBM_WATSONX_PROJECT_ID=xxx
Install libraries
pip install -U ibm-watsonx-ai duckduckgo-search agno
Run Agent
python cookbook/models/ibm/watsonx/tool_use.py
Was this page helpful?