Documentation
¶
Index ¶
- type Image
- type ImageResult
- type PromptResponse
- type Server
- func (s Server) Cancel(promptId ...string) error
- func (s Server) History(promptId string, timeout *time.Duration, keys ...string) ([]*ImageResult, map[string]interface{}, error)
- func (s Server) Prompt(clientId string, prompt map[string]interface{}, ...) (*PromptResponse, error)
- func (s Server) QueueIsRunning(promptId string) (bool, error)
- func (s Server) UploadImage(payload *bytes.Buffer, writer *multipart.Writer) (*UploadImageResponse, error)
- type UploadImageResponse
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ImageResult ¶
type PromptResponse ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
func (Server) History ¶
func (s Server) History(promptId string, timeout *time.Duration, keys ...string) ([]*ImageResult, map[string]interface{}, error)
History 查询任务状态 promptId 任务id keys 要取的结果(outputs)的key
func (Server) Prompt ¶
func (s Server) Prompt(clientId string, prompt map[string]interface{}, extraData map[string]interface{}) (*PromptResponse, error)
Prompt 加入队列
func (Server) QueueIsRunning ¶ added in v0.0.26
func (Server) UploadImage ¶
func (s Server) UploadImage(payload *bytes.Buffer, writer *multipart.Writer) (*UploadImageResponse, error)
UploadImage 上传图片
type UploadImageResponse ¶
Click to show internal directories.
Click to hide internal directories.