Example
OpenAI Params
For more information, please refer to the OpenAI docs as well.
OpenAILike is a subclass of the OpenAI class and has access to the same params.Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
from phi.agent import Agent
from phi.model.openai import OpenAIChat
agent = Agent(
model=OpenAIChat(id="gpt-4o"),
show_tool_calls=True,
markdown=True,
)
agent.print_response("What is the stock price of NVDA and TSLA")
| Parameter | Type | Default | Description |
|---|---|---|---|
id | str | - | The name of the model to be used for generating responses. |
api_key | str | - | The API key for authenticating requests to the service. |
base_url | str | - | The base URL for making API requests to the service. |
OpenAILike is a subclass of the OpenAI class and has access to the same params.Was this page helpful?