Versions in this module Expand all Collapse all v0 v0.1.0 May 13, 2023 Changes in this version + const UA + type Author struct + Name interface{} + Role string + type ChatUnoRequest struct + func NewRequests(jar http.CookieJar) *ChatUnoRequest + func (r *ChatUnoRequest) Do(method, baseUrl string) (*http.Response, error) + func (r *ChatUnoRequest) Get(baseUrl string) (*http.Response, error) + func (r *ChatUnoRequest) Patch(baseUrl string) (*http.Response, error) + func (r *ChatUnoRequest) Post(baseUrl string) (*http.Response, error) + func (r *ChatUnoRequest) SetBody(reader io.Reader) + func (r *ChatUnoRequest) SetCookie(name, value string) + func (r *ChatUnoRequest) SetHeaders(headers http.Header) + func (r *ChatUnoRequest) SetNoRedirects() + func (r *ChatUnoRequest) SetProxy(proxy string) + func (r *ChatUnoRequest) SetTimeout(timeout int) + type Config struct + AccessToken string + BaseUrl string + EmailAddr string + Model string + Passwd string + Proxy string + SessionToken string + type ConversationNode struct + func (node *ConversationNode) ConversationId() string + func (node *ConversationNode) CurrentNode() string + func (node *ConversationNode) SetConversationId(conversationId string) + func (node *ConversationNode) SetConversationInfo(info gjson.Result) + func (node *ConversationNode) SetCurrentNode(parentId string) + func (node *ConversationNode) SetHistory(history gjson.Result) + func (node *ConversationNode) SetTitle(title string) + func (node *ConversationNode) Title() string + type FinishDetail struct + Stop string + Type string + type Mapping struct + func NewMapping() *Mapping + func (mapping *Mapping) GetConversationNode(convId string) *ConversationNode + func (mapping *Mapping) SetConversationNode(convId string, node *ConversationNode) + type Message struct + Author Author + Content ResContent + CreateTime float64 + EndTurn bool + ID string + Metadata Metadata + Recipient string + UpdateTime *float64 + Weight float64 + type Metadata struct + FinishDetails FinishDetail + MessageType string + ModelSlug string + type NextAction struct + Action string + ConversationID *string + Messages []PromptMessage + Model interface{} + ParentMessageID string + func NewNextAction(prompt string, conversationId, parentId string, model string) *NextAction + func (nextAction *NextAction) Byte() []byte + func (nextAction *NextAction) String() string + type PromptMessage struct + Author map[string]string + Content ReqContent + ID string + Role string + type ReqContent struct + ContentType string + Parts []string + type ResContent struct + ContentType string + Parts []string + type Response struct + ConversationID string + Error *string + Message Message + Raw string + func NewResponse(text string) *Response + type UnoBot struct + func NewChatGPTUnoBot(cfg *Config) *UnoBot + func (chat *UnoBot) Ask(prompt, conversationId, parentId, model string, timeout int, ...) (err error) + func (chat *UnoBot) BaseURL() string