claudeai

package
v0.0.0-...-6faa15f Latest Latest
Warning

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

Go to latest
Published: Jan 7, 2025 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ClaudeClient

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

ClaudeClient é uma estrutura que contém o cliente de ClaudeAI com suas configurações

func NewClaudeClient

func NewClaudeClient(apiKey string, model string, logger *zap.Logger) *ClaudeClient

NewClaudeClient cria um novo cliente ClaudeAI com configurações personalizáveis

func (*ClaudeClient) GetModelName

func (c *ClaudeClient) GetModelName() string

GetModelName retorna o nome do modelo configurado para ClaudeAI

func (*ClaudeClient) SendPrompt

func (c *ClaudeClient) SendPrompt(ctx context.Context, prompt string, history []models.Message) (string, error)

SendPrompt monta a requisição com o histórico e a envia para a ClaudeAI, retornando a resposta formatada

Jump to

Keyboard shortcuts

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