Documentation
¶
Index ¶
- type AnthropicModel
- func (m *AnthropicModel) GetHeaders() map[string]string
- func (m *AnthropicModel) GetUrl() string
- func (m *AnthropicModel) Model() string
- func (m *AnthropicModel) ParseResponse(rawRes []byte) (string, error)
- func (m *AnthropicModel) PreparePayload(chatHistory *chat.ChatHistory, systemPrompt string) (string, error)
- type AnthropicResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnthropicModel ¶
type AnthropicModel struct {
// contains filtered or unexported fields
}
func NewProvider ¶
func NewProvider(modelSlug string, apiKey string) *AnthropicModel
func (*AnthropicModel) GetHeaders ¶
func (m *AnthropicModel) GetHeaders() map[string]string
func (*AnthropicModel) GetUrl ¶
func (m *AnthropicModel) GetUrl() string
func (*AnthropicModel) Model ¶
func (m *AnthropicModel) Model() string
func (*AnthropicModel) ParseResponse ¶
func (m *AnthropicModel) ParseResponse(rawRes []byte) (string, error)
func (*AnthropicModel) PreparePayload ¶
func (m *AnthropicModel) PreparePayload(chatHistory *chat.ChatHistory, systemPrompt string) (string, error)
type AnthropicResponse ¶
type AnthropicResponse struct {
Content []content `json:"content"`
}
Click to show internal directories.
Click to hide internal directories.