Documentation
¶
Overview ¶
Package bedrock connects to the Amazon Bedrock Converse API.
Index ¶
Constants ¶
const ( ProviderOptionAdditionalModelRequestFields = "additionalModelRequestFields" ProviderOptionAdditionalModelResponseFieldPaths = "additionalModelResponseFieldPaths" ProviderOptionGuardrailConfig = "guardrailConfig" ProviderOptionPerformanceConfig = "performanceConfig" ProviderOptionPromptVariables = "promptVariables" ProviderOptionRequestMetadata = "requestMetadata" )
ProviderOptions are native Converse fields copied into the body. An option naming a generated object is merged into it, so model-specific fields go under "additionalModelRequestFields".
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Config ¶
type Config struct {
// Name identifies the provider in responses, errors and ProviderState,
// "bedrock" by default.
Name string
// Region selects the endpoint and signing region, us-east-1 by default.
Region string
// BaseURL overrides the bedrock-runtime endpoint.
BaseURL string
// Credentials is required and resolved for every call.
Credentials CredentialsProvider
HTTPClient litellm.HTTPClient
}
Config configures Converse. HTTPClient, when set, sends the SigV4-signed requests; wrap it with retry.NewHTTPClient to retry.
type Credentials ¶
Credentials are AWS credentials; SessionToken is for temporary ones.
type CredentialsProvider ¶
type CredentialsProvider interface {
Credentials(context.Context) (Credentials, error)
}
CredentialsProvider supplies credentials, allowing rotation.
func StaticCredentials ¶
func StaticCredentials(accessKeyID, secretAccessKey, sessionToken string) CredentialsProvider
StaticCredentials returns a CredentialsProvider with fixed credentials.
type Provider ¶
type Provider struct {
// contains filtered or unexported fields
}
Provider implements litellm.Provider and litellm.CapabilityProvider.
func (*Provider) Capabilities ¶ added in v1.8.1
func (p *Provider) Capabilities() litellm.Capabilities
Capabilities reports the static protocol facts.