pulsatrix 1.1.0
Loading...
Searching...
No Matches
pulsatrix::orch::AnthropicOptions Struct Reference

Settings for the Anthropic Messages API. More...

#include <provider.hpp>

Collaboration diagram for pulsatrix::orch::AnthropicOptions:

Static Public Member Functions

static AnthropicOptions FromEnv ()
 Options with the key from ANTHROPIC_API_KEY.
 

Public Attributes

Secret api_key
 
std::string base_url = "https://api.anthropic.com"
 
std::string api_version = "2023-06-01"
 
std::vector< std::string > betas
 Beta features to enable (the anthropic-beta header), for example a dated feature name.
 
bool prompt_caching = true
 Cache the tool definitions, the system prompt and the conversation so far, so each turn of a tool loop pays full price only for what's new.
 
RetryPolicy retry
 
std::chrono::milliseconds read_timeout {600'000}
 

Detailed Description

Settings for the Anthropic Messages API.

Member Function Documentation

◆ FromEnv()

static AnthropicOptions pulsatrix::orch::AnthropicOptions::FromEnv ( )
static

Options with the key from ANTHROPIC_API_KEY.

Exceptions
std::runtime_errorif the variable isn't set.

Member Data Documentation

◆ api_key

Secret pulsatrix::orch::AnthropicOptions::api_key

◆ api_version

std::string pulsatrix::orch::AnthropicOptions::api_version = "2023-06-01"

◆ base_url

std::string pulsatrix::orch::AnthropicOptions::base_url = "https://api.anthropic.com"

◆ betas

std::vector<std::string> pulsatrix::orch::AnthropicOptions::betas

Beta features to enable (the anthropic-beta header), for example a dated feature name.

◆ prompt_caching

bool pulsatrix::orch::AnthropicOptions::prompt_caching = true

Cache the tool definitions, the system prompt and the conversation so far, so each turn of a tool loop pays full price only for what's new.

◆ read_timeout

std::chrono::milliseconds pulsatrix::orch::AnthropicOptions::read_timeout {600'000}

◆ retry

RetryPolicy pulsatrix::orch::AnthropicOptions::retry

The documentation for this struct was generated from the following file: