View source: R/provider-azure.R
chat_azure | R Documentation |
The Azure OpenAI server hosts a number of open source models as well as proprietary models from OpenAI.
chat_azure()
supports API keys and the credentials
parameter, but it also
makes use of:
Azure service principals (when the AZURE_TENANT_ID
, AZURE_CLIENT_ID
,
and AZURE_CLIENT_SECRET
environment variables are set).
Interactive Entra ID authentication, like the Azure CLI.
Viewer-based credentials on Posit Connect. Requires the connectcreds package.
chat_azure(
endpoint = azure_endpoint(),
deployment_id,
api_version = NULL,
system_prompt = NULL,
turns = NULL,
api_key = NULL,
token = deprecated(),
credentials = NULL,
api_args = list(),
echo = c("none", "text", "all")
)
A Chat object.
## Not run:
chat <- chat_azure(deployment_id = "gpt-4o-mini")
chat$chat("Tell me three jokes about statisticians")
## End(Not run)
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.