Versions in this module Expand all Collapse all v0 v0.7.1 Dec 26, 2025 v0.7.0 Nov 28, 2025 Changes in this version + const ServiceRerank + const ServiceRerankAvatar + const TimeFormat type EngineRecommendConfig + DeviceType string + type FlavorConversionDef struct + Conversion []ConversionStepDef + Epilogue []string + Prologue []string + type LocalTime time.Time + func Now() LocalTime + func (t *LocalTime) Scan(v interface{}) error + func (t *LocalTime) UnmarshalJSON(data []byte) error + func (t LocalTime) After(u LocalTime) bool + func (t LocalTime) Before(u LocalTime) bool + func (t LocalTime) Format(layout string) string + func (t LocalTime) IsZero() bool + func (t LocalTime) MarshalJSON() ([]byte, error) + func (t LocalTime) ToTime() time.Time + func (t LocalTime) Value() (driver.Value, error) type ServiceProvider + Protocol string v0.6.0 Sep 12, 2025 Changes in this version + const RagServiceFileSize + const RagServiceFileTypeDOCX + const RagServiceFileTypeHTML + const RagServiceFileTypeMD + const RagServiceFileTypePDF + const RagServiceFileTypeTXT + const RagServiceFileTypeXLSX + const TableRagChunk + const TableRagFile + const TableRagVector + var SupportRagServiceFileType = []string + type RagChunk struct + ChunkIndex int + Content string + CreatedAt time.Time + Embedding datastore.Float32List + FileID string + ID string + UpdatedAt time.Time + func (t *RagChunk) Index() map[string]interface{} + func (t *RagChunk) PrimaryKey() string + func (t *RagChunk) SetCreateTime(tm time.Time) + func (t *RagChunk) SetUpdateTime(tm time.Time) + func (t *RagChunk) TableName() string + type RagFile struct + CreatedAt time.Time + EmbedModel string + FileID string + FileName string + FilePath string + FileType string + ID int + Status int + UpdatedAt time.Time + func (t *RagFile) Index() map[string]interface{} + func (t *RagFile) PrimaryKey() string + func (t *RagFile) SetCreateTime(tm time.Time) + func (t *RagFile) SetUpdateTime(tm time.Time) + func (t *RagFile) TableName() string + type RagServiceConfig struct + ChunkOverlap int + ChunkSize int + DuplicationThreshold float64 + EmbedModel string + EmbeddingDim int + ScoreThreshold float64 + TopK int type ServiceProvider + Scope string type ServiceRequest + Think bool v0.5.1 Aug 21, 2025 v0.5.0 Aug 18, 2025 Changes in this version + const AudioAac + const AudioFlac + const AudioM4a + const AudioMp3 + const AudioMp4 + const AudioOgg + const AudioWav + const AuthTypeApiKey + const AuthTypeNone + const AuthTypeSign + const AuthTypeToken + const EngineStartModeDaemon + const EngineStartModeStandard + const ExposeProtocolHTTP + const ExposeProtocolWEBSOCKET + const FlavorAOG + const FlavorAliYun + const FlavorBaidu + const FlavorDeepSeek + const FlavorOllama + const FlavorOpenAI + const FlavorOpenvino + const FlavorTencent + const GPUTypeAmd + const GPUTypeIntelArc + const GPUTypeIntelCore + const GPUTypeNone + const GPUTypeNvidia + const HybridPolicyDefault + const HybridPolicyLocal + const HybridPolicyRemote + const ImageTypeBase64 + const ImageTypePath + const ImageTypeUrl + const LanguageEn + const LanguageZh + const LogLevelDebug + const LogLevelError + const LogLevelInfo + const LogLevelWarn + const ProtocolGRPC + const ProtocolGRPC_STREAM + const ProtocolHTTP + const ProtocolHTTPS + const ServiceChat + const ServiceChatAvatar + const ServiceEmbed + const ServiceEmbedAvatar + const ServiceGenerate + const ServiceGenerateAvatar + const ServiceImageToImage + const ServiceImageToImageAvatar + const ServiceImageToVideo + const ServiceImageToVideoAvatar + const ServiceModels + const ServiceSourceLocal + const ServiceSourceRemote + const ServiceSpeechToText + const ServiceSpeechToTextAvatar + const ServiceSpeechToTextWS + const ServiceSpeechToTextWSAvatar + const ServiceTextToImage + const ServiceTextToImageAvatar + const ServiceTextToSpeech + const ServiceTextToSpeechAvatar + const ServiceTextToVideo + const TableDataMigrateVersion + const TableModel + const TableService + const TableServiceProvider + const TableVersionUpdate + const VersionRecordStatusInstalled + const VersionRecordStatusUpdated + const VoiceBaby + const VoiceFemale + const VoiceGirl + const VoiceMale + const WSActionFinishTask + const WSActionRunTask + const WSErrorCodeClientError + const WSErrorCodeModelError + const WSErrorCodeServerError + const WSEventResultGenerated + const WSEventTaskFailed + const WSEventTaskFinished + const WSEventTaskResultGenerate + const WSEventTaskStarted + const WSSTTTaskTypeAudio + const WSSTTTaskTypeFinishTask + const WSSTTTaskTypeRunTask + const WSSTTTaskTypeUnknown + const WSTaskTypeAudio + var SupportAudioType = []string + var SupportAuthType = []string + var SupportFlavor = []string + var SupportHybridPolicy = []string + var SupportImageType = []string + var SupportModelEngine = []string + var SupportOnlyRemoteService = []string + var SupportService = []string + var SupportServiceAvatar = map[string]string + var SupportVoiceType = []string + var WSRemoteLocalMap = make(map[string]*websocket.Conn) + func GetWSRemoteConnection(connID string) (*websocket.Conn, bool) + func IsDropAction(err error) bool + func RemoveWSRemoteConnection(connID string) + func SetWSRemoteConnection(connID string, conn *websocket.Conn) + type ConversionStepDef struct + Config any + Converter string + type DataMigrateVersion struct + CreatedAt time.Time + ID int + UpdatedAt time.Time + Version string + func (t *DataMigrateVersion) Index() map[string]interface{} + func (t *DataMigrateVersion) PrimaryKey() string + func (t *DataMigrateVersion) SetCreateTime(time time.Time) + func (t *DataMigrateVersion) SetUpdateTime(time time.Time) + func (t *DataMigrateVersion) TableName() string + type DeleteRequest struct + Model string + type DropAction struct + func (d *DropAction) Error() string + type EngineRecommendConfig struct + DownloadPath string + DownloadUrl string + EnginePath string + ExecFile string + ExecPath string + Host string + Origin string + RecommendModel string + Scheme string + type EngineVersionResponse struct + Version string + type HTTPContent struct + Body []byte + Header http.Header + func (hc HTTPContent) String() string + type HTTPErrorResponse struct + Body []byte + Header http.Header + StatusCode int + func (hc *HTTPErrorResponse) Error() string + type ListModelResponse struct + Details ModelDetails + Digest string + Model string + ModifiedAt time.Time + Name string + Size int64 + type ListResponse struct + Models []ListModelResponse + type LoadRequest struct + Model string + type Model struct + CreatedAt time.Time + ID int + IsDefault bool + ModelName string + ProviderName string + ServiceName string + ServiceSource string + Status string + UpdatedAt time.Time + func (t *Model) Index() map[string]interface{} + func (t *Model) PrimaryKey() string + func (t *Model) SetCreateTime(time time.Time) + func (t *Model) SetUpdateTime(time time.Time) + func (t *Model) TableName() string + type ModelDetails struct + Families []string + Family string + Format string + ParameterSize string + ParentModel string + QuantizationLevel string + type OllamaLoadModelRequest struct + Model string + type OllamaUnloadModelRequest struct + KeepAlive int64 + Model string + type PathDiskSizeInfo struct + FreeSize int + TotalSize int + UsageSize int + type ProgressResponse struct + Completed int64 + Digest string + Status string + Total int64 + type PullModelRequest struct + Insecure bool + Model string + ModelType string + Name string + Password string + Stream *bool + Username string + type PullProgressFunc func(ProgressResponse) error + type RecommendConfig struct + EngineDownloadUrl string + ModelEngine string + ModelName string + type ScheduleDetails struct + Id uint64 + IsRunning bool + ListMark *list.Element + TimeComplete time.Time + TimeEnqueue time.Time + TimeRun time.Time + type Service struct + Avatar string + CanInstall int + CreatedAt time.Time + HybridPolicy string + LocalProvider string + Name string + RemoteProvider string + Status int + UpdatedAt time.Time + func (t *Service) Index() map[string]interface{} + func (t *Service) PrimaryKey() string + func (t *Service) SetCreateTime(time time.Time) + func (t *Service) SetUpdateTime(time time.Time) + func (t *Service) TableName() string + type ServiceProvider struct + AuthKey string + AuthType string + CreatedAt time.Time + Desc string + ExtraHeaders string + ExtraJSONBody string + Flavor string + ID int + Method string + Properties string + ProviderName string + ServiceName string + ServiceSource string + Status int + URL string + UpdatedAt time.Time + func (t *ServiceProvider) Index() map[string]interface{} + func (t *ServiceProvider) PrimaryKey() string + func (t *ServiceProvider) SetCreateTime(time time.Time) + func (t *ServiceProvider) SetUpdateTime(time time.Time) + func (t *ServiceProvider) TableName() string + type ServiceProviderProperties struct + MaxInputTokens int + ModeIsChangeable bool + Models []string + SupportedResponseMode []string + XPU []string + type ServiceRequest struct + AskStreamMode bool + FromFlavor string + HTTP HTTPContent + HybridPolicy string + Model string + OriginalRequest *http.Request + Priority int + RemoteServiceProvider string + RequestExtraUrl string + RequestSegments int + Service string + WebSocketConnID string + func (sr *ServiceRequest) String() string + type ServiceResult struct + Error error + HTTP HTTPContent + StatusCode int + TaskId uint64 + Type ServiceResultType + func (sr *ServiceResult) String() string + func (sr *ServiceResult) WriteBack(w http.ResponseWriter) + type ServiceResultType int + const ServiceResultChunk + const ServiceResultDone + const ServiceResultFailed + type ServiceTarget struct + ExposeProtocol string + Location string + Model string + Protocol string + ServiceProvider *ServiceProvider + Stream bool + ToFavor string + XPU string + func (sr *ServiceTarget) String() string + type SpeechToTextParams struct + Action string + AudioFormat string + Language string + LastAudioTime int64 + MaxDuration int + Model string + ReturnFormat string + SampleRate int + Service string + TaskID string + TotalAudioBytes int + UseVAD bool + func NewSpeechToTextParams() *SpeechToTextParams + func (p *SpeechToTextParams) FromJSON(data []byte) error + func (p *SpeechToTextParams) ToJSON() ([]byte, error) + type StreamMode struct + Header http.Header + Mode StreamModeType + func (sm *StreamMode) IsStream() bool + func (sm *StreamMode) ReadChunk(reader *bufio.Reader) ([]byte, error) + func (sm *StreamMode) UnwrapChunk(chunk []byte) []byte + func (sm *StreamMode) WrapChunk(chunk []byte) []byte + type StreamModeType int + const StreamModeEventStream + const StreamModeNDJson + const StreamModeNonStream + func (st StreamModeType) String() string + type SupportModel struct + ApiFlavor string + Avatar string + Class []string + Context float32 + CreatedAt time.Time + Description string + Flavor string + Id string + InputLength int + MaxInput int + MaxOutput int + Name string + OllamaId string + OutputLength int + ParamSize float32 + ServiceName string + ServiceSource string + Size string + Think bool + ThinkSwitch bool + Tools bool + UpdatedAt time.Time + func (s *SupportModel) Index() map[string]interface{} + func (s *SupportModel) PrimaryKey() string + func (s *SupportModel) SetCreateTime(time time.Time) + func (s *SupportModel) SetUpdateTime(time time.Time) + func (s *SupportModel) TableName() string + type TextToSpeechRequest struct + Params string + Text string + Voice string + type UnloadModelRequest struct + Models []string + type VersionUpdateRecord struct + CreatedAt time.Time + ID int + ReleaseNotes string + Status int + UpdatedAt time.Time + Version string + func (t *VersionUpdateRecord) Index() map[string]interface{} + func (t *VersionUpdateRecord) PrimaryKey() string + func (t *VersionUpdateRecord) SetCreateTime(time time.Time) + func (t *VersionUpdateRecord) SetUpdateTime(time time.Time) + func (t *VersionUpdateRecord) TableName() string + type WebSocketActionMessage struct + Action string + Model string + Parameters *WebSocketParameters + Task string + TaskID string + type WebSocketEventHeader struct + Action string + ErrorCode string + ErrorMessage string + Event string + Streaming string + TaskID string + type WebSocketEventMessage struct + Header WebSocketEventHeader + Payload interface{} + func NewTaskFailedEvent(taskID, errorCode, errorMessage string) WebSocketEventMessage + func NewTaskFinishedEvent(taskID string) WebSocketEventMessage + func NewTaskStartedEvent(taskID string) WebSocketEventMessage + type WebSocketFinishTaskAction struct + func NewFinishTaskAction(taskID, model string) WebSocketFinishTaskAction + type WebSocketParameters struct + Format string + Language string + ReturnFormat string + SampleRate int + Service string + UseVAD bool + type WebSocketRecognitionOutput struct + Sentence WebSocketSentence + type WebSocketResultEvent struct + Header WebSocketEventHeader + Payload WebSocketResultPayload + func NewResultGeneratedEvent(taskID string, beginTime *int, endTime *int, text string) WebSocketResultEvent + type WebSocketResultPayload struct + Output WebSocketRecognitionOutput + type WebSocketRunTaskAction struct + func NewRunTaskAction(model string, parameters *WebSocketParameters) WebSocketRunTaskAction + type WebSocketSentence struct + BeginTime *int + EndTime *int + Text string