View Source HyperLLM.Provider.Anthropic (hyper_llm v0.5.0)

Provider implementation for Anthropic.

https://docs.anthropic.com/en/api/messages

Configuration

api_key - The API key for the Anthropic API.

api_version - The API version to use. Defaults to 2023-06-01.

congfig :hyper_llm, 
  anthropic: [
    api_key: "sk-...",
    api_version: "2023-06-01"
  ]

Summary

Functions

Check if a model is supported by the provider.

Functions

completion(messages, config)

See HyperLLM.Chat.completion/3 for more information.

model_supported?(model)

Check if a model is supported by the provider.

Supported Models:

  • claude-3-5-sonnet-latest
  • claude-3-5-sonnet-20240620
  • claude-3-5-haiku-latest
  • claude-3-5-haiku-20241022
  • claude-3-opus-20240229
  • claude-3-sonnet-20240229
  • claude-3-haiku-20240307