Prerequisite
To start using the Autogen SDK with the AI Router, you need an API Key ready within your account.To setup your API key, see API keys & Endpoints.
To use libraries with private models, see Onboarding Private Models.
Action required: Entity management is moving from Workspaces to Projects. Migrate your entities now. See how to move entities in our guide.
Build production AI agents with Agno and the AI Router. Create tool-using agents with observability, memory, and multi-provider LLM orchestration.
from os import getenv
from agno.agent import Agent
from agno.tools.yfinance import YFinanceTools
from agno.models.openai.like import OpenAILike
agent = Agent(
model=OpenAILike(
id="openai/gpt-4o",
api_key=getenv("ORQ_API_KEY"),
base_url="https://api.orq.ai/v2/proxy",
),
tools=[YFinanceTools(stock_price=True)],
instructions="Use tables to display data. Don't include any other text.",
markdown=True,
)
# Print the response in the terminal
agent.print_response("What is the stock price of Apple?", stream=True)
Was this page helpful?