Documentation
¶
Index ¶
- Constants
- type AnalysisUrlDocReq
- type AppBriefConfig
- type AppKnowledgeBase
- type AppKnowledgebaseConfig
- type AppKnowledgebaseParams
- type AppModelConfig
- type AppSafetyConfig
- type AppUrlConfig
- type AppUrlCreateRequest
- type AppUrlIdRequest
- type AppUrlListRequest
- type AppUrlStatusRequest
- type AppUrlUpdateRequest
- type AssistantBrief
- type AssistantConfig
- type AssistantDeleteRequest
- type AssistantIdRequest
- type AssistantMCPToolAddRequest
- type AssistantMCPToolDelRequest
- type AssistantMCPToolEnableRequest
- type AssistantPublish
- type AssistantTemplateRequest
- type AssistantToolAddRequest
- type AssistantToolConfig
- type AssistantToolConfigRequest
- type AssistantToolDelRequest
- type AssistantToolEnableRequest
- type AssistantWorkFlowAddRequest
- type AssistantWorkFlowDelRequest
- type AssistantWorkFlowToolEnableRequest
- type Avatar
- type BaseModelRequest
- type BatchCreateDocSegmentReq
- type BatchDocMetaDataReq
- type BindKnowledgeTagReq
- type CallbackMetaData
- type CallbackUpdateDocStatusReq
- type CallbackUpdateKnowledgeStatusReq
- type ChangeExplorationAppFavoriteRequest
- type ChangeUserPasswordByEmail
- type ChatRagRequest
- type CheckFileListReq
- type CheckFileReq
- type ChildChunk
- type CleanFileReq
- type CommonCheck
- type ConversationCreateRequest
- type ConversationGetDetailListRequest
- type ConversationGetListRequest
- type ConversationIdRequest
- type ConversionStreamFile
- type ConversionStreamRequest
- type CreateDocChildSegmentReq
- type CreateDocSegmentReq
- type CreateKeywordsReq
- type CreateKnowledgeReq
- type CreateKnowledgeSplitterReq
- type CreateKnowledgeTagReq
- type CreateOauthAppReq
- type CreatePromptByTemplateReq
- type CreateSensitiveWordTableReq
- type CreateWorkflowByTemplateReq
- type CustomHomeConfig
- type CustomLoginConfig
- type CustomModelInfo
- type CustomPromptCreate
- type CustomPromptIDReq
- type CustomTabConfig
- type CustomToolCreate
- type CustomToolIDReq
- type CustomToolSchemaReq
- type CustomToolUpdateReq
- type DelApiKeyRequest
- type DeleteAgentScopeWorkFlowRequest
- type DeleteAppSpaceAppRequest
- type DeleteDocChildSegmentReq
- type DeleteDocReq
- type DeleteDocSegmentReq
- type DeleteFileReq
- type DeleteKeywordsReq
- type DeleteKnowledge
- type DeleteKnowledgeSplitterReq
- type DeleteKnowledgeTagReq
- type DeleteModelRequest
- type DeleteOauthAppReq
- type DeleteSensitiveVocabularyReq
- type DeleteSensitiveWordTableReq
- type DocChildListReq
- type DocImportReq
- type DocInfo
- type DocListReq
- type DocMetaData
- type DocMetaDataReq
- type DocSegment
- type DocSegmentLabelsReq
- type DocSegmentListReq
- type EmbeddingModel
- type FileUrlConvertBase64Req
- type GenApiKeyRequest
- type GetApiBaseUrlRequest
- type GetApiKeyListRequest
- type GetAppSpaceAppListRequest
- type GetExplorationAppListRequest
- type GetKeywordsDetailReq
- type GetKnowledgeMetaSelectReq
- type GetKnowledgeReq
- type GetKnowledgeSplitterReq
- type GetModelByIdRequest
- type GetModelRequest
- type GetSensitiveVocabularyReq
- type GetWorkflowListReq
- type History
- type HistoryItem
- type ImportOrUpdateModelRequest
- type KnowledgeBatchSelectReq
- type KnowledgeGraph
- type KnowledgeGraphReq
- type KnowledgeHitReq
- type KnowledgeMatchParams
- type KnowledgeMetaValueListReq
- type KnowledgeOrgSelectReq
- type KnowledgeReportAddReq
- type KnowledgeReportBatchAddReq
- type KnowledgeReportDeleteReq
- type KnowledgeReportGenerateReq
- type KnowledgeReportSelectReq
- type KnowledgeReportUpdateReq
- type KnowledgeSelectReq
- type KnowledgeTagBindCountReq
- type KnowledgeTagSelectReq
- type KnowledgeTransferUserAdminReq
- type KnowledgeUserAddReq
- type KnowledgeUserDeleteReq
- type KnowledgeUserEditReq
- type KnowledgeUserInfo
- type KnowledgeUserNoPermitSelectReq
- type KnowledgeUserSelectReq
- type ListKeywordsReq
- type ListModelsRequest
- type ListTypeModelsRequest
- type Login
- type LoginEmailCheck
- type LoginSendEmailCode
- type MCPActionListReq
- type MCPActionReq
- type MCPCreate
- type MCPIDReq
- type MCPServerCreateReq
- type MCPServerIDReq
- type MCPServerOpenAPIToolCreate
- type MCPServerToolCreateReq
- type MCPServerToolIDReq
- type MCPServerToolUpdateReq
- type MCPServerUpdateReq
- type MCPUpdate
- type MergeFileReq
- type MetaDataFilterParams
- type MetaFilterParams
- type MetaItem
- type MetadataFilterItem
- type ModelConfig
- type ModelStatusRequest
- type OAuthRefreshRequest
- type OAuthRequest
- type OAuthTokenRequest
- type OpenAPIAgentChatRequest
- type OpenAPIAgentCreateConversationRequest
- type OpenAPIChatflowChatRequest
- type OpenAPIChatflowCreateConversationRequest
- type OpenAPIRagChatRequest
- type OrgCreate
- type OrgID
- type OrgStatus
- type OrgUpdate
- type OrgUserAdd
- type PageSearch
- type PromptOptimizeReq
- type ProxyUploadFileReq
- type PublishAgentScopeWorkFlowRequest
- type PublishAppRequest
- type QueryKnowledgeReq
- type RagBrief
- type RagConfig
- type RagKnowledgeChatReq
- type RagKnowledgeInfo
- type RagReq
- type RagSearchKnowledgeBaseReq
- type RegisterByEmail
- type RegisterSendEmailCode
- type ResetPasswordByEmail
- type ResetPasswordSendEmailCode
- type RoleCreate
- type RoleID
- type RoleStatus
- type RoleUpdate
- type SearchKnowledgeInfoReq
- type SensitiveTable
- type ToolActionListReq
- type ToolActionReq
- type ToolSquareAPIKeyReq
- type UnPublishAgentScopeWorkFlowRequest
- type UnPublishAppRequest
- type UpdateCustomPrompt
- type UpdateDocChildSegmentReq
- type UpdateDocSegmentReq
- type UpdateDocSegmentStatusReq
- type UpdateKeywordsReq
- type UpdateKnowledgeReq
- type UpdateKnowledgeSplitterReq
- type UpdateKnowledgeTagReq
- type UpdateMetaValueReq
- type UpdateOauthAppReq
- type UpdateOauthAppStatusReq
- type UpdateSensitiveWordTableReplyReq
- type UpdateSensitiveWordTableReq
- type UploadFileReq
- type UploadSensitiveVocabularyReq
- type UrlConversationCreateRequest
- type UrlConversationIdRequest
- type UrlConversionStreamRequest
- type UserAvatarUpdate
- type UserCreate
- type UserID
- type UserInfo
- type UserPassword
- type UserPasswordByAdmin
- type UserStatus
- type UserUpdate
- type VisionConfig
- type WeightParams
- type WorkflowIDReq
- type WorkflowUploadFileByBase64Req
- type WorkflowUploadFileReq
Constants ¶
View Source
const ( DocAnalyzerOCR = "ocr" DocAnalyzerPdfParser = "model" CommonSplitMethod = "0" //通用分段 ParentSplitMethod = "1" //父子分段 )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AnalysisUrlDocReq ¶
type AnalysisUrlDocReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"`
UrlList []string `json:"urlList" validate:"required"`
CommonCheck
}
type AppBriefConfig ¶
type AppBriefConfig struct {
Avatar Avatar `json:"avatar"` // 图标
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc"` // 描述
}
func (AppBriefConfig) Check ¶
func (a AppBriefConfig) Check() error
type AppKnowledgeBase ¶
type AppKnowledgeBase struct {
ID string `json:"id" validate:"required"` // 知识库id
Name string `json:"name"`
GraphSwitch int32 `json:"graphSwitch"` // 知识图谱开关
MetaDataFilterParams *MetaDataFilterParams `json:"metaDataFilterParams"`
}
type AppKnowledgebaseConfig ¶
type AppKnowledgebaseConfig struct {
Knowledgebases []AppKnowledgeBase `json:"knowledgebases"` // 知识库id、名字
Config AppKnowledgebaseParams `json:"config"` // 知识库参数
}
type AppKnowledgebaseParams ¶
type AppKnowledgebaseParams struct {
MaxHistory int32 `json:"maxHistory"` // 最长上下文
Threshold float32 `json:"threshold"` // 过滤阈值
TopK int32 `json:"topK"` // 知识条数
MatchType string `json:"matchType"` //matchType:vector(向量检索)、text(文本检索)、mix(混合检索:向量+文本)
PriorityMatch int32 `json:"priorityMatch"` // 权重匹配,只有在混合检索模式下,选择权重设置后,这个才设置为1
SemanticsPriority float32 `json:"semanticsPriority"` // 语义权重
KeywordPriority float32 `json:"keywordPriority"` // 关键词权重
TermWeight float32 `json:"termWeight"` // 关键词系数,默认为1
TermWeightEnable bool `json:"termWeightEnable"` // 关键词系数开关
UseGraph bool `json:"useGraph"` // 知识图谱开关
}
type AppModelConfig ¶
type AppModelConfig struct {
Provider string `json:"provider"` // 模型供应商
Model string `json:"model"` // 模型名称
ModelId string `json:"modelId"` // 模型ID
ModelType string `json:"modelType"` // 模型类型(llm/embedding/rerank)
DisplayName string `json:"displayName"` // 模型展示名称(请求非必填)
Config interface{} `json:"config"` // 模型配置
Examples *mp.AppModelParams // 仅用于swagger展示;模型对应供应商中的对应llm、embedding或rerank结构是config实际的参数
}
func (*AppModelConfig) Check ¶
func (cfg *AppModelConfig) Check() error
func (*AppModelConfig) ConfigString ¶
func (cfg *AppModelConfig) ConfigString() (string, error)
type AppSafetyConfig ¶ added in v0.1.5
type AppSafetyConfig struct {
Enable bool `json:"enable"` // 安全护栏(开关)
Tables []SensitiveTable `json:"tables"`
}
type AppUrlConfig ¶ added in v0.1.7
type AppUrlConfig struct {
Name string `json:"name" validate:"required"` // 名称
ExpiredAt string `json:"expiredAt"` // 过期时间
Copyright string `json:"copyright"` // 版权
CopyrightEnable bool `json:"copyrightEnable"` // 版权开关
PrivacyPolicy string `json:"privacyPolicy"` // 隐私协议
PrivacyPolicyEnable bool `json:"privacyPolicyEnable"` // 隐私协议开关
Disclaimer string `json:"disclaimer"` // 免责声明
DisclaimerEnable bool `json:"disclaimerEnable"` // 免责声明开关
Description string `json:"description"`
}
func (AppUrlConfig) Check ¶ added in v0.1.7
func (cfg AppUrlConfig) Check() error
type AppUrlCreateRequest ¶ added in v0.1.7
type AppUrlCreateRequest struct {
AppId string `json:"appId" validate:"required"` // 应用id
AppType string `json:"appType" validate:"required"` // 应用类型
AppUrlConfig
}
type AppUrlIdRequest ¶ added in v0.1.7
type AppUrlIdRequest struct {
UrlId string `json:"urlId" form:"urlId" validate:"required"` // UrlID
}
func (*AppUrlIdRequest) Check ¶ added in v0.1.7
func (a *AppUrlIdRequest) Check() error
type AppUrlListRequest ¶ added in v0.1.7
type AppUrlListRequest struct {
AppId string `json:"appId" form:"appId" validate:"required"` // 应用id
AppType string `json:"appType" form:"appType" validate:"required"` // 应用类型
}
func (*AppUrlListRequest) Check ¶ added in v0.1.7
func (a *AppUrlListRequest) Check() error
type AppUrlStatusRequest ¶ added in v0.1.7
type AppUrlStatusRequest struct {
UrlId string `json:"urlId" validate:"required"` // UrlID
Status bool `json:"status"` // 启停状态
}
func (*AppUrlStatusRequest) Check ¶ added in v0.1.7
func (a *AppUrlStatusRequest) Check() error
type AppUrlUpdateRequest ¶ added in v0.1.7
type AppUrlUpdateRequest struct {
UrlId string `json:"urlId" validate:"required"` // UrlID
AppUrlConfig
}
type AssistantBrief ¶
type AssistantBrief struct {
AssistantId string `json:"assistantId" validate:"required"`
AppBriefConfig
}
func (*AssistantBrief) Check ¶
func (a *AssistantBrief) Check() error
type AssistantConfig ¶
type AssistantConfig struct {
AssistantId string `json:"assistantId" validate:"required"`
Prologue string `json:"prologue"` // 开场白
Instructions string `json:"instructions"` // 系统提示词
RecommendQuestion []string `json:"recommendQuestion"` // 推荐问题
ModelConfig AppModelConfig `json:"modelConfig"` // 模型
KnowledgeBaseConfig AppKnowledgebaseConfig `json:"knowledgeBaseConfig"` // 知识库
SafetyConfig AppSafetyConfig `json:"safetyConfig"` // 敏感词表配置
RerankConfig AppModelConfig `json:"rerankConfig"` // Rerank模型
VisionConfig VisionConfig `json:"visionConfig"` // 视觉配置
}
func (*AssistantConfig) Check ¶
func (a *AssistantConfig) Check() error
type AssistantDeleteRequest ¶
type AssistantDeleteRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
}
func (*AssistantDeleteRequest) Check ¶
func (a *AssistantDeleteRequest) Check() error
type AssistantIdRequest ¶
type AssistantIdRequest struct {
AssistantId string `json:"assistantId" form:"assistantId" validate:"required"`
}
func (*AssistantIdRequest) Check ¶
func (a *AssistantIdRequest) Check() error
type AssistantMCPToolAddRequest ¶ added in v0.1.8
type AssistantMCPToolAddRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
MCPId string `json:"mcpId" validate:"required"`
MCPType string `json:"mcpType" validate:"required,oneof=mcp mcpserver"`
ActionName string `json:"actionName" validate:"required"`
}
func (*AssistantMCPToolAddRequest) Check ¶ added in v0.1.8
func (m *AssistantMCPToolAddRequest) Check() error
type AssistantMCPToolDelRequest ¶ added in v0.1.8
type AssistantMCPToolDelRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
MCPId string `json:"mcpId" validate:"required"`
MCPType string `json:"mcpType" validate:"required,oneof=mcp mcpserver"`
ActionName string `json:"actionName" validate:"required"`
}
func (*AssistantMCPToolDelRequest) Check ¶ added in v0.1.8
func (w *AssistantMCPToolDelRequest) Check() error
type AssistantMCPToolEnableRequest ¶ added in v0.1.8
type AssistantMCPToolEnableRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
MCPId string `json:"mcpId" validate:"required"`
MCPType string `json:"mcpType" validate:"required,oneof=mcp mcpserver"`
ActionName string `json:"actionName" validate:"required"`
Enable bool `json:"enable"`
}
func (*AssistantMCPToolEnableRequest) Check ¶ added in v0.1.8
func (a *AssistantMCPToolEnableRequest) Check() error
type AssistantPublish ¶
type AssistantPublish struct {
AssistantId string `json:"assistantId" validate:"required"`
Scope int32 `json:"scope" validate:"required"`
}
func (*AssistantPublish) Check ¶
func (a *AssistantPublish) Check() error
type AssistantTemplateRequest ¶ added in v0.1.2
type AssistantTemplateRequest struct {
AssistantTemplateId string `json:"assistantTemplateId" form:"assistantTemplateId" validate:"required"`
}
func (*AssistantTemplateRequest) Check ¶ added in v0.1.2
func (a *AssistantTemplateRequest) Check() error
type AssistantToolAddRequest ¶ added in v0.2.5
type AssistantToolAddRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
ToolId string `json:"toolId" validate:"required"`
ToolType string `json:"toolType" validate:"required,oneof=builtin custom"`
ActionName string `json:"actionName" validate:"required"`
}
func (*AssistantToolAddRequest) Check ¶ added in v0.2.5
func (c *AssistantToolAddRequest) Check() error
type AssistantToolConfig ¶ added in v0.2.7
type AssistantToolConfig struct {
RerankId string `json:"rerankId,omitempty"`
}
type AssistantToolConfigRequest ¶ added in v0.2.6
type AssistantToolConfigRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
ToolId string `json:"toolId" validate:"required"`
ToolConfig AssistantToolConfig `json:"toolConfig" validate:"required"`
}
func (*AssistantToolConfigRequest) Check ¶ added in v0.2.6
func (c *AssistantToolConfigRequest) Check() error
type AssistantToolDelRequest ¶ added in v0.2.5
type AssistantToolDelRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
ToolId string `json:"toolId" validate:"required"`
ToolType string `json:"toolType" validate:"required,oneof=builtin custom"`
ActionName string `json:"actionName" validate:"required"`
}
func (*AssistantToolDelRequest) Check ¶ added in v0.2.5
func (c *AssistantToolDelRequest) Check() error
type AssistantToolEnableRequest ¶ added in v0.2.5
type AssistantToolEnableRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
ToolId string `json:"toolId" validate:"required"`
ToolType string `json:"toolType" validate:"required,oneof=builtin custom"`
ActionName string `json:"actionName" validate:"required"`
Enable bool `json:"enable"`
}
func (*AssistantToolEnableRequest) Check ¶ added in v0.2.5
func (c *AssistantToolEnableRequest) Check() error
type AssistantWorkFlowAddRequest ¶ added in v0.1.8
type AssistantWorkFlowAddRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
WorkFlowId string `json:"workFlowId" validate:"required"`
}
func (*AssistantWorkFlowAddRequest) Check ¶ added in v0.1.8
func (w *AssistantWorkFlowAddRequest) Check() error
type AssistantWorkFlowDelRequest ¶ added in v0.1.8
type AssistantWorkFlowDelRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
WorkFlowId string `json:"workFlowId" validate:"required"`
}
func (*AssistantWorkFlowDelRequest) Check ¶ added in v0.1.8
func (w *AssistantWorkFlowDelRequest) Check() error
type AssistantWorkFlowToolEnableRequest ¶ added in v0.1.8
type AssistantWorkFlowToolEnableRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
WorkFlowId string `json:"workFlowId" validate:"required"`
Enable bool `json:"enable"`
}
func (*AssistantWorkFlowToolEnableRequest) Check ¶ added in v0.1.8
func (w *AssistantWorkFlowToolEnableRequest) Check() error
type BaseModelRequest ¶ added in v0.2.1
type BaseModelRequest struct {
ModelId string `json:"modelId" form:"modelId" validate:"required"`
}
type BatchCreateDocSegmentReq ¶ added in v0.2.1
type BatchCreateDocSegmentReq struct {
DocId string `json:"docId" validate:"required"` // 文档id
FileUploadId string `json:"fileUploadId" validate:"required"` // fileUploadId
CommonCheck
}
type BatchDocMetaDataReq ¶ added in v0.2.3
type BatchDocMetaDataReq struct {
KnowledgeId string `json:"knowledgeId"`
MetaDataList []*DocMetaData `json:"metaDataList"` //文档元数据
CreateMeta bool `json:"createMeta"` //文档没设置过对应key则创建元数据
}
func (*BatchDocMetaDataReq) Check ¶ added in v0.2.3
func (c *BatchDocMetaDataReq) Check() error
type BindKnowledgeTagReq ¶ added in v0.1.3
type BindKnowledgeTagReq struct {
TagIdList []string `json:"tagIdList" form:"tagIdList" validate:"required"`
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
Option int `json:"option" form:"option" ` //0:bind,1:unbind
CommonCheck
}
type CallbackMetaData ¶ added in v0.1.7
type CallbackUpdateDocStatusReq ¶
type CallbackUpdateDocStatusReq struct {
DocId string `json:"id" validate:"required"`
Status int32 `json:"status" validate:"required"`
MetaDataList []*CallbackMetaData `json:"metaDataList"`
CommonCheck
}
type CallbackUpdateKnowledgeStatusReq ¶ added in v0.2.7
type CallbackUpdateKnowledgeStatusReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"`
ReportStatus int32 `json:"reportStatus" validate:"required"` //此状态不会是0
CommonCheck
}
type ChangeExplorationAppFavoriteRequest ¶
type ChangeExplorationAppFavoriteRequest struct {
AppId string `json:"appId" validate:"required"` // 应用id
AppType string `json:"appType" validate:"required"` // 应用类型
IsFavorite bool `json:"isFavorite"` // 是否收藏
}
func (ChangeExplorationAppFavoriteRequest) Check ¶
func (c ChangeExplorationAppFavoriteRequest) Check() error
type ChangeUserPasswordByEmail ¶ added in v0.2.4
type ChangeUserPasswordByEmail struct {
OldPassword string `json:"oldPassword" validate:"required"`
NewPassword string `json:"newPassword" validate:"required"`
Email string `json:"email" validate:"required"` // 邮箱
Code string `json:"code" validate:"required"` // 邮箱验证码
}
func (*ChangeUserPasswordByEmail) Check ¶ added in v0.2.4
func (c *ChangeUserPasswordByEmail) Check() error
type ChatRagRequest ¶
type ChatRagRequest struct {
RagID string `json:"ragId" validate:"required"`
Question string `json:"question" validate:"required"`
History []*History `json:"history"`
}
func (ChatRagRequest) Check ¶
func (c ChatRagRequest) Check() error
type CheckFileListReq ¶
type CheckFileListReq struct {
ChunkName string `json:"chunkName" form:"chunkName" validate:"required"` //上传批次标识
}
func (*CheckFileListReq) Check ¶
func (c *CheckFileListReq) Check() error
type CheckFileReq ¶
type CheckFileReq struct {
FileName string `json:"fileName" form:"fileName" validate:"required"` //原始文件名
Sequence int `json:"sequence" form:"sequence" validate:"gt=0"` //分片文件序号
ChunkName string `json:"chunkName" form:"chunkName" validate:"required"` //上传批次标识
}
func (*CheckFileReq) Check ¶
func (c *CheckFileReq) Check() error
type ChildChunk ¶ added in v0.2.4
type CleanFileReq ¶
type CleanFileReq struct {
ChunkName string `json:"chunkName" form:"chunkName" validate:"required"` //上传批次标识
}
func (*CleanFileReq) Check ¶
func (c *CleanFileReq) Check() error
type CommonCheck ¶
type CommonCheck struct {
}
func (*CommonCheck) Check ¶
func (c *CommonCheck) Check() error
type ConversationCreateRequest ¶
type ConversationCreateRequest struct {
AssistantId string `json:"assistantId" validate:"required"`
Prompt string `json:"prompt" validate:"required"`
}
func (*ConversationCreateRequest) Check ¶
func (c *ConversationCreateRequest) Check() error
type ConversationGetDetailListRequest ¶
type ConversationGetDetailListRequest struct {
ConversationId string `json:"conversationId" form:"conversationId" validate:"required"`
PageSize int `json:"pageSize" form:"pageSize" validate:"required"`
PageNo int `json:"pageNo" form:"pageNo" validate:"required"`
}
func (*ConversationGetDetailListRequest) Check ¶
func (c *ConversationGetDetailListRequest) Check() error
type ConversationGetListRequest ¶
type ConversationGetListRequest struct {
AssistantId string `json:"assistantId" form:"assistantId" validate:"required"`
PageSize int `json:"pageSize" form:"pageSize" validate:"required"`
PageNo int `json:"pageNo" form:"pageNo" validate:"required"`
}
func (*ConversationGetListRequest) Check ¶
func (c *ConversationGetListRequest) Check() error
type ConversationIdRequest ¶
type ConversationIdRequest struct {
ConversationId string `json:"conversationId" form:"conversationId" validate:"required"`
}
func (*ConversationIdRequest) Check ¶
func (c *ConversationIdRequest) Check() error
type ConversionStreamFile ¶
type ConversionStreamRequest ¶
type ConversionStreamRequest struct {
AssistantId string `json:"assistantId" form:"assistantId" validate:"required"`
ConversationId string `json:"conversationId" form:"conversionId"`
FileInfo []ConversionStreamFile `json:"fileInfo" form:"fileInfo"`
Trial bool `json:"trial" form:"trial"`
Prompt string `json:"prompt" form:"prompt" validate:"required"`
SystemPrompt string `json:"systemPrompt" form:"systemPrompt"`
}
func (*ConversionStreamRequest) Check ¶
func (c *ConversionStreamRequest) Check() error
type CreateDocChildSegmentReq ¶ added in v0.2.4
type CreateDocChildSegmentReq struct {
DocId string `json:"docId" validate:"required"` // 文档id
ParentId string `json:"parentId" validate:"required"` // 父分段id
Content []string `json:"content" validate:"required"` // 分段内容
CommonCheck
}
type CreateDocSegmentReq ¶ added in v0.2.0
type CreateDocSegmentReq struct {
DocId string `json:"docId" validate:"required"` // 文档id
Labels []string `json:"labels" validate:"required"` // 关键词列表
Content string `json:"content" validate:"required"` // 分段内容
CommonCheck
}
type CreateKeywordsReq ¶ added in v0.1.4
type CreateKeywordsReq struct {
Name string `json:"name" validate:"required"`
Alias string `json:"alias" validate:"required"`
KnowledgeBaseIds []string `json:"knowledgeBaseIds" validate:"required"`
CommonCheck
}
type CreateKnowledgeReq ¶
type CreateKnowledgeReq struct {
Name string `json:"name" validate:"required"`
Description string `json:"description"`
EmbeddingModel *EmbeddingModel `json:"embeddingModelInfo" validate:"required"`
KnowledgeGraph *KnowledgeGraph `json:"knowledgeGraph" validate:"required"`
}
func (*CreateKnowledgeReq) Check ¶
func (c *CreateKnowledgeReq) Check() error
type CreateKnowledgeSplitterReq ¶ added in v0.1.6
type CreateKnowledgeSplitterReq struct {
SplitterName string `json:"splitterName" form:"splitterName" validate:"required"`
SplitterValue string `json:"splitterValue" form:"splitterValue" validate:"required"`
CommonCheck
}
type CreateKnowledgeTagReq ¶ added in v0.1.3
type CreateKnowledgeTagReq struct {
TagName string `json:"tagName" form:"tagName" validate:"required"`
CommonCheck
}
type CreateOauthAppReq ¶ added in v0.2.7
type CreateOauthAppReq struct {
Name string `json:"name" validate:"required"`
Desc string `json:"desc"`
RedirectURI string `json:"redirectUri" validate:"required"`
}
func (*CreateOauthAppReq) Check ¶ added in v0.2.7
func (c *CreateOauthAppReq) Check() error
type CreatePromptByTemplateReq ¶ added in v0.2.6
type CreatePromptByTemplateReq struct {
TemplateId string `json:"templateId" validate:"required"`
AppBriefConfig
}
func (*CreatePromptByTemplateReq) Check ¶ added in v0.2.6
func (req *CreatePromptByTemplateReq) Check() error
type CreateSensitiveWordTableReq ¶ added in v0.1.5
type CreateSensitiveWordTableReq struct {
TableName string `json:"tableName" validate:"required"` // 敏感词表名
Remark string `json:"remark"` // 备注
CommonCheck
}
type CreateWorkflowByTemplateReq ¶ added in v0.2.5
type CreateWorkflowByTemplateReq struct {
TemplateId string `json:"templateId" validate:"required"`
AppBriefConfig
}
func (*CreateWorkflowByTemplateReq) Check ¶ added in v0.2.5
func (r *CreateWorkflowByTemplateReq) Check() error
type CustomHomeConfig ¶ added in v0.1.6
type CustomHomeConfig struct {
HomeLogo Avatar `json:"homeLogo"` // 平台图标
HomeName string `json:"homeName"` // 平台名称
HomeBgColor string `json:"homeBgColor"` // 平台背景颜色
CommonCheck
}
type CustomLoginConfig ¶ added in v0.1.6
type CustomLoginConfig struct {
LoginBg Avatar `json:"loginBg"` // 登录页背景图
LoginLogo Avatar `json:"loginLogo"` // 登录页图标
LoginWelcomeText string `json:"loginWelcomeText"` // 登录页欢迎语
LoginButtonColor string `json:"loginButtonColor"` // 登录按钮颜色
CommonCheck
}
type CustomModelInfo ¶ added in v0.2.5
type CustomModelInfo struct {
LlmModelID string `json:"llm_model_id"`
}
type CustomPromptCreate ¶ added in v0.2.6
type CustomPromptCreate struct {
Avatar Avatar `json:"avatar"` // 图标
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc" validate:"required"` // 描述
Prompt string `json:"prompt" validate:"required"` // 提示词
}
func (*CustomPromptCreate) Check ¶ added in v0.2.6
func (req *CustomPromptCreate) Check() error
type CustomPromptIDReq ¶ added in v0.2.6
type CustomPromptIDReq struct {
CustomPromptID string `json:"customPromptId" validate:"required"` // 自定义提示词ID
}
func (*CustomPromptIDReq) Check ¶ added in v0.2.6
func (req *CustomPromptIDReq) Check() error
type CustomTabConfig ¶ added in v0.1.6
type CustomTabConfig struct {
TabLogo Avatar `json:"tabLogo"` // 标签页图标
TabTitle string `json:"tabTitle"` // 标签页标题
CommonCheck
}
type CustomToolCreate ¶ added in v0.1.8
type CustomToolCreate struct {
Avatar Avatar `json:"avatar"` // 图标
Name string `json:"name" validate:"required"` // 名称
Description string `json:"description" validate:"required"` // 描述
ApiAuth util.ApiAuthWebRequest `json:"apiAuth" validate:"required"` // api身份认证
Schema string `json:"schema" validate:"required"` // schema
PrivacyPolicy string `json:"privacyPolicy"` // 隐私政策
}
func (*CustomToolCreate) Check ¶ added in v0.1.8
func (req *CustomToolCreate) Check() error
type CustomToolIDReq ¶ added in v0.1.8
type CustomToolIDReq struct {
CustomToolID string `json:"customToolId" validate:"required"` // 自定义工具id
}
func (*CustomToolIDReq) Check ¶ added in v0.1.8
func (req *CustomToolIDReq) Check() error
type CustomToolSchemaReq ¶ added in v0.1.8
type CustomToolSchemaReq struct {
Schema string `json:"schema" validate:"required"` // schema
}
func (*CustomToolSchemaReq) Check ¶ added in v0.1.8
func (req *CustomToolSchemaReq) Check() error
type CustomToolUpdateReq ¶ added in v0.1.8
type CustomToolUpdateReq struct {
Avatar Avatar `json:"avatar"` // 图标
CustomToolID string `json:"customToolId" validate:"required"` // 自定义工具ID
Name string `json:"name" validate:"required"` // 名称
Description string `json:"description" validate:"required"` // 描述
ApiAuth util.ApiAuthWebRequest `json:"apiAuth" validate:"required"` // api身份认证
Schema string `json:"schema" validate:"required"` // schema
PrivacyPolicy string `json:"privacyPolicy"` // 隐私政策
}
func (*CustomToolUpdateReq) Check ¶ added in v0.1.8
func (req *CustomToolUpdateReq) Check() error
type DelApiKeyRequest ¶
type DelApiKeyRequest struct {
ApiId string `json:"apiId" validate:"required"` // ApiID
}
func (DelApiKeyRequest) Check ¶
func (d DelApiKeyRequest) Check() error
type DeleteAgentScopeWorkFlowRequest ¶ added in v0.1.8
type DeleteAgentScopeWorkFlowRequest struct {
AppId string `form:"workflowID" json:"workflowID" validate:"required"` // 应用ID
}
func (*DeleteAgentScopeWorkFlowRequest) Check ¶ added in v0.1.8
func (o *DeleteAgentScopeWorkFlowRequest) Check() error
type DeleteAppSpaceAppRequest ¶
type DeleteAppSpaceAppRequest struct {
AppId string `json:"appId" validate:"required"` // 应用ID
AppType string `json:"appType" validate:"required"` // 应用类型
}
func (DeleteAppSpaceAppRequest) Check ¶
func (req DeleteAppSpaceAppRequest) Check() error
type DeleteDocChildSegmentReq ¶ added in v0.2.4
type DeleteDocChildSegmentReq struct {
DocId string `json:"docId" validate:"required"` // 文档id
ParentId string `json:"parentId" validate:"required"` // 父分段id
ParentChunkNo int32 `json:"parentChunkNo"` // 父分段序列号
ChildChunkNoList []int32 `json:"ChildChunkNoList" validate:"required"` // 子分段序列号列表
CommonCheck
}
type DeleteDocReq ¶
type DeleteDocReq struct {
DocIdList []string `json:"docIdList" validate:"required"`
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
CommonCheck
}
type DeleteDocSegmentReq ¶ added in v0.2.1
type DeleteDocSegmentReq struct {
DocId string `json:"docId" validate:"required"` // 文档id
ContentId string `json:"contentId" validate:"required"`
CommonCheck
}
type DeleteFileReq ¶
type DeleteFileReq struct {
FileList []string `json:"fileList" form:"fileList"` //文件列表
IsExpired bool `json:"isExpired" form:"isExpired"` //minio存储文件是否过期 0:过期,1:不过期
}
func (*DeleteFileReq) Check ¶
func (c *DeleteFileReq) Check() error
type DeleteKeywordsReq ¶ added in v0.1.4
type DeleteKeywordsReq struct {
Id uint32 `json:"id"`
CommonCheck
}
type DeleteKnowledge ¶
type DeleteKnowledge struct {
KnowledgeId string `json:"knowledgeId" validate:"required"`
CommonCheck
}
type DeleteKnowledgeSplitterReq ¶ added in v0.1.6
type DeleteKnowledgeSplitterReq struct {
SplitterId string `json:"splitterId" form:"splitterId" validate:"required"`
CommonCheck
}
type DeleteKnowledgeTagReq ¶ added in v0.1.3
type DeleteKnowledgeTagReq struct {
TagId string `json:"tagId" form:"tagId" validate:"required"`
CommonCheck
}
type DeleteModelRequest ¶
type DeleteModelRequest struct {
BaseModelRequest
}
func (*DeleteModelRequest) Check ¶
func (o *DeleteModelRequest) Check() error
type DeleteOauthAppReq ¶ added in v0.2.7
type DeleteOauthAppReq struct {
ClientID string `json:"clientId" validate:"required"`
}
func (*DeleteOauthAppReq) Check ¶ added in v0.2.7
func (d *DeleteOauthAppReq) Check() error
type DeleteSensitiveVocabularyReq ¶ added in v0.1.5
type DeleteSensitiveVocabularyReq struct {
TableId string `json:"tableId" validate:"required"` // 敏感词表id
WordId string `json:"wordId" validate:"required"` // 敏感词id
CommonCheck
}
type DeleteSensitiveWordTableReq ¶ added in v0.1.5
type DeleteSensitiveWordTableReq struct {
TableId string `json:"tableId" validate:"required"` // 敏感词表id
CommonCheck
}
type DocChildListReq ¶ added in v0.2.3
type DocChildListReq struct {
DocId string `json:"docId" form:"docId" validate:"required"`
ContentId string `json:"contentId" form:"contentId" validate:"required"`
CommonCheck
}
type DocImportReq ¶
type DocImportReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"` //知识库id
DocImportType int `json:"docImportType"` //文档导入类型,0:文件上传,1:url上传,2.批量url上传
DocInfo []*DocInfo `json:"docInfoList" validate:"required"` //上传文档列表
DocSegment *DocSegment `json:"docSegment" validate:"required"` //文档分段配置
DocAnalyzer []string `json:"docAnalyzer" validate:"required"` //文档解析类型 text / ocr / model
ParserModelId string `json:"parserModelId"` //模型解析或ocr模型id
DocPreprocess []string `json:"docPreprocess"` //文本预处理规则 replaceSymbols / deleteLinks
DocMetaData []*DocMetaData `json:"docMetaData"` //元数据
}
func (*DocImportReq) Check ¶ added in v0.2.2
func (c *DocImportReq) Check() error
type DocListReq ¶
type DocListReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
DocName string `json:"docName" form:"docName"`
Status int `json:"status" form:"status"` // 当前状态 -1-全部, 0-待处理, 1- 处理完成, 2-正在审核中,3-正在解析中,4-审核未通过,5-解析失败
PageSearch
CommonCheck
}
type DocMetaData ¶ added in v0.1.7
type DocMetaData struct {
MetaId string `json:"metaId"` // 元数据id
MetaKey string `json:"metaKey"` // key
MetaValue string `json:"metaValue"` // 确定值
MetaValueType string `json:"metaValueType"` // string,number,time
MetaRule string `json:"metaRule"` // 正则表达式
Option string `json:"option"` // option:add(新增)、update(更新)、delete(删除),update 和delete 的时候metaId 不能为空
}
type DocMetaDataReq ¶ added in v0.1.6
type DocMetaDataReq struct {
KnowledgeId string `json:"knowledgeId"`
DocId string `json:"docId"`
MetaDataList []*DocMetaData `json:"metaDataList"` //文档元数据
}
func (*DocMetaDataReq) Check ¶ added in v0.2.2
func (c *DocMetaDataReq) Check() error
type DocSegment ¶
type DocSegment struct {
SegmentMethod string `json:"segmentMethod" validate:"required"` // 分段方法 0:通用分段;1:父子分段
SegmentType string `json:"segmentType"` // 分段方式,只有通用分段必填 0:自动分段;1:自定义分段
Splitter []string `json:"splitter"` // 分隔符(只有自定义分段必填)
MaxSplitter int `json:"maxSplitter"` // 可分隔最大值(只有自定义分段必填)
Overlap float32 `json:"overlap"` // 可重叠值(只有自定义分段必填)
SubSplitter []string `json:"subSplitter"` // 分隔符(只有父子分段必填)
SubMaxSplitter int `json:"subMaxSplitter"` // 可分隔最大值(只有父子分段必填)
}
type DocSegmentLabelsReq ¶ added in v0.1.8
type DocSegmentLabelsReq struct {
ContentId string `json:"contentId" validate:"required"`
DocId string `json:"docId" validate:"required"`
Labels []string `json:"labels" validate:"required"`
CommonCheck
}
type DocSegmentListReq ¶
type DocSegmentListReq struct {
DocId string `json:"docId" form:"docId" validate:"required"`
PageSearch
CommonCheck
}
type EmbeddingModel ¶
type EmbeddingModel struct {
ModelId string `json:"modelId" validate:"required"`
}
type FileUrlConvertBase64Req ¶ added in v0.2.8
type FileUrlConvertBase64Req struct {
FileUrl string `form:"fileUrl" json:"fileUrl" validate:"required"` // 文件URL
}
func (*FileUrlConvertBase64Req) Check ¶ added in v0.2.8
func (f *FileUrlConvertBase64Req) Check() error
type GenApiKeyRequest ¶
type GenApiKeyRequest struct {
AppId string `json:"appId" validate:"required"` // 应用id
AppType string `json:"appType" validate:"required"` // 应用类型
}
func (GenApiKeyRequest) Check ¶
func (g GenApiKeyRequest) Check() error
type GetApiBaseUrlRequest ¶
type GetApiBaseUrlRequest struct {
AppId string `form:"appId" json:"appId" validate:"required"` // 应用ID
AppType string `form:"appType" json:"appType" validate:"required"` // 应用类型
}
func (GetApiBaseUrlRequest) Check ¶
func (req GetApiBaseUrlRequest) Check() error
type GetApiKeyListRequest ¶
type GetApiKeyListRequest struct {
AppId string `form:"appId" json:"appId" validate:"required"` // 应用id
AppType string `form:"appType" json:"appType" validate:"required"` // 应用类型
}
func (GetApiKeyListRequest) Check ¶
func (g GetApiKeyListRequest) Check() error
type GetAppSpaceAppListRequest ¶
type GetAppSpaceAppListRequest struct {
Name string `form:"name" json:"name"`
AppType string `form:"appType" json:"appType"`
}
func (*GetAppSpaceAppListRequest) Check ¶
func (o *GetAppSpaceAppListRequest) Check() error
type GetExplorationAppListRequest ¶
type GetExplorationAppListRequest struct {
Name string `form:"name" json:"name"` // 应用名称
AppType string `form:"appType" json:"appType"` // 应用类型
SearchType string `form:"searchType" json:"searchType"` // 搜索类型(all(全部),favorite(显示收藏的),private(显示私密发布的),history(历史应用))
}
func (GetExplorationAppListRequest) Check ¶
func (g GetExplorationAppListRequest) Check() error
type GetKeywordsDetailReq ¶ added in v0.1.4
type GetKeywordsDetailReq struct {
Id uint32 `json:"id" form:"id"`
CommonCheck
}
type GetKnowledgeMetaSelectReq ¶ added in v0.2.2
type GetKnowledgeMetaSelectReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
CommonCheck
}
type GetKnowledgeReq ¶ added in v0.2.2
type GetKnowledgeReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"`
CommonCheck
}
type GetKnowledgeSplitterReq ¶ added in v0.1.7
type GetKnowledgeSplitterReq struct {
SplitterName string `json:"splitterName" form:"splitterName"`
CommonCheck
}
type GetModelByIdRequest ¶
type GetModelByIdRequest struct {
BaseModelRequest
}
func (*GetModelByIdRequest) Check ¶
func (o *GetModelByIdRequest) Check() error
type GetModelRequest ¶
type GetModelRequest struct {
BaseModelRequest
}
func (*GetModelRequest) Check ¶
func (o *GetModelRequest) Check() error
type GetSensitiveVocabularyReq ¶ added in v0.1.5
type GetSensitiveVocabularyReq struct {
TableId string `json:"tableId" form:"tableId" validate:"required"` // 敏感词表id
CommonCheck
}
type GetWorkflowListReq ¶ added in v0.2.3
type GetWorkflowListReq struct {
UserId string `form:"userId" json:"userId" validate:"required" `
OrgId string `form:"orgId" json:"orgId" validate:"required" `
}
func (*GetWorkflowListReq) Check ¶ added in v0.2.3
func (g *GetWorkflowListReq) Check() error
type HistoryItem ¶ added in v0.2.5
type ImportOrUpdateModelRequest ¶
type ImportOrUpdateModelRequest struct {
ModelConfig
}
func (*ImportOrUpdateModelRequest) Check ¶
func (o *ImportOrUpdateModelRequest) Check() error
type KnowledgeBatchSelectReq ¶ added in v0.2.5
type KnowledgeBatchSelectReq struct {
KnowledgeIdList []string `json:"knowledgeIdList" form:"knowledgeIdList" `
UserId string `json:"userId" form:"userId" `
CommonCheck
}
type KnowledgeGraph ¶ added in v0.2.7
type KnowledgeGraph struct {
Switch bool `json:"switch"` //知识图谱开关
LLMModelId string `json:"llmModelId"` //大模型id,开关为true必填
SchemaUrl string `json:"schemaUrl"` //模型schema文件地址,可以为空
}
KnowledgeGraph 知识图谱信息
type KnowledgeGraphReq ¶ added in v0.2.7
type KnowledgeGraphReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
CommonCheck
}
type KnowledgeHitReq ¶ added in v0.1.3
type KnowledgeHitReq struct {
KnowledgeList []*AppKnowledgeBase `json:"knowledgeList"`
Question string `json:"question" validate:"required"`
KnowledgeMatchParams *KnowledgeMatchParams `json:"knowledgeMatchParams" validate:"required"`
CommonCheck
}
type KnowledgeMatchParams ¶ added in v0.1.5
type KnowledgeMatchParams struct {
MatchType string `json:"matchType" validate:"required"` //matchType:vector(向量检索)、text(文本检索)、mix(混合检索:向量+文本)
RerankModelId string `json:"rerankModelId"` //rerank模型id
PriorityMatch int32 `json:"priorityMatch"` // 权重匹配,只有在混合检索模式下,选择权重设置后,这个才设置为1
SemanticsPriority float32 `json:"semanticsPriority"` // 语义权重
KeywordPriority float32 `json:"keywordPriority"` // 关键词权重
TopK int32 `json:"topK"` //topK 获取最高的几行
Threshold float32 `json:"threshold"` //threshold 过滤分数阈值
TermWeight float32 `json:"termWeight"` // 关键词系数
TermWeightEnable bool `json:"termWeightEnable"` // 关键词系数开关
UseGraph bool `json:"useGraph"` // 是否使用知识图谱
CommonCheck
}
type KnowledgeMetaValueListReq ¶ added in v0.2.4
type KnowledgeMetaValueListReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
DocIdList []string `json:"docIdList" form:"docIdList" validate:"required" `
CommonCheck
}
type KnowledgeOrgSelectReq ¶ added in v0.2.5
type KnowledgeOrgSelectReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"` //知识库id
CommonCheck
}
type KnowledgeReportAddReq ¶ added in v0.2.7
type KnowledgeReportAddReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
Content string `json:"content" form:"content" validate:"required"`
Title string `json:"title" form:"title" validate:"required"`
CommonCheck
}
type KnowledgeReportBatchAddReq ¶ added in v0.2.7
type KnowledgeReportBatchAddReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
FileUploadId string `json:"fileUploadId" validate:"required"`
CommonCheck
}
type KnowledgeReportDeleteReq ¶ added in v0.2.7
type KnowledgeReportDeleteReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
ContentId string `json:"contentId" form:"contentId" validate:"required"`
CommonCheck
}
type KnowledgeReportGenerateReq ¶ added in v0.2.7
type KnowledgeReportGenerateReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
CommonCheck
}
type KnowledgeReportSelectReq ¶ added in v0.2.7
type KnowledgeReportSelectReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
PageSearch
CommonCheck
}
type KnowledgeReportUpdateReq ¶ added in v0.2.7
type KnowledgeReportUpdateReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
ContentId string `json:"contentId" form:"contentId" validate:"required"`
Content string `json:"content" form:"content" validate:"required"`
Title string `json:"title" form:"title" validate:"required"`
CommonCheck
}
type KnowledgeSelectReq ¶
type KnowledgeSelectReq struct {
Name string `json:"name" form:"name" `
TagIdList []string `json:"tagId" form:"tagId" `
CommonCheck
}
type KnowledgeTagBindCountReq ¶ added in v0.2.5
type KnowledgeTagBindCountReq struct {
TagId string `json:"tagId" form:"tagId" validate:"required"`
CommonCheck
}
type KnowledgeTagSelectReq ¶ added in v0.1.3
type KnowledgeTagSelectReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" `
TagName string `json:"tagName" form:"tagName" `
CommonCheck
}
type KnowledgeTransferUserAdminReq ¶ added in v0.2.5
type KnowledgeTransferUserAdminReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"` // 知识库id
PermissionId string `json:"permissionId" form:"permissionId"` // 权限id编辑时传入
KnowledgeUser *KnowledgeUserInfo `json:"knowledgeUser" validate:"required"` // 知识库用户信息
CommonCheck
}
type KnowledgeUserAddReq ¶ added in v0.2.5
type KnowledgeUserAddReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"` // 知识库id
PermissionType int `json:"permissionType"` // 权限类型:0: 查看权限; 10: 编辑权限; 20: 授权权限,数值不连续的原因防止后续有中间权限,目前逻辑 授权权限>编辑权限>查看权限
KnowledgeUserList []*KnowledgeUserInfo `json:"knowledgeUserList" validate:"required"` // 知识库用户信息
CommonCheck
}
type KnowledgeUserDeleteReq ¶ added in v0.2.5
type KnowledgeUserDeleteReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"` // 知识库id
PermissionId string `json:"permissionId" validate:"required"` // 知识库用户信息权限信息
CommonCheck
}
type KnowledgeUserEditReq ¶ added in v0.2.5
type KnowledgeUserEditReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"` // 知识库id
KnowledgeUser *KnowledgeUserInfo `json:"knowledgeUser" validate:"required"` // 知识库用户信息
CommonCheck
}
type KnowledgeUserInfo ¶ added in v0.2.5
type KnowledgeUserInfo struct {
UserId string `json:"userId" validate:"required"`
OrgId string `json:"orgId" validate:"required"`
PermissionId string `json:"permissionId" form:"permissionId"` // 权限id编辑时传入
PermissionType int `json:"permissionType"` // 权限类型: -1 删除此用户权限;0: 查看权限; 10: 编辑权限; 20: 授权权限,数值不连续的原因防止后续有中间权限,目前逻辑 授权权限>编辑权限>查看权限
}
type KnowledgeUserNoPermitSelectReq ¶ added in v0.2.5
type KnowledgeUserNoPermitSelectReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"` //知识库id
OrgId string `json:"orgId" form:"orgId" validate:"required"` //选择组织id
Transfer bool `json:"transfer" form:"transfer"` //是否是转让列表
CommonCheck
}
type KnowledgeUserSelectReq ¶ added in v0.2.5
type KnowledgeUserSelectReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"` //知识库id
CommonCheck
}
type ListKeywordsReq ¶ added in v0.1.4
type ListKeywordsReq struct {
PageSize int `json:"pageSize" form:"pageSize"`
PageNum int `json:"pageNo" form:"pageNo"`
Name string `json:"name" form:"name"` // 用于搜索【问题中的关键词】/【文档中的词语】
CommonCheck
}
type ListModelsRequest ¶
type ListModelsRequest struct {
ModelType string `json:"modelType" form:"modelType" ` // 模型类型
Provider string `json:"provider" form:"provider"` // 模型供应商
DisplayName string `json:"displayName" form:"displayName"` // 模型显示名称
IsActive bool `json:"isActive" form:"isActive"` // 启用状态(true: 启用)
}
func (*ListModelsRequest) Check ¶
func (o *ListModelsRequest) Check() error
type ListTypeModelsRequest ¶
type ListTypeModelsRequest struct {
ModelType string `json:"modelType" form:"modelType" ` // 模型类型
}
func (*ListTypeModelsRequest) Check ¶
func (o *ListTypeModelsRequest) Check() error
type Login ¶
type Login struct {
Username string `json:"username" validate:"required"` // 用户名
Password string `json:"password" validate:"required"` // 密码
Key string `json:"key" validate:"required"` // 客户端key
Code string `json:"code" validate:"required"` // 验证码
}
Login 登录请求的参数
type LoginEmailCheck ¶ added in v0.2.4
type LoginEmailCheck struct {
Email string `json:"email" validate:"required"` // 邮箱
Code string `json:"code" validate:"required"` // 邮箱验证码
}
func (*LoginEmailCheck) Check ¶ added in v0.2.4
func (l *LoginEmailCheck) Check() error
type LoginSendEmailCode ¶ added in v0.2.4
type LoginSendEmailCode struct {
Email string `json:"email" validate:"required"` // 邮箱
}
func (*LoginSendEmailCode) Check ¶ added in v0.2.4
func (l *LoginSendEmailCode) Check() error
type MCPActionListReq ¶ added in v0.2.5
type MCPActionListReq struct {
ToolId string `form:"toolId" json:"toolId" validate:"required"`
ToolType string `form:"toolType" json:"toolType" validate:"required,oneof=mcp mcpserver"`
}
func (*MCPActionListReq) Check ¶ added in v0.2.5
func (req *MCPActionListReq) Check() error
type MCPActionReq ¶ added in v0.2.5
type MCPActionReq struct {
ToolId string `json:"toolId" validate:"required"`
ToolType string `json:"toolType" validate:"required,oneof=mcp mcpserver"`
ActionName string `json:"actionName" validate:"required"`
}
func (*MCPActionReq) Check ¶ added in v0.2.5
func (req *MCPActionReq) Check() error
type MCPCreate ¶
type MCPCreate struct {
Avatar Avatar `json:"avatar"` // 图标
MCPSquareID string `json:"mcpSquareId"` // 广场mcpId(非空表示来源于广场)
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc" validate:"required"` // 描述
From string `json:"from" validate:"required"` // 来源
SSEURL string `json:"sseUrl" validate:"required"` // SSE URL
}
type MCPServerCreateReq ¶ added in v0.2.5
type MCPServerCreateReq struct {
Avatar Avatar `json:"avatar"` // 图标
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc" validate:"required"` // 描述
}
func (*MCPServerCreateReq) Check ¶ added in v0.2.5
func (req *MCPServerCreateReq) Check() error
type MCPServerIDReq ¶ added in v0.2.5
type MCPServerIDReq struct {
MCPServerID string `json:"mcpServerId" validate:"required"`
}
func (*MCPServerIDReq) Check ¶ added in v0.2.5
func (req *MCPServerIDReq) Check() error
type MCPServerOpenAPIToolCreate ¶ added in v0.2.5
type MCPServerOpenAPIToolCreate struct {
MCPServerID string `json:"mcpServerId" validate:"required"` // mcp server Id
Name string `json:"name" validate:"required"` // 名称
ApiAuth util.ApiAuthWebRequest `json:"apiAuth" validate:"required"` // api身份认证
Schema string `json:"schema" validate:"required"` // schema
PrivacyPolicy string `json:"privacyPolicy"` // 隐私政策
MethodNames []string `json:"methodNames" validate:"required"` // API名称列表
}
func (*MCPServerOpenAPIToolCreate) Check ¶ added in v0.2.5
func (req *MCPServerOpenAPIToolCreate) Check() error
type MCPServerToolCreateReq ¶ added in v0.2.5
type MCPServerToolCreateReq struct {
MCPServerID string `json:"mcpServerId" validate:"required"` // mcp server Id
Id string `json:"id" validate:"required"` // 应用或工具id
Type string `json:"type" validate:"required"` // mcp server tool类型
MethodName string `json:"methodName" validate:"required"` // 显示名称
}
func (*MCPServerToolCreateReq) Check ¶ added in v0.2.5
func (req *MCPServerToolCreateReq) Check() error
type MCPServerToolIDReq ¶ added in v0.2.5
type MCPServerToolIDReq struct {
MCPServerToolID string `json:"mcpServerToolId" validate:"required"` //mcp server tool id
}
func (*MCPServerToolIDReq) Check ¶ added in v0.2.5
func (req *MCPServerToolIDReq) Check() error
type MCPServerToolUpdateReq ¶ added in v0.2.5
type MCPServerToolUpdateReq struct {
MCPServerToolID string `json:"mcpServerToolId" validate:"required"` // mcp server tool id
MethodName string `json:"methodName" validate:"required"` // 显示名称
Desc string `json:"desc" validate:"required"` // 描述
}
func (*MCPServerToolUpdateReq) Check ¶ added in v0.2.5
func (req *MCPServerToolUpdateReq) Check() error
type MCPServerUpdateReq ¶ added in v0.2.5
type MCPServerUpdateReq struct {
MCPServerID string `json:"mcpServerId" validate:"required"` // mcp server Id
Avatar Avatar `json:"avatar"` // 图标
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc" validate:"required"` // 描述
}
func (*MCPServerUpdateReq) Check ¶ added in v0.2.5
func (req *MCPServerUpdateReq) Check() error
type MCPUpdate ¶ added in v0.2.5
type MCPUpdate struct {
Avatar Avatar `json:"avatar"` // 图标
MCPID string `json:"mcpId" validate:"required"`
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc" validate:"required"` // 描述
From string `json:"from" validate:"required"` // 来源
SSEURL string `json:"sseUrl" validate:"required"` // SSE URL
}
type MergeFileReq ¶
type MergeFileReq struct {
FileName string `json:"fileName" form:"fileName" validate:"required"` //原始文件名
FileSize int64 `json:"fileSize" form:"fileSize" validate:"gt=0"` //原始文件大小
ChunkName string `json:"chunkName" form:"chunkName" validate:"required"` //上传批次标识
ChunkTotal int `json:"chunkTotal" form:"chunkTotal" validate:"gt=0"` //分片总数
IsExpired bool `json:"isExpired" form:"isExpired"` //minio存储文件是否过期 0:过期,1:不过期
}
func (*MergeFileReq) Check ¶
func (c *MergeFileReq) Check() error
type MetaDataFilterParams ¶ added in v0.2.2
type MetaDataFilterParams struct {
FilterEnable bool `json:"filterEnable"` // 元数据过滤开关
MetaFilterParams []*MetaFilterParams `json:"metaFilterParams"` // 元数据过滤参数列表
FilterLogicType string `json:"filterLogicType"` // 元数据逻辑条件:and/or
}
type MetaFilterParams ¶ added in v0.2.2
type MetadataFilterItem ¶ added in v0.2.5
type ModelConfig ¶
type ModelConfig struct {
ModelId string `json:"modelId"`
Provider string `json:"provider" validate:"required" enums:"OpenAI-API-compatible,YuanJing"` // 模型供应商
Model string `json:"model" validate:"required"` // 模型名称
ModelType string `json:"modelType" validate:"required" enums:"llm,embedding,rerank"` // 模型类型
DisplayName string `json:"displayName" validate:"required"` // 模型显示名称
Avatar Avatar `json:"avatar" ` // 模型图标路径
PublishDate string `json:"publishDate"` // 模型发布时间
Config interface{} `json:"config"`
ModelDesc string `json:"modelDesc"` // 模型描述
Examples *mp.ProviderModelConfig `json:"examples,omitempty"` // 仅用于swagger展示;模型对应供应商中的对应llm、embedding或rerank结构是config实际的参数
}
func (*ModelConfig) Check ¶
func (cfg *ModelConfig) Check() error
func (*ModelConfig) ConfigString ¶
func (cfg *ModelConfig) ConfigString() (string, error)
type ModelStatusRequest ¶
type ModelStatusRequest struct {
BaseModelRequest
IsActive bool `json:"isActive"` // 启用状态(true: 启用,false: 禁用)
}
func (*ModelStatusRequest) Check ¶
func (o *ModelStatusRequest) Check() error
type OAuthRefreshRequest ¶ added in v0.2.7
type OAuthRefreshRequest struct {
GrantType string `json:"grant_type" validate:"required,eq=refresh_token"`
ClientID string `json:"client_id"`
ClientSecret string `json:"client_secret"`
RefreshToken string `json:"refresh_token"`
}
func (*OAuthRefreshRequest) Check ¶ added in v0.2.7
func (t *OAuthRefreshRequest) Check() error
type OAuthRequest ¶ added in v0.2.7
type OAuthRequest struct {
ResponseType string `form:"response_type" validate:"required,eq=code"`
RedirectURI string `form:"redirect_uri"`
ClientID string `form:"client_id" validate:"required"`
Scopes []string `form:"scope"`
State string `form:"state" validate:"required"`
}
func (*OAuthRequest) Check ¶ added in v0.2.7
func (t *OAuthRequest) Check() error
type OAuthTokenRequest ¶ added in v0.2.7
type OAuthTokenRequest struct {
GrantType string `form:"grant_type" validate:"required,eq=authorization_code"`
Code string `form:"code" validate:"required"`
RedirectURI string `form:"redirect_uri"`
ClientID string `form:"client_id" validate:"required"`
ClientSecret string `form:"client_secret" validate:"required"`
}
func (*OAuthTokenRequest) Check ¶ added in v0.2.7
func (t *OAuthTokenRequest) Check() error
type OpenAPIAgentChatRequest ¶
type OpenAPIAgentChatRequest struct {
ConversationID string `json:"conversation_id" validate:"required"`
Query string `json:"query" validate:"required"`
Stream bool `json:"stream"`
}
func (*OpenAPIAgentChatRequest) Check ¶
func (req *OpenAPIAgentChatRequest) Check() error
type OpenAPIAgentCreateConversationRequest ¶
type OpenAPIAgentCreateConversationRequest struct {
Title string `json:"title"`
}
func (*OpenAPIAgentCreateConversationRequest) Check ¶
func (req *OpenAPIAgentCreateConversationRequest) Check() error
type OpenAPIChatflowChatRequest ¶ added in v0.2.8
type OpenAPIChatflowChatRequest struct {
ConversationId string `json:"conversation_id"`
Query string `json:"query"`
}
func (*OpenAPIChatflowChatRequest) Check ¶ added in v0.2.8
func (req *OpenAPIChatflowChatRequest) Check() error
type OpenAPIChatflowCreateConversationRequest ¶ added in v0.2.8
type OpenAPIChatflowCreateConversationRequest struct {
ConversationName string `json:"conversation_name"`
}
func (*OpenAPIChatflowCreateConversationRequest) Check ¶ added in v0.2.8
func (req *OpenAPIChatflowCreateConversationRequest) Check() error
type OpenAPIRagChatRequest ¶
type OpenAPIRagChatRequest struct {
Query string `json:"query" validate:"required"`
Stream bool `json:"stream"`
History []*History `json:"history"`
}
func (*OpenAPIRagChatRequest) Check ¶
func (req *OpenAPIRagChatRequest) Check() error
type OrgCreate ¶
type OrgUserAdd ¶
func (*OrgUserAdd) Check ¶
func (o *OrgUserAdd) Check() error
type PageSearch ¶
type PromptOptimizeReq ¶ added in v0.2.7
type PromptOptimizeReq struct {
Prompt string `json:"prompt" validate:"required"`
ModelId string `json:"modelId" validate:"required"`
}
func (*PromptOptimizeReq) Check ¶ added in v0.2.7
func (req *PromptOptimizeReq) Check() error
type ProxyUploadFileReq ¶
type ProxyUploadFileReq struct {
FileName string `json:"file_name" form:"file_name" validate:"required"` //原始文件名
}
func (*ProxyUploadFileReq) Check ¶
func (c *ProxyUploadFileReq) Check() error
type PublishAgentScopeWorkFlowRequest ¶ added in v0.1.8
type PublishAgentScopeWorkFlowRequest struct {
AppId string `form:"workflowID" json:"workflowID" validate:"required"` // 应用ID
}
func (*PublishAgentScopeWorkFlowRequest) Check ¶ added in v0.1.8
func (p *PublishAgentScopeWorkFlowRequest) Check() error
type PublishAppRequest ¶
type PublishAppRequest struct {
AppId string `json:"appId"` // 应用ID
AppType string `json:"appType"` // 应用类型
PublishType string `json:"publishType"` // 发布类型(public:系统公开发布,organization:组织公开发布,private:私密发布)
}
func (PublishAppRequest) Check ¶
func (req PublishAppRequest) Check() error
type QueryKnowledgeReq ¶
type QueryKnowledgeReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
CommonCheck
}
type RagBrief ¶
type RagBrief struct {
RagID string `json:"ragId" validate:"required"`
AppBriefConfig
}
type RagConfig ¶
type RagConfig struct {
RagID string `json:"ragId" validate:"required"`
ModelConfig AppModelConfig `json:"modelConfig" validate:"required"` // 模型
RerankConfig AppModelConfig `json:"rerankConfig" validate:"required"` // Rerank模型
KnowledgeBaseConfig AppKnowledgebaseConfig `json:"knowledgeBaseConfig" validate:"required"` // 知识库
SafetyConfig AppSafetyConfig `json:"safetyConfig"` // 敏感词表配置
}
type RagKnowledgeChatReq ¶ added in v0.2.5
type RagKnowledgeChatReq struct {
UserId string `json:"userId"`
KnowledgeUser map[string][]*RagKnowledgeInfo `json:"knowledge_base_info"`
KnowledgeIdList []string `json:"knowledgeIdList"` // 知识库id列表
Question string `json:"question"`
Threshold float32 `json:"threshold"` // Score阈值
TopK int32 `json:"topK"`
Stream bool `json:"stream"`
Chichat bool `json:"chichat"` // 当知识库召回结果为空时是否使用默认话术(兜底),默认为true
RerankModelId string `json:"rerank_model_id"`
CustomModelInfo *CustomModelInfo `json:"custom_model_info"`
History []*HistoryItem `json:"history"`
MaxHistory int32 `json:"max_history"`
RewriteQuery bool `json:"rewrite_query"` // 是否query改写
RerankMod string `json:"rerank_mod"` // rerank_model:重排序模式,weighted_score:权重搜索
RetrieveMethod string `json:"retrieve_method"` // hybrid_search:混合搜索, semantic_search:向量搜索, full_text_search:文本搜索
Weight *WeightParams `json:"weights"` // 权重搜索下的权重配置
Temperature float32 `json:"temperature,omitempty"`
TopP float32 `json:"top_p,omitempty"` // 多样性
RepetitionPenalty float32 `json:"repetition_penalty,omitempty"` // 重复惩罚/频率惩罚
ReturnMeta bool `json:"return_meta,omitempty"` // 是否返回元数据
AutoCitation bool `json:"auto_citation"` // 是否自动角标
TermWeight float32 `json:"term_weight_coefficient"` // 关键词系数
MetaFilter bool `json:"metadata_filtering"` // 元数据过滤开关
MetaFilterConditions []*MetadataFilterItem `json:"metadata_filtering_conditions"` // 元数据过滤条件
UseGraph bool `json:"use_graph"` // 是否启动知识图谱查询
CommonCheck
}
type RagKnowledgeInfo ¶ added in v0.2.5
type RagSearchKnowledgeBaseReq ¶ added in v0.2.5
type RagSearchKnowledgeBaseReq struct {
UserId string `json:"userId" validate:"required"`
Question string `json:"question" validate:"required"`
KnowledgeIdList []string `json:"knowledgeIdList,omitempty" validate:"required"`
KnowledgeUser map[string][]*RagKnowledgeInfo `json:"knowledge_base_info"`
Threshold float64 `json:"threshold"`
TopK int32 `json:"topK"`
RerankModelId string `json:"rerank_model_id"` // rerankId
RerankMod string `json:"rerank_mod"` // rerank_model:重排序模式,weighted_score:权重搜索
RetrieveMethod string `json:"retrieve_method"` // hybrid_search:混合搜索, semantic_search:向量搜索, full_text_search:文本搜索
Weight *WeightParams `json:"weights"` // 权重搜索下的权重配置
TermWeight float32 `json:"term_weight_coefficient"` // 关键词系数
MetaFilter bool `json:"metadata_filtering"` // 元数据过滤开关
MetaFilterConditions []*MetadataFilterItem `json:"metadata_filtering_conditions"` // 元数据过滤条件
UseGraph bool `json:"use_graph"` // 是否启动知识图谱查询
CommonCheck
}
RagSearchKnowledgeBaseReq rag知识库查询请求
type RegisterByEmail ¶ added in v0.2.2
type RegisterByEmail struct {
Username string `json:"username" validate:"required"` // 用户名
Email string `json:"email" validate:"required"` // 邮箱
Code string `json:"code" validate:"required"` // 邮箱验证码
}
func (*RegisterByEmail) Check ¶ added in v0.2.2
func (l *RegisterByEmail) Check() error
type RegisterSendEmailCode ¶ added in v0.2.2
type RegisterSendEmailCode struct {
Username string `json:"username" validate:"required"` // 用户名
Email string `json:"email" validate:"required"` // 邮箱
}
func (*RegisterSendEmailCode) Check ¶ added in v0.2.2
func (l *RegisterSendEmailCode) Check() error
type ResetPasswordByEmail ¶ added in v0.2.3
type ResetPasswordByEmail struct {
Email string `json:"email" validate:"required"` // 邮箱
Code string `json:"code" validate:"required"` // 邮箱验证码
Password string `json:"password" validate:"required"` // 密码
}
func (*ResetPasswordByEmail) Check ¶ added in v0.2.3
func (r *ResetPasswordByEmail) Check() error
type ResetPasswordSendEmailCode ¶ added in v0.2.3
type ResetPasswordSendEmailCode struct {
Email string `json:"email" validate:"required"` // 邮箱
}
func (*ResetPasswordSendEmailCode) Check ¶ added in v0.2.3
func (r *ResetPasswordSendEmailCode) Check() error
type RoleCreate ¶
type RoleCreate struct {
Name string `json:"name" validate:"required"` // 角色名
Remark string `json:"remark"` // 备注
Permissions []string // 权限列表
}
func (*RoleCreate) Check ¶
func (r *RoleCreate) Check() error
type RoleStatus ¶
func (*RoleStatus) Check ¶
func (r *RoleStatus) Check() error
type RoleUpdate ¶
type RoleUpdate struct {
RoleID string `json:"roleId" validate:"required"`
RoleCreate
}
func (*RoleUpdate) Check ¶
func (r *RoleUpdate) Check() error
type SearchKnowledgeInfoReq ¶
type SearchKnowledgeInfoReq struct {
KnowledgeName string `json:"categoryName" form:"categoryName" validate:"required"`
UserId string `json:"userId" form:"userId" validate:"required"`
OrgId string `json:"orgId"`
CommonCheck
}
type SensitiveTable ¶ added in v0.1.5
type ToolActionListReq ¶ added in v0.2.5
type ToolActionListReq struct {
ToolId string `form:"toolId" json:"toolId" validate:"required"` // 工具id
ToolType string `form:"toolType" json:"toolType" validate:"required,oneof=builtin custom"` // 工具类型
}
func (*ToolActionListReq) Check ¶ added in v0.2.5
func (req *ToolActionListReq) Check() error
type ToolActionReq ¶ added in v0.2.5
type ToolActionReq struct {
ToolId string `form:"toolId" json:"toolId" validate:"required"` // 工具id
ToolType string `form:"toolType" json:"toolType" validate:"required,oneof=builtin custom"` // 工具类型
ActionName string `form:"actionName" json:"actionName" validate:"required"` // action名称
}
func (*ToolActionReq) Check ¶ added in v0.2.5
func (req *ToolActionReq) Check() error
type ToolSquareAPIKeyReq ¶ added in v0.2.4
type ToolSquareAPIKeyReq struct {
ToolSquareID string `json:"toolSquareId" validate:"required"` // 广场toolId
APIKey string `json:"apiKey"` // apiKey
}
func (*ToolSquareAPIKeyReq) Check ¶ added in v0.2.4
func (req *ToolSquareAPIKeyReq) Check() error
type UnPublishAgentScopeWorkFlowRequest ¶ added in v0.1.8
type UnPublishAgentScopeWorkFlowRequest struct {
AppId string `form:"workflowID" json:"workflowID" validate:"required"` // 应用ID
}
func (*UnPublishAgentScopeWorkFlowRequest) Check ¶ added in v0.1.8
func (p *UnPublishAgentScopeWorkFlowRequest) Check() error
type UnPublishAppRequest ¶ added in v0.1.3
type UnPublishAppRequest struct {
AppId string `json:"appId"` // 应用ID
AppType string `json:"appType"` // 应用类型
}
func (UnPublishAppRequest) Check ¶ added in v0.1.3
func (req UnPublishAppRequest) Check() error
type UpdateCustomPrompt ¶ added in v0.2.6
type UpdateCustomPrompt struct {
CustomPromptIDReq
Avatar Avatar `json:"avatar"` // 图标
Name string `json:"name" validate:"required"` // 名称
Desc string `json:"desc" validate:"required"` // 描述
Prompt string `json:"prompt" validate:"required"` // 提示词
}
func (*UpdateCustomPrompt) Check ¶ added in v0.2.6
func (req *UpdateCustomPrompt) Check() error
type UpdateDocChildSegmentReq ¶ added in v0.2.4
type UpdateDocChildSegmentReq struct {
DocId string `json:"docId" validate:"required"` // 文档id
ParentId string `json:"parentId" validate:"required"` // 父分段id
ParentChunkNo int32 `json:"parentChunkNo"` // 父分段序列号
ChildChunk *ChildChunk `json:"childChunk" validate:"required"` // 子分段序列号列表
CommonCheck
}
type UpdateDocSegmentReq ¶ added in v0.2.1
type UpdateDocSegmentReq struct {
DocId string `json:"docId" validate:"required"`
ContentId string `json:"contentId" validate:"required"`
Content string `json:"content" validate:"required"`
CommonCheck
}
type UpdateDocSegmentStatusReq ¶
type UpdateDocSegmentStatusReq struct {
DocId string `json:"docId" validate:"required"`
ContentId string `json:"contentId"`
ContentStatus string `json:"contentStatus" validate:"required"`
ALL bool `json:"all" ` // all 代表全部启用,此时将忽略contentId
CommonCheck
}
type UpdateKeywordsReq ¶ added in v0.1.4
type UpdateKeywordsReq struct {
Id uint32 `json:"id" validate:"required"`
Name string `json:"name" validate:"required"`
Alias string `json:"alias" validate:"required"`
KnowledgeBaseIds []string `json:"knowledgeBaseIds" validate:"required"`
CommonCheck
}
type UpdateKnowledgeReq ¶
type UpdateKnowledgeReq struct {
KnowledgeId string `json:"knowledgeId" validate:"required"`
Name string `json:"name" validate:"required"`
Description string `json:"description"`
CommonCheck
}
type UpdateKnowledgeSplitterReq ¶ added in v0.1.6
type UpdateKnowledgeSplitterReq struct {
SplitterId string `json:"splitterId" form:"splitterId" validate:"required"`
SplitterName string `json:"splitterName" form:"splitterName" validate:"required"`
SplitterValue string `json:"splitterValue" form:"splitterValue" validate:"required"`
CommonCheck
}
type UpdateKnowledgeTagReq ¶ added in v0.1.3
type UpdateKnowledgeTagReq struct {
TagId string `json:"tagId" form:"tagId" validate:"required"`
TagName string `json:"tagName" form:"tagName" validate:"required"`
CommonCheck
}
type UpdateMetaValueReq ¶ added in v0.2.4
type UpdateMetaValueReq struct {
KnowledgeId string `json:"knowledgeId" form:"knowledgeId" validate:"required"`
DocIdList []string `json:"docIdList" validate:"required"`
MetaValueList []*DocMetaData `json:"metaValueList"`
ApplyToSelected bool `json:"applyToSelected"`
}
func (*UpdateMetaValueReq) Check ¶ added in v0.2.4
func (c *UpdateMetaValueReq) Check() error
type UpdateOauthAppReq ¶ added in v0.2.7
type UpdateOauthAppReq struct {
ClientID string `json:"clientId" validate:"required"`
Name string `json:"name" validate:"required"`
Desc string `json:"desc"`
RedirectURI string `json:"redirectUri" validate:"required"`
}
func (*UpdateOauthAppReq) Check ¶ added in v0.2.7
func (u *UpdateOauthAppReq) Check() error
type UpdateOauthAppStatusReq ¶ added in v0.2.7
type UpdateOauthAppStatusReq struct {
ClientID string `json:"clientId" validate:"required"`
Status bool `json:"status"` // 启停状态
}
func (*UpdateOauthAppStatusReq) Check ¶ added in v0.2.7
func (u *UpdateOauthAppStatusReq) Check() error
type UpdateSensitiveWordTableReplyReq ¶ added in v0.1.5
type UpdateSensitiveWordTableReplyReq struct {
TableId string `json:"tableId" validate:"required"` // 敏感词表id
Reply string `json:"reply"` // 回复设置
CommonCheck
}
type UpdateSensitiveWordTableReq ¶ added in v0.1.5
type UpdateSensitiveWordTableReq struct {
TableId string `json:"tableId" validate:"required"` // 敏感词表id
TableName string `json:"tableName" validate:"required"` // 敏感词表名
Remark string `json:"remark"` // 备注
CommonCheck
}
type UploadFileReq ¶
type UploadFileReq struct {
FileName string `json:"fileName" form:"fileName" validate:"required"` //原始文件名
Sequence int `json:"sequence" form:"sequence" validate:"gt=0"` //分片文件序号
ChunkName string `json:"chunkName" form:"chunkName" validate:"required"` //上传批次标识
}
func (*UploadFileReq) Check ¶
func (c *UploadFileReq) Check() error
type UploadSensitiveVocabularyReq ¶ added in v0.1.5
type UploadSensitiveVocabularyReq struct {
TableId string `json:"tableId" validate:"required"` // 敏感词表id
ImportType string `json:"importType" validate:"required"` // 上传敏感词方式,single:单条添加,file:批量上传
Word string `json:"word"` // 敏感词
SensitiveType string `json:"sensitiveType"` // 敏感词类型 (涉政:Political, 辱骂:Revile, 涉黄:Pornography, 暴恐:ViolentTerror, 违禁:Illegal, 信息安全:InformationSecurity, 其他:Other)
FileName string `json:"fileName"` // 文件名
CommonCheck
}
type UrlConversationCreateRequest ¶ added in v0.1.7
type UrlConversationCreateRequest struct {
Prompt string `json:"prompt" validate:"required"`
}
func (*UrlConversationCreateRequest) Check ¶ added in v0.1.7
func (c *UrlConversationCreateRequest) Check() error
type UrlConversationIdRequest ¶ added in v0.1.7
type UrlConversationIdRequest struct {
ConversationId string `json:"conversationId" form:"conversationId" validate:"required"`
}
func (*UrlConversationIdRequest) Check ¶ added in v0.1.7
func (c *UrlConversationIdRequest) Check() error
type UrlConversionStreamRequest ¶ added in v0.1.7
type UrlConversionStreamRequest struct {
ConversationId string `json:"conversationId" form:"conversionId"`
Prompt string `json:"prompt" form:"prompt" validate:"required"`
}
func (*UrlConversionStreamRequest) Check ¶ added in v0.1.7
func (c *UrlConversionStreamRequest) Check() error
type UserAvatarUpdate ¶ added in v0.2.3
type UserAvatarUpdate struct {
Avatar Avatar `json:"avatar"`
}
func (*UserAvatarUpdate) Check ¶ added in v0.2.3
func (u *UserAvatarUpdate) Check() error
type UserCreate ¶
func (*UserCreate) Check ¶
func (u *UserCreate) Check() error
type UserInfo ¶
type UserInfo struct {
Nickname string `json:"nickname"` // 昵称
Password string `json:"password" validate:"required"` // 密码
Phone string `json:"phone" validate:"required"` // 电话
Remark string `json:"remark"` // 备注
Gender string `json:"gender"` // 性别(0-女,1-男,空-未知)
Company string `json:"company"` // 公司
RoleIDs []string `json:"roleIds" validate:"max=1"` // 角色列表
}
type UserPassword ¶
type UserPassword struct {
UserID
OldPassword string `json:"oldPassword" validate:"required"`
NewPassword string `json:"newPassword" validate:"required"`
}
func (*UserPassword) Check ¶
func (u *UserPassword) Check() error
type UserPasswordByAdmin ¶
func (*UserPasswordByAdmin) Check ¶
func (u *UserPasswordByAdmin) Check() error
type UserStatus ¶
func (*UserStatus) Check ¶
func (u *UserStatus) Check() error
type UserUpdate ¶
func (*UserUpdate) Check ¶
func (u *UserUpdate) Check() error
type VisionConfig ¶ added in v0.2.5
type VisionConfig struct {
PicNum int32 `json:"picNum"` // 视觉配置图片数量
}
type WeightParams ¶ added in v0.2.5
type WorkflowIDReq ¶ added in v0.2.0
type WorkflowIDReq struct {
WorkflowID string `json:"workflow_id" validate:"required"`
}
func (*WorkflowIDReq) Check ¶ added in v0.2.0
func (r *WorkflowIDReq) Check() error
type WorkflowUploadFileByBase64Req ¶ added in v0.2.8
type WorkflowUploadFileByBase64Req struct {
File string `form:"file" json:"file" validate:"required"` // base64格式
FileName string `form:"fileName" json:"fileName" validate:"required"`
}
func (*WorkflowUploadFileByBase64Req) Check ¶ added in v0.2.8
func (u *WorkflowUploadFileByBase64Req) Check() error
type WorkflowUploadFileReq ¶ added in v0.2.8
type WorkflowUploadFileReq struct {
File *multipart.FileHeader `form:"file" json:"file" validate:"required"` // 二进制格式
FileName string `form:"fileName" json:"fileName" validate:"required"`
}
func (*WorkflowUploadFileReq) Check ¶ added in v0.2.8
func (u *WorkflowUploadFileReq) Check() error
Source Files
¶
- api_key.go
- app_url.go
- appspace.go
- appspace_common.go
- assistant.go
- callback.go
- common.go
- explore.go
- file_upload.go
- guest.go
- knowledge.go
- knowledge_doc.go
- knowledge_keywords.go
- knowledge_permission.go
- knowledge_report.go
- knowledge_splitter.go
- knowledge_tag.go
- mcp.go
- mcp_server.go
- model.go
- model_config.go
- oauth.go
- openapi.go
- openurl.go
- permission_org.go
- permission_role.go
- permission_user.go
- prompt.go
- rag.go
- safety.go
- setting.go
- tool.go
- workflow.go
- workflow_agentscope.go
Click to show internal directories.
Click to hide internal directories.