anthropic
function configures Anthropic’s Claude as your model provider.
Configuration
Theanthropic
function accepts a model name string or a configuration object:
Note:
defaultParameters.max_tokens
is required.Options
ID of the model to use. See the model endpoint
compatibility table
for details on which models work with the Anthropic API.
This option has been moved to the
The maximum number of tokens to generate before stopping.
defaultParameters
option.The maximum number of tokens to generate before stopping.
The Anthropic API key to use for authenticating your request. By default we’ll
search for and use the
ANTHROPIC_API_KEY
environment variable.The beta headers to enable, eg. for computer use, prompt caching, and so on.
The base URL for the Anthropic API.
The default parameters to use for the model (ex:
Note:
temperature
, max_tokens
,
etc).Note:
defaultParameters.max_tokens
is required.Available Models
Anthropic