Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ChatContext ¶
type ChatContext struct {
*api.APIContext
// contains filtered or unexported fields
}
ChatContext is context data for chat
func New ¶
func New(apiKey string, profilePath string) (*ChatContext, error)
New function create new ChatContext instance.
func (*ChatContext) Interactive ¶
func (*ChatContext) Request ¶
Request requesta OpenAI Chat completion, and returns response message. (REST access)
func (*ChatContext) RequestRaw ¶
func (cctx *ChatContext) RequestRaw(ctx context.Context, msg string) (openai.ChatCompletionResponse, error)
RequestRaw requesta OpenAI Chat completion, and returns raw response. (REST access)
Click to show internal directories.
Click to hide internal directories.