Documentation ¶
Index ¶
Constants ¶
View Source
const ( UserRole = openai.ChatMessageRoleUser SystemRole = openai.ChatMessageRoleSystem AssistantRole = openai.ChatMessageRoleAssistant GPT3_5Turbo = openai.GPT3Dot5Turbo GPT4 = openai.GPT4 GPT4Prefix = "gpt-4" GPT3_5Prefix = "gpt-3.5" GPT3_5CostInput = 0.0015 // USD GPT3_5CostOutput = 0.002 // USD GPT4CostInput = 0.03 // USD GPT4CostOutput = 0.06 // USD )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChatModel ¶
type ChatModel struct {
// contains filtered or unexported fields
}
func NewChatModel ¶
func (*ChatModel) AddUserMessage ¶
type ChatResponse ¶
type Engine ¶
type Engine interface { SendChat(messages []openai.ChatCompletionMessage) (ChatResponse, error) GetModel() string }
func NewMockGPT ¶
Click to show internal directories.
Click to hide internal directories.