Documentation
¶
Index ¶
- func Client(apiKey string, req types.ChatArgs) (string, error)
- func StreamClient(apiKey string, req types.ChatArgs, chunkChan chan string) error
- func StreamCompleteClient(apiKey string, req types.ChatArgs) (string, error)
- type AnthChatArgs
- func (params AnthChatArgs) Chat(apiKey string, prompt string, system string) (string, error)
- func (params AnthChatArgs) StreamChat(apiKey string, prompt string, system string, ipcChan chan string)
- func (params AnthChatArgs) StreamCompleteChat(apiKey string, prompt string, system string) (string, error)
- type ClientChatError
- type RateLimiter
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func StreamClient ¶
Types ¶
type AnthChatArgs ¶
func ChatAnth ¶
func ChatAnth(kwargs ...map[string]interface{}) AnthChatArgs
func (AnthChatArgs) StreamChat ¶
func (params AnthChatArgs) StreamChat(apiKey string, prompt string, system string, ipcChan chan string)
func (AnthChatArgs) StreamCompleteChat ¶
type ClientChatError ¶
type ClientChatError struct {
// contains filtered or unexported fields
}
ChatError represents a chat-related error.
type RateLimiter ¶
RateLimiter is a simple rate limiter implementation
func (*RateLimiter) Wait ¶
func (r *RateLimiter) Wait()
Wait blocks until it's time to allow the next request
Click to show internal directories.
Click to hide internal directories.