anthropic

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 13, 2026 License: MIT Imports: 8 Imported by: 0

Documentation

Overview

Package anthropic implements the LLM provider interface for Anthropic Claude models.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AnthropicAdapter

type AnthropicAdapter struct {
	// contains filtered or unexported fields
}

AnthropicAdapter implements provider.Provider for Anthropic Claude models.

func New

func New(apiKey string) *AnthropicAdapter

New creates a new Anthropic adapter with the given API key.

func (*AnthropicAdapter) Chat

Chat sends a non-streaming request to the Anthropic Messages API.

func (*AnthropicAdapter) Models

func (a *AnthropicAdapter) Models() []provider.ModelInfo

Models returns the list of supported Anthropic models.

func (*AnthropicAdapter) Name

func (a *AnthropicAdapter) Name() string

Name returns the provider identifier.

func (*AnthropicAdapter) Stream

Stream sends a streaming request to the Anthropic Messages API. Returns a channel of StreamChunk that the caller can read from.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL