chore: replace all cn comments to en version by volc api (#313)
This commit is contained in:
parent
91d6cdb430
commit
5abc63fba6
|
|
@ -267,7 +267,7 @@ func GetUploadAuthToken(ctx context.Context, c *app.RequestContext) {
|
||||||
func createSecret(uid int64, fileType string) string {
|
func createSecret(uid int64, fileType string) string {
|
||||||
num := 10
|
num := 10
|
||||||
input := fmt.Sprintf("upload_%d_Ma*9)fhi_%d_gou_%s_rand_%d", uid, time.Now().Unix(), fileType, rand.Intn(100000))
|
input := fmt.Sprintf("upload_%d_Ma*9)fhi_%d_gou_%s_rand_%d", uid, time.Now().Unix(), fileType, rand.Intn(100000))
|
||||||
// 做md5,取前20个,// mapIntToBase62 把数字映射到 Base62
|
// Do md5, take the first 20,//mapIntToBase62 map the number to Base62
|
||||||
hash := sha256.Sum256([]byte(fmt.Sprintf("%s", input)))
|
hash := sha256.Sum256([]byte(fmt.Sprintf("%s", input)))
|
||||||
hashString := base64.StdEncoding.EncodeToString(hash[:])
|
hashString := base64.StdEncoding.EncodeToString(hash[:])
|
||||||
if len(hashString) > num {
|
if len(hashString) > num {
|
||||||
|
|
|
||||||
|
|
@ -138,7 +138,7 @@ func CreatePersonalAccessTokenAndPermission(ctx context.Context, c *app.RequestC
|
||||||
c.JSON(consts.StatusOK, resp)
|
c.JSON(consts.StatusOK, resp)
|
||||||
}
|
}
|
||||||
|
|
||||||
// checkCPATParams 检查创建个人访问令牌的参数
|
// checkCPATParams Check parameters for creating personal access tokens
|
||||||
func checkCPATParams(ctx context.Context, req *openapiauth.CreatePersonalAccessTokenAndPermissionRequest) error {
|
func checkCPATParams(ctx context.Context, req *openapiauth.CreatePersonalAccessTokenAndPermissionRequest) error {
|
||||||
|
|
||||||
if req.Name == "" {
|
if req.Name == "" {
|
||||||
|
|
|
||||||
|
|
@ -159,7 +159,7 @@ func UserUpdateAvatar(ctx context.Context, c *app.RequestContext) {
|
||||||
var err error
|
var err error
|
||||||
var req passport.UserUpdateAvatarRequest
|
var req passport.UserUpdateAvatarRequest
|
||||||
|
|
||||||
// 获取上传的文件
|
// Get the uploaded file
|
||||||
file, err := c.FormFile("avatar")
|
file, err := c.FormFile("avatar")
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logs.CtxErrorf(ctx, "Get Avatar Fail failed, err=%v", err)
|
logs.CtxErrorf(ctx, "Get Avatar Fail failed, err=%v", err)
|
||||||
|
|
@ -167,13 +167,13 @@ func UserUpdateAvatar(ctx context.Context, c *app.RequestContext) {
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检查文件类型
|
// Check file type
|
||||||
if !strings.HasPrefix(file.Header.Get("Content-Type"), "image/") {
|
if !strings.HasPrefix(file.Header.Get("Content-Type"), "image/") {
|
||||||
invalidParamRequestResponse(c, "invalid file type, only image allowed")
|
invalidParamRequestResponse(c, "invalid file type, only image allowed")
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
|
||||||
// 读取文件内容
|
// Read file content
|
||||||
src, err := file.Open()
|
src, err := file.Open()
|
||||||
if err != nil {
|
if err != nil {
|
||||||
internalServerErrorResponse(ctx, c, err)
|
internalServerErrorResponse(ctx, c, err)
|
||||||
|
|
|
||||||
|
|
@ -13,17 +13,17 @@ type ColumnType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
ColumnType_Unknown ColumnType = 0
|
ColumnType_Unknown ColumnType = 0
|
||||||
// 文本
|
// Text
|
||||||
ColumnType_Text ColumnType = 1
|
ColumnType_Text ColumnType = 1
|
||||||
// 数字
|
// number
|
||||||
ColumnType_Number ColumnType = 2
|
ColumnType_Number ColumnType = 2
|
||||||
// 时间
|
// time
|
||||||
ColumnType_Date ColumnType = 3
|
ColumnType_Date ColumnType = 3
|
||||||
// float
|
// float
|
||||||
ColumnType_Float ColumnType = 4
|
ColumnType_Float ColumnType = 4
|
||||||
// bool
|
// bool
|
||||||
ColumnType_Boolean ColumnType = 5
|
ColumnType_Boolean ColumnType = 5
|
||||||
// 图片
|
// picture
|
||||||
ColumnType_Image ColumnType = 6
|
ColumnType_Image ColumnType = 6
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -83,11 +83,11 @@ func (p *ColumnType) Value() (driver.Value, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DocTableSheet struct {
|
type DocTableSheet struct {
|
||||||
// sheet 的编号
|
// Number of sheet
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id" query:"id"`
|
ID int64 `thrift:"id,1" form:"id" json:"id" query:"id"`
|
||||||
// sheet 名
|
// Sheet name
|
||||||
SheetName string `thrift:"sheet_name,2" form:"sheet_name" json:"sheet_name" query:"sheet_name"`
|
SheetName string `thrift:"sheet_name,2" form:"sheet_name" json:"sheet_name" query:"sheet_name"`
|
||||||
// 总行数
|
// total number of rows
|
||||||
TotalRow int64 `thrift:"total_row,3" form:"total_row" json:"total_row" query:"total_row"`
|
TotalRow int64 `thrift:"total_row,3" form:"total_row" json:"total_row" query:"total_row"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -314,20 +314,20 @@ func (p *DocTableSheet) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 表格的列信息
|
// Table column information
|
||||||
type DocTableColumn struct {
|
type DocTableColumn struct {
|
||||||
// 列 id
|
// Column ID
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id,string"`
|
ID int64 `thrift:"id,1" form:"id" json:"id,string"`
|
||||||
// 列名
|
// column_name
|
||||||
ColumnName string `thrift:"column_name,2" form:"column_name" json:"column_name" query:"column_name"`
|
ColumnName string `thrift:"column_name,2" form:"column_name" json:"column_name" query:"column_name"`
|
||||||
// 是否为语义匹配列
|
// Is it a semantically matched column?
|
||||||
IsSemantic bool `thrift:"is_semantic,3" form:"is_semantic" json:"is_semantic" query:"is_semantic"`
|
IsSemantic bool `thrift:"is_semantic,3" form:"is_semantic" json:"is_semantic" query:"is_semantic"`
|
||||||
// 列原本在 excel 的序号
|
// List the serial number originally in excel
|
||||||
Sequence int64 `thrift:"sequence,4" form:"sequence" json:"sequence,string"`
|
Sequence int64 `thrift:"sequence,4" form:"sequence" json:"sequence,string"`
|
||||||
// 列类型
|
// column type
|
||||||
ColumnType *ColumnType `thrift:"column_type,5,optional" form:"column_type" json:"column_type,omitempty" query:"column_type"`
|
ColumnType *ColumnType `thrift:"column_type,5,optional" form:"column_type" json:"column_type,omitempty" query:"column_type"`
|
||||||
ContainsEmptyValue *bool `thrift:"contains_empty_value,6,optional" form:"contains_empty_value" json:"contains_empty_value,omitempty" query:"contains_empty_value"`
|
ContainsEmptyValue *bool `thrift:"contains_empty_value,6,optional" form:"contains_empty_value" json:"contains_empty_value,omitempty" query:"contains_empty_value"`
|
||||||
// 描述
|
// describe
|
||||||
Desc *string `thrift:"desc,7,optional" form:"desc" json:"desc,omitempty" query:"desc"`
|
Desc *string `thrift:"desc,7,optional" form:"desc" json:"desc,omitempty" query:"desc"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,10 +3,10 @@
|
||||||
package agentrun
|
package agentrun
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/conversation/run"
|
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/conversation/run"
|
||||||
)
|
)
|
||||||
|
|
||||||
type AgentRunService interface {
|
type AgentRunService interface {
|
||||||
|
|
|
||||||
|
|
@ -15,14 +15,14 @@ const (
|
||||||
Scene_Explore Scene = 1
|
Scene_Explore Scene = 1
|
||||||
Scene_BotStore Scene = 2
|
Scene_BotStore Scene = 2
|
||||||
Scene_CozeHome Scene = 3
|
Scene_CozeHome Scene = 3
|
||||||
//调试
|
//debugging
|
||||||
Scene_Playground Scene = 4
|
Scene_Playground Scene = 4
|
||||||
// 评测平台
|
// evaluation platform
|
||||||
Scene_Evaluation Scene = 5
|
Scene_Evaluation Scene = 5
|
||||||
Scene_AgentAPP Scene = 6
|
Scene_AgentAPP Scene = 6
|
||||||
//prompt优化
|
//Prompt optimization
|
||||||
Scene_PromptOptimize Scene = 7
|
Scene_PromptOptimize Scene = 7
|
||||||
// createbot的nl2bot功能
|
// Createbot's nl2bot features
|
||||||
Scene_GenerateAgentInfo Scene = 8
|
Scene_GenerateAgentInfo Scene = 8
|
||||||
//openapi
|
//openapi
|
||||||
Scene_SceneOpenApi Scene = 9
|
Scene_SceneOpenApi Scene = 9
|
||||||
|
|
|
||||||
|
|
@ -3,10 +3,10 @@
|
||||||
package conversation
|
package conversation
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/conversation/common"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/conversation/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type ClearConversationHistoryRequest struct {
|
type ClearConversationHistoryRequest struct {
|
||||||
|
|
@ -509,7 +509,7 @@ func (p *ClearConversationHistoryResponse) String() string {
|
||||||
type ClearConversationCtxRequest struct {
|
type ClearConversationCtxRequest struct {
|
||||||
ConversationID int64 `thrift:"conversation_id,1,required" form:"conversation_id,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
ConversationID int64 `thrift:"conversation_id,1,required" form:"conversation_id,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
||||||
Scene *common.Scene `thrift:"scene,2,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
Scene *common.Scene `thrift:"scene,2,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
||||||
// 存在需要插入聊天的情况
|
// There is a situation that needs to be inserted into the chat.
|
||||||
InsertHistoryMessageList []string `thrift:"insert_history_message_list,3,optional" form:"insert_history_message_list" json:"insert_history_message_list,omitempty" query:"insert_history_message_list"`
|
InsertHistoryMessageList []string `thrift:"insert_history_message_list,3,optional" form:"insert_history_message_list" json:"insert_history_message_list,omitempty" query:"insert_history_message_list"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1507,7 +1507,7 @@ func (p *ConversationData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type CreateConversationRequest struct {
|
type CreateConversationRequest struct {
|
||||||
//自定义透传字段
|
//custom passthrough field
|
||||||
MetaData map[string]string `thrift:"MetaData,1,optional" form:"meta_data" json:"meta_data,omitempty"`
|
MetaData map[string]string `thrift:"MetaData,1,optional" form:"meta_data" json:"meta_data,omitempty"`
|
||||||
BotId *int64 `thrift:"BotId,3,optional" form:"bot_id" json:"bot_id,string,omitempty"`
|
BotId *int64 `thrift:"BotId,3,optional" form:"bot_id" json:"bot_id,string,omitempty"`
|
||||||
ConnectorId *int64 `thrift:"ConnectorId,4,optional" form:"connector_id" json:"connector_id,string,omitempty"`
|
ConnectorId *int64 `thrift:"ConnectorId,4,optional" form:"connector_id" json:"connector_id,string,omitempty"`
|
||||||
|
|
@ -2418,11 +2418,11 @@ func (p *Section) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ClearConversationApiResponse struct {
|
type ClearConversationApiResponse struct {
|
||||||
// 错误code
|
// Error code
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code"`
|
||||||
// 错误消息
|
// error message
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg"`
|
||||||
// section 信息
|
// Section information
|
||||||
Data *Section `thrift:"data,3" form:"data" json:"data"`
|
Data *Section `thrift:"data,3" form:"data" json:"data"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255" form:"BaseResp" json:"BaseResp" query:"BaseResp"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255" form:"BaseResp" json:"BaseResp" query:"BaseResp"`
|
||||||
}
|
}
|
||||||
|
|
@ -2709,9 +2709,9 @@ func (p *ClearConversationApiResponse) String() string {
|
||||||
type ListConversationsApiRequest struct {
|
type ListConversationsApiRequest struct {
|
||||||
PageNum int64 `thrift:"page_num,1" json:"page_num" query:"page_num"`
|
PageNum int64 `thrift:"page_num,1" json:"page_num" query:"page_num"`
|
||||||
PageSize int64 `thrift:"page_size,2" json:"page_size" query:"page_size"`
|
PageSize int64 `thrift:"page_size,2" json:"page_size" query:"page_size"`
|
||||||
// 可选值:ASC、DESC
|
// Optional values: ASC, DESC
|
||||||
SortOrder string `thrift:"sort_order,3" json:"sort_order" query:"sort_order"`
|
SortOrder string `thrift:"sort_order,3" json:"sort_order" query:"sort_order"`
|
||||||
// 可选值:created_at创建时间
|
// Optional value: such as created_at
|
||||||
SortField string `thrift:"sort_field,4" json:"sort_field" query:"sort_field"`
|
SortField string `thrift:"sort_field,4" json:"sort_field" query:"sort_field"`
|
||||||
BotID int64 `thrift:"bot_id,5,required" json:"bot_id,string,required" query:"bot_id,required"`
|
BotID int64 `thrift:"bot_id,5,required" json:"bot_id,string,required" query:"bot_id,required"`
|
||||||
ConnectorID *int64 `thrift:"connector_id,6,optional" json:"connector_id,string,omitempty" query:"connector_id"`
|
ConnectorID *int64 `thrift:"connector_id,6,optional" json:"connector_id,string,omitempty" query:"connector_id"`
|
||||||
|
|
@ -3143,9 +3143,9 @@ func (p *ListConversationsApiRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ListConversationsApiResponse struct {
|
type ListConversationsApiResponse struct {
|
||||||
// 错误code
|
// Error code
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code"`
|
||||||
// 错误消息
|
// error message
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg"`
|
||||||
Data *ListConversationData `thrift:"data,3" form:"data" json:"data"`
|
Data *ListConversationData `thrift:"data,3" form:"data" json:"data"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255" form:"BaseResp" json:"BaseResp" query:"BaseResp"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255" form:"BaseResp" json:"BaseResp" query:"BaseResp"`
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,12 @@
|
||||||
package message
|
package message
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/conversation/common"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/conversation/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -106,21 +106,21 @@ func (p *MsgParticipantType) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// follow copilot 定义的枚举
|
// Enumeration following copilot definition
|
||||||
type ChatMessageMetaType int64
|
type ChatMessageMetaType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// Compatible value
|
// Compatible value
|
||||||
ChatMessageMetaType_Default_0 ChatMessageMetaType = 0
|
ChatMessageMetaType_Default_0 ChatMessageMetaType = 0
|
||||||
// 端侧直接替换
|
// End-to-side direct replacement
|
||||||
ChatMessageMetaType_Replaceable ChatMessageMetaType = 1
|
ChatMessageMetaType_Replaceable ChatMessageMetaType = 1
|
||||||
// 插入引用
|
// insert reference
|
||||||
ChatMessageMetaType_Insertable ChatMessageMetaType = 2
|
ChatMessageMetaType_Insertable ChatMessageMetaType = 2
|
||||||
// 文档引用
|
// document citation
|
||||||
ChatMessageMetaType_DocumentRef ChatMessageMetaType = 3
|
ChatMessageMetaType_DocumentRef ChatMessageMetaType = 3
|
||||||
// 知识库引用卡片
|
// Knowledge Base Reference Card
|
||||||
ChatMessageMetaType_KnowledgeCard ChatMessageMetaType = 4
|
ChatMessageMetaType_KnowledgeCard ChatMessageMetaType = 4
|
||||||
// 嵌入的多媒体信息,只是alice给端上用的,因为全链路复用这一个字段,所以在这儿改了
|
// The embedded multimedia information is only used by Alice for the end. Because full link multiplexing uses this field, it has been changed here.
|
||||||
ChatMessageMetaType_EmbeddedMultimedia ChatMessageMetaType = 100
|
ChatMessageMetaType_EmbeddedMultimedia ChatMessageMetaType = 100
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -196,9 +196,9 @@ type ExtraInfo struct {
|
||||||
NewSectionID string `thrift:"new_section_id,17" form:"new_section_id" json:"new_section_id" query:"new_section_id"`
|
NewSectionID string `thrift:"new_section_id,17" form:"new_section_id" json:"new_section_id" query:"new_section_id"`
|
||||||
RemoveQueryID string `thrift:"remove_query_id,18" form:"remove_query_id" json:"remove_query_id" query:"remove_query_id"`
|
RemoveQueryID string `thrift:"remove_query_id,18" form:"remove_query_id" json:"remove_query_id" query:"remove_query_id"`
|
||||||
ExecuteDisplayName string `thrift:"execute_display_name,19" form:"execute_display_name" json:"execute_display_name" query:"execute_display_name"`
|
ExecuteDisplayName string `thrift:"execute_display_name,19" form:"execute_display_name" json:"execute_display_name" query:"execute_display_name"`
|
||||||
// 对应定时任务task_type,1-预设任务,2-用户任务,3-Plugin后台任务
|
// Corresponding to timed task task_type, 1-preset task, 2-user task, 3-Plugin background task
|
||||||
TaskType string `thrift:"task_type,20" form:"task_type" json:"task_type" query:"task_type"`
|
TaskType string `thrift:"task_type,20" form:"task_type" json:"task_type" query:"task_type"`
|
||||||
//agent app使用引用格式
|
//Agent app uses reference format
|
||||||
ReferFormat string `thrift:"refer_format,21" form:"refer_format" json:"refer_format" query:"refer_format"`
|
ReferFormat string `thrift:"refer_format,21" form:"refer_format" json:"refer_format" query:"refer_format"`
|
||||||
CallID string `thrift:"call_id,22" form:"call_id" json:"call_id" query:"call_id"`
|
CallID string `thrift:"call_id,22" form:"call_id" json:"call_id" query:"call_id"`
|
||||||
}
|
}
|
||||||
|
|
@ -1273,9 +1273,9 @@ type MsgParticipantInfo struct {
|
||||||
UserName string `thrift:"user_name,8" form:"user_name" json:"user_name" query:"user_name"`
|
UserName string `thrift:"user_name,8" form:"user_name" json:"user_name" query:"user_name"`
|
||||||
AllowMention bool `thrift:"allow_mention,9" form:"allow_mention" json:"allow_mention" query:"allow_mention"`
|
AllowMention bool `thrift:"allow_mention,9" form:"allow_mention" json:"allow_mention" query:"allow_mention"`
|
||||||
AccessPath string `thrift:"access_path,10" form:"access_path" json:"access_path" query:"access_path"`
|
AccessPath string `thrift:"access_path,10" form:"access_path" json:"access_path" query:"access_path"`
|
||||||
// 是否被收藏
|
// Is collected
|
||||||
IsFav bool `thrift:"is_fav,11" form:"is_fav" json:"is_fav" query:"is_fav"`
|
IsFav bool `thrift:"is_fav,11" form:"is_fav" json:"is_fav" query:"is_fav"`
|
||||||
// 12: shortcut_command.ShortcutStruct shortcuts //快捷指令
|
// 12: shortcut_command ShortcutStruct shortcuts//Shortcuts
|
||||||
AllowShare bool `thrift:"allow_share,13" form:"allow_share" json:"allow_share" query:"allow_share"`
|
AllowShare bool `thrift:"allow_share,13" form:"allow_share" json:"allow_share" query:"allow_share"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2251,7 +2251,7 @@ func (p *SubmitToolOutputs) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 和 bot_connector_platform保持同步
|
// Keep up with bot_connector_platform
|
||||||
type RequiredAction struct {
|
type RequiredAction struct {
|
||||||
Type string `thrift:"type,1" form:"type" json:"type" query:"type"`
|
Type string `thrift:"type,1" form:"type" json:"type" query:"type"`
|
||||||
SubmitToolOutputs *SubmitToolOutputs `thrift:"submit_tool_outputs,2" form:"submit_tool_outputs" json:"submit_tool_outputs" query:"submit_tool_outputs"`
|
SubmitToolOutputs *SubmitToolOutputs `thrift:"submit_tool_outputs,2" form:"submit_tool_outputs" json:"submit_tool_outputs" query:"submit_tool_outputs"`
|
||||||
|
|
@ -2635,25 +2635,25 @@ type ChatMessage struct {
|
||||||
ReplyID string `thrift:"reply_id,6" form:"reply_id" json:"reply_id" query:"reply_id"`
|
ReplyID string `thrift:"reply_id,6" form:"reply_id" json:"reply_id" query:"reply_id"`
|
||||||
SectionID string `thrift:"section_id,7" form:"section_id" json:"section_id" query:"section_id"`
|
SectionID string `thrift:"section_id,7" form:"section_id" json:"section_id" query:"section_id"`
|
||||||
ExtraInfo *ExtraInfo `thrift:"extra_info,8" form:"extra_info" json:"extra_info" query:"extra_info"`
|
ExtraInfo *ExtraInfo `thrift:"extra_info,8" form:"extra_info" json:"extra_info" query:"extra_info"`
|
||||||
// 正常、打断状态 拉消息列表时使用,chat运行时没有这个字段
|
// Normal, interrupted state, used when pulling the message list, this field is not available when chat is running.
|
||||||
Status string `thrift:"status,9" form:"status" json:"status" query:"status"`
|
Status string `thrift:"status,9" form:"status" json:"status" query:"status"`
|
||||||
// 打断位置
|
// interrupt position
|
||||||
BrokenPos *int32 `thrift:"broken_pos,10,optional" form:"broken_pos" json:"broken_pos,omitempty" query:"broken_pos"`
|
BrokenPos *int32 `thrift:"broken_pos,10,optional" form:"broken_pos" json:"broken_pos,omitempty" query:"broken_pos"`
|
||||||
SenderID *string `thrift:"sender_id,11,optional" form:"sender_id" json:"sender_id,omitempty" query:"sender_id"`
|
SenderID *string `thrift:"sender_id,11,optional" form:"sender_id" json:"sender_id,omitempty" query:"sender_id"`
|
||||||
MentionList []*MsgParticipantInfo `thrift:"mention_list,12,optional" form:"mention_list" json:"mention_list,omitempty" query:"mention_list"`
|
MentionList []*MsgParticipantInfo `thrift:"mention_list,12,optional" form:"mention_list" json:"mention_list,omitempty" query:"mention_list"`
|
||||||
ContentTime int64 `thrift:"content_time,13" form:"content_time" json:"content_time" query:"content_time"`
|
ContentTime int64 `thrift:"content_time,13" form:"content_time" json:"content_time" query:"content_time"`
|
||||||
MessageIndex int64 `thrift:"message_index,14" json:"message_index,string" form:"message_index" query:"message_index"`
|
MessageIndex int64 `thrift:"message_index,14" json:"message_index,string" form:"message_index" query:"message_index"`
|
||||||
// 消息来源,0 普通聊天消息,1 定时任务,2 通知,3 异步结果
|
// Sources, 0 normal chat messages, 1 scheduled task, 2 notifications, 3 asynchronous results
|
||||||
Source int32 `thrift:"source,15" form:"source" json:"source" query:"source"`
|
Source int32 `thrift:"source,15" form:"source" json:"source" query:"source"`
|
||||||
// 对应回复的query 找不到后端加一个兜底的
|
// Corresponding to the replied query, the backend cannot be found, and a backend is added.
|
||||||
ReplyMessage *ChatMessage `thrift:"reply_message,16,optional" form:"reply_message" json:"reply_message,omitempty" query:"reply_message"`
|
ReplyMessage *ChatMessage `thrift:"reply_message,16,optional" form:"reply_message" json:"reply_message,omitempty" query:"reply_message"`
|
||||||
// 打断信息
|
// interrupt message
|
||||||
RequiredAction *RequiredAction `thrift:"required_action,17,optional" form:"required_action" json:"required_action,omitempty" query:"required_action"`
|
RequiredAction *RequiredAction `thrift:"required_action,17,optional" form:"required_action" json:"required_action,omitempty" query:"required_action"`
|
||||||
// 引用、高亮等文本标记
|
// Text markup such as quoting, highlighting, etc
|
||||||
MetaInfos []*ChatMessageMetaInfo `thrift:"meta_infos,18,optional" form:"meta_infos" json:"meta_infos,omitempty" query:"meta_infos"`
|
MetaInfos []*ChatMessageMetaInfo `thrift:"meta_infos,18,optional" form:"meta_infos" json:"meta_infos,omitempty" query:"meta_infos"`
|
||||||
// 卡片状态
|
// Card Status
|
||||||
CardStatus map[string]string `thrift:"card_status,19,optional" form:"card_status" json:"card_status,omitempty" query:"card_status"`
|
CardStatus map[string]string `thrift:"card_status,19,optional" form:"card_status" json:"card_status,omitempty" query:"card_status"`
|
||||||
//模型思维链
|
//Model Thinking Chain
|
||||||
ReasoningContent *string `thrift:"reasoning_content,20,optional" form:"reasoning_content" json:"reasoning_content,omitempty" query:"reasoning_content"`
|
ReasoningContent *string `thrift:"reasoning_content,20,optional" form:"reasoning_content" json:"reasoning_content,omitempty" query:"reasoning_content"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3787,22 +3787,22 @@ func (p *ChatMessage) String() string {
|
||||||
|
|
||||||
type GetMessageListRequest struct {
|
type GetMessageListRequest struct {
|
||||||
ConversationID string `thrift:"conversation_id,1" form:"conversation_id" json:"conversation_id" query:"conversation_id"`
|
ConversationID string `thrift:"conversation_id,1" form:"conversation_id" json:"conversation_id" query:"conversation_id"`
|
||||||
// 首次传0/-1,0-最后一页,-1-未读第一页
|
// First pass 0/-1, 0 - last page, -1 - unread first page
|
||||||
Cursor string `thrift:"cursor,2,required" form:"cursor,required" json:"cursor,required" query:"cursor,required"`
|
Cursor string `thrift:"cursor,2,required" form:"cursor,required" json:"cursor,required" query:"cursor,required"`
|
||||||
Count int32 `thrift:"count,3,required" form:"count,required" json:"count,required" query:"count,required"`
|
Count int32 `thrift:"count,3,required" form:"count,required" json:"count,required" query:"count,required"`
|
||||||
BotID string `thrift:"bot_id,4" form:"bot_id" json:"bot_id" query:"bot_id"`
|
BotID string `thrift:"bot_id,4" form:"bot_id" json:"bot_id" query:"bot_id"`
|
||||||
DraftMode *bool `thrift:"draft_mode,5,optional" form:"draft_mode" json:"draft_mode,omitempty" query:"draft_mode"`
|
DraftMode *bool `thrift:"draft_mode,5,optional" form:"draft_mode" json:"draft_mode,omitempty" query:"draft_mode"`
|
||||||
// 使用的bot模版
|
// The bot template used
|
||||||
PresetBot *string `thrift:"preset_bot,6,optional" form:"preset_bot" json:"preset_bot,omitempty" query:"preset_bot"`
|
PresetBot *string `thrift:"preset_bot,6,optional" form:"preset_bot" json:"preset_bot,omitempty" query:"preset_bot"`
|
||||||
Scene *common.Scene `thrift:"scene,7,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
Scene *common.Scene `thrift:"scene,7,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
||||||
// 同一个bot和uid下面的不同业务情况
|
// Different business situations under the same bot and uid
|
||||||
BizKind *string `thrift:"biz_kind,8,optional" form:"biz_kind" json:"biz_kind,omitempty" query:"biz_kind"`
|
BizKind *string `thrift:"biz_kind,8,optional" form:"biz_kind" json:"biz_kind,omitempty" query:"biz_kind"`
|
||||||
// 存在创建聊天记录前需要插入聊天的情况
|
// There are situations where you need to insert a chat before creating a chat history
|
||||||
InsertHistoryMessageList []string `thrift:"insert_history_message_list,9,optional" form:"insert_history_message_list" json:"insert_history_message_list,omitempty" query:"insert_history_message_list"`
|
InsertHistoryMessageList []string `thrift:"insert_history_message_list,9,optional" form:"insert_history_message_list" json:"insert_history_message_list,omitempty" query:"insert_history_message_list"`
|
||||||
LoadDirection *LoadDirection `thrift:"load_direction,10,optional" form:"load_direction" json:"load_direction,omitempty" query:"load_direction"`
|
LoadDirection *LoadDirection `thrift:"load_direction,10,optional" form:"load_direction" json:"load_direction,omitempty" query:"load_direction"`
|
||||||
// 在已有conversation情况下,是否强制append message
|
// Whether to force an appended message in an existing conversation
|
||||||
MustAppend *bool `thrift:"must_append,11,optional" form:"must_append" json:"must_append,omitempty" query:"must_append"`
|
MustAppend *bool `thrift:"must_append,11,optional" form:"must_append" json:"must_append,omitempty" query:"must_append"`
|
||||||
// 分享ID
|
// Share ID
|
||||||
ShareID *int64 `thrift:"share_id,12,optional" json:"share_id,string" form:"share_id" query:"share_id"`
|
ShareID *int64 `thrift:"share_id,12,optional" json:"share_id,string" form:"share_id" query:"share_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4552,22 +4552,22 @@ func (p *GetMessageListRequest) String() string {
|
||||||
|
|
||||||
type GetMessageListResponse struct {
|
type GetMessageListResponse struct {
|
||||||
MessageList []*ChatMessage `thrift:"message_list,1,required" form:"message_list,required" json:"message_list,required" query:"message_list,required"`
|
MessageList []*ChatMessage `thrift:"message_list,1,required" form:"message_list,required" json:"message_list,required" query:"message_list,required"`
|
||||||
// 下一刷存在时的位置(向上翻页),与next_cursor翻页方向相反。兼容旧逻辑,不加prev前缀
|
// The position when the next brush exists (page up), opposite to the next_cursor page turning direction. Compatible with old logic, no prev prefix
|
||||||
Cursor string `thrift:"cursor,2,required" form:"cursor,required" json:"cursor,required" query:"cursor,required"`
|
Cursor string `thrift:"cursor,2,required" form:"cursor,required" json:"cursor,required" query:"cursor,required"`
|
||||||
// 下一刷是否存在(向上翻页),与next_has_more翻页方向相反。兼容旧逻辑,不加prev前缀
|
// Whether the next swipe exists (page up), the opposite direction to the next_has_more page turning. Compatible with old logic, without prev prefix
|
||||||
Hasmore bool `thrift:"hasmore,3,required" form:"hasmore,required" json:"hasmore,required" query:"hasmore,required"`
|
Hasmore bool `thrift:"hasmore,3,required" form:"hasmore,required" json:"hasmore,required" query:"hasmore,required"`
|
||||||
ConversationID string `thrift:"conversation_id,4,required" form:"conversation_id,required" json:"conversation_id,required" query:"conversation_id,required"`
|
ConversationID string `thrift:"conversation_id,4,required" form:"conversation_id,required" json:"conversation_id,required" query:"conversation_id,required"`
|
||||||
// 会话最新的section_id 只有第一刷返回
|
// Session Latest section_id Only First Brush Back
|
||||||
LastSectionID *string `thrift:"last_section_id,5,optional" form:"last_section_id" json:"last_section_id,omitempty" query:"last_section_id"`
|
LastSectionID *string `thrift:"last_section_id,5,optional" form:"last_section_id" json:"last_section_id,omitempty" query:"last_section_id"`
|
||||||
Code int64 `thrift:"code,6" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,6" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,7" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,7" form:"msg" json:"msg" query:"msg"`
|
||||||
ParticipantInfoMap map[string]*MsgParticipantInfo `thrift:"participant_info_map,8,optional" form:"participant_info_map" json:"participant_info_map,omitempty" query:"participant_info_map"`
|
ParticipantInfoMap map[string]*MsgParticipantInfo `thrift:"participant_info_map,8,optional" form:"participant_info_map" json:"participant_info_map,omitempty" query:"participant_info_map"`
|
||||||
// 下一刷存在时的位置(向下翻页),
|
// The position when the next swipe exists (page down),
|
||||||
NextCursor string `thrift:"next_cursor,9" form:"next_cursor" json:"next_cursor" query:"next_cursor"`
|
NextCursor string `thrift:"next_cursor,9" form:"next_cursor" json:"next_cursor" query:"next_cursor"`
|
||||||
// 下一刷是否存在(向下翻页)
|
// Does the next swipe exist (page down)
|
||||||
NextHasMore bool `thrift:"next_has_more,10" form:"next_has_more" json:"next_has_more" query:"next_has_more"`
|
NextHasMore bool `thrift:"next_has_more,10" form:"next_has_more" json:"next_has_more" query:"next_has_more"`
|
||||||
ReadMessageIndex int64 `thrift:"read_message_index,11" json:"read_message_index,string" form:"read_message_index" query:"read_message_index"`
|
ReadMessageIndex int64 `thrift:"read_message_index,11" json:"read_message_index,string" form:"read_message_index" query:"read_message_index"`
|
||||||
//botconnector对应的id
|
//ID for botconnector
|
||||||
ConnectorConversationID string `thrift:"connector_conversation_id,12" form:"connector_conversation_id" json:"connector_conversation_id" query:"connector_conversation_id"`
|
ConnectorConversationID string `thrift:"connector_conversation_id,12" form:"connector_conversation_id" json:"connector_conversation_id" query:"connector_conversation_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5787,13 +5787,13 @@ func (p *DeleteMessageResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BreakMessageRequest struct {
|
type BreakMessageRequest struct {
|
||||||
//会话id
|
//session id
|
||||||
ConversationID int64 `thrift:"conversation_id,1,required" form:"conversation_id,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
ConversationID int64 `thrift:"conversation_id,1,required" form:"conversation_id,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
||||||
// 当前问题id
|
// Current issue id
|
||||||
QueryMessageID int64 `thrift:"query_message_id,2,required" form:"query_message_id,required" json:"query_message_id,string,required" query:"query_message_id,required"`
|
QueryMessageID int64 `thrift:"query_message_id,2,required" form:"query_message_id,required" json:"query_message_id,string,required" query:"query_message_id,required"`
|
||||||
// 当前问题下哪一条回复被打断了
|
// Which reply was interrupted under the current question?
|
||||||
AnswerMessageID *int64 `thrift:"answer_message_id,3,optional" form:"answer_message_id" json:"answer_message_id,string,omitempty" query:"answer_message_id"`
|
AnswerMessageID *int64 `thrift:"answer_message_id,3,optional" form:"answer_message_id" json:"answer_message_id,string,omitempty" query:"answer_message_id"`
|
||||||
// 打断位置
|
// interrupt position
|
||||||
BrokenPos *int32 `thrift:"broken_pos,4,optional" form:"broken_pos" json:"broken_pos,omitempty" query:"broken_pos"`
|
BrokenPos *int32 `thrift:"broken_pos,4,optional" form:"broken_pos" json:"broken_pos,omitempty" query:"broken_pos"`
|
||||||
Scene *common.Scene `thrift:"scene,5,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
Scene *common.Scene `thrift:"scene,5,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
||||||
}
|
}
|
||||||
|
|
@ -6342,19 +6342,19 @@ func (p *BreakMessageResponse) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 批量查询
|
// batch query
|
||||||
type ListMessageApiRequest struct {
|
type ListMessageApiRequest struct {
|
||||||
//会话id
|
//session id
|
||||||
ConversationID int64 `thrift:"conversation_id,1,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
ConversationID int64 `thrift:"conversation_id,1,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
||||||
// 限制条数
|
// limit number of entries
|
||||||
Limit *int64 `thrift:"limit,2,optional" form:"limit" json:"limit,omitempty"`
|
Limit *int64 `thrift:"limit,2,optional" form:"limit" json:"limit,omitempty"`
|
||||||
// 排序方式 desc/asc
|
// Sort by desc/asc
|
||||||
Order *string `thrift:"order,3,optional" form:"order" json:"order,omitempty"`
|
Order *string `thrift:"order,3,optional" form:"order" json:"order,omitempty"`
|
||||||
//一次对话的id
|
//ID of a conversation
|
||||||
ChatID *int64 `thrift:"chat_id,4,optional" form:"chat_id" json:"chat_id,string,omitempty"`
|
ChatID *int64 `thrift:"chat_id,4,optional" form:"chat_id" json:"chat_id,string,omitempty"`
|
||||||
// 向前翻页需要传的ID
|
// The ID you need to pass to turn the page forward.
|
||||||
BeforeID *int64 `thrift:"before_id,5,optional" form:"before_id" json:"before_id,string,omitempty"`
|
BeforeID *int64 `thrift:"before_id,5,optional" form:"before_id" json:"before_id,string,omitempty"`
|
||||||
// 向后返回需要传的ID
|
// Return the ID to be passed backwards.
|
||||||
AfterID *int64 `thrift:"after_id,6,optional" form:"after_id" json:"after_id,string,omitempty"`
|
AfterID *int64 `thrift:"after_id,6,optional" form:"after_id" json:"after_id,string,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -6828,31 +6828,31 @@ func (p *ListMessageApiRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type OpenMessageApi struct {
|
type OpenMessageApi struct {
|
||||||
// 主键ID
|
// primary key ID
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id,string" query:"id"`
|
ID int64 `thrift:"id,1" form:"id" json:"id,string" query:"id"`
|
||||||
// agent id
|
// agent id
|
||||||
BotID int64 `thrift:"bot_id,2" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
BotID int64 `thrift:"bot_id,2" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
||||||
// user / assistant/tool
|
// user / assistant/tool
|
||||||
Role string `thrift:"role,3" form:"role" json:"role" query:"role"`
|
Role string `thrift:"role,3" form:"role" json:"role" query:"role"`
|
||||||
//消息内容
|
//message content
|
||||||
Content string `thrift:"content,4" form:"content" json:"content" query:"content"`
|
Content string `thrift:"content,4" form:"content" json:"content" query:"content"`
|
||||||
//会话id
|
//session id
|
||||||
ConversationID int64 `thrift:"conversation_id,5" form:"conversation_id" json:"conversation_id" query:"conversation_id"`
|
ConversationID int64 `thrift:"conversation_id,5" form:"conversation_id" json:"conversation_id" query:"conversation_id"`
|
||||||
// 自定义字段
|
// custom field
|
||||||
MetaData map[string]string `thrift:"meta_data,6" form:"meta_data" json:"meta_data" query:"meta_data"`
|
MetaData map[string]string `thrift:"meta_data,6" form:"meta_data" json:"meta_data" query:"meta_data"`
|
||||||
//创建时间
|
//creation time
|
||||||
CreatedAt int64 `thrift:"created_at,7" form:"created_at" json:"created_at" query:"created_at"`
|
CreatedAt int64 `thrift:"created_at,7" form:"created_at" json:"created_at" query:"created_at"`
|
||||||
//更新时间
|
//update time
|
||||||
UpdatedAt int64 `thrift:"updated_at,8" form:"updated_at" json:"updated_at" query:"updated_at"`
|
UpdatedAt int64 `thrift:"updated_at,8" form:"updated_at" json:"updated_at" query:"updated_at"`
|
||||||
// 一次对话的id
|
// ID of a conversation
|
||||||
ChatID int64 `thrift:"chat_id,9" form:"chat_id" json:"chat_id" query:"chat_id"`
|
ChatID int64 `thrift:"chat_id,9" form:"chat_id" json:"chat_id" query:"chat_id"`
|
||||||
// content 类型 ,text/mix
|
// Content type, text/mix
|
||||||
ContentType string `thrift:"content_type,10" form:"content_type" json:"content_type" query:"content_type"`
|
ContentType string `thrift:"content_type,10" form:"content_type" json:"content_type" query:"content_type"`
|
||||||
//消息类型 answer/question/function_call/tool_response
|
//Message Type answer/question/function_call/tool_response
|
||||||
Type string `thrift:"type,11" form:"type" json:"type" query:"type"`
|
Type string `thrift:"type,11" form:"type" json:"type" query:"type"`
|
||||||
// 会话的section_id
|
// The section_id of conversation
|
||||||
SectionID string `thrift:"section_id,12" form:"section_id" json:"section_id" query:"section_id"`
|
SectionID string `thrift:"section_id,12" form:"section_id" json:"section_id" query:"section_id"`
|
||||||
//模型思维链
|
//Model Thinking Chain
|
||||||
ReasoningContent *string `thrift:"reasoning_content,13,optional" form:"reasoning_content" json:"reasoning_content,omitempty" query:"reasoning_content"`
|
ReasoningContent *string `thrift:"reasoning_content,13,optional" form:"reasoning_content" json:"reasoning_content,omitempty" query:"reasoning_content"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7561,11 +7561,11 @@ func (p *OpenMessageApi) String() string {
|
||||||
|
|
||||||
type ListMessageApiResponse struct {
|
type ListMessageApiResponse struct {
|
||||||
Messages []*OpenMessageApi `thrift:"messages,1,optional" form:"data" json:"data,omitempty"`
|
Messages []*OpenMessageApi `thrift:"messages,1,optional" form:"data" json:"data,omitempty"`
|
||||||
// 是否还有数据,true 有,false 没有
|
// Is there still data, true yes, false no
|
||||||
HasMore *bool `thrift:"has_more,2,optional" form:"has_more" json:"has_more,omitempty"`
|
HasMore *bool `thrift:"has_more,2,optional" form:"has_more" json:"has_more,omitempty"`
|
||||||
// 第一条数据的id
|
// The ID of the first piece of data
|
||||||
FirstID *int64 `thrift:"first_id,3,optional" form:"first_id" json:"first_id,string,omitempty"`
|
FirstID *int64 `thrift:"first_id,3,optional" form:"first_id" json:"first_id,string,omitempty"`
|
||||||
// 最后一条数据的id
|
// The id of the last piece of data.
|
||||||
LastID *int64 `thrift:"last_id,4,optional" form:"last_id" json:"last_id,string,omitempty"`
|
LastID *int64 `thrift:"last_id,4,optional" form:"last_id" json:"last_id,string,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,12 @@
|
||||||
package run
|
package run
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/conversation/common"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/conversation/message"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/conversation/common"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/conversation/message"
|
||||||
)
|
)
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -2133,23 +2133,23 @@ func (p *AdditionalContent) String() string {
|
||||||
type AgentRunRequest struct {
|
type AgentRunRequest struct {
|
||||||
//agent id
|
//agent id
|
||||||
BotID int64 `thrift:"bot_id,1" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
BotID int64 `thrift:"bot_id,1" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
||||||
// 会话id
|
// session id
|
||||||
ConversationID int64 `thrift:"conversation_id,2,required" form:"conversation_id,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
ConversationID int64 `thrift:"conversation_id,2,required" form:"conversation_id,required" json:"conversation_id,string,required" query:"conversation_id,required"`
|
||||||
Query string `thrift:"query,5,required" form:"query,required" json:"query,required" query:"query,required"`
|
Query string `thrift:"query,5,required" form:"query,required" json:"query,required" query:"query,required"`
|
||||||
// ext 透传字段
|
// ext pass-through field
|
||||||
Extra map[string]string `thrift:"extra,7" form:"extra" json:"extra" query:"extra"`
|
Extra map[string]string `thrift:"extra,7" form:"extra" json:"extra" query:"extra"`
|
||||||
CustomVariables map[string]string `thrift:"custom_variables,9" form:"custom_variables" json:"custom_variables" query:"custom_variables"`
|
CustomVariables map[string]string `thrift:"custom_variables,9" form:"custom_variables" json:"custom_variables" query:"custom_variables"`
|
||||||
// 草稿bot or 线上bot
|
// Draft bot or online bot
|
||||||
DraftMode *bool `thrift:"draft_mode,10,optional" form:"draft_mode" json:"draft_mode,omitempty" query:"draft_mode"`
|
DraftMode *bool `thrift:"draft_mode,10,optional" form:"draft_mode" json:"draft_mode,omitempty" query:"draft_mode"`
|
||||||
// explore场景
|
// Explore the scene
|
||||||
Scene *common.Scene `thrift:"scene,11,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
Scene *common.Scene `thrift:"scene,11,optional" form:"scene" json:"scene,omitempty" query:"scene"`
|
||||||
// 文件 file 图片 image 等
|
// Files files pictures images etc
|
||||||
ContentType *string `thrift:"content_type,12,optional" form:"content_type" json:"content_type,omitempty" query:"content_type"`
|
ContentType *string `thrift:"content_type,12,optional" form:"content_type" json:"content_type,omitempty" query:"content_type"`
|
||||||
// 重试消息id
|
// Retry message id
|
||||||
RegenMessageID *int64 `thrift:"regen_message_id,13,optional" form:"regen_message_id" json:"regen_message_id,string,omitempty" query:"regen_message_id"`
|
RegenMessageID *int64 `thrift:"regen_message_id,13,optional" form:"regen_message_id" json:"regen_message_id,string,omitempty" query:"regen_message_id"`
|
||||||
// 前端本地的message_id 在extra_info 里面透传返回
|
// The local message_id on the front end is passed back in the extra_info
|
||||||
LocalMessageID *string `thrift:"local_message_id,14,optional" form:"local_message_id" json:"local_message_id,omitempty" query:"local_message_id"`
|
LocalMessageID *string `thrift:"local_message_id,14,optional" form:"local_message_id" json:"local_message_id,omitempty" query:"local_message_id"`
|
||||||
// 使用的bot模版 代替bot_id bot_version draft_mode参数, coze home使用 preset_bot="coze_home"
|
// The bot template used, instead of bot_id bot_version draft_mode parameters, coze home uses preset_bot = "coze_home"
|
||||||
PresetBot *string `thrift:"preset_bot,15,optional" form:"preset_bot" json:"preset_bot,omitempty" query:"preset_bot"`
|
PresetBot *string `thrift:"preset_bot,15,optional" form:"preset_bot" json:"preset_bot,omitempty" query:"preset_bot"`
|
||||||
InsertHistoryMessageList []string `thrift:"insert_history_message_list,16,optional" form:"insert_history_message_list" json:"insert_history_message_list,omitempty" query:"insert_history_message_list"`
|
InsertHistoryMessageList []string `thrift:"insert_history_message_list,16,optional" form:"insert_history_message_list" json:"insert_history_message_list,omitempty" query:"insert_history_message_list"`
|
||||||
DeviceID *string `thrift:"device_id,17,optional" form:"device_id" json:"device_id,omitempty" query:"device_id"`
|
DeviceID *string `thrift:"device_id,17,optional" form:"device_id" json:"device_id,omitempty" query:"device_id"`
|
||||||
|
|
@ -2157,9 +2157,9 @@ type AgentRunRequest struct {
|
||||||
MentionList []*message.MsgParticipantInfo `thrift:"mention_list,19,optional" form:"mention_list" json:"mention_list,omitempty" query:"mention_list"`
|
MentionList []*message.MsgParticipantInfo `thrift:"mention_list,19,optional" form:"mention_list" json:"mention_list,omitempty" query:"mention_list"`
|
||||||
ToolList []*Tool `thrift:"toolList,20,optional" form:"toolList" json:"toolList,omitempty" query:"toolList"`
|
ToolList []*Tool `thrift:"toolList,20,optional" form:"toolList" json:"toolList,omitempty" query:"toolList"`
|
||||||
CommitVersion *string `thrift:"commit_version,21,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
CommitVersion *string `thrift:"commit_version,21,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
||||||
// scene粒度下进一步区分场景,目前仅给bot模版使用 = bot_template
|
// Scene granularity further distinguish scenes, currently only used for bot templates = bot_template
|
||||||
SubScene *string `thrift:"sub_scene,22,optional" form:"sub_scene" json:"sub_scene,omitempty" query:"sub_scene"`
|
SubScene *string `thrift:"sub_scene,22,optional" form:"sub_scene" json:"sub_scene,omitempty" query:"sub_scene"`
|
||||||
// diff模式下的聊天配置,仅草稿single bot
|
// Chat configuration in diff mode, draft only single bot
|
||||||
DiffModeIdentifier *DiffModeIdentifier `thrift:"diff_mode_identifier,23,optional" form:"diff_mode_identifier" json:"diff_mode_identifier,omitempty" query:"diff_mode_identifier"`
|
DiffModeIdentifier *DiffModeIdentifier `thrift:"diff_mode_identifier,23,optional" form:"diff_mode_identifier" json:"diff_mode_identifier,omitempty" query:"diff_mode_identifier"`
|
||||||
ShortcutCmdID *int64 `thrift:"shortcut_cmd_id,24,optional" form:"shortcut_cmd_id" json:"shortcut_cmd_id,string,omitempty" query:"shortcut_cmd_id"`
|
ShortcutCmdID *int64 `thrift:"shortcut_cmd_id,24,optional" form:"shortcut_cmd_id" json:"shortcut_cmd_id,string,omitempty" query:"shortcut_cmd_id"`
|
||||||
}
|
}
|
||||||
|
|
@ -4726,7 +4726,7 @@ func (p *BotConfig) String() string {
|
||||||
|
|
||||||
type ShortcutCommandDetail struct {
|
type ShortcutCommandDetail struct {
|
||||||
CommandID int64 `thrift:"command_id,1,required" form:"command_id,required" json:"command_id,string,required" query:"command_id,required"`
|
CommandID int64 `thrift:"command_id,1,required" form:"command_id,required" json:"command_id,string,required" query:"command_id,required"`
|
||||||
// key=参数名 value=值 object_string object 数组序列化之后的 JSON String
|
// Key = parameter name value = value object_string JSON String after object array serialization
|
||||||
Parameters map[string]string `thrift:"parameters,2" form:"parameters" json:"parameters" query:"parameters"`
|
Parameters map[string]string `thrift:"parameters,2" form:"parameters" json:"parameters" query:"parameters"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4951,21 +4951,21 @@ type ChatV3Request struct {
|
||||||
BotID int64 `thrift:"BotID,1,required" form:"bot_id,required" json:"bot_id,string,required"`
|
BotID int64 `thrift:"BotID,1,required" form:"bot_id,required" json:"bot_id,string,required"`
|
||||||
//conversation_id
|
//conversation_id
|
||||||
ConversationID *int64 `thrift:"ConversationID,2,optional" json:"ConversationID,string,omitempty" query:"conversation_id"`
|
ConversationID *int64 `thrift:"ConversationID,2,optional" json:"ConversationID,string,omitempty" query:"conversation_id"`
|
||||||
//user_id,数据隔离标识,需要保证唯一
|
//user_id, data isolation identification, need to ensure unique
|
||||||
User string `thrift:"User,3,required" form:"user_id,required" json:"user_id,required"`
|
User string `thrift:"User,3,required" form:"user_id,required" json:"user_id,required"`
|
||||||
//是否流式,当前仅支持流失
|
//Whether to stream, currently only supports churn.
|
||||||
Stream *bool `thrift:"Stream,4,optional" form:"stream" json:"stream,omitempty"`
|
Stream *bool `thrift:"Stream,4,optional" form:"stream" json:"stream,omitempty"`
|
||||||
//本次对话消息,当前仅支持role=user
|
//In this conversation message, only role = user is currently supported.
|
||||||
AdditionalMessages []*EnterMessage `thrift:"AdditionalMessages,5,optional" form:"additional_messages" json:"additional_messages,omitempty"`
|
AdditionalMessages []*EnterMessage `thrift:"AdditionalMessages,5,optional" form:"additional_messages" json:"additional_messages,omitempty"`
|
||||||
//用户自定义变量
|
//user-defined variables
|
||||||
CustomVariables map[string]string `thrift:"CustomVariables,6,optional" form:"custom_variables" json:"custom_variables,omitempty"`
|
CustomVariables map[string]string `thrift:"CustomVariables,6,optional" form:"custom_variables" json:"custom_variables,omitempty"`
|
||||||
MetaData map[string]string `thrift:"MetaData,8,optional" form:"meta_data" json:"meta_data,omitempty"`
|
MetaData map[string]string `thrift:"MetaData,8,optional" form:"meta_data" json:"meta_data,omitempty"`
|
||||||
CustomConfig *CustomConfig `thrift:"CustomConfig,10,optional" form:"custom_config" json:"custom_config,omitempty"`
|
CustomConfig *CustomConfig `thrift:"CustomConfig,10,optional" form:"custom_config" json:"custom_config,omitempty"`
|
||||||
// 透传参数到 plugin/workflow 等下游
|
// Pass parameters to plugin/workflow etc downstream
|
||||||
ExtraParams map[string]string `thrift:"ExtraParams,11,optional" form:"extra_params" json:"extra_params,omitempty"`
|
ExtraParams map[string]string `thrift:"ExtraParams,11,optional" form:"extra_params" json:"extra_params,omitempty"`
|
||||||
// 手动指定渠道 id 聊天。目前仅支持 websdk(=999)
|
// Manually specify channel id chat. Currently only supports websdk (= 999)
|
||||||
ConnectorID *int64 `thrift:"ConnectorID,12,optional" form:"connector_id" json:"connector_id,string,omitempty"`
|
ConnectorID *int64 `thrift:"ConnectorID,12,optional" form:"connector_id" json:"connector_id,string,omitempty"`
|
||||||
// 指定快捷指令
|
// Specify shortcut instructions
|
||||||
ShortcutCommand *ShortcutCommandDetail `thrift:"ShortcutCommand,13,optional" form:"shortcut_command" json:"shortcut_command,omitempty"`
|
ShortcutCommand *ShortcutCommandDetail `thrift:"ShortcutCommand,13,optional" form:"shortcut_command" json:"shortcut_command,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -6582,7 +6582,7 @@ func (p *ChatV3MessageDetail) String() string {
|
||||||
type EnterMessage struct {
|
type EnterMessage struct {
|
||||||
// user / assistant
|
// user / assistant
|
||||||
Role string `thrift:"Role,1" form:"role" json:"role"`
|
Role string `thrift:"Role,1" form:"role" json:"role"`
|
||||||
// 如果是非 text,需要解析 JSON
|
// If it is not text, you need to parse JSON.
|
||||||
Content string `thrift:"Content,2" form:"content" json:"content"`
|
Content string `thrift:"Content,2" form:"content" json:"content"`
|
||||||
MetaData map[string]string `thrift:"MetaData,3" form:"meta_data" json:"meta_data"`
|
MetaData map[string]string `thrift:"MetaData,3" form:"meta_data" json:"meta_data"`
|
||||||
// text, card, object_string
|
// text, card, object_string
|
||||||
|
|
|
||||||
|
|
@ -30,10 +30,10 @@ type ListKnowledgeRequest struct {
|
||||||
IDs []int64
|
IDs []int64
|
||||||
SpaceID *int64
|
SpaceID *int64
|
||||||
AppID *int64
|
AppID *int64
|
||||||
Name *string // 完全匹配
|
Name *string // Exact match
|
||||||
Status []int32
|
Status []int32
|
||||||
UserID *int64
|
UserID *int64
|
||||||
Query *string // 模糊匹配
|
Query *string // fuzzy match
|
||||||
Page *int
|
Page *int
|
||||||
PageSize *int
|
PageSize *int
|
||||||
Order *Order
|
Order *Order
|
||||||
|
|
@ -58,10 +58,10 @@ const (
|
||||||
type DocumentType int64
|
type DocumentType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
DocumentTypeText DocumentType = 0 // 文本
|
DocumentTypeText DocumentType = 0 // Text
|
||||||
DocumentTypeTable DocumentType = 1 // 表格
|
DocumentTypeTable DocumentType = 1 // table
|
||||||
DocumentTypeImage DocumentType = 2 // 图片
|
DocumentTypeImage DocumentType = 2 // image
|
||||||
DocumentTypeUnknown DocumentType = 9 // 未知
|
DocumentTypeUnknown DocumentType = 9 // unknown
|
||||||
)
|
)
|
||||||
|
|
||||||
type ListKnowledgeResponse struct {
|
type ListKnowledgeResponse struct {
|
||||||
|
|
@ -102,14 +102,14 @@ type RetrieveRequest struct {
|
||||||
Query string
|
Query string
|
||||||
ChatHistory []*schema.Message
|
ChatHistory []*schema.Message
|
||||||
|
|
||||||
// 从指定的知识库和文档中召回
|
// Recall from the specified knowledge base and documentation
|
||||||
KnowledgeIDs []int64
|
KnowledgeIDs []int64
|
||||||
DocumentIDs []int64 // todo: 确认下这个场景
|
DocumentIDs []int64 // TODO: Confirm the scene
|
||||||
|
|
||||||
// 召回策略
|
// recall strategy
|
||||||
Strategy *RetrievalStrategy
|
Strategy *RetrievalStrategy
|
||||||
|
|
||||||
// 用于 nl2sql 和 message to query 的 chat model config
|
// Chat model config for nl2sql and message to query
|
||||||
ChatModelProtocol *chatmodel.Protocol
|
ChatModelProtocol *chatmodel.Protocol
|
||||||
ChatModelConfig *chatmodel.Config
|
ChatModelConfig *chatmodel.Config
|
||||||
}
|
}
|
||||||
|
|
@ -119,8 +119,8 @@ type RetrievalStrategy struct {
|
||||||
MinScore *float64 // 0.01-0.99 default 0.5
|
MinScore *float64 // 0.01-0.99 default 0.5
|
||||||
MaxTokens *int64
|
MaxTokens *int64
|
||||||
|
|
||||||
SelectType SelectType // 调用方式
|
SelectType SelectType // call method
|
||||||
SearchType SearchType // 搜索策略
|
SearchType SearchType // search strategy
|
||||||
EnableQueryRewrite bool
|
EnableQueryRewrite bool
|
||||||
EnableRerank bool
|
EnableRerank bool
|
||||||
EnableNL2SQL bool
|
EnableNL2SQL bool
|
||||||
|
|
@ -129,16 +129,16 @@ type RetrievalStrategy struct {
|
||||||
type SelectType int64
|
type SelectType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
SelectTypeAuto = 0 // 自动调用
|
SelectTypeAuto = 0 // automatic call
|
||||||
SelectTypeOnDemand = 1 // 按需调用
|
SelectTypeOnDemand = 1 // call on demand
|
||||||
)
|
)
|
||||||
|
|
||||||
type SearchType int64
|
type SearchType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
SearchTypeSemantic SearchType = 0 // 语义
|
SearchTypeSemantic SearchType = 0 // semantics
|
||||||
SearchTypeFullText SearchType = 1 // 全文
|
SearchTypeFullText SearchType = 1 // full text
|
||||||
SearchTypeHybrid SearchType = 2 // 混合
|
SearchTypeHybrid SearchType = 2 // mix
|
||||||
)
|
)
|
||||||
|
|
||||||
type RetrieveResponse struct {
|
type RetrieveResponse struct {
|
||||||
|
|
@ -158,10 +158,10 @@ type Slice struct {
|
||||||
DocumentName string
|
DocumentName string
|
||||||
RawContent []*SliceContent
|
RawContent []*SliceContent
|
||||||
SliceStatus SliceStatus
|
SliceStatus SliceStatus
|
||||||
ByteCount int64 // 切片 bytes
|
ByteCount int64 // Sliced bytes
|
||||||
CharCount int64 // 切片字符数
|
CharCount int64 // number of sliced characters
|
||||||
Sequence int64 // 切片位置序号
|
Sequence int64 // Slicing position serial number
|
||||||
Hit int64 // 命中次数
|
Hit int64 // hit count
|
||||||
Extra map[string]string
|
Extra map[string]string
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -215,9 +215,9 @@ type SliceContent struct {
|
||||||
type SliceStatus int64
|
type SliceStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
SliceStatusInit SliceStatus = 0 // 初始化
|
SliceStatusInit SliceStatus = 0 // initialization
|
||||||
SliceStatusFinishStore SliceStatus = 1 // searchStore存储完成
|
SliceStatusFinishStore SliceStatus = 1 // searchStore storage complete
|
||||||
SliceStatusFailed SliceStatus = 9 // 失败
|
SliceStatusFailed SliceStatus = 9 // fail
|
||||||
)
|
)
|
||||||
|
|
||||||
type SliceContentType int64
|
type SliceContentType int64
|
||||||
|
|
@ -231,11 +231,11 @@ const (
|
||||||
type SliceImage struct {
|
type SliceImage struct {
|
||||||
Base64 []byte
|
Base64 []byte
|
||||||
URI string
|
URI string
|
||||||
OCR bool // 是否使用 ocr 提取了文本
|
OCR bool // Is the text extracted using OCR?
|
||||||
OCRText *string
|
OCRText *string
|
||||||
}
|
}
|
||||||
|
|
||||||
type SliceTable struct { // table slice 为一行数据
|
type SliceTable struct { // Table sliced into one row
|
||||||
Columns []*document.ColumnData
|
Columns []*document.ColumnData
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -261,7 +261,7 @@ func (op *Openapi3Operation) ToEinoSchemaParameterInfo(ctx context.Context) (map
|
||||||
result[paramName] = paramInfo
|
result[paramName] = paramInfo
|
||||||
}
|
}
|
||||||
|
|
||||||
break // 只取一种 MIME
|
break // Take only one MIME.
|
||||||
}
|
}
|
||||||
|
|
||||||
return result, nil
|
return result, nil
|
||||||
|
|
@ -375,8 +375,8 @@ func validateOpenapi3Responses(responses openapi3.Responses) (err error) {
|
||||||
return nil
|
return nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// default status 不处理
|
// Default status not processed
|
||||||
// 只处理 '200' status
|
// Only process' 200 'status
|
||||||
if len(responses) != 1 {
|
if len(responses) != 1 {
|
||||||
if len(responses) != 2 {
|
if len(responses) != 2 {
|
||||||
return errorx.New(errno.ErrPluginInvalidOpenapi3Doc, errorx.KV(errno.PluginMsgKey,
|
return errorx.New(errno.ErrPluginInvalidOpenapi3Doc, errorx.KV(errno.PluginMsgKey,
|
||||||
|
|
|
||||||
|
|
@ -341,7 +341,7 @@ type AuthV2 struct {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (au *AuthV2) UnmarshalJSON(data []byte) error {
|
func (au *AuthV2) UnmarshalJSON(data []byte) error {
|
||||||
auth := &Auth{} // 兼容老数据
|
auth := &Auth{} // Compatible with old data
|
||||||
err := json.Unmarshal(data, auth)
|
err := json.Unmarshal(data, auth)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return errorx.WrapByCode(err, errno.ErrPluginInvalidManifest, errorx.KV(errno.PluginMsgKey,
|
return errorx.WrapByCode(err, errno.ErrPluginInvalidManifest, errorx.KV(errno.PluginMsgKey,
|
||||||
|
|
@ -381,7 +381,7 @@ func (au *AuthV2) UnmarshalJSON(data []byte) error {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (au *AuthV2) unmarshalService(auth *Auth) (err error) {
|
func (au *AuthV2) unmarshalService(auth *Auth) (err error) {
|
||||||
if au.SubType == "" && au.Payload == "" { // 兼容老数据
|
if au.SubType == "" && au.Payload == "" { // Compatible with old data
|
||||||
au.SubType = AuthzSubTypeOfServiceAPIToken
|
au.SubType = AuthzSubTypeOfServiceAPIToken
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -421,7 +421,7 @@ func (au *AuthV2) unmarshalService(auth *Auth) (err error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
func (au *AuthV2) unmarshalOAuth(auth *Auth) (err error) {
|
func (au *AuthV2) unmarshalOAuth(auth *Auth) (err error) {
|
||||||
if au.SubType == "" { // 兼容老数据
|
if au.SubType == "" { // Compatible with old data
|
||||||
au.SubType = AuthzSubTypeOfOAuthAuthorizationCode
|
au.SubType = AuthzSubTypeOfOAuthAuthorizationCode
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -232,7 +232,7 @@ func (t ToolInfo) ToReqAPIParameter() ([]*common.APIParameter, error) {
|
||||||
params = append(params, apiParam)
|
params = append(params, apiParam)
|
||||||
}
|
}
|
||||||
|
|
||||||
break // 只取一种 MIME
|
break // Take only one MIME.
|
||||||
}
|
}
|
||||||
|
|
||||||
return params, nil
|
return params, nil
|
||||||
|
|
@ -257,7 +257,7 @@ func toAPIParameter(paramMeta paramMetaInfo, sc *openapi3.Schema) (*common.APIPa
|
||||||
Name: paramMeta.name,
|
Name: paramMeta.name,
|
||||||
Desc: paramMeta.desc,
|
Desc: paramMeta.desc,
|
||||||
Type: apiType,
|
Type: apiType,
|
||||||
Location: location, // 使用父节点的值
|
Location: location, // Using the value of the parent node
|
||||||
IsRequired: paramMeta.required,
|
IsRequired: paramMeta.required,
|
||||||
SubParameters: []*common.APIParameter{},
|
SubParameters: []*common.APIParameter{},
|
||||||
}
|
}
|
||||||
|
|
@ -453,7 +453,7 @@ func (t ToolInfo) ToPluginParameters() ([]*common.PluginParameter, error) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
break // 只取一种 MIME
|
break // Take only one MIME.
|
||||||
}
|
}
|
||||||
|
|
||||||
return params, nil
|
return params, nil
|
||||||
|
|
|
||||||
|
|
@ -50,7 +50,7 @@ func (r *ResourceDocument) GetOwnerID() int64 {
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
// GetUpdateTime 获取更新时间
|
// GetUpdateTime Get the update time
|
||||||
func (r *ResourceDocument) GetUpdateTime() int64 {
|
func (r *ResourceDocument) GetUpdateTime() int64 {
|
||||||
if r.UpdateTimeMS != nil {
|
if r.UpdateTimeMS != nil {
|
||||||
return *r.UpdateTimeMS
|
return *r.UpdateTimeMS
|
||||||
|
|
|
||||||
|
|
@ -3,11 +3,11 @@
|
||||||
package database
|
package database
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/knowledge/document"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/table"
|
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/knowledge/document"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/table"
|
||||||
)
|
)
|
||||||
|
|
||||||
type DatabaseService interface {
|
type DatabaseService interface {
|
||||||
|
|
|
||||||
|
|
@ -13,15 +13,15 @@ import (
|
||||||
type ConfigStatus int64
|
type ConfigStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 已配置
|
// Configured
|
||||||
ConfigStatus_Configured ConfigStatus = 1
|
ConfigStatus_Configured ConfigStatus = 1
|
||||||
// 未配置
|
// Not configured
|
||||||
ConfigStatus_NotConfigured ConfigStatus = 2
|
ConfigStatus_NotConfigured ConfigStatus = 2
|
||||||
// Token发生变化
|
// Token changes
|
||||||
ConfigStatus_Disconnected ConfigStatus = 3
|
ConfigStatus_Disconnected ConfigStatus = 3
|
||||||
// 配置中,授权中
|
// Configuring, authorizing
|
||||||
ConfigStatus_Configuring ConfigStatus = 4
|
ConfigStatus_Configuring ConfigStatus = 4
|
||||||
// 需要重新配置 https://bytedance.larkoffice.com/docx/KXNed5NWUoplVBxXdQxcfPNwnrf#Gn7dd2KoaoNZo6xw1tkcT92znbG
|
// Need to reconfigure https://bytedance.larkoffice.com/docx/KXNed5NWUoplVBxXdQxcfPNwnrf#Gn7dd2KoaoNZo6xw1tkcT92znbG
|
||||||
ConfigStatus_NeedReconfiguring ConfigStatus = 5
|
ConfigStatus_NeedReconfiguring ConfigStatus = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -75,19 +75,19 @@ func (p *ConfigStatus) Value() (driver.Value, error) {
|
||||||
type BindType int64
|
type BindType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 无需绑定
|
// No binding required
|
||||||
BindType_NoBindRequired BindType = 1
|
BindType_NoBindRequired BindType = 1
|
||||||
// Auth绑定
|
// Auth binding
|
||||||
BindType_AuthBind BindType = 2
|
BindType_AuthBind BindType = 2
|
||||||
// Kv绑定=
|
// Kv binding =
|
||||||
BindType_KvBind BindType = 3
|
BindType_KvBind BindType = 3
|
||||||
// Kv并Auth授权
|
// Kv and Auth authorization
|
||||||
BindType_KvAuthBind BindType = 4
|
BindType_KvAuthBind BindType = 4
|
||||||
// api渠道绑定
|
// API channel binding
|
||||||
BindType_ApiBind BindType = 5
|
BindType_ApiBind BindType = 5
|
||||||
BindType_WebSDKBind BindType = 6
|
BindType_WebSDKBind BindType = 6
|
||||||
BindType_StoreBind BindType = 7
|
BindType_StoreBind BindType = 7
|
||||||
// 授权和配置各一个按钮
|
// One button each for authorization and configuration
|
||||||
BindType_AuthAndConfig BindType = 8
|
BindType_AuthAndConfig BindType = 8
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -195,11 +195,11 @@ func (p *AllowPublishStatus) Value() (driver.Value, error) {
|
||||||
type BotConnectorStatus int64
|
type BotConnectorStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 正常
|
// Normal
|
||||||
BotConnectorStatus_Normal BotConnectorStatus = 0
|
BotConnectorStatus_Normal BotConnectorStatus = 0
|
||||||
// 审核中
|
// Under review.
|
||||||
BotConnectorStatus_InReview BotConnectorStatus = 1
|
BotConnectorStatus_InReview BotConnectorStatus = 1
|
||||||
// 已下线
|
// offline
|
||||||
BotConnectorStatus_Offline BotConnectorStatus = 2
|
BotConnectorStatus_Offline BotConnectorStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -245,11 +245,11 @@ func (p *BotConnectorStatus) Value() (driver.Value, error) {
|
||||||
type UserAuthStatus int64
|
type UserAuthStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 已授权
|
// Authorized
|
||||||
UserAuthStatus_Authorized UserAuthStatus = 1
|
UserAuthStatus_Authorized UserAuthStatus = 1
|
||||||
// 未授权
|
// unauthorized
|
||||||
UserAuthStatus_UnAuthorized UserAuthStatus = 2
|
UserAuthStatus_UnAuthorized UserAuthStatus = 2
|
||||||
// 授权中
|
// Authorizing
|
||||||
UserAuthStatus_Authorizing UserAuthStatus = 3
|
UserAuthStatus_Authorizing UserAuthStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1002,49 +1002,49 @@ func (p *PublishConnectorListRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishConnectorInfo struct {
|
type PublishConnectorInfo struct {
|
||||||
// 发布平台 connector_id
|
// Publishing Platform connector_id
|
||||||
ID string `thrift:"id,1,required" form:"id,required" json:"id,required" query:"id,required"`
|
ID string `thrift:"id,1,required" form:"id,required" json:"id,required" query:"id,required"`
|
||||||
// 发布平台名称
|
// publishing platform name
|
||||||
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
// 发布平台图标
|
// publishing platform icon
|
||||||
Icon string `thrift:"icon,3,required" form:"icon,required" json:"icon,required" query:"icon,required"`
|
Icon string `thrift:"icon,3,required" form:"icon,required" json:"icon,required" query:"icon,required"`
|
||||||
// 发布平台描述
|
// Publish Platform Description
|
||||||
Desc string `thrift:"desc,4,required" form:"desc,required" json:"desc,required" query:"desc,required"`
|
Desc string `thrift:"desc,4,required" form:"desc,required" json:"desc,required" query:"desc,required"`
|
||||||
// 分享链接
|
// share link
|
||||||
ShareLink string `thrift:"share_link,5,required" form:"share_link,required" json:"share_link,required" query:"share_link,required"`
|
ShareLink string `thrift:"share_link,5,required" form:"share_link,required" json:"share_link,required" query:"share_link,required"`
|
||||||
// 配置状态 1:已绑定 2:未绑定
|
// Configuration Status 1: Bound 2: Unbound
|
||||||
ConfigStatus ConfigStatus `thrift:"config_status,6,required" form:"config_status,required" json:"config_status,required" query:"config_status,required"`
|
ConfigStatus ConfigStatus `thrift:"config_status,6,required" form:"config_status,required" json:"config_status,required" query:"config_status,required"`
|
||||||
// 最近发布时间
|
// Last Post
|
||||||
LastPublishTime int64 `thrift:"last_publish_time,7,required" form:"last_publish_time,required" json:"last_publish_time,required" query:"last_publish_time,required"`
|
LastPublishTime int64 `thrift:"last_publish_time,7,required" form:"last_publish_time,required" json:"last_publish_time,required" query:"last_publish_time,required"`
|
||||||
// 绑定类型 1:无需绑定 2:Auth 3: kv值
|
// Binding type 1: No binding required 2: Auth 3: kv value
|
||||||
BindType BindType `thrift:"bind_type,8,required" form:"bind_type,required" json:"bind_type,required" query:"bind_type,required"`
|
BindType BindType `thrift:"bind_type,8,required" form:"bind_type,required" json:"bind_type,required" query:"bind_type,required"`
|
||||||
// 绑定信息 key字段名 value是值
|
// Binding information key field name value is value
|
||||||
BindInfo map[string]string `thrift:"bind_info,9,required" form:"bind_info,required" json:"bind_info,required" query:"bind_info,required"`
|
BindInfo map[string]string `thrift:"bind_info,9,required" form:"bind_info,required" json:"bind_info,required" query:"bind_info,required"`
|
||||||
// 绑定id信息,用于解绑使用
|
// Bind id information for unbinding and use
|
||||||
BindID *string `thrift:"bind_id,10,optional" form:"bind_id" json:"bind_id,omitempty" query:"bind_id"`
|
BindID *string `thrift:"bind_id,10,optional" form:"bind_id" json:"bind_id,omitempty" query:"bind_id"`
|
||||||
// 用户授权登陆信息
|
// user authorization login information
|
||||||
AuthLoginInfo *AuthLoginInfo `thrift:"auth_login_info,11,optional" form:"auth_login_info" json:"auth_login_info,omitempty" query:"auth_login_info"`
|
AuthLoginInfo *AuthLoginInfo `thrift:"auth_login_info,11,optional" form:"auth_login_info" json:"auth_login_info,omitempty" query:"auth_login_info"`
|
||||||
// 是否为上次发布
|
// Is it the last release?
|
||||||
IsLastPublished *bool `thrift:"is_last_published,12,optional" form:"is_last_published" json:"is_last_published,omitempty" query:"is_last_published"`
|
IsLastPublished *bool `thrift:"is_last_published,12,optional" form:"is_last_published" json:"is_last_published,omitempty" query:"is_last_published"`
|
||||||
// bot渠道状态
|
// bot channel status
|
||||||
ConnectorStatus *BotConnectorStatus `thrift:"connector_status,13,optional" form:"connector_status" json:"connector_status,omitempty" query:"connector_status"`
|
ConnectorStatus *BotConnectorStatus `thrift:"connector_status,13,optional" form:"connector_status" json:"connector_status,omitempty" query:"connector_status"`
|
||||||
// 隐私政策
|
// Privacy Policy
|
||||||
PrivacyPolicy *string `thrift:"privacy_policy,14,optional" form:"privacy_policy" json:"privacy_policy,omitempty" query:"privacy_policy"`
|
PrivacyPolicy *string `thrift:"privacy_policy,14,optional" form:"privacy_policy" json:"privacy_policy,omitempty" query:"privacy_policy"`
|
||||||
// 用户协议
|
// User Agreement
|
||||||
UserAgreement *string `thrift:"user_agreement,15,optional" form:"user_agreement" json:"user_agreement,omitempty" query:"user_agreement"`
|
UserAgreement *string `thrift:"user_agreement,15,optional" form:"user_agreement" json:"user_agreement,omitempty" query:"user_agreement"`
|
||||||
// 渠道是否允许发布
|
// Is the channel allowed to publish?
|
||||||
AllowPunish *AllowPublishStatus `thrift:"allow_punish,16,optional" form:"allow_punish" json:"allow_punish,omitempty" query:"allow_punish"`
|
AllowPunish *AllowPublishStatus `thrift:"allow_punish,16,optional" form:"allow_punish" json:"allow_punish,omitempty" query:"allow_punish"`
|
||||||
// 不允许发布原因
|
// Reason for not allowing posting
|
||||||
NotAllowReason *string `thrift:"not_allow_reason,17,optional" form:"not_allow_reason" json:"not_allow_reason,omitempty" query:"not_allow_reason"`
|
NotAllowReason *string `thrift:"not_allow_reason,17,optional" form:"not_allow_reason" json:"not_allow_reason,omitempty" query:"not_allow_reason"`
|
||||||
// 配置状态toast
|
// Configuration status toast
|
||||||
ConfigStatusToast *string `thrift:"config_status_toast,18,optional" form:"config_status_toast" json:"config_status_toast,omitempty" query:"config_status_toast"`
|
ConfigStatusToast *string `thrift:"config_status_toast,18,optional" form:"config_status_toast" json:"config_status_toast,omitempty" query:"config_status_toast"`
|
||||||
// 品牌 ID
|
// Brand ID
|
||||||
BrandID *int64 `thrift:"brand_id,19,optional" form:"brand_id" json:"brand_id,omitempty" query:"brand_id"`
|
BrandID *int64 `thrift:"brand_id,19,optional" form:"brand_id" json:"brand_id,omitempty" query:"brand_id"`
|
||||||
// 支持商业化
|
// Support commercialization
|
||||||
SupportMonetization *bool `thrift:"support_monetization,20,optional" form:"support_monetization" json:"support_monetization,omitempty" query:"support_monetization"`
|
SupportMonetization *bool `thrift:"support_monetization,20,optional" form:"support_monetization" json:"support_monetization,omitempty" query:"support_monetization"`
|
||||||
// 1: 已授权,2:未授权. 目前仅 bind_type == 8 时这个字段才有 https://bytedance.larkoffice.com/docx/KXNed5NWUoplVBxXdQxcfPNwnrf#Gn7dd2KoaoNZo6xw1tkcT92znbG
|
// 1: Authorized, 2: Unauthorized. Currently, this field is only available bind_type == 8 https://bytedance.larkoffice.com/docx/KXNed5NWUoplVBxXdQxcfPNwnrf#Gn7dd2KoaoNZo6xw1tkcT92znbG
|
||||||
AuthStatus *UserAuthStatus `thrift:"auth_status,21,optional" form:"auth_status" json:"auth_status,omitempty" query:"auth_status"`
|
AuthStatus *UserAuthStatus `thrift:"auth_status,21,optional" form:"auth_status" json:"auth_status,omitempty" query:"auth_status"`
|
||||||
// 补全信息按钮的 url
|
// URL of the complete info button
|
||||||
ToCompleteInfoURL *string `thrift:"to_complete_info_url,22,optional" form:"to_complete_info_url" json:"to_complete_info_url,omitempty" query:"to_complete_info_url"`
|
ToCompleteInfoURL *string `thrift:"to_complete_info_url,22,optional" form:"to_complete_info_url" json:"to_complete_info_url,omitempty" query:"to_complete_info_url"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2344,7 +2344,7 @@ func (p *PublishConnectorInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SubmitBotMarketOption struct {
|
type SubmitBotMarketOption struct {
|
||||||
// 是否可以公开编排
|
// Is it possible to publicly orchestrate?
|
||||||
CanOpenSource *bool `thrift:"can_open_source,1,optional" form:"can_open_source" json:"can_open_source,omitempty" query:"can_open_source"`
|
CanOpenSource *bool `thrift:"can_open_source,1,optional" form:"can_open_source" json:"can_open_source,omitempty" query:"can_open_source"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2495,11 +2495,11 @@ func (p *SubmitBotMarketOption) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SubmitBotMarketConfig struct {
|
type SubmitBotMarketConfig struct {
|
||||||
// 是否发布到market
|
// Whether to publish to the market
|
||||||
NeedSubmit *bool `thrift:"need_submit,1,optional" form:"need_submit" json:"need_submit,omitempty" query:"need_submit"`
|
NeedSubmit *bool `thrift:"need_submit,1,optional" form:"need_submit" json:"need_submit,omitempty" query:"need_submit"`
|
||||||
// 是否开源
|
// Is it open source?
|
||||||
OpenSource *bool `thrift:"open_source,2,optional" form:"open_source" json:"open_source,omitempty" query:"open_source"`
|
OpenSource *bool `thrift:"open_source,2,optional" form:"open_source" json:"open_source,omitempty" query:"open_source"`
|
||||||
// 分类
|
// classification
|
||||||
CategoryID *string `thrift:"category_id,3,optional" form:"category_id" json:"category_id,omitempty" query:"category_id"`
|
CategoryID *string `thrift:"category_id,3,optional" form:"category_id" json:"category_id,omitempty" query:"category_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3011,7 +3011,7 @@ func (p *ConnectorBrandInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishTips struct {
|
type PublishTips struct {
|
||||||
// 成本承担提醒
|
// cost-bearing reminder
|
||||||
CostTips *string `thrift:"cost_tips,1,optional" form:"cost_tips" json:"cost_tips,omitempty" query:"cost_tips"`
|
CostTips *string `thrift:"cost_tips,1,optional" form:"cost_tips" json:"cost_tips,omitempty" query:"cost_tips"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3166,11 +3166,11 @@ type PublishConnectorListResponse struct {
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
PublishConnectorList []*PublishConnectorInfo `thrift:"publish_connector_list,3" form:"publish_connector_list" json:"publish_connector_list" query:"publish_connector_list"`
|
PublishConnectorList []*PublishConnectorInfo `thrift:"publish_connector_list,3" form:"publish_connector_list" json:"publish_connector_list" query:"publish_connector_list"`
|
||||||
SubmitBotMarketOption *SubmitBotMarketOption `thrift:"submit_bot_market_option,4,optional" form:"submit_bot_market_option" json:"submit_bot_market_option,omitempty" query:"submit_bot_market_option"`
|
SubmitBotMarketOption *SubmitBotMarketOption `thrift:"submit_bot_market_option,4,optional" form:"submit_bot_market_option" json:"submit_bot_market_option,omitempty" query:"submit_bot_market_option"`
|
||||||
// 上次提交market的配置
|
// The configuration of the last submitted market
|
||||||
LastSubmitConfig *SubmitBotMarketConfig `thrift:"last_submit_config,5,optional" form:"last_submit_config" json:"last_submit_config,omitempty" query:"last_submit_config"`
|
LastSubmitConfig *SubmitBotMarketConfig `thrift:"last_submit_config,5,optional" form:"last_submit_config" json:"last_submit_config,omitempty" query:"last_submit_config"`
|
||||||
// 渠道品牌信息
|
// Channel brand information
|
||||||
ConnectorBrandInfoMap map[int64]*ConnectorBrandInfo `thrift:"connector_brand_info_map,6" form:"connector_brand_info_map" json:"connector_brand_info_map" query:"connector_brand_info_map"`
|
ConnectorBrandInfoMap map[int64]*ConnectorBrandInfo `thrift:"connector_brand_info_map,6" form:"connector_brand_info_map" json:"connector_brand_info_map" query:"connector_brand_info_map"`
|
||||||
// 发布提醒
|
// post alert
|
||||||
PublishTips *PublishTips `thrift:"publish_tips,7,optional" form:"publish_tips" json:"publish_tips,omitempty" query:"publish_tips"`
|
PublishTips *PublishTips `thrift:"publish_tips,7,optional" form:"publish_tips" json:"publish_tips,omitempty" query:"publish_tips"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,17 +9,17 @@ import (
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
)
|
)
|
||||||
|
|
||||||
// 类型
|
// type
|
||||||
type FormatType int64
|
type FormatType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 文本
|
// Text
|
||||||
FormatType_Text FormatType = 0
|
FormatType_Text FormatType = 0
|
||||||
// 表格
|
// table
|
||||||
FormatType_Table FormatType = 1
|
FormatType_Table FormatType = 1
|
||||||
// 图片
|
// image
|
||||||
FormatType_Image FormatType = 2
|
FormatType_Image FormatType = 2
|
||||||
// 数据库
|
// database
|
||||||
FormatType_Database FormatType = 3
|
FormatType_Database FormatType = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -158,9 +158,9 @@ func (p *ContentSchema) Value() (driver.Value, error) {
|
||||||
type CaptionType int64
|
type CaptionType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 智能标注
|
// intelligent annotation
|
||||||
CaptionType_Auto CaptionType = 0
|
CaptionType_Auto CaptionType = 0
|
||||||
// 人工标注
|
// manual annotation
|
||||||
CaptionType_Manual CaptionType = 1
|
CaptionType_Manual CaptionType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -202,19 +202,19 @@ func (p *CaptionType) Value() (driver.Value, error) {
|
||||||
type DocumentStatus int64
|
type DocumentStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 上传中
|
// Uploading
|
||||||
DocumentStatus_Processing DocumentStatus = 0
|
DocumentStatus_Processing DocumentStatus = 0
|
||||||
// 生效
|
// take effect
|
||||||
DocumentStatus_Enable DocumentStatus = 1
|
DocumentStatus_Enable DocumentStatus = 1
|
||||||
// 失效
|
// failure
|
||||||
DocumentStatus_Disable DocumentStatus = 2
|
DocumentStatus_Disable DocumentStatus = 2
|
||||||
// 删除
|
// delete
|
||||||
DocumentStatus_Deleted DocumentStatus = 3
|
DocumentStatus_Deleted DocumentStatus = 3
|
||||||
// 重新分片中,调用方不感知该状态
|
// In rescaling, the caller is not aware of the state
|
||||||
DocumentStatus_Resegment DocumentStatus = 4
|
DocumentStatus_Resegment DocumentStatus = 4
|
||||||
// 刷新中(刷新成功后会删除)
|
// Refreshing (will be deleted after successful refresh)
|
||||||
DocumentStatus_Refreshing DocumentStatus = 5
|
DocumentStatus_Refreshing DocumentStatus = 5
|
||||||
// 失败
|
// fail
|
||||||
DocumentStatus_Failed DocumentStatus = 9
|
DocumentStatus_Failed DocumentStatus = 9
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -276,9 +276,9 @@ func (p *DocumentStatus) Value() (driver.Value, error) {
|
||||||
type DocumentSource int64
|
type DocumentSource int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 本地文件上传
|
// local file upload
|
||||||
DocumentSource_Document DocumentSource = 0
|
DocumentSource_Document DocumentSource = 0
|
||||||
// 自定义类型
|
// custom type
|
||||||
DocumentSource_Custom DocumentSource = 2
|
DocumentSource_Custom DocumentSource = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -320,9 +320,9 @@ func (p *DocumentSource) Value() (driver.Value, error) {
|
||||||
type ParsingType int64
|
type ParsingType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
//快速解析
|
//fast parse
|
||||||
ParsingType_FastParsing ParsingType = 0
|
ParsingType_FastParsing ParsingType = 0
|
||||||
//精准解析
|
//accurate analysis
|
||||||
ParsingType_AccurateParsing ParsingType = 1
|
ParsingType_AccurateParsing ParsingType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -361,7 +361,7 @@ func (p *ParsingType) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 排序字段
|
// sort field
|
||||||
type OrderField int64
|
type OrderField int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -404,7 +404,7 @@ func (p *OrderField) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 排序规则
|
// OrderType
|
||||||
type OrderType int64
|
type OrderType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -450,13 +450,13 @@ func (p *OrderType) Value() (driver.Value, error) {
|
||||||
type ReviewStatus int64
|
type ReviewStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 处理中
|
// Processing
|
||||||
ReviewStatus_Processing ReviewStatus = 0
|
ReviewStatus_Processing ReviewStatus = 0
|
||||||
// 已完成
|
// Completed.
|
||||||
ReviewStatus_Enable ReviewStatus = 1
|
ReviewStatus_Enable ReviewStatus = 1
|
||||||
// 失败
|
// fail
|
||||||
ReviewStatus_Failed ReviewStatus = 2
|
ReviewStatus_Failed ReviewStatus = 2
|
||||||
// 失败
|
// fail
|
||||||
ReviewStatus_ForceStop ReviewStatus = 3
|
ReviewStatus_ForceStop ReviewStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -504,23 +504,23 @@ func (p *ReviewStatus) Value() (driver.Value, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ChunkStrategy struct {
|
type ChunkStrategy struct {
|
||||||
// 分隔符,如句号
|
// A separator, such as a period
|
||||||
Separator string `thrift:"separator,1" form:"separator" json:"separator" query:"separator"`
|
Separator string `thrift:"separator,1" form:"separator" json:"separator" query:"separator"`
|
||||||
// 分片的最大token数
|
// Maximum number of tokens for sharding
|
||||||
MaxTokens int64 `thrift:"max_tokens,2" form:"max_tokens" json:"max_tokens" query:"max_tokens"`
|
MaxTokens int64 `thrift:"max_tokens,2" form:"max_tokens" json:"max_tokens" query:"max_tokens"`
|
||||||
// 替换掉连续的空格、换行符和制表符
|
// Replace consecutive spaces, newlines, and tabs
|
||||||
RemoveExtraSpaces bool `thrift:"remove_extra_spaces,3" form:"remove_extra_spaces" json:"remove_extra_spaces" query:"remove_extra_spaces"`
|
RemoveExtraSpaces bool `thrift:"remove_extra_spaces,3" form:"remove_extra_spaces" json:"remove_extra_spaces" query:"remove_extra_spaces"`
|
||||||
// 是否去除url和email
|
// Remove URL and email
|
||||||
RemoveUrlsEmails bool `thrift:"remove_urls_emails,4" form:"remove_urls_emails" json:"remove_urls_emails" query:"remove_urls_emails"`
|
RemoveUrlsEmails bool `thrift:"remove_urls_emails,4" form:"remove_urls_emails" json:"remove_urls_emails" query:"remove_urls_emails"`
|
||||||
// 如果为0, 则不使用以上字段的配置
|
// If 0, the configuration of the above fields is not used
|
||||||
ChunkType ChunkType `thrift:"chunk_type,5" form:"chunk_type" json:"chunk_type" query:"chunk_type"`
|
ChunkType ChunkType `thrift:"chunk_type,5" form:"chunk_type" json:"chunk_type" query:"chunk_type"`
|
||||||
// 图片类型,图片描述文字的标注方式
|
// Image type, image description text annotation method
|
||||||
CaptionType *CaptionType `thrift:"caption_type,7,optional" form:"caption_type" json:"caption_type,omitempty" query:"caption_type"`
|
CaptionType *CaptionType `thrift:"caption_type,7,optional" form:"caption_type" json:"caption_type,omitempty" query:"caption_type"`
|
||||||
//分段重叠度
|
//segmented overlap
|
||||||
Overlap *int64 `thrift:"overlap,8,optional" form:"overlap" json:"overlap,omitempty" query:"overlap"`
|
Overlap *int64 `thrift:"overlap,8,optional" form:"overlap" json:"overlap,omitempty" query:"overlap"`
|
||||||
//最大层级数(按层级分段时生效)
|
//Maximum number of levels (effective when segmented by level)
|
||||||
MaxLevel *int64 `thrift:"max_level,9,optional" form:"max_level" json:"max_level,omitempty" query:"max_level"`
|
MaxLevel *int64 `thrift:"max_level,9,optional" form:"max_level" json:"max_level,omitempty" query:"max_level"`
|
||||||
//切片保留层级标题(按层级分段时生效)
|
//Slice preserves level headers (effective when segmented by level)
|
||||||
SaveTitle *bool `thrift:"save_title,10,optional" form:"save_title" json:"save_title,omitempty" query:"save_title"`
|
SaveTitle *bool `thrift:"save_title,10,optional" form:"save_title" json:"save_title,omitempty" query:"save_title"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1057,13 +1057,13 @@ func (p *ChunkStrategy) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ParsingStrategy struct {
|
type ParsingStrategy struct {
|
||||||
//解析类型
|
//parse type
|
||||||
ParsingType *ParsingType `thrift:"parsing_type,1,optional" form:"parsing_type" json:"parsing_type,omitempty" query:"parsing_type"`
|
ParsingType *ParsingType `thrift:"parsing_type,1,optional" form:"parsing_type" json:"parsing_type,omitempty" query:"parsing_type"`
|
||||||
//是否开启图片元素提取(精准解析时生效)
|
//Whether to enable image element extraction (effective when accurately parsing)
|
||||||
ImageExtraction *bool `thrift:"image_extraction,2,optional" form:"image_extraction" json:"image_extraction,omitempty" query:"image_extraction"`
|
ImageExtraction *bool `thrift:"image_extraction,2,optional" form:"image_extraction" json:"image_extraction,omitempty" query:"image_extraction"`
|
||||||
//是否开启表格元素提取(精准解析时生效)
|
//Whether to enable table element extraction (effective when accurately parsing)
|
||||||
TableExtraction *bool `thrift:"table_extraction,3,optional" form:"table_extraction" json:"table_extraction,omitempty" query:"table_extraction"`
|
TableExtraction *bool `thrift:"table_extraction,3,optional" form:"table_extraction" json:"table_extraction,omitempty" query:"table_extraction"`
|
||||||
//是否开启图片OCR(精准解析时生效)
|
//Whether to turn on picture OCR (effective when accurate analysis)
|
||||||
ImageOcr *bool `thrift:"image_ocr,4,optional" form:"image_ocr" json:"image_ocr,omitempty" query:"image_ocr"`
|
ImageOcr *bool `thrift:"image_ocr,4,optional" form:"image_ocr" json:"image_ocr,omitempty" query:"image_ocr"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1380,13 +1380,13 @@ func (p *ParsingStrategy) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type IndexStrategy struct {
|
type IndexStrategy struct {
|
||||||
//是否开启向量索引(默认为true)
|
//Whether to enable vector indexing (default is true)
|
||||||
VectorIndexing *bool `thrift:"vector_indexing,1,optional" form:"vector_indexing" json:"vector_indexing,omitempty" query:"vector_indexing"`
|
VectorIndexing *bool `thrift:"vector_indexing,1,optional" form:"vector_indexing" json:"vector_indexing,omitempty" query:"vector_indexing"`
|
||||||
//是否开启关键词索引(默认为true)
|
//Whether to enable keyword indexing (default is true)
|
||||||
KeywordIndexing *bool `thrift:"keyword_indexing,2,optional" form:"keyword_indexing" json:"keyword_indexing,omitempty" query:"keyword_indexing"`
|
KeywordIndexing *bool `thrift:"keyword_indexing,2,optional" form:"keyword_indexing" json:"keyword_indexing,omitempty" query:"keyword_indexing"`
|
||||||
//是否开启分层索引
|
//Whether to enable hierarchical indexing
|
||||||
HierarchicalIndexing *bool `thrift:"hierarchical_indexing,3,optional" form:"hierarchical_indexing" json:"hierarchical_indexing,omitempty" query:"hierarchical_indexing"`
|
HierarchicalIndexing *bool `thrift:"hierarchical_indexing,3,optional" form:"hierarchical_indexing" json:"hierarchical_indexing,omitempty" query:"hierarchical_indexing"`
|
||||||
//向量模型
|
//vector model
|
||||||
Model *string `thrift:"model,4,optional" form:"model" json:"model,omitempty" query:"model"`
|
Model *string `thrift:"model,4,optional" form:"model" json:"model,omitempty" query:"model"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1702,7 +1702,7 @@ func (p *IndexStrategy) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type FilterStrategy struct {
|
type FilterStrategy struct {
|
||||||
//过滤页数
|
//filter pages
|
||||||
FilterPage []int32 `thrift:"filter_page,1,optional" form:"filter_page" json:"filter_page,omitempty" query:"filter_page"`
|
FilterPage []int32 `thrift:"filter_page,1,optional" form:"filter_page" json:"filter_page,omitempty" query:"filter_page"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1873,7 +1873,7 @@ func (p *FilterStrategy) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SinkStrategy struct {
|
type SinkStrategy struct {
|
||||||
// 是否检查索引成功
|
// Check whether the index was successful
|
||||||
CheckIndex bool `thrift:"check_index,1" form:"check_index" json:"check_index" query:"check_index"`
|
CheckIndex bool `thrift:"check_index,1" form:"check_index" json:"check_index" query:"check_index"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,11 +3,11 @@
|
||||||
package dataset
|
package dataset
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type DatasetStatus int64
|
type DatasetStatus int64
|
||||||
|
|
@ -15,9 +15,9 @@ type DatasetStatus int64
|
||||||
const (
|
const (
|
||||||
DatasetStatus_DatasetProcessing DatasetStatus = 0
|
DatasetStatus_DatasetProcessing DatasetStatus = 0
|
||||||
DatasetStatus_DatasetReady DatasetStatus = 1
|
DatasetStatus_DatasetReady DatasetStatus = 1
|
||||||
// 软删
|
// soft delete
|
||||||
DatasetStatus_DatasetDeleted DatasetStatus = 2
|
DatasetStatus_DatasetDeleted DatasetStatus = 2
|
||||||
// 不启用
|
// Do not enable
|
||||||
DatasetStatus_DatasetForbid DatasetStatus = 3
|
DatasetStatus_DatasetForbid DatasetStatus = 3
|
||||||
DatasetStatus_DatasetFailed DatasetStatus = 9
|
DatasetStatus_DatasetFailed DatasetStatus = 9
|
||||||
)
|
)
|
||||||
|
|
@ -154,18 +154,18 @@ func (p *DatasetSource) Value() (driver.Value, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type CreateDatasetRequest struct {
|
type CreateDatasetRequest struct {
|
||||||
// 知识库名称,长度不超过100个字符
|
// Knowledge base name, no more than 100 characters in length
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
// 知识库描述
|
// Knowledge Base Description
|
||||||
Description string `thrift:"description,2" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,2" form:"description" json:"description" query:"description"`
|
||||||
// 空间ID
|
// Space ID
|
||||||
SpaceID int64 `thrift:"space_id,3" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,3" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
// 知识库头像URI
|
// Knowledge Base Avatar URI
|
||||||
IconURI string `thrift:"icon_uri,4" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
IconURI string `thrift:"icon_uri,4" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
||||||
FormatType FormatType `thrift:"format_type,5" form:"format_type" json:"format_type" query:"format_type"`
|
FormatType FormatType `thrift:"format_type,5" form:"format_type" json:"format_type" query:"format_type"`
|
||||||
// 开放给第三方的业务标识, coze 传 0 或者不传
|
// Open to third-party business identity, coze pass 0 or no pass
|
||||||
BizID int64 `thrift:"biz_id,6" form:"biz_id" json:"biz_id,string" query:"biz_id"`
|
BizID int64 `thrift:"biz_id,6" form:"biz_id" json:"biz_id,string" query:"biz_id"`
|
||||||
//新增project ID
|
//project ID
|
||||||
ProjectID int64 `thrift:"project_id,7" form:"project_id" json:"project_id,string" query:"project_id"`
|
ProjectID int64 `thrift:"project_id,7" form:"project_id" json:"project_id,string" query:"project_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -920,7 +920,7 @@ func (p *CreateDatasetResponse) String() string {
|
||||||
|
|
||||||
type DatasetDetailRequest struct {
|
type DatasetDetailRequest struct {
|
||||||
DatasetIDs []string `thrift:"DatasetIDs,1" form:"dataset_ids" json:"dataset_ids"`
|
DatasetIDs []string `thrift:"DatasetIDs,1" form:"dataset_ids" json:"dataset_ids"`
|
||||||
//新增project ID
|
// project ID
|
||||||
ProjectID int64 `thrift:"project_id,3" form:"project_id" json:"project_id,string" query:"project_id"`
|
ProjectID int64 `thrift:"project_id,3" form:"project_id" json:"project_id,string" query:"project_id"`
|
||||||
SpaceID int64 `thrift:"space_id,2" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,2" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -1549,44 +1549,44 @@ func (p *DatasetDetailResponse) String() string {
|
||||||
|
|
||||||
type Dataset struct {
|
type Dataset struct {
|
||||||
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
||||||
// 数据集名称
|
// Dataset name
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
// 文件列表
|
// file list
|
||||||
FileList []string `thrift:"file_list,3" form:"file_list" json:"file_list" query:"file_list"`
|
FileList []string `thrift:"file_list,3" form:"file_list" json:"file_list" query:"file_list"`
|
||||||
// 所有文件大小
|
// All file sizes
|
||||||
AllFileSize int64 `thrift:"all_file_size,4" form:"all_file_size" json:"all_file_size,string" query:"all_file_size"`
|
AllFileSize int64 `thrift:"all_file_size,4" form:"all_file_size" json:"all_file_size,string" query:"all_file_size"`
|
||||||
// 使用Bot数
|
// Bot count
|
||||||
BotUsedCount int32 `thrift:"bot_used_count,5" form:"bot_used_count" json:"bot_used_count" query:"bot_used_count"`
|
BotUsedCount int32 `thrift:"bot_used_count,5" form:"bot_used_count" json:"bot_used_count" query:"bot_used_count"`
|
||||||
Status DatasetStatus `thrift:"status,6" form:"status" json:"status" query:"status"`
|
Status DatasetStatus `thrift:"status,6" form:"status" json:"status" query:"status"`
|
||||||
// 处理中的文件名称列表,兼容老逻辑
|
// List of file names in process, compatible with old logic
|
||||||
ProcessingFileList []string `thrift:"processing_file_list,7" form:"processing_file_list" json:"processing_file_list" query:"processing_file_list"`
|
ProcessingFileList []string `thrift:"processing_file_list,7" form:"processing_file_list" json:"processing_file_list" query:"processing_file_list"`
|
||||||
// 更新时间,秒级时间戳
|
// Update time, second timestamp
|
||||||
UpdateTime int32 `thrift:"update_time,8" form:"update_time" json:"update_time" query:"update_time"`
|
UpdateTime int32 `thrift:"update_time,8" form:"update_time" json:"update_time" query:"update_time"`
|
||||||
IconURL string `thrift:"icon_url,9" form:"icon_url" json:"icon_url" query:"icon_url"`
|
IconURL string `thrift:"icon_url,9" form:"icon_url" json:"icon_url" query:"icon_url"`
|
||||||
Description string `thrift:"description,10" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,10" form:"description" json:"description" query:"description"`
|
||||||
IconURI string `thrift:"icon_uri,11" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
IconURI string `thrift:"icon_uri,11" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
||||||
// 是否可以编辑
|
// Can it be edited?
|
||||||
CanEdit bool `thrift:"can_edit,12" form:"can_edit" json:"can_edit" query:"can_edit"`
|
CanEdit bool `thrift:"can_edit,12" form:"can_edit" json:"can_edit" query:"can_edit"`
|
||||||
// 创建时间,秒级时间戳
|
// create_time, second timestamp
|
||||||
CreateTime int32 `thrift:"create_time,13" form:"create_time" json:"create_time" query:"create_time"`
|
CreateTime int32 `thrift:"create_time,13" form:"create_time" json:"create_time" query:"create_time"`
|
||||||
// 创建者ID
|
// creator ID
|
||||||
CreatorID int64 `thrift:"creator_id,14" form:"creator_id" json:"creator_id,string" query:"creator_id"`
|
CreatorID int64 `thrift:"creator_id,14" form:"creator_id" json:"creator_id,string" query:"creator_id"`
|
||||||
// 空间ID
|
// Space ID
|
||||||
SpaceID int64 `thrift:"space_id,15" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,15" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
// 处理失败的文件
|
// Processing failed files
|
||||||
FailedFileList []string `thrift:"failed_file_list,18" form:"failed_file_list" json:"failed_file_list" query:"failed_file_list"`
|
FailedFileList []string `thrift:"failed_file_list,18" form:"failed_file_list" json:"failed_file_list" query:"failed_file_list"`
|
||||||
FormatType FormatType `thrift:"format_type,19" form:"format_type" json:"format_type" query:"format_type"`
|
FormatType FormatType `thrift:"format_type,19" form:"format_type" json:"format_type" query:"format_type"`
|
||||||
// 分段数量
|
// number of segments
|
||||||
SliceCount int32 `thrift:"slice_count,20" form:"slice_count" json:"slice_count" query:"slice_count"`
|
SliceCount int32 `thrift:"slice_count,20" form:"slice_count" json:"slice_count" query:"slice_count"`
|
||||||
// 命中次数
|
// hit count
|
||||||
HitCount int32 `thrift:"hit_count,21" form:"hit_count" json:"hit_count" query:"hit_count"`
|
HitCount int32 `thrift:"hit_count,21" form:"hit_count" json:"hit_count" query:"hit_count"`
|
||||||
// 文档数量
|
// number of documents
|
||||||
DocCount int32 `thrift:"doc_count,22" form:"doc_count" json:"doc_count" query:"doc_count"`
|
DocCount int32 `thrift:"doc_count,22" form:"doc_count" json:"doc_count" query:"doc_count"`
|
||||||
// 切片规则
|
// slicing rule
|
||||||
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,23" form:"chunk_strategy" json:"chunk_strategy" query:"chunk_strategy"`
|
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,23" form:"chunk_strategy" json:"chunk_strategy" query:"chunk_strategy"`
|
||||||
// 处理中的文件ID列表
|
// List of file IDs in process
|
||||||
ProcessingFileIDList []string `thrift:"processing_file_id_list,24" form:"processing_file_id_list" json:"processing_file_id_list" query:"processing_file_id_list"`
|
ProcessingFileIDList []string `thrift:"processing_file_id_list,24" form:"processing_file_id_list" json:"processing_file_id_list" query:"processing_file_id_list"`
|
||||||
//新增project ID
|
//project ID
|
||||||
ProjectID string `thrift:"project_id,25" form:"project_id" json:"project_id" query:"project_id"`
|
ProjectID string `thrift:"project_id,25" form:"project_id" json:"project_id" query:"project_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2784,17 +2784,17 @@ type ListDatasetRequest struct {
|
||||||
Page *int32 `thrift:"page,3,optional" form:"page" json:"page,omitempty" query:"page"`
|
Page *int32 `thrift:"page,3,optional" form:"page" json:"page,omitempty" query:"page"`
|
||||||
Size *int32 `thrift:"size,4,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int32 `thrift:"size,4,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
SpaceID int64 `thrift:"space_id,5" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,5" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
// 排序字段
|
// sort field
|
||||||
OrderField *OrderField `thrift:"order_field,6,optional" form:"order_field" json:"order_field,omitempty" query:"order_field"`
|
OrderField *OrderField `thrift:"order_field,6,optional" form:"order_field" json:"order_field,omitempty" query:"order_field"`
|
||||||
// 排序规则
|
// order_type
|
||||||
OrderType *OrderType `thrift:"order_type,7,optional" form:"order_type" json:"order_type,omitempty" query:"order_type"`
|
OrderType *OrderType `thrift:"order_type,7,optional" form:"order_type" json:"order_type,omitempty" query:"order_type"`
|
||||||
// 如果传了指定值, 就放开校验
|
// If the specified value is passed, the verification is released
|
||||||
SpaceAuth *string `thrift:"space_auth,8,optional" form:"space_auth" json:"space_auth,omitempty" query:"space_auth"`
|
SpaceAuth *string `thrift:"space_auth,8,optional" form:"space_auth" json:"space_auth,omitempty" query:"space_auth"`
|
||||||
// 开放给第三方的业务标识
|
// Business identity open to third parties
|
||||||
BizID *int64 `thrift:"biz_id,9,optional" form:"biz_id" json:"biz_id,string,omitempty" query:"biz_id"`
|
BizID *int64 `thrift:"biz_id,9,optional" form:"biz_id" json:"biz_id,string,omitempty" query:"biz_id"`
|
||||||
// 是否需要拉取引用bots的数量,会增加响应延时
|
// Whether the number of reference bots needs to be pulled will increase the response delay
|
||||||
NeedRefBots *bool `thrift:"need_ref_bots,10,optional" form:"need_ref_bots" json:"need_ref_bots,omitempty" query:"need_ref_bots"`
|
NeedRefBots *bool `thrift:"need_ref_bots,10,optional" form:"need_ref_bots" json:"need_ref_bots,omitempty" query:"need_ref_bots"`
|
||||||
//新增project ID
|
//project ID
|
||||||
ProjectID *string `thrift:"project_id,11,optional" form:"project_id" json:"project_id,omitempty" query:"project_id"`
|
ProjectID *string `thrift:"project_id,11,optional" form:"project_id" json:"project_id,omitempty" query:"project_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3848,15 +3848,15 @@ func (p *ListDatasetResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DatasetFilter struct {
|
type DatasetFilter struct {
|
||||||
// 如果都设置了,And 关系
|
// The following conditions are related to and
|
||||||
Name *string `thrift:"name,1,optional" form:"name" json:"name,omitempty" query:"name"`
|
Name *string `thrift:"name,1,optional" form:"name" json:"name,omitempty" query:"name"`
|
||||||
// 知识库id列表
|
// Knowledge id list
|
||||||
DatasetIds []string `thrift:"dataset_ids,2,optional" form:"dataset_ids" json:"dataset_ids,omitempty" query:"dataset_ids"`
|
DatasetIds []string `thrift:"dataset_ids,2,optional" form:"dataset_ids" json:"dataset_ids,omitempty" query:"dataset_ids"`
|
||||||
// 来源
|
// source
|
||||||
SourceType *DatasetSource `thrift:"source_type,3,optional" form:"source_type" json:"source_type,omitempty" query:"source_type"`
|
SourceType *DatasetSource `thrift:"source_type,3,optional" form:"source_type" json:"source_type,omitempty" query:"source_type"`
|
||||||
// 搜索类型
|
// search type
|
||||||
ScopeType *DatasetScopeType `thrift:"scope_type,4,optional" form:"scope_type" json:"scope_type,omitempty" query:"scope_type"`
|
ScopeType *DatasetScopeType `thrift:"scope_type,4,optional" form:"scope_type" json:"scope_type,omitempty" query:"scope_type"`
|
||||||
// 类型
|
// type
|
||||||
FormatType *FormatType `thrift:"format_type,5,optional" form:"format_type" json:"format_type,omitempty" query:"format_type"`
|
FormatType *FormatType `thrift:"format_type,5,optional" form:"format_type" json:"format_type,omitempty" query:"format_type"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4694,13 +4694,13 @@ func (p *DeleteDatasetResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UpdateDatasetRequest struct {
|
type UpdateDatasetRequest struct {
|
||||||
// 知识库id
|
// Knowledge ID
|
||||||
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
||||||
// 知识库名称,不能为空
|
// Knowledge base name, cannot be empty
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
// 知识库icon
|
// Knowledge base icon
|
||||||
IconURI string `thrift:"icon_uri,3" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
IconURI string `thrift:"icon_uri,3" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
||||||
// 知识库描述
|
// Knowledge Base Description
|
||||||
Description string `thrift:"description,4" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,4" form:"description" json:"description" query:"description"`
|
||||||
Status *DatasetStatus `thrift:"status,5,optional" form:"status" json:"status,omitempty" query:"status"`
|
Status *DatasetStatus `thrift:"status,5,optional" form:"status" json:"status,omitempty" query:"status"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
|
||||||
|
|
@ -3,28 +3,28 @@
|
||||||
package dataset
|
package dataset
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type ColumnType int64
|
type ColumnType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
ColumnType_Unknown ColumnType = 0
|
ColumnType_Unknown ColumnType = 0
|
||||||
// 文本
|
// Text
|
||||||
ColumnType_Text ColumnType = 1
|
ColumnType_Text ColumnType = 1
|
||||||
// 数字
|
// number
|
||||||
ColumnType_Number ColumnType = 2
|
ColumnType_Number ColumnType = 2
|
||||||
// 时间
|
// time
|
||||||
ColumnType_Date ColumnType = 3
|
ColumnType_Date ColumnType = 3
|
||||||
// float
|
// float
|
||||||
ColumnType_Float ColumnType = 4
|
ColumnType_Float ColumnType = 4
|
||||||
// bool
|
// bool
|
||||||
ColumnType_Boolean ColumnType = 5
|
ColumnType_Boolean ColumnType = 5
|
||||||
// 图片
|
// picture
|
||||||
ColumnType_Image ColumnType = 6
|
ColumnType_Image ColumnType = 6
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -86,11 +86,11 @@ func (p *ColumnType) Value() (driver.Value, error) {
|
||||||
type TableDataType int64
|
type TableDataType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// schema sheets 和 preview data
|
// Schema sheets and preview data
|
||||||
TableDataType_AllData TableDataType = 0
|
TableDataType_AllData TableDataType = 0
|
||||||
// 只需要 schema 结构 & Sheets
|
// Only need schema structure & Sheets
|
||||||
TableDataType_OnlySchema TableDataType = 1
|
TableDataType_OnlySchema TableDataType = 1
|
||||||
// 只需要 preview data
|
// Just preview the data
|
||||||
TableDataType_OnlyPreview TableDataType = 2
|
TableDataType_OnlyPreview TableDataType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -138,7 +138,7 @@ type ListDocumentRequest struct {
|
||||||
DocumentIds []string `thrift:"document_ids,2,optional" form:"document_ids" json:"document_ids,omitempty" query:"document_ids"`
|
DocumentIds []string `thrift:"document_ids,2,optional" form:"document_ids" json:"document_ids,omitempty" query:"document_ids"`
|
||||||
Page *int32 `thrift:"page,3,optional" form:"page" json:"page,omitempty" query:"page"`
|
Page *int32 `thrift:"page,3,optional" form:"page" json:"page,omitempty" query:"page"`
|
||||||
Size *int32 `thrift:"size,4,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int32 `thrift:"size,4,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
// 根据名称搜索
|
// Search by name
|
||||||
Keyword *string `thrift:"keyword,5,optional" form:"keyword" json:"keyword,omitempty" query:"keyword"`
|
Keyword *string `thrift:"keyword,5,optional" form:"keyword" json:"keyword,omitempty" query:"keyword"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -948,55 +948,55 @@ func (p *ListDocumentResponse) String() string {
|
||||||
type DocumentInfo struct {
|
type DocumentInfo struct {
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
DocumentID int64 `thrift:"document_id,2" form:"document_id" json:"document_id,string" query:"document_id"`
|
DocumentID int64 `thrift:"document_id,2" form:"document_id" json:"document_id,string" query:"document_id"`
|
||||||
// 文件链接
|
// file link
|
||||||
TosURI *string `thrift:"tos_uri,3,optional" form:"tos_uri" json:"tos_uri,omitempty" query:"tos_uri"`
|
TosURI *string `thrift:"tos_uri,3,optional" form:"tos_uri" json:"tos_uri,omitempty" query:"tos_uri"`
|
||||||
// 创建时间
|
// create_time
|
||||||
CreateTime int32 `thrift:"create_time,5" form:"create_time" json:"create_time" query:"create_time"`
|
CreateTime int32 `thrift:"create_time,5" form:"create_time" json:"create_time" query:"create_time"`
|
||||||
// 更新时间
|
// update time
|
||||||
UpdateTime int32 `thrift:"update_time,6" form:"update_time" json:"update_time" query:"update_time"`
|
UpdateTime int32 `thrift:"update_time,6" form:"update_time" json:"update_time" query:"update_time"`
|
||||||
// 创建人
|
// creator_id
|
||||||
CreatorID *int64 `thrift:"creator_id,7,optional" form:"creator_id" json:"creator_id,string,omitempty"`
|
CreatorID *int64 `thrift:"creator_id,7,optional" form:"creator_id" json:"creator_id,string,omitempty"`
|
||||||
// 包含分段数量
|
// number of segments included
|
||||||
SliceCount int32 `thrift:"slice_count,8" form:"slice_count" json:"slice_count" query:"slice_count"`
|
SliceCount int32 `thrift:"slice_count,8" form:"slice_count" json:"slice_count" query:"slice_count"`
|
||||||
// 文件后缀 csv, pdf 等
|
// File suffix csv, pdf, etc
|
||||||
Type string `thrift:"type,9" form:"type" json:"type" query:"type"`
|
Type string `thrift:"type,9" form:"type" json:"type" query:"type"`
|
||||||
// 文件大小 字节数
|
// File size, number of bytes
|
||||||
Size int32 `thrift:"size,10" form:"size" json:"size" query:"size"`
|
Size int32 `thrift:"size,10" form:"size" json:"size" query:"size"`
|
||||||
// 字符数
|
// character count
|
||||||
CharCount int32 `thrift:"char_count,11" form:"char_count" json:"char_count" query:"char_count"`
|
CharCount int32 `thrift:"char_count,11" form:"char_count" json:"char_count" query:"char_count"`
|
||||||
// 状态
|
// status
|
||||||
Status DocumentStatus `thrift:"status,12" form:"status" json:"status" query:"status"`
|
Status DocumentStatus `thrift:"status,12" form:"status" json:"status" query:"status"`
|
||||||
// 命中次数
|
// hit count
|
||||||
HitCount int32 `thrift:"hit_count,13" form:"hit_count" json:"hit_count" query:"hit_count"`
|
HitCount int32 `thrift:"hit_count,13" form:"hit_count" json:"hit_count" query:"hit_count"`
|
||||||
// 来源
|
// source
|
||||||
SourceType DocumentSource `thrift:"source_type,14" form:"source_type" json:"source_type" query:"source_type"`
|
SourceType DocumentSource `thrift:"source_type,14" form:"source_type" json:"source_type" query:"source_type"`
|
||||||
// 文件类型
|
// file type
|
||||||
FormatType FormatType `thrift:"format_type,18" form:"format_type" json:"format_type" query:"format_type"`
|
FormatType FormatType `thrift:"format_type,18" form:"format_type" json:"format_type" query:"format_type"`
|
||||||
// 表格类型元数据
|
// Table type metadata
|
||||||
TableMeta []*TableColumn `thrift:"table_meta,19,optional" form:"table_meta" json:"table_meta,omitempty" query:"table_meta"`
|
TableMeta []*TableColumn `thrift:"table_meta,19,optional" form:"table_meta" json:"table_meta,omitempty" query:"table_meta"`
|
||||||
// url 地址
|
// URL address
|
||||||
WebURL *string `thrift:"web_url,20,optional" form:"web_url" json:"web_url,omitempty" query:"web_url"`
|
WebURL *string `thrift:"web_url,20,optional" form:"web_url" json:"web_url,omitempty" query:"web_url"`
|
||||||
// 状态的详细信息;如果切片失败,返回失败信息
|
// Details of the status; if the slice fails, return the failure information
|
||||||
StatusDescript *string `thrift:"status_descript,21,optional" form:"status_descript" json:"status_descript,omitempty" query:"status_descript"`
|
StatusDescript *string `thrift:"status_descript,21,optional" form:"status_descript" json:"status_descript,omitempty" query:"status_descript"`
|
||||||
// 空间id
|
// Space ID
|
||||||
SpaceID *int64 `thrift:"space_id,24,optional" form:"space_id" json:"space_id,string,omitempty" query:"space_id"`
|
SpaceID *int64 `thrift:"space_id,24,optional" form:"space_id" json:"space_id,string,omitempty" query:"space_id"`
|
||||||
// 以下字段仅针对重构后的表格类型有用,用于前端判断
|
// The following fields are only useful for the reconstructed table type and are used for front-end judgment
|
||||||
EditableAppendContent *bool `thrift:"editable_append_content,26,optional" form:"editable_append_content" json:"editable_append_content,omitempty" query:"editable_append_content"`
|
EditableAppendContent *bool `thrift:"editable_append_content,26,optional" form:"editable_append_content" json:"editable_append_content,omitempty" query:"editable_append_content"`
|
||||||
// 切片规则
|
// slicing rule
|
||||||
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,27" form:"chunk_strategy" json:"chunk_strategy" query:"chunk_strategy"`
|
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,27" form:"chunk_strategy" json:"chunk_strategy" query:"chunk_strategy"`
|
||||||
// imagex 存储的文件链接
|
// File links stored by ImageX
|
||||||
ImagexURI *string `thrift:"imagex_uri,28,optional" form:"imagex_uri" json:"imagex_uri,omitempty" query:"imagex_uri"`
|
ImagexURI *string `thrift:"imagex_uri,28,optional" form:"imagex_uri" json:"imagex_uri,omitempty" query:"imagex_uri"`
|
||||||
// 层级分段文档树Json (未使用)
|
// Hierarchical Segmentation Document Tree Json (unused)
|
||||||
DocOutline *string `thrift:"doc_outline,29,optional" form:"doc_outline" json:"doc_outline,omitempty" query:"doc_outline"`
|
DocOutline *string `thrift:"doc_outline,29,optional" form:"doc_outline" json:"doc_outline,omitempty" query:"doc_outline"`
|
||||||
// 解析策略
|
// parsing strategy
|
||||||
ParsingStrategy *ParsingStrategy `thrift:"parsing_strategy,30,optional" form:"parsing_strategy" json:"parsing_strategy,omitempty" query:"parsing_strategy"`
|
ParsingStrategy *ParsingStrategy `thrift:"parsing_strategy,30,optional" form:"parsing_strategy" json:"parsing_strategy,omitempty" query:"parsing_strategy"`
|
||||||
// 过滤策略
|
// filtering strategy
|
||||||
FilterStrategy *FilterStrategy `thrift:"filter_strategy,32,optional" form:"filter_strategy" json:"filter_strategy,omitempty" query:"filter_strategy"`
|
FilterStrategy *FilterStrategy `thrift:"filter_strategy,32,optional" form:"filter_strategy" json:"filter_strategy,omitempty" query:"filter_strategy"`
|
||||||
// 层级分段文档树 tos_url
|
// Hierarchical segmented document tree tos_url
|
||||||
DocTreeTosURL *string `thrift:"doc_tree_tos_url,33,optional" form:"doc_tree_tos_url" json:"doc_tree_tos_url,omitempty" query:"doc_tree_tos_url"`
|
DocTreeTosURL *string `thrift:"doc_tree_tos_url,33,optional" form:"doc_tree_tos_url" json:"doc_tree_tos_url,omitempty" query:"doc_tree_tos_url"`
|
||||||
// 预览用的原文档 tos_url
|
// Preview the original document tos_url
|
||||||
PreviewTosURL *string `thrift:"preview_tos_url,34,optional" form:"preview_tos_url" json:"preview_tos_url,omitempty" query:"preview_tos_url"`
|
PreviewTosURL *string `thrift:"preview_tos_url,34,optional" form:"preview_tos_url" json:"preview_tos_url,omitempty" query:"preview_tos_url"`
|
||||||
// 预览用的原文档 tos_url
|
// Preview the original document tos_url
|
||||||
ReviewID *int64 `thrift:"review_id,35,optional" form:"review_id" json:"review_id,omitempty" query:"review_id"`
|
ReviewID *int64 `thrift:"review_id,35,optional" form:"review_id" json:"review_id,omitempty" query:"review_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2454,18 +2454,18 @@ func (p *DocumentInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type TableColumn struct {
|
type TableColumn struct {
|
||||||
// 列 id
|
// Column ID
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id,string"`
|
ID int64 `thrift:"id,1" form:"id" json:"id,string"`
|
||||||
// 列名
|
// column_name
|
||||||
ColumnName string `thrift:"column_name,2" form:"column_name" json:"column_name" query:"column_name"`
|
ColumnName string `thrift:"column_name,2" form:"column_name" json:"column_name" query:"column_name"`
|
||||||
// 是否为语义匹配列
|
// Is it a semantically matched column?
|
||||||
IsSemantic bool `thrift:"is_semantic,3" form:"is_semantic" json:"is_semantic" query:"is_semantic"`
|
IsSemantic bool `thrift:"is_semantic,3" form:"is_semantic" json:"is_semantic" query:"is_semantic"`
|
||||||
// 列原本在 excel 的序号
|
// List the serial number originally in excel
|
||||||
Sequence int64 `thrift:"sequence,4" form:"sequence" json:"sequence,string"`
|
Sequence int64 `thrift:"sequence,4" form:"sequence" json:"sequence,string"`
|
||||||
// 列类型
|
// column type
|
||||||
ColumnType *ColumnType `thrift:"column_type,5,optional" form:"column_type" json:"column_type,omitempty" query:"column_type"`
|
ColumnType *ColumnType `thrift:"column_type,5,optional" form:"column_type" json:"column_type,omitempty" query:"column_type"`
|
||||||
ContainsEmptyValue *bool `thrift:"contains_empty_value,6,optional" form:"contains_empty_value" json:"contains_empty_value,omitempty" query:"contains_empty_value"`
|
ContainsEmptyValue *bool `thrift:"contains_empty_value,6,optional" form:"contains_empty_value" json:"contains_empty_value,omitempty" query:"contains_empty_value"`
|
||||||
// 描述
|
// describe
|
||||||
Desc *string `thrift:"desc,7,optional" form:"desc" json:"desc,omitempty" query:"desc"`
|
Desc *string `thrift:"desc,7,optional" form:"desc" json:"desc,omitempty" query:"desc"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2903,7 +2903,7 @@ func (p *TableColumn) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DeleteDocumentRequest struct {
|
type DeleteDocumentRequest struct {
|
||||||
// 要删除的文档ID列表
|
// List of document IDs to delete
|
||||||
DocumentIds []string `thrift:"document_ids,2" form:"document_ids" json:"document_ids" query:"document_ids"`
|
DocumentIds []string `thrift:"document_ids,2" form:"document_ids" json:"document_ids" query:"document_ids"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3374,9 +3374,9 @@ func (p *DeleteDocumentResponse) String() string {
|
||||||
|
|
||||||
type UpdateDocumentRequest struct {
|
type UpdateDocumentRequest struct {
|
||||||
DocumentID int64 `thrift:"document_id,1" form:"document_id" json:"document_id,string" query:"document_id"`
|
DocumentID int64 `thrift:"document_id,1" form:"document_id" json:"document_id,string" query:"document_id"`
|
||||||
// 需要更新就传, 更新名称
|
// If you need to update, please upload it and update the name.
|
||||||
DocumentName *string `thrift:"document_name,3,optional" form:"document_name" json:"document_name,omitempty" query:"document_name"`
|
DocumentName *string `thrift:"document_name,3,optional" form:"document_name" json:"document_name,omitempty" query:"document_name"`
|
||||||
// 更新表结构
|
// Update table structure
|
||||||
TableMeta []*TableColumn `thrift:"table_meta,5,optional" form:"table_meta" json:"table_meta,omitempty" query:"table_meta"`
|
TableMeta []*TableColumn `thrift:"table_meta,5,optional" form:"table_meta" json:"table_meta,omitempty" query:"table_meta"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3951,9 +3951,9 @@ func (p *UpdateDocumentResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UpdatePhotoCaptionRequest struct {
|
type UpdatePhotoCaptionRequest struct {
|
||||||
// 文档ID
|
// Document ID
|
||||||
DocumentID int64 `thrift:"document_id,1,required" form:"document_id,required" json:"document_id,string,required" query:"document_id,required"`
|
DocumentID int64 `thrift:"document_id,1,required" form:"document_id,required" json:"document_id,string,required" query:"document_id,required"`
|
||||||
// 要更新的图片描述信息
|
// Picture description information to be updated
|
||||||
Caption string `thrift:"caption,2,required" form:"caption,required" json:"caption,required" query:"caption,required"`
|
Caption string `thrift:"caption,2,required" form:"caption,required" json:"caption,required" query:"caption,required"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -4462,11 +4462,11 @@ func (p *UpdatePhotoCaptionResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ListPhotoRequest struct {
|
type ListPhotoRequest struct {
|
||||||
// 知识库ID
|
// Knowledge ID
|
||||||
DatasetID int64 `thrift:"dataset_id,1,required" form:"dataset_id,required" json:"dataset_id,string,required" query:"dataset_id,required"`
|
DatasetID int64 `thrift:"dataset_id,1,required" form:"dataset_id,required" json:"dataset_id,string,required" query:"dataset_id,required"`
|
||||||
// 页数,从 1 开始
|
// Number of pages, starting from 1
|
||||||
Page *int32 `thrift:"page,2,optional" form:"page" json:"page,omitempty" query:"page"`
|
Page *int32 `thrift:"page,2,optional" form:"page" json:"page,omitempty" query:"page"`
|
||||||
// 每页大小
|
// page size
|
||||||
Size *int32 `thrift:"size,3,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int32 `thrift:"size,3,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
Filter *PhotoFilter `thrift:"filter,4,optional" form:"filter" json:"filter,omitempty" query:"filter"`
|
Filter *PhotoFilter `thrift:"filter,4,optional" form:"filter" json:"filter,omitempty" query:"filter"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -4830,11 +4830,11 @@ func (p *ListPhotoRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PhotoFilter struct {
|
type PhotoFilter struct {
|
||||||
// true 筛选 “已标注” 的图片,false 筛选 “未标注” 的图片
|
// True to filter "marked" images, false to filter "unmarked" images
|
||||||
HasCaption *bool `thrift:"has_caption,1,optional" form:"has_caption" json:"has_caption,omitempty" query:"has_caption"`
|
HasCaption *bool `thrift:"has_caption,1,optional" form:"has_caption" json:"has_caption,omitempty" query:"has_caption"`
|
||||||
// 搜索关键字,对图片名称和图片描述进行搜索
|
// Search keywords, search for image names and picture descriptions
|
||||||
Keyword *string `thrift:"keyword,2,optional" form:"keyword" json:"keyword,omitempty" query:"keyword"`
|
Keyword *string `thrift:"keyword,2,optional" form:"keyword" json:"keyword,omitempty" query:"keyword"`
|
||||||
// 状态
|
// status
|
||||||
Status *DocumentStatus `thrift:"status,3,optional" form:"status" json:"status,omitempty" query:"status"`
|
Status *DocumentStatus `thrift:"status,3,optional" form:"status" json:"status,omitempty" query:"status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5463,27 +5463,27 @@ func (p *ListPhotoResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PhotoInfo struct {
|
type PhotoInfo struct {
|
||||||
// 图片型知识库一个图片对应一个文档
|
// Picture Knowledge Base One picture corresponds to one document
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
// 文档ID
|
// Document ID
|
||||||
DocumentID int64 `thrift:"document_id,2" form:"document_id" json:"document_id,string" query:"document_id"`
|
DocumentID int64 `thrift:"document_id,2" form:"document_id" json:"document_id,string" query:"document_id"`
|
||||||
// 图片链接
|
// image link
|
||||||
URL string `thrift:"url,3" form:"url" json:"url" query:"url"`
|
URL string `thrift:"url,3" form:"url" json:"url" query:"url"`
|
||||||
// 图片描述信息
|
// picture description information
|
||||||
Caption string `thrift:"caption,4" form:"caption" json:"caption" query:"caption"`
|
Caption string `thrift:"caption,4" form:"caption" json:"caption" query:"caption"`
|
||||||
// 创建时间
|
// create_time
|
||||||
CreateTime int32 `thrift:"create_time,5" form:"create_time" json:"create_time" query:"create_time"`
|
CreateTime int32 `thrift:"create_time,5" form:"create_time" json:"create_time" query:"create_time"`
|
||||||
// 更新时间
|
// update time
|
||||||
UpdateTime int32 `thrift:"update_time,6" form:"update_time" json:"update_time" query:"update_time"`
|
UpdateTime int32 `thrift:"update_time,6" form:"update_time" json:"update_time" query:"update_time"`
|
||||||
// 创建人
|
// creator_id
|
||||||
CreatorID int64 `thrift:"creator_id,7" form:"creator_id" json:"creator_id,string"`
|
CreatorID int64 `thrift:"creator_id,7" form:"creator_id" json:"creator_id,string"`
|
||||||
// 图片后缀 jpg, png 等
|
// Image suffix jpg, png, etc
|
||||||
Type string `thrift:"type,8" form:"type" json:"type" query:"type"`
|
Type string `thrift:"type,8" form:"type" json:"type" query:"type"`
|
||||||
// 图片大小
|
// image size
|
||||||
Size int32 `thrift:"size,9" form:"size" json:"size" query:"size"`
|
Size int32 `thrift:"size,9" form:"size" json:"size" query:"size"`
|
||||||
// 状态
|
// status
|
||||||
Status DocumentStatus `thrift:"status,10" form:"status" json:"status" query:"status"`
|
Status DocumentStatus `thrift:"status,10" form:"status" json:"status" query:"status"`
|
||||||
// 来源
|
// source
|
||||||
SourceType DocumentSource `thrift:"source_type,11" form:"source_type" json:"source_type" query:"source_type"`
|
SourceType DocumentSource `thrift:"source_type,11" form:"source_type" json:"source_type" query:"source_type"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -6063,9 +6063,9 @@ func (p *PhotoInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PhotoDetailRequest struct {
|
type PhotoDetailRequest struct {
|
||||||
// 文档ID列表
|
// Document ID List
|
||||||
DocumentIds []string `thrift:"document_ids,1,required" form:"document_ids,required" json:"document_ids,required" query:"document_ids,required"`
|
DocumentIds []string `thrift:"document_ids,1,required" form:"document_ids,required" json:"document_ids,required" query:"document_ids,required"`
|
||||||
// 知识库ID
|
// Knowledge ID
|
||||||
DatasetID int64 `thrift:"dataset_id,2,required" form:"dataset_id,required" json:"dataset_id,string,required" query:"dataset_id,required"`
|
DatasetID int64 `thrift:"dataset_id,2,required" form:"dataset_id,required" json:"dataset_id,string,required" query:"dataset_id,required"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -6337,7 +6337,7 @@ func (p *PhotoDetailRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PhotoDetailResponse struct {
|
type PhotoDetailResponse struct {
|
||||||
// 文档ID到图片信息的映射
|
// Mapping document ID to image information
|
||||||
PhotoInfos map[string]*PhotoInfo `thrift:"photo_infos,1" form:"photo_infos" json:"photo_infos" query:"photo_infos"`
|
PhotoInfos map[string]*PhotoInfo `thrift:"photo_infos,1" form:"photo_infos" json:"photo_infos" query:"photo_infos"`
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
|
|
@ -6669,15 +6669,15 @@ func (p *PhotoDetailResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResegmentRequest struct {
|
type ResegmentRequest struct {
|
||||||
// 知识库ID
|
// Knowledge ID
|
||||||
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
||||||
// 要重新分段的文档
|
// Document to be re-segmented
|
||||||
DocumentIds []string `thrift:"document_ids,2" form:"document_ids" json:"document_ids" query:"document_ids"`
|
DocumentIds []string `thrift:"document_ids,2" form:"document_ids" json:"document_ids" query:"document_ids"`
|
||||||
// 分段策略
|
// segmentation strategy
|
||||||
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,3" form:"chunk_strategy" json:"chunk_strategy" query:"chunk_strategy"`
|
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,3" form:"chunk_strategy" json:"chunk_strategy" query:"chunk_strategy"`
|
||||||
// 解析策略
|
// parsing strategy
|
||||||
ParsingStrategy *ParsingStrategy `thrift:"parsing_strategy,5,optional" form:"parsing_strategy" json:"parsing_strategy,omitempty" query:"parsing_strategy"`
|
ParsingStrategy *ParsingStrategy `thrift:"parsing_strategy,5,optional" form:"parsing_strategy" json:"parsing_strategy,omitempty" query:"parsing_strategy"`
|
||||||
// 过滤策略
|
// filtering strategy
|
||||||
FilterStrategy *FilterStrategy `thrift:"filter_strategy,7,optional" form:"filter_strategy" json:"filter_strategy,omitempty" query:"filter_strategy"`
|
FilterStrategy *FilterStrategy `thrift:"filter_strategy,7,optional" form:"filter_strategy" json:"filter_strategy,omitempty" query:"filter_strategy"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -7088,7 +7088,7 @@ func (p *ResegmentRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResegmentResponse struct {
|
type ResegmentResponse struct {
|
||||||
// 老版需要. 仅返回id 和名称即可
|
// The old version requires. Just return the id and name.
|
||||||
DocumentInfos []*DocumentInfo `thrift:"document_infos,1" form:"document_infos" json:"document_infos" query:"document_infos"`
|
DocumentInfos []*DocumentInfo `thrift:"document_infos,1" form:"document_infos" json:"document_infos" query:"document_infos"`
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
|
|
@ -7406,17 +7406,17 @@ func (p *ResegmentResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type CreateDocumentRequest struct {
|
type CreateDocumentRequest struct {
|
||||||
// 要插入文档的知识库id
|
// The knowledge base id of the document to insert.
|
||||||
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
DatasetID int64 `thrift:"dataset_id,1" form:"dataset_id" json:"dataset_id,string" query:"dataset_id"`
|
||||||
// 知识库的类型,目前支持文本、表格、图片三种知识库
|
// Types of knowledge bases, currently supporting text, tables, and images
|
||||||
FormatType FormatType `thrift:"format_type,4" form:"format_type" json:"format_type" query:"format_type"`
|
FormatType FormatType `thrift:"format_type,4" form:"format_type" json:"format_type" query:"format_type"`
|
||||||
// 表格类型一次只能创建一个
|
// Only one table type can be created at a time
|
||||||
DocumentBases []*DocumentBase `thrift:"document_bases,6" form:"document_bases" json:"document_bases" query:"document_bases"`
|
DocumentBases []*DocumentBase `thrift:"document_bases,6" form:"document_bases" json:"document_bases" query:"document_bases"`
|
||||||
// 只在知识库中没有文档时需要传递,已有则从知识库获取.切片规则,为空则自动按段落切片
|
// Only when there is no document in the knowledge base, it needs to be passed, and if there is one, it will be obtained from the knowledge base. Slicing rules, if it is empty, it will be automatically sliced by paragraph
|
||||||
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,17,optional" form:"chunk_strategy" json:"chunk_strategy,omitempty" query:"chunk_strategy"`
|
ChunkStrategy *ChunkStrategy `thrift:"chunk_strategy,17,optional" form:"chunk_strategy" json:"chunk_strategy,omitempty" query:"chunk_strategy"`
|
||||||
// 为 true 时向已有的 document 追加内容。text 类型不能使用
|
// Appends content to an existing document when true. The text type cannot be used
|
||||||
IsAppend *bool `thrift:"is_append,31,optional" form:"is_append" json:"is_append,omitempty" query:"is_append"`
|
IsAppend *bool `thrift:"is_append,31,optional" form:"is_append" json:"is_append,omitempty" query:"is_append"`
|
||||||
// 解析策略
|
// parsing strategy
|
||||||
ParsingStrategy *ParsingStrategy `thrift:"parsing_strategy,32,optional" form:"parsing_strategy" json:"parsing_strategy,omitempty" query:"parsing_strategy"`
|
ParsingStrategy *ParsingStrategy `thrift:"parsing_strategy,32,optional" form:"parsing_strategy" json:"parsing_strategy,omitempty" query:"parsing_strategy"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -8197,18 +8197,18 @@ func (p *CreateDocumentResponse) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 用于创建文档的基本信息
|
// Basic information for creating a document
|
||||||
type DocumentBase struct {
|
type DocumentBase struct {
|
||||||
// 文档名称
|
// Document name
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
SourceInfo *SourceInfo `thrift:"source_info,2" form:"source_info" json:"source_info" query:"source_info"`
|
SourceInfo *SourceInfo `thrift:"source_info,2" form:"source_info" json:"source_info" query:"source_info"`
|
||||||
// 以下参数表格类型需要传递
|
// The following parameter table types need to be passed
|
||||||
TableMeta []*TableColumn `thrift:"table_meta,4,optional" form:"table_meta" json:"table_meta,omitempty" query:"table_meta"`
|
TableMeta []*TableColumn `thrift:"table_meta,4,optional" form:"table_meta" json:"table_meta,omitempty" query:"table_meta"`
|
||||||
// 表格解析信息
|
// Table parsing information
|
||||||
TableSheet *TableSheet `thrift:"table_sheet,5,optional" form:"table_sheet" json:"table_sheet,omitempty" query:"table_sheet"`
|
TableSheet *TableSheet `thrift:"table_sheet,5,optional" form:"table_sheet" json:"table_sheet,omitempty" query:"table_sheet"`
|
||||||
// 过滤策略
|
// filtering strategy
|
||||||
FilterStrategy *FilterStrategy `thrift:"filter_strategy,6,optional" form:"filter_strategy" json:"filter_strategy,omitempty" query:"filter_strategy"`
|
FilterStrategy *FilterStrategy `thrift:"filter_strategy,6,optional" form:"filter_strategy" json:"filter_strategy,omitempty" query:"filter_strategy"`
|
||||||
// 图片类型知识库,人工标注时的图片描述
|
// Image type knowledge base, picture description when manually annotated
|
||||||
Caption *string `thrift:"caption,7,optional" form:"caption" json:"caption,omitempty" query:"caption"`
|
Caption *string `thrift:"caption,7,optional" form:"caption" json:"caption,omitempty" query:"caption"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8631,18 +8631,18 @@ func (p *DocumentBase) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 支持多种数据源
|
// Supports multiple data sources
|
||||||
type SourceInfo struct {
|
type SourceInfo struct {
|
||||||
// 本地上传返回的 uri
|
// Upload the returned URI locally.
|
||||||
TosURI *string `thrift:"tos_uri,1,optional" form:"tos_uri" json:"tos_uri,omitempty"`
|
TosURI *string `thrift:"tos_uri,1,optional" form:"tos_uri" json:"tos_uri,omitempty"`
|
||||||
DocumentSource *DocumentSource `thrift:"document_source,4,optional" form:"document_source" json:"document_source,omitempty"`
|
DocumentSource *DocumentSource `thrift:"document_source,4,optional" form:"document_source" json:"document_source,omitempty"`
|
||||||
// document_source 自定义原始内容: 表格型知识库需要符合的格式:json list<map<string, string>>
|
// document_source custom raw content: Format required for a tabular knowledge base: json list < map < string, string > >
|
||||||
CustomContent *string `thrift:"custom_content,5,optional" form:"custom_content" json:"custom_content,omitempty"`
|
CustomContent *string `thrift:"custom_content,5,optional" form:"custom_content" json:"custom_content,omitempty"`
|
||||||
// document_source 本地: 如果不传 tos 地址, 则需要传文件 base64, 类型
|
// document_source local: If you don't send the tos address, you need to send the file base64, type
|
||||||
FileBase64 *string `thrift:"file_base64,7,optional" form:"file_base64" json:"file_base64,omitempty" query:"file_base64"`
|
FileBase64 *string `thrift:"file_base64,7,optional" form:"file_base64" json:"file_base64,omitempty" query:"file_base64"`
|
||||||
// 文件类型, 比如 pdf
|
// File type, such as PDF
|
||||||
FileType *string `thrift:"file_type,8,optional" form:"file_type" json:"file_type,omitempty" query:"file_type"`
|
FileType *string `thrift:"file_type,8,optional" form:"file_type" json:"file_type,omitempty" query:"file_type"`
|
||||||
// imagex_uri, 和 tos_uri 二选一, imagex_uri 优先,需要通过 imagex 的方法获取数据和签发 url
|
// imagex_uri, and tos_uri choose one, imagex_uri priority, need to get data and sign url through imagex method
|
||||||
ImagexURI *string `thrift:"imagex_uri,10,optional" form:"imagex_uri" json:"imagex_uri,omitempty" query:"imagex_uri"`
|
ImagexURI *string `thrift:"imagex_uri,10,optional" form:"imagex_uri" json:"imagex_uri,omitempty" query:"imagex_uri"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -9069,11 +9069,11 @@ func (p *SourceInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type TableSheet struct {
|
type TableSheet struct {
|
||||||
// 用户选择的 sheet id
|
// User selected sheet id
|
||||||
SheetID int64 `thrift:"sheet_id,1" form:"sheet_id" json:"sheet_id,string"`
|
SheetID int64 `thrift:"sheet_id,1" form:"sheet_id" json:"sheet_id,string"`
|
||||||
// 用户选择的表头行数,从 0 开始编号
|
// The number of header rows selected by the user, numbered from 0
|
||||||
HeaderLineIdx int64 `thrift:"header_line_idx,2" form:"header_line_idx" json:"header_line_idx,string"`
|
HeaderLineIdx int64 `thrift:"header_line_idx,2" form:"header_line_idx" json:"header_line_idx,string"`
|
||||||
// 用户选择的起始行号,从 0 开始编号
|
// User-selected starting line number, numbered from 0
|
||||||
StartLineIdx int64 `thrift:"start_line_idx,3" form:"start_line_idx" json:"start_line_idx,string"`
|
StartLineIdx int64 `thrift:"start_line_idx,3" form:"start_line_idx" json:"start_line_idx,string"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -9831,13 +9831,13 @@ func (p *GetDocumentProgressResponse) String() string {
|
||||||
|
|
||||||
type DocumentProgress struct {
|
type DocumentProgress struct {
|
||||||
DocumentID int64 `thrift:"document_id,1" form:"document_id" json:"document_id,string" query:"document_id"`
|
DocumentID int64 `thrift:"document_id,1" form:"document_id" json:"document_id,string" query:"document_id"`
|
||||||
// 知识库进度百分比
|
// Knowledge Base Progress Percentage
|
||||||
Progress int32 `thrift:"progress,2" form:"progress" json:"progress" query:"progress"`
|
Progress int32 `thrift:"progress,2" form:"progress" json:"progress" query:"progress"`
|
||||||
Status DocumentStatus `thrift:"status,3" form:"status" json:"status" query:"status"`
|
Status DocumentStatus `thrift:"status,3" form:"status" json:"status" query:"status"`
|
||||||
// 状态的详细描述;如果切片失败,返回失败信息
|
// A detailed description of the status; if the slice fails, a failure message is returned
|
||||||
StatusDescript *string `thrift:"status_descript,4,optional" form:"status_descript" json:"status_descript,omitempty" query:"status_descript"`
|
StatusDescript *string `thrift:"status_descript,4,optional" form:"status_descript" json:"status_descript,omitempty" query:"status_descript"`
|
||||||
DocumentName string `thrift:"document_name,5" form:"document_name" json:"document_name" query:"document_name"`
|
DocumentName string `thrift:"document_name,5" form:"document_name" json:"document_name" query:"document_name"`
|
||||||
// 剩余时间单位秒
|
// Remaining time in seconds
|
||||||
RemainingTime *int64 `thrift:"remaining_time,6,optional" form:"remaining_time" json:"remaining_time,omitempty" query:"remaining_time"`
|
RemainingTime *int64 `thrift:"remaining_time,6,optional" form:"remaining_time" json:"remaining_time,omitempty" query:"remaining_time"`
|
||||||
Size *int64 `thrift:"size,7,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int64 `thrift:"size,7,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
Type *string `thrift:"type,8,optional" form:"type" json:"type,omitempty" query:"type"`
|
Type *string `thrift:"type,8,optional" form:"type" json:"type,omitempty" query:"type"`
|
||||||
|
|
@ -10386,19 +10386,19 @@ func (p *DocumentProgress) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取 database 上传的表格文件元信息
|
// Get the table file meta information uploaded by the database
|
||||||
type GetTableSchemaRequest struct {
|
type GetTableSchemaRequest struct {
|
||||||
// 表格解析信息, 默认初始值0,0,1,表示第1个表格,表头行为第1行,数据行从第2行开始
|
// Table parsing information, the default initial value is 0, 0, 1, which represents the first table, the first row of the table header, and the data row starts from the second row
|
||||||
TableSheet *TableSheet `thrift:"table_sheet,1,optional" form:"table_sheet" json:"table_sheet,omitempty" query:"table_sheet"`
|
TableSheet *TableSheet `thrift:"table_sheet,1,optional" form:"table_sheet" json:"table_sheet,omitempty" query:"table_sheet"`
|
||||||
// 不传默认返回所有数据
|
// All data is returned by default without passing it on.
|
||||||
TableDataType *TableDataType `thrift:"table_data_type,2,optional" form:"table_data_type" json:"table_data_type,omitempty" query:"table_data_type"`
|
TableDataType *TableDataType `thrift:"table_data_type,2,optional" form:"table_data_type" json:"table_data_type,omitempty" query:"table_data_type"`
|
||||||
// 兼容重构前的版本:如果需要拉取的是当前 document 的 schema 时传递该值
|
// Compatible with pre-refactoring versions: pass this value if you need to pull the schema of the current document
|
||||||
DocumentID *int64 `thrift:"document_id,3,optional" form:"document_id" json:"document_id,string,omitempty"`
|
DocumentID *int64 `thrift:"document_id,3,optional" form:"document_id" json:"document_id,string,omitempty"`
|
||||||
// source file 的信息,新增 segment / 之前逻辑迁移到这里
|
// Source file information, add segment/before logic migrate here
|
||||||
SourceFile *SourceInfo `thrift:"source_file,4,optional" form:"source_file" json:"source_file,omitempty" query:"source_file"`
|
SourceFile *SourceInfo `thrift:"source_file,4,optional" form:"source_file" json:"source_file,omitempty" query:"source_file"`
|
||||||
// 表格预览前端需要传递原始的数据表结构
|
// The table preview front end needs to pass the original data table structure
|
||||||
OriginTableMeta []*TableColumn `thrift:"origin_table_meta,5,optional" form:"origin_table_meta" json:"origin_table_meta,omitempty" query:"origin_table_meta"`
|
OriginTableMeta []*TableColumn `thrift:"origin_table_meta,5,optional" form:"origin_table_meta" json:"origin_table_meta,omitempty" query:"origin_table_meta"`
|
||||||
// 表格预览前端需要传递用户编辑之后的数据表结构
|
// The table preview front end needs to pass the data table structure edited by the user
|
||||||
PreviewTableMeta []*TableColumn `thrift:"preview_table_meta,6,optional" form:"preview_table_meta" json:"preview_table_meta,omitempty" query:"preview_table_meta"`
|
PreviewTableMeta []*TableColumn `thrift:"preview_table_meta,6,optional" form:"preview_table_meta" json:"preview_table_meta,omitempty" query:"preview_table_meta"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -10912,11 +10912,11 @@ func (p *GetTableSchemaRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DocTableSheet struct {
|
type DocTableSheet struct {
|
||||||
// sheet 的编号
|
// Number of sheet
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id" query:"id"`
|
ID int64 `thrift:"id,1" form:"id" json:"id" query:"id"`
|
||||||
// sheet 名
|
// Sheet name
|
||||||
SheetName string `thrift:"sheet_name,2" form:"sheet_name" json:"sheet_name" query:"sheet_name"`
|
SheetName string `thrift:"sheet_name,2" form:"sheet_name" json:"sheet_name" query:"sheet_name"`
|
||||||
// 总行数
|
// total number of rows
|
||||||
TotalRow int64 `thrift:"total_row,3" form:"total_row" json:"total_row" query:"total_row"`
|
TotalRow int64 `thrift:"total_row,3" form:"total_row" json:"total_row" query:"total_row"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -11147,9 +11147,9 @@ type GetTableSchemaResponse struct {
|
||||||
Code int32 `thrift:"code,1,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int32 `thrift:"code,1,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,2,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,2,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
SheetList []*DocTableSheet `thrift:"sheet_list,3" form:"sheet_list" json:"sheet_list" query:"sheet_list"`
|
SheetList []*DocTableSheet `thrift:"sheet_list,3" form:"sheet_list" json:"sheet_list" query:"sheet_list"`
|
||||||
// 选中的 sheet 的 schema, 不选择默认返回第一个 sheet
|
// The schema of the selected sheet, not selected to return the first sheet by default
|
||||||
TableMeta []*TableColumn `thrift:"table_meta,4" form:"table_meta" json:"table_meta" query:"table_meta"`
|
TableMeta []*TableColumn `thrift:"table_meta,4" form:"table_meta" json:"table_meta" query:"table_meta"`
|
||||||
// knowledge table 场景中会返回
|
// The knowledge table will return
|
||||||
PreviewData []map[string]string `thrift:"preview_data,5" form:"preview_data" json:"preview_data"`
|
PreviewData []map[string]string `thrift:"preview_data,5" form:"preview_data" json:"preview_data"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"-" json:"-" query:"-"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
@ -11621,15 +11621,15 @@ func (p *GetTableSchemaResponse) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 判断用户配置的 schema 是否和对应 document id 的一致
|
// Determine whether the schema configured by the user is consistent with the corresponding document id
|
||||||
type ValidateTableSchemaRequest struct {
|
type ValidateTableSchemaRequest struct {
|
||||||
// 空间ID
|
// Space ID
|
||||||
SpaceID int64 `thrift:"space_id,1" form:"space_id" json:"space_id,string"`
|
SpaceID int64 `thrift:"space_id,1" form:"space_id" json:"space_id,string"`
|
||||||
// 要校验的文档ID
|
// Document ID to verify
|
||||||
DocumentID int64 `thrift:"document_id,2" form:"document_id" json:"document_id,string"`
|
DocumentID int64 `thrift:"document_id,2" form:"document_id" json:"document_id,string"`
|
||||||
// source file 的信息
|
// Information from the source file
|
||||||
SourceInfo *SourceInfo `thrift:"source_info,3" form:"source_file" json:"source_file"`
|
SourceInfo *SourceInfo `thrift:"source_info,3" form:"source_file" json:"source_file"`
|
||||||
// 表格解析信息, 默认初始值0,0,1,表示第1个表格,表头行为第1行,数据行从第2行开始
|
// Table parsing information, the default initial value is 0, 0, 1, which represents the first table, the first row of the table header, and the data row starts from the second row
|
||||||
TableSheet *TableSheet `thrift:"table_sheet,4" form:"table_sheet" json:"table_sheet"`
|
TableSheet *TableSheet `thrift:"table_sheet,4" form:"table_sheet" json:"table_sheet"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -11967,7 +11967,7 @@ func (p *ValidateTableSchemaRequest) String() string {
|
||||||
|
|
||||||
type ValidateTableSchemaResponse struct {
|
type ValidateTableSchemaResponse struct {
|
||||||
ColumnValidResult map[string]string `thrift:"ColumnValidResult,1,optional" form:"column_valid_result" json:"column_valid_result,omitempty"`
|
ColumnValidResult map[string]string `thrift:"ColumnValidResult,1,optional" form:"column_valid_result" json:"column_valid_result,omitempty"`
|
||||||
// 如果失败会返回错误码
|
// If it fails, an error code will be returned.
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"-" json:"-" query:"-"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"-" json:"-" query:"-"`
|
||||||
|
|
@ -12504,7 +12504,7 @@ func (p *ExtractPhotoCaptionRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ExtractPhotoCaptionResponse struct {
|
type ExtractPhotoCaptionResponse struct {
|
||||||
// 图片描述
|
// picture description
|
||||||
Caption string `thrift:"caption,1" form:"caption" json:"caption" query:"caption"`
|
Caption string `thrift:"caption,1" form:"caption" json:"caption" query:"caption"`
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
type DatasetService interface {
|
type DatasetService interface {
|
||||||
// 知识库相关
|
// Knowledge base related
|
||||||
GetIconForDataset(ctx context.Context, req *GetIconRequest) (r *GetIconResponse, err error)
|
GetIconForDataset(ctx context.Context, req *GetIconRequest) (r *GetIconResponse, err error)
|
||||||
|
|
||||||
CreateDataset(ctx context.Context, req *CreateDatasetRequest) (r *CreateDatasetResponse, err error)
|
CreateDataset(ctx context.Context, req *CreateDatasetRequest) (r *CreateDatasetResponse, err error)
|
||||||
|
|
@ -21,7 +21,7 @@ type DatasetService interface {
|
||||||
DeleteDataset(ctx context.Context, req *DeleteDatasetRequest) (r *DeleteDatasetResponse, err error)
|
DeleteDataset(ctx context.Context, req *DeleteDatasetRequest) (r *DeleteDatasetResponse, err error)
|
||||||
|
|
||||||
UpdateDataset(ctx context.Context, req *UpdateDatasetRequest) (r *UpdateDatasetResponse, err error)
|
UpdateDataset(ctx context.Context, req *UpdateDatasetRequest) (r *UpdateDatasetResponse, err error)
|
||||||
// Document相关
|
// Document related
|
||||||
CreateDocument(ctx context.Context, req *CreateDocumentRequest) (r *CreateDocumentResponse, err error)
|
CreateDocument(ctx context.Context, req *CreateDocumentRequest) (r *CreateDocumentResponse, err error)
|
||||||
|
|
||||||
ListDocument(ctx context.Context, req *ListDocumentRequest) (r *ListDocumentResponse, err error)
|
ListDocument(ctx context.Context, req *ListDocumentRequest) (r *ListDocumentResponse, err error)
|
||||||
|
|
@ -45,7 +45,7 @@ type DatasetService interface {
|
||||||
GetTableSchema(ctx context.Context, req *GetTableSchemaRequest) (r *GetTableSchemaResponse, err error)
|
GetTableSchema(ctx context.Context, req *GetTableSchemaRequest) (r *GetTableSchemaResponse, err error)
|
||||||
|
|
||||||
ValidateTableSchema(ctx context.Context, req *ValidateTableSchemaRequest) (r *ValidateTableSchemaResponse, err error)
|
ValidateTableSchema(ctx context.Context, req *ValidateTableSchemaRequest) (r *ValidateTableSchemaResponse, err error)
|
||||||
// slice相关
|
// Slice related
|
||||||
DeleteSlice(ctx context.Context, req *DeleteSliceRequest) (r *DeleteSliceResponse, err error)
|
DeleteSlice(ctx context.Context, req *DeleteSliceRequest) (r *DeleteSliceResponse, err error)
|
||||||
|
|
||||||
CreateSlice(ctx context.Context, req *CreateSliceRequest) (r *CreateSliceResponse, err error)
|
CreateSlice(ctx context.Context, req *CreateSliceRequest) (r *CreateSliceResponse, err error)
|
||||||
|
|
@ -53,7 +53,7 @@ type DatasetService interface {
|
||||||
UpdateSlice(ctx context.Context, req *UpdateSliceRequest) (r *UpdateSliceResponse, err error)
|
UpdateSlice(ctx context.Context, req *UpdateSliceRequest) (r *UpdateSliceResponse, err error)
|
||||||
|
|
||||||
ListSlice(ctx context.Context, req *ListSliceRequest) (r *ListSliceResponse, err error)
|
ListSlice(ctx context.Context, req *ListSliceRequest) (r *ListSliceResponse, err error)
|
||||||
/** 预分片相关 **/
|
/** Pre-sharding related **/
|
||||||
CreateDocumentReview(ctx context.Context, req *CreateDocumentReviewRequest) (r *CreateDocumentReviewResponse, err error)
|
CreateDocumentReview(ctx context.Context, req *CreateDocumentReviewRequest) (r *CreateDocumentReviewResponse, err error)
|
||||||
|
|
||||||
MGetDocumentReview(ctx context.Context, req *MGetDocumentReviewRequest) (r *MGetDocumentReviewResponse, err error)
|
MGetDocumentReview(ctx context.Context, req *MGetDocumentReviewRequest) (r *MGetDocumentReviewResponse, err error)
|
||||||
|
|
|
||||||
|
|
@ -3,9 +3,9 @@
|
||||||
package dataset
|
package dataset
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type ReviewInput struct {
|
type ReviewInput struct {
|
||||||
|
|
@ -298,7 +298,7 @@ type Review struct {
|
||||||
DocumentName string `thrift:"document_name,2" form:"document_name" json:"document_name" query:"document_name"`
|
DocumentName string `thrift:"document_name,2" form:"document_name" json:"document_name" query:"document_name"`
|
||||||
DocumentType string `thrift:"document_type,3" form:"document_type" json:"document_type" query:"document_type"`
|
DocumentType string `thrift:"document_type,3" form:"document_type" json:"document_type" query:"document_type"`
|
||||||
TosURL string `thrift:"tos_url,4" form:"tos_url" json:"tos_url" query:"tos_url"`
|
TosURL string `thrift:"tos_url,4" form:"tos_url" json:"tos_url" query:"tos_url"`
|
||||||
// 状态
|
// status
|
||||||
Status *ReviewStatus `thrift:"status,5,optional" form:"status" json:"status,omitempty" query:"status"`
|
Status *ReviewStatus `thrift:"status,5,optional" form:"status" json:"status,omitempty" query:"status"`
|
||||||
DocTreeTosURL *string `thrift:"doc_tree_tos_url,6,optional" form:"doc_tree_tos_url" json:"doc_tree_tos_url,omitempty" query:"doc_tree_tos_url"`
|
DocTreeTosURL *string `thrift:"doc_tree_tos_url,6,optional" form:"doc_tree_tos_url" json:"doc_tree_tos_url,omitempty" query:"doc_tree_tos_url"`
|
||||||
PreviewTosURL *string `thrift:"preview_tos_url,7,optional" form:"preview_tos_url" json:"preview_tos_url,omitempty" query:"preview_tos_url"`
|
PreviewTosURL *string `thrift:"preview_tos_url,7,optional" form:"preview_tos_url" json:"preview_tos_url,omitempty" query:"preview_tos_url"`
|
||||||
|
|
|
||||||
|
|
@ -3,21 +3,21 @@
|
||||||
package dataset
|
package dataset
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type SliceStatus int64
|
type SliceStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 未向量化
|
// unvectorized
|
||||||
SliceStatus_PendingVectoring SliceStatus = 0
|
SliceStatus_PendingVectoring SliceStatus = 0
|
||||||
// 已向量化
|
// vectorized
|
||||||
SliceStatus_FinishVectoring SliceStatus = 1
|
SliceStatus_FinishVectoring SliceStatus = 1
|
||||||
// 禁用
|
// disable
|
||||||
SliceStatus_Deactive SliceStatus = 9
|
SliceStatus_Deactive SliceStatus = 9
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -61,7 +61,7 @@ func (p *SliceStatus) Value() (driver.Value, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DeleteSliceRequest struct {
|
type DeleteSliceRequest struct {
|
||||||
// 要删除的分片ID列表
|
// List of sharding IDs to delete
|
||||||
SliceIds []string `thrift:"slice_ids,4,optional" form:"slice_ids" json:"slice_ids,omitempty"`
|
SliceIds []string `thrift:"slice_ids,4,optional" form:"slice_ids" json:"slice_ids,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -537,11 +537,11 @@ func (p *DeleteSliceResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type CreateSliceRequest struct {
|
type CreateSliceRequest struct {
|
||||||
// 新增分片插入的文档ID
|
// Add sharding inserted document ID
|
||||||
DocumentID int64 `thrift:"document_id,2,required" form:"document_id,required" json:"document_id,string,required" query:"document_id,required"`
|
DocumentID int64 `thrift:"document_id,2,required" form:"document_id,required" json:"document_id,string,required" query:"document_id,required"`
|
||||||
// 新增分片的内容
|
// Add sharding content
|
||||||
RawText *string `thrift:"raw_text,5,optional" form:"raw_text" json:"raw_text,omitempty" query:"raw_text"`
|
RawText *string `thrift:"raw_text,5,optional" form:"raw_text" json:"raw_text,omitempty" query:"raw_text"`
|
||||||
// 分片插入位置,1表示文档开头,最大值为最后一个分片位置+1
|
// Sharding insertion position, 1 indicates the beginning of the document, and the maximum value is the last sharding position + 1
|
||||||
Sequence *int64 `thrift:"sequence,6,optional" form:"sequence" json:"sequence,string,omitempty" query:"sequence"`
|
Sequence *int64 `thrift:"sequence,6,optional" form:"sequence" json:"sequence,string,omitempty" query:"sequence"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -852,7 +852,7 @@ func (p *CreateSliceRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type CreateSliceResponse struct {
|
type CreateSliceResponse struct {
|
||||||
// 新增分片ID
|
// Add sharding ID
|
||||||
SliceID int64 `thrift:"slice_id,1" form:"slice_id" json:"slice_id,string" query:"slice_id"`
|
SliceID int64 `thrift:"slice_id,1" form:"slice_id" json:"slice_id,string" query:"slice_id"`
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
|
|
@ -1150,9 +1150,9 @@ func (p *CreateSliceResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UpdateSliceRequest struct {
|
type UpdateSliceRequest struct {
|
||||||
// 要更新的分片ID
|
// The sharding ID to update
|
||||||
SliceID int64 `thrift:"slice_id,2,required" form:"slice_id,required" json:"slice_id,string,required" query:"slice_id,required"`
|
SliceID int64 `thrift:"slice_id,2,required" form:"slice_id,required" json:"slice_id,string,required" query:"slice_id,required"`
|
||||||
// 要更新的内容
|
// Content to be updated
|
||||||
RawText *string `thrift:"raw_text,7,optional" form:"raw_text" json:"raw_text,omitempty" query:"raw_text"`
|
RawText *string `thrift:"raw_text,7,optional" form:"raw_text" json:"raw_text,omitempty" query:"raw_text"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -1660,15 +1660,15 @@ func (p *UpdateSliceResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ListSliceRequest struct {
|
type ListSliceRequest struct {
|
||||||
// 要list的分片所属的文档ID
|
// The document ID of the sharding to list
|
||||||
DocumentID *int64 `thrift:"document_id,2,optional" form:"document_id" json:"document_id,string,omitempty" query:"document_id"`
|
DocumentID *int64 `thrift:"document_id,2,optional" form:"document_id" json:"document_id,string,omitempty" query:"document_id"`
|
||||||
// 分片序号,表示从该序号的分片开始list
|
// Sharding serial number, indicating that the list starts from the sharding of this serial number
|
||||||
Sequence *int64 `thrift:"sequence,3,optional" form:"sequence" json:"sequence,string,omitempty" query:"sequence"`
|
Sequence *int64 `thrift:"sequence,3,optional" form:"sequence" json:"sequence,string,omitempty" query:"sequence"`
|
||||||
// 查询关键字
|
// query keyword
|
||||||
Keyword *string `thrift:"keyword,4,optional" form:"keyword" json:"keyword,omitempty" query:"keyword"`
|
Keyword *string `thrift:"keyword,4,optional" form:"keyword" json:"keyword,omitempty" query:"keyword"`
|
||||||
// 如果只传 dataset_id,则返回该知识库下的分片
|
// If only dataset_id, return sharding under that knowledge base
|
||||||
DatasetID *int64 `thrift:"dataset_id,5,optional" form:"dataset_id" json:"dataset_id,string,omitempty" query:"dataset_id"`
|
DatasetID *int64 `thrift:"dataset_id,5,optional" form:"dataset_id" json:"dataset_id,string,omitempty" query:"dataset_id"`
|
||||||
// 每页大小
|
// page size
|
||||||
PageSize int64 `thrift:"page_size,21" form:"page_size" json:"page_size,string" query:"page_size"`
|
PageSize int64 `thrift:"page_size,21" form:"page_size" json:"page_size,string" query:"page_size"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -2081,11 +2081,11 @@ func (p *ListSliceRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ListSliceResponse struct {
|
type ListSliceResponse struct {
|
||||||
// 返回的分片列表
|
// Returned list of shardings
|
||||||
Slices []*SliceInfo `thrift:"slices,1" form:"slices" json:"slices" query:"slices"`
|
Slices []*SliceInfo `thrift:"slices,1" form:"slices" json:"slices" query:"slices"`
|
||||||
// 总分片数
|
// Total shardings
|
||||||
Total int64 `thrift:"total,2" form:"total" json:"total,string" query:"total"`
|
Total int64 `thrift:"total,2" form:"total" json:"total,string" query:"total"`
|
||||||
// 是否还有更多分片
|
// Is there more sharding?
|
||||||
Hasmore bool `thrift:"hasmore,3" form:"hasmore" json:"hasmore" query:"hasmore"`
|
Hasmore bool `thrift:"hasmore,3" form:"hasmore" json:"hasmore" query:"hasmore"`
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
Msg string `thrift:"msg,254,required" form:"msg,required" json:"msg,required" query:"msg,required"`
|
||||||
|
|
@ -2491,21 +2491,21 @@ func (p *ListSliceResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SliceInfo struct {
|
type SliceInfo struct {
|
||||||
// 分片ID
|
// Sharding ID
|
||||||
SliceID int64 `thrift:"slice_id,1" form:"slice_id" json:"slice_id,string" query:"slice_id"`
|
SliceID int64 `thrift:"slice_id,1" form:"slice_id" json:"slice_id,string" query:"slice_id"`
|
||||||
// 分片内容
|
// Sharding content
|
||||||
Content string `thrift:"content,2" form:"content" json:"content" query:"content"`
|
Content string `thrift:"content,2" form:"content" json:"content" query:"content"`
|
||||||
// 分片状态
|
// Sharding state
|
||||||
Status SliceStatus `thrift:"status,3" form:"status" json:"status" query:"status"`
|
Status SliceStatus `thrift:"status,3" form:"status" json:"status" query:"status"`
|
||||||
// 命中次数
|
// hit count
|
||||||
HitCount int64 `thrift:"hit_count,4" form:"hit_count" json:"hit_count,string" query:"hit_count"`
|
HitCount int64 `thrift:"hit_count,4" form:"hit_count" json:"hit_count,string" query:"hit_count"`
|
||||||
// 字符数
|
// character count
|
||||||
CharCount int64 `thrift:"char_count,5" form:"char_count" json:"char_count,string" query:"char_count"`
|
CharCount int64 `thrift:"char_count,5" form:"char_count" json:"char_count,string" query:"char_count"`
|
||||||
// 序号
|
// serial number
|
||||||
Sequence int64 `thrift:"sequence,7" form:"sequence" json:"sequence,string" query:"sequence"`
|
Sequence int64 `thrift:"sequence,7" form:"sequence" json:"sequence,string" query:"sequence"`
|
||||||
// 分片所属的文档ID
|
// The document ID to which sharding belongs
|
||||||
DocumentID int64 `thrift:"document_id,8" form:"document_id" json:"document_id,string" query:"document_id"`
|
DocumentID int64 `thrift:"document_id,8" form:"document_id" json:"document_id,string" query:"document_id"`
|
||||||
// 分片相关的元信息, 透传 slice 表里的 extra->chunk_info 字段 (json)
|
// Meta information related to sharding, extra- > chunk_info field in the transparent slice table (json)
|
||||||
ChunkInfo string `thrift:"chunk_info,9" form:"chunk_info" json:"chunk_info" query:"chunk_info"`
|
ChunkInfo string `thrift:"chunk_info,9" form:"chunk_info" json:"chunk_info" query:"chunk_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,19 +3,19 @@
|
||||||
package coze
|
package coze
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"fmt"
|
||||||
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/flow/devops/debugger/domain/infra"
|
"github.com/coze-dev/coze-studio/backend/api/model/flow/devops/debugger/domain/infra"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/flow/devops/debugger/domain/testcase"
|
"github.com/coze-dev/coze-studio/backend/api/model/flow/devops/debugger/domain/testcase"
|
||||||
"fmt"
|
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
// ========== TestCase =========== //
|
// ========== TestCase =========== //
|
||||||
type SaveCaseDataReq struct {
|
type SaveCaseDataReq struct {
|
||||||
// 业务信息
|
// business information
|
||||||
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
||||||
BizComponentSubject *infra.ComponentSubject `thrift:"bizComponentSubject,2,optional" form:"bizComponentSubject" json:"bizComponentSubject,omitempty" query:"bizComponentSubject"`
|
BizComponentSubject *infra.ComponentSubject `thrift:"bizComponentSubject,2,optional" form:"bizComponentSubject" json:"bizComponentSubject,omitempty" query:"bizComponentSubject"`
|
||||||
// case基本数据
|
// Case basic data
|
||||||
CaseBase *testcase.CaseDataBase `thrift:"caseBase,3,optional" form:"caseBase" json:"caseBase,omitempty" query:"caseBase"`
|
CaseBase *testcase.CaseDataBase `thrift:"caseBase,3,optional" form:"caseBase" json:"caseBase,omitempty" query:"caseBase"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -632,9 +632,9 @@ func (p *SaveCaseDataResp) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DeleteCaseDataReq struct {
|
type DeleteCaseDataReq struct {
|
||||||
// 业务信息
|
// business information
|
||||||
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
||||||
// 单次上限20个
|
// A single maximum of 20
|
||||||
CaseIDs []int64 `thrift:"caseIDs,2,optional" form:"caseIDs" json:"caseIDs,omitempty" query:"caseIDs"`
|
CaseIDs []int64 `thrift:"caseIDs,2,optional" form:"caseIDs" json:"caseIDs,omitempty" query:"caseIDs"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -1246,7 +1246,7 @@ func (p *DeleteCaseDataResp) String() string {
|
||||||
|
|
||||||
type CheckCaseDuplicateReq struct {
|
type CheckCaseDuplicateReq struct {
|
||||||
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
||||||
// case名称
|
// Case name
|
||||||
CaseName *string `thrift:"caseName,2,optional" form:"caseName" json:"caseName,omitempty" query:"caseName"`
|
CaseName *string `thrift:"caseName,2,optional" form:"caseName" json:"caseName,omitempty" query:"caseName"`
|
||||||
BizComponentSubject *infra.ComponentSubject `thrift:"bizComponentSubject,3,optional" form:"bizComponentSubject" json:"bizComponentSubject,omitempty" query:"bizComponentSubject"`
|
BizComponentSubject *infra.ComponentSubject `thrift:"bizComponentSubject,3,optional" form:"bizComponentSubject" json:"bizComponentSubject,omitempty" query:"bizComponentSubject"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -1556,7 +1556,7 @@ func (p *CheckCaseDuplicateReq) String() string {
|
||||||
|
|
||||||
type CheckCaseDuplicateResp struct {
|
type CheckCaseDuplicateResp struct {
|
||||||
IsPass *bool `thrift:"isPass,1,optional" form:"isPass" json:"isPass,omitempty" query:"isPass"`
|
IsPass *bool `thrift:"isPass,1,optional" form:"isPass" json:"isPass,omitempty" query:"isPass"`
|
||||||
// 当pass=false时,给出具体的校验不通过的原因
|
// When pass = false, give the specific reason why the check failed
|
||||||
FailReason *string `thrift:"failReason,2,optional" form:"failReason" json:"failReason,omitempty" query:"failReason"`
|
FailReason *string `thrift:"failReason,2,optional" form:"failReason" json:"failReason,omitempty" query:"failReason"`
|
||||||
FailCode *int32 `thrift:"failCode,3,optional" form:"failCode" json:"failCode,omitempty" query:"failCode"`
|
FailCode *int32 `thrift:"failCode,3,optional" form:"failCode" json:"failCode,omitempty" query:"failCode"`
|
||||||
Code *int32 `thrift:"code,253,optional" form:"code" json:"code,omitempty" query:"code"`
|
Code *int32 `thrift:"code,253,optional" form:"code" json:"code,omitempty" query:"code"`
|
||||||
|
|
@ -1983,7 +1983,7 @@ func (p *CheckCaseDuplicateResp) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetSchemaByIDReq struct {
|
type GetSchemaByIDReq struct {
|
||||||
// 业务信息
|
// business information
|
||||||
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
BizCtx *infra.BizCtx `thrift:"bizCtx,1,optional" form:"bizCtx" json:"bizCtx,omitempty" query:"bizCtx"`
|
||||||
BizComponentSubject *infra.ComponentSubject `thrift:"bizComponentSubject,2,optional" form:"bizComponentSubject" json:"bizComponentSubject,omitempty" query:"bizComponentSubject"`
|
BizComponentSubject *infra.ComponentSubject `thrift:"bizComponentSubject,2,optional" form:"bizComponentSubject" json:"bizComponentSubject,omitempty" query:"bizComponentSubject"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -2237,7 +2237,7 @@ func (p *GetSchemaByIDReq) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetSchemaByIDResp struct {
|
type GetSchemaByIDResp struct {
|
||||||
// Json格式的组件input信息,与Input Json Schema保持一致,不包含Value值信息
|
// Component input information in JSON format, consistent with Input JSON Schema, does not contain Value information
|
||||||
SchemaJson *string `thrift:"schemaJson,1,optional" form:"schemaJson" json:"schemaJson,omitempty" query:"schemaJson"`
|
SchemaJson *string `thrift:"schemaJson,1,optional" form:"schemaJson" json:"schemaJson,omitempty" query:"schemaJson"`
|
||||||
Code *int32 `thrift:"code,253,optional" form:"code" json:"code,omitempty" query:"code"`
|
Code *int32 `thrift:"code,253,optional" form:"code" json:"code,omitempty" query:"code"`
|
||||||
Msg *string `thrift:"msg,254,optional" form:"msg" json:"msg,omitempty" query:"msg"`
|
Msg *string `thrift:"msg,254,optional" form:"msg" json:"msg,omitempty" query:"msg"`
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import (
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
)
|
)
|
||||||
|
|
||||||
// ComponentType 支持组件类型
|
// ComponentType Supports component types
|
||||||
type ComponentType int64
|
type ComponentType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -20,23 +20,23 @@ const (
|
||||||
ComponentType_CozeTool ComponentType = 10001
|
ComponentType_CozeTool ComponentType = 10001
|
||||||
// Coze Workflow
|
// Coze Workflow
|
||||||
ComponentType_CozeWorkflow ComponentType = 10002
|
ComponentType_CozeWorkflow ComponentType = 10002
|
||||||
// Coze SubWorkflow,即在Workflow中被引用的子Workflow
|
// Coze SubWorkflow, which is referenced in Workflow.
|
||||||
ComponentType_CozeSubWorkflow ComponentType = 10003
|
ComponentType_CozeSubWorkflow ComponentType = 10003
|
||||||
// Coze workflow中的LLM节点
|
// LLM nodes in Coze workflow
|
||||||
ComponentType_CozeLLMNode ComponentType = 10004
|
ComponentType_CozeLLMNode ComponentType = 10004
|
||||||
// Coze workflow中的Code节点
|
// Coding nodes in a Coze workflow
|
||||||
ComponentType_CozeCodeNode ComponentType = 10005
|
ComponentType_CozeCodeNode ComponentType = 10005
|
||||||
// Coze workflow中的Knowledge节点
|
// Knowledge nodes in Coze workflow
|
||||||
ComponentType_CozeKnowledgeNode ComponentType = 10006
|
ComponentType_CozeKnowledgeNode ComponentType = 10006
|
||||||
// Coze workflow中的Tool节点
|
// Tools nodes in Coze workflow
|
||||||
ComponentType_CozeToolNode ComponentType = 10007
|
ComponentType_CozeToolNode ComponentType = 10007
|
||||||
// Coze workflow中的start节点
|
// Coze workflow start node
|
||||||
ComponentType_CozeStartNode ComponentType = 10008
|
ComponentType_CozeStartNode ComponentType = 10008
|
||||||
// Coze workflow中的variable节点
|
// Cozing variable nodes in workflow
|
||||||
ComponentType_CozeVariableNode ComponentType = 10009
|
ComponentType_CozeVariableNode ComponentType = 10009
|
||||||
// Coze 虚拟节点用于标识 variable 依赖的bot
|
// Coze virtual nodes to identify variable dependent bots
|
||||||
ComponentType_CozeVariableBot ComponentType = 20000
|
ComponentType_CozeVariableBot ComponentType = 20000
|
||||||
// Coze 虚拟节点用于标识 variable 依赖的chat
|
// Coze virtual nodes to identify variable dependent chats
|
||||||
ComponentType_CozeVariableChat ComponentType = 20001
|
ComponentType_CozeVariableChat ComponentType = 20001
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -119,18 +119,18 @@ func (p *ComponentType) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// TrafficScene 流量请求场景
|
// TrafficScene traffic request scenario
|
||||||
type TrafficScene int64
|
type TrafficScene int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
TrafficScene_Undefined TrafficScene = 0
|
TrafficScene_Undefined TrafficScene = 0
|
||||||
// 单Agent调试页
|
// Single Agent Debug Page
|
||||||
TrafficScene_CozeSingleAgentDebug TrafficScene = 10000
|
TrafficScene_CozeSingleAgentDebug TrafficScene = 10000
|
||||||
// 多Agent调试页
|
// Multi-Agent Debug Page
|
||||||
TrafficScene_CozeMultiAgentDebug TrafficScene = 10001
|
TrafficScene_CozeMultiAgentDebug TrafficScene = 10001
|
||||||
// Tool调试页
|
// Tool Debug Page
|
||||||
TrafficScene_CozeToolDebug TrafficScene = 10002
|
TrafficScene_CozeToolDebug TrafficScene = 10002
|
||||||
// Workflow调试页
|
// Workflow debugging page
|
||||||
TrafficScene_CozeWorkflowDebug TrafficScene = 10003
|
TrafficScene_CozeWorkflowDebug TrafficScene = 10003
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -181,7 +181,7 @@ func (p *TrafficScene) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// ComponentMappingType 组件映射类型
|
// ComponentMappingType Component Mapping Types
|
||||||
type ComponentMappingType int64
|
type ComponentMappingType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -264,7 +264,7 @@ func (p *OrderBy) Value() (driver.Value, error) {
|
||||||
type DebugScene int64
|
type DebugScene int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 默认play ground Debug场景
|
// Default play ground Debug scene
|
||||||
DebugScene_Debug DebugScene = 0
|
DebugScene_Debug DebugScene = 0
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -302,7 +302,7 @@ func (p *DebugScene) Value() (driver.Value, error) {
|
||||||
type CozeChannel int64
|
type CozeChannel int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 默认为Coze, 未来扩展到其他渠道
|
// Default to Coze, expand to other channels in the future
|
||||||
CozeChannel_Coze CozeChannel = 0
|
CozeChannel_Coze CozeChannel = 0
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -337,19 +337,19 @@ func (p *CozeChannel) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// BizCtx 业务上下文
|
// BizCtx Business Context
|
||||||
type BizCtx struct {
|
type BizCtx struct {
|
||||||
// connectorID
|
// connectorID
|
||||||
ConnectorID *string `thrift:"connectorID,1,optional" form:"connectorID" json:"connectorID,omitempty" query:"connectorID"`
|
ConnectorID *string `thrift:"connectorID,1,optional" form:"connectorID" json:"connectorID,omitempty" query:"connectorID"`
|
||||||
// connector下用户ID
|
// User ID under connector
|
||||||
ConnectorUID *string `thrift:"connectorUID,2,optional" form:"connectorUID" json:"connectorUID,omitempty" query:"connectorUID"`
|
ConnectorUID *string `thrift:"connectorUID,2,optional" form:"connectorUID" json:"connectorUID,omitempty" query:"connectorUID"`
|
||||||
// 业务场景
|
// business scenario
|
||||||
TrafficScene *TrafficScene `thrift:"trafficScene,3,optional" form:"trafficScene" json:"trafficScene,omitempty" query:"trafficScene"`
|
TrafficScene *TrafficScene `thrift:"trafficScene,3,optional" form:"trafficScene" json:"trafficScene,omitempty" query:"trafficScene"`
|
||||||
// 业务场景组件ID,比如Bot调试页,则trafficSceneID为BotID
|
// Business Scenario Component ID, such as Bot Debug Page, where trafficSceneID is BotID
|
||||||
TrafficCallerID *string `thrift:"trafficCallerID,4,optional" form:"trafficCallerID" json:"trafficCallerID,omitempty" query:"trafficCallerID"`
|
TrafficCallerID *string `thrift:"trafficCallerID,4,optional" form:"trafficCallerID" json:"trafficCallerID,omitempty" query:"trafficCallerID"`
|
||||||
// 业务线SpaceID,用于访问控制
|
// Line of business SpaceID for access control
|
||||||
BizSpaceID *string `thrift:"bizSpaceID,5,optional" form:"bizSpaceID" json:"bizSpaceID,omitempty" query:"bizSpaceID"`
|
BizSpaceID *string `thrift:"bizSpaceID,5,optional" form:"bizSpaceID" json:"bizSpaceID,omitempty" query:"bizSpaceID"`
|
||||||
// 额外信息
|
// Additional information
|
||||||
Ext map[string]string `thrift:"ext,6,optional" form:"ext" json:"ext,omitempty" query:"ext"`
|
Ext map[string]string `thrift:"ext,6,optional" form:"ext" json:"ext,omitempty" query:"ext"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -804,15 +804,15 @@ func (p *BizCtx) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// ComponentSubject 业务组件的二级结构
|
// Secondary structure of the ComponentSubject business component
|
||||||
type ComponentSubject struct {
|
type ComponentSubject struct {
|
||||||
// 组件ID,例如Tool ID、Node ID等
|
// Component IDs, such as Tool ID, Node ID, etc
|
||||||
ComponentID *string `thrift:"componentID,1,optional" form:"componentID" json:"componentID,omitempty" query:"componentID"`
|
ComponentID *string `thrift:"componentID,1,optional" form:"componentID" json:"componentID,omitempty" query:"componentID"`
|
||||||
// 组件类型
|
// component type
|
||||||
ComponentType *ComponentType `thrift:"componentType,2,optional" form:"componentType" json:"componentType,omitempty" query:"componentType"`
|
ComponentType *ComponentType `thrift:"componentType,2,optional" form:"componentType" json:"componentType,omitempty" query:"componentType"`
|
||||||
// 父组件ID,例如Tool->Plugin, Node->Workflow
|
// Parent component ID, e.g. Tool- > Plugin, Node- > Workflow
|
||||||
ParentComponentID *string `thrift:"parentComponentID,3,optional" form:"parentComponentID" json:"parentComponentID,omitempty" query:"parentComponentID"`
|
ParentComponentID *string `thrift:"parentComponentID,3,optional" form:"parentComponentID" json:"parentComponentID,omitempty" query:"parentComponentID"`
|
||||||
// 父组件类型
|
// Parent component type
|
||||||
ParentComponentType *ComponentType `thrift:"parentComponentType,4,optional" form:"parentComponentType" json:"parentComponentType,omitempty" query:"parentComponentType"`
|
ParentComponentType *ComponentType `thrift:"parentComponentType,4,optional" form:"parentComponentType" json:"parentComponentType,omitempty" query:"parentComponentType"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,17 +3,17 @@
|
||||||
package testcase
|
package testcase
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/flow/devops/debugger/domain/infra"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/flow/devops/debugger/domain/infra"
|
||||||
)
|
)
|
||||||
|
|
||||||
type CaseDataBase struct {
|
type CaseDataBase struct {
|
||||||
// 新增时不填,更新时填写
|
// Do not fill in when adding, fill in when updating
|
||||||
CaseID *int64 `thrift:"caseID,1,optional" json:"caseID,string" form:"caseID" query:"caseID"`
|
CaseID *int64 `thrift:"caseID,1,optional" json:"caseID,string" form:"caseID" query:"caseID"`
|
||||||
Name *string `thrift:"name,2,optional" form:"name" json:"name,omitempty" query:"name"`
|
Name *string `thrift:"name,2,optional" form:"name" json:"name,omitempty" query:"name"`
|
||||||
Description *string `thrift:"description,3,optional" form:"description" json:"description,omitempty" query:"description"`
|
Description *string `thrift:"description,3,optional" form:"description" json:"description,omitempty" query:"description"`
|
||||||
// json格式的输入信息
|
// Input information in JSON format
|
||||||
Input *string `thrift:"input,4,optional" form:"input" json:"input,omitempty" query:"input"`
|
Input *string `thrift:"input,4,optional" form:"input" json:"input,omitempty" query:"input"`
|
||||||
IsDefault *bool `thrift:"isDefault,5,optional" form:"isDefault" json:"isDefault,omitempty" query:"isDefault"`
|
IsDefault *bool `thrift:"isDefault,5,optional" form:"isDefault" json:"isDefault,omitempty" query:"isDefault"`
|
||||||
}
|
}
|
||||||
|
|
@ -389,7 +389,7 @@ type CaseDataDetail struct {
|
||||||
CreatorID *string `thrift:"creatorID,2,optional" form:"creatorID" json:"creatorID,omitempty" query:"creatorID"`
|
CreatorID *string `thrift:"creatorID,2,optional" form:"creatorID" json:"creatorID,omitempty" query:"creatorID"`
|
||||||
CreateTimeInSec *int64 `thrift:"createTimeInSec,3,optional" form:"createTimeInSec" json:"createTimeInSec,omitempty" query:"createTimeInSec"`
|
CreateTimeInSec *int64 `thrift:"createTimeInSec,3,optional" form:"createTimeInSec" json:"createTimeInSec,omitempty" query:"createTimeInSec"`
|
||||||
UpdateTimeInSec *int64 `thrift:"updateTimeInSec,4,optional" form:"updateTimeInSec" json:"updateTimeInSec,omitempty" query:"updateTimeInSec"`
|
UpdateTimeInSec *int64 `thrift:"updateTimeInSec,4,optional" form:"updateTimeInSec" json:"updateTimeInSec,omitempty" query:"updateTimeInSec"`
|
||||||
// schema不兼容
|
// Schema incompatibility
|
||||||
SchemaIncompatible *bool `thrift:"schemaIncompatible,5,optional" form:"schemaIncompatible" json:"schemaIncompatible,omitempty" query:"schemaIncompatible"`
|
SchemaIncompatible *bool `thrift:"schemaIncompatible,5,optional" form:"schemaIncompatible" json:"schemaIncompatible,omitempty" query:"schemaIncompatible"`
|
||||||
Updater *infra.Creator `thrift:"updater,6,optional" form:"updater" json:"updater,omitempty" query:"updater"`
|
Updater *infra.Creator `thrift:"updater,6,optional" form:"updater" json:"updater,omitempty" query:"updater"`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -12,13 +12,13 @@ import (
|
||||||
type FollowType int64
|
type FollowType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 无关系
|
// Unknown
|
||||||
FollowType_Unknown FollowType = 0
|
FollowType_Unknown FollowType = 0
|
||||||
// 关注
|
// followee
|
||||||
FollowType_Followee FollowType = 1
|
FollowType_Followee FollowType = 1
|
||||||
// 粉丝
|
// follower
|
||||||
FollowType_Follower FollowType = 2
|
FollowType_Follower FollowType = 2
|
||||||
// 互相关注
|
// MutualFollow
|
||||||
FollowType_MutualFollow FollowType = 3
|
FollowType_MutualFollow FollowType = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -66,11 +66,11 @@ func (p *FollowType) Value() (driver.Value, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type Price struct {
|
type Price struct {
|
||||||
// 金额
|
// amount
|
||||||
Amount int64 `thrift:"Amount,1" form:"amount" json:"amount,string"`
|
Amount int64 `thrift:"Amount,1" form:"amount" json:"amount,string"`
|
||||||
// 币种,如USD、CNY
|
// Currencies such as USD and CNY
|
||||||
Currency string `thrift:"Currency,2" form:"currency" json:"currency"`
|
Currency string `thrift:"Currency,2" form:"currency" json:"currency"`
|
||||||
// 小数位数
|
// decimal places
|
||||||
DecimalNum int8 `thrift:"DecimalNum,3" form:"decimal_num" json:"decimal_num"`
|
DecimalNum int8 `thrift:"DecimalNum,3" form:"decimal_num" json:"decimal_num"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,11 +3,11 @@
|
||||||
package product_common
|
package product_common
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/flow/marketplace/marketplace_common"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/flow/marketplace/marketplace_common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type ProductEntityType int64
|
type ProductEntityType int64
|
||||||
|
|
@ -18,28 +18,28 @@ const (
|
||||||
// Workflow = 3 ,
|
// Workflow = 3 ,
|
||||||
ProductEntityType_SocialScene ProductEntityType = 4
|
ProductEntityType_SocialScene ProductEntityType = 4
|
||||||
ProductEntityType_Project ProductEntityType = 6
|
ProductEntityType_Project ProductEntityType = 6
|
||||||
// 历史工作流,后续不会再有(废弃)
|
// History workflow, no more in the future (abandoned)
|
||||||
ProductEntityType_WorkflowTemplate ProductEntityType = 13
|
ProductEntityType_WorkflowTemplate ProductEntityType = 13
|
||||||
// 历史图像流模板,后续不会再有(废弃)
|
// Historical image stream template, no more in the future (obsolete)
|
||||||
ProductEntityType_ImageflowTemplate ProductEntityType = 15
|
ProductEntityType_ImageflowTemplate ProductEntityType = 15
|
||||||
// 模板通用标识,仅用于绑定模板相关的配置,不绑定商品
|
// Template universal identification, only used to bind template-related configurations, not bind products
|
||||||
ProductEntityType_TemplateCommon ProductEntityType = 20
|
ProductEntityType_TemplateCommon ProductEntityType = 20
|
||||||
// Bot 模板
|
// Bot template
|
||||||
ProductEntityType_BotTemplate ProductEntityType = 21
|
ProductEntityType_BotTemplate ProductEntityType = 21
|
||||||
// 工作流模板
|
// workflow template
|
||||||
ProductEntityType_WorkflowTemplateV2 ProductEntityType = 23
|
ProductEntityType_WorkflowTemplateV2 ProductEntityType = 23
|
||||||
// 图像流模板(该类型已下线,合并入 workflow,但历史数据会保留,前端视作 workflow 展示)
|
// Image stream template (this type has been offline and merged into workflow, but historical data will be preserved, and the front end will be treated as workflow display)
|
||||||
ProductEntityType_ImageflowTemplateV2 ProductEntityType = 25
|
ProductEntityType_ImageflowTemplateV2 ProductEntityType = 25
|
||||||
// 项目模板
|
// project template
|
||||||
ProductEntityType_ProjectTemplate ProductEntityType = 26
|
ProductEntityType_ProjectTemplate ProductEntityType = 26
|
||||||
// coze token 类商品,理论上只会有一个
|
// Coze token products, theoretically there will only be one
|
||||||
ProductEntityType_CozeToken ProductEntityType = 50
|
ProductEntityType_CozeToken ProductEntityType = 50
|
||||||
// 订阅 credit 的流量包,理论上只会有一个
|
// Subscribe to the traffic package of credit, theoretically there will only be one
|
||||||
ProductEntityType_MsgCredit ProductEntityType = 55
|
ProductEntityType_MsgCredit ProductEntityType = 55
|
||||||
// 消息订阅类商品,理论上只有一个
|
// There is only one subscription product in theory
|
||||||
ProductEntityType_SubsMsgCredit ProductEntityType = 60
|
ProductEntityType_SubsMsgCredit ProductEntityType = 60
|
||||||
ProductEntityType_Common ProductEntityType = 99
|
ProductEntityType_Common ProductEntityType = 99
|
||||||
// 专题(兼容之前的设计)
|
// Special Topics (Compatible with previous designs)
|
||||||
ProductEntityType_Topic ProductEntityType = 101
|
ProductEntityType_Topic ProductEntityType = 101
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -139,9 +139,9 @@ type SortType int64
|
||||||
const (
|
const (
|
||||||
SortType_Heat SortType = 1
|
SortType_Heat SortType = 1
|
||||||
SortType_Newest SortType = 2
|
SortType_Newest SortType = 2
|
||||||
// 收藏时间
|
// collection time
|
||||||
SortType_FavoriteTime SortType = 3
|
SortType_FavoriteTime SortType = 3
|
||||||
// 相关性,只用于搜索场景
|
// Correlation, only for search scenarios
|
||||||
SortType_Relative SortType = 4
|
SortType_Relative SortType = 4
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -233,9 +233,9 @@ func (p *ProductPublishMode) Value() (driver.Value, error) {
|
||||||
type ProductListSource int64
|
type ProductListSource int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 推荐列表页
|
// recommended list page
|
||||||
ProductListSource_Recommend ProductListSource = 1
|
ProductListSource_Recommend ProductListSource = 1
|
||||||
// 个性化推荐
|
// personalized recommendation
|
||||||
ProductListSource_CustomizedRecommend ProductListSource = 2
|
ProductListSource_CustomizedRecommend ProductListSource = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -362,7 +362,7 @@ func (p *ProductPaidType) Value() (driver.Value, error) {
|
||||||
type ProductStatus int64
|
type ProductStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 从未上架
|
// NeverListed
|
||||||
ProductStatus_NeverListed ProductStatus = 0
|
ProductStatus_NeverListed ProductStatus = 0
|
||||||
ProductStatus_Listed ProductStatus = 1
|
ProductStatus_Listed ProductStatus = 1
|
||||||
ProductStatus_Unlisted ProductStatus = 2
|
ProductStatus_Unlisted ProductStatus = 2
|
||||||
|
|
@ -415,15 +415,15 @@ func (p *ProductStatus) Value() (driver.Value, error) {
|
||||||
type ProductDraftStatus int64
|
type ProductDraftStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 默认
|
// default
|
||||||
ProductDraftStatus_Default ProductDraftStatus = 0
|
ProductDraftStatus_Default ProductDraftStatus = 0
|
||||||
// 审核中
|
// Under review.
|
||||||
ProductDraftStatus_Pending ProductDraftStatus = 1
|
ProductDraftStatus_Pending ProductDraftStatus = 1
|
||||||
// 审核通过
|
// approved
|
||||||
ProductDraftStatus_Approved ProductDraftStatus = 2
|
ProductDraftStatus_Approved ProductDraftStatus = 2
|
||||||
// 审核不通过
|
// The review failed.
|
||||||
ProductDraftStatus_Rejected ProductDraftStatus = 3
|
ProductDraftStatus_Rejected ProductDraftStatus = 3
|
||||||
// 已废弃
|
// Abandoned
|
||||||
ProductDraftStatus_Abandoned ProductDraftStatus = 4
|
ProductDraftStatus_Abandoned ProductDraftStatus = 4
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -576,27 +576,27 @@ func (p *PluginParamTypeFormat) Value() (driver.Value, error) {
|
||||||
type WorkflowNodeType int64
|
type WorkflowNodeType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 开始
|
// start
|
||||||
WorkflowNodeType_Start WorkflowNodeType = 1
|
WorkflowNodeType_Start WorkflowNodeType = 1
|
||||||
// 结束
|
// end
|
||||||
WorkflowNodeType_End WorkflowNodeType = 2
|
WorkflowNodeType_End WorkflowNodeType = 2
|
||||||
// 大模型
|
// Large model
|
||||||
WorkflowNodeType_LLM WorkflowNodeType = 3
|
WorkflowNodeType_LLM WorkflowNodeType = 3
|
||||||
// 插件
|
// plugin
|
||||||
WorkflowNodeType_Api WorkflowNodeType = 4
|
WorkflowNodeType_Api WorkflowNodeType = 4
|
||||||
// 代码
|
// code
|
||||||
WorkflowNodeType_Code WorkflowNodeType = 5
|
WorkflowNodeType_Code WorkflowNodeType = 5
|
||||||
// 知识库
|
// Knowledge Base
|
||||||
WorkflowNodeType_Dataset WorkflowNodeType = 6
|
WorkflowNodeType_Dataset WorkflowNodeType = 6
|
||||||
// 选择器
|
// selector
|
||||||
WorkflowNodeType_If WorkflowNodeType = 8
|
WorkflowNodeType_If WorkflowNodeType = 8
|
||||||
// 工作流
|
// Workflow
|
||||||
WorkflowNodeType_SubWorkflow WorkflowNodeType = 9
|
WorkflowNodeType_SubWorkflow WorkflowNodeType = 9
|
||||||
// 变量
|
// variable
|
||||||
WorkflowNodeType_Variable WorkflowNodeType = 11
|
WorkflowNodeType_Variable WorkflowNodeType = 11
|
||||||
// 数据库
|
// database
|
||||||
WorkflowNodeType_Database WorkflowNodeType = 12
|
WorkflowNodeType_Database WorkflowNodeType = 12
|
||||||
// 消息
|
// message
|
||||||
WorkflowNodeType_Message WorkflowNodeType = 13
|
WorkflowNodeType_Message WorkflowNodeType = 13
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -721,9 +721,9 @@ func (p *SocialSceneRoleType) Value() (driver.Value, error) {
|
||||||
type UIPreviewType int64
|
type UIPreviewType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// UI 预览类型,定义对齐 UI Builder,目前用于 Project
|
// UI preview type, defining alignment UI Builder, currently used in Project
|
||||||
UIPreviewType_Web UIPreviewType = 1
|
UIPreviewType_Web UIPreviewType = 1
|
||||||
// 移动端
|
// mobile end
|
||||||
UIPreviewType_Client UIPreviewType = 2
|
UIPreviewType_Client UIPreviewType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -765,7 +765,7 @@ func (p *UIPreviewType) Value() (driver.Value, error) {
|
||||||
type FavoriteListSource int64
|
type FavoriteListSource int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 用户自己创建的
|
// Created by users themselves
|
||||||
FavoriteListSource_CreatedByMe FavoriteListSource = 1
|
FavoriteListSource_CreatedByMe FavoriteListSource = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1837,7 +1837,7 @@ func (p *ImageInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type OpeningDialog struct {
|
type OpeningDialog struct {
|
||||||
// Bot开场白
|
// Bot OpeningDialog
|
||||||
Content string `thrift:"content,1" form:"content" json:"content"`
|
Content string `thrift:"content,1" form:"content" json:"content"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2166,13 +2166,13 @@ type FavoriteEntity struct {
|
||||||
Name string `thrift:"Name,4" form:"name" json:"name"`
|
Name string `thrift:"Name,4" form:"name" json:"name"`
|
||||||
IconURL string `thrift:"IconURL,5" form:"icon_url" json:"icon_url"`
|
IconURL string `thrift:"IconURL,5" form:"icon_url" json:"icon_url"`
|
||||||
Description string `thrift:"Description,6" form:"description" json:"description"`
|
Description string `thrift:"Description,6" form:"description" json:"description"`
|
||||||
// 废弃,使用UserInfo
|
// Abandoned, using UserInfo
|
||||||
Seller *SellerInfo `thrift:"Seller,7" form:"seller" json:"seller"`
|
Seller *SellerInfo `thrift:"Seller,7" form:"seller" json:"seller"`
|
||||||
// 用于跳转到Bot编辑页
|
// Use to jump to the bot edit page
|
||||||
SpaceID int64 `thrift:"SpaceID,8" form:"space_id" json:"space_id,string"`
|
SpaceID int64 `thrift:"SpaceID,8" form:"space_id" json:"space_id,string"`
|
||||||
// 用户是否有该实体所在Space的权限
|
// Does the user have permissions to the space where the entity is located?
|
||||||
HasSpacePermission bool `thrift:"HasSpacePermission,9" form:"has_space_permission" json:"has_space_permission"`
|
HasSpacePermission bool `thrift:"HasSpacePermission,9" form:"has_space_permission" json:"has_space_permission"`
|
||||||
// 收藏时间
|
// collection time
|
||||||
FavoriteAt int64 `thrift:"FavoriteAt,10" form:"favorite_at" json:"favorite_at,string"`
|
FavoriteAt int64 `thrift:"FavoriteAt,10" form:"favorite_at" json:"favorite_at,string"`
|
||||||
ProductExtra *FavoriteProductExtra `thrift:"ProductExtra,11,optional" form:"product_extra" json:"product_extra,omitempty"`
|
ProductExtra *FavoriteProductExtra `thrift:"ProductExtra,11,optional" form:"product_extra" json:"product_extra,omitempty"`
|
||||||
UserInfo *UserInfo `thrift:"UserInfo,12" form:"user_info" json:"user_info"`
|
UserInfo *UserInfo `thrift:"UserInfo,12" form:"user_info" json:"user_info"`
|
||||||
|
|
|
||||||
|
|
@ -3,26 +3,26 @@
|
||||||
package product_public_api
|
package product_public_api
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/flow/marketplace/marketplace_common"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/flow/marketplace/product_common"
|
|
||||||
"context"
|
"context"
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/flow/marketplace/marketplace_common"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/flow/marketplace/product_common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type PluginAuthMode int64
|
type PluginAuthMode int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 不需要授权
|
// No authorization required.
|
||||||
PluginAuthMode_NoAuth PluginAuthMode = 0
|
PluginAuthMode_NoAuth PluginAuthMode = 0
|
||||||
// 需要授权,但无授权配置
|
// Authorization required, but no authorization configuration
|
||||||
PluginAuthMode_Required PluginAuthMode = 1
|
PluginAuthMode_Required PluginAuthMode = 1
|
||||||
// 需要授权,且已经配置
|
// Authorization is required and has been configured
|
||||||
PluginAuthMode_Configured PluginAuthMode = 2
|
PluginAuthMode_Configured PluginAuthMode = 2
|
||||||
// 需要授权,但授权配置可能是用户级别,可由用户自己配置
|
// Authorization is required, but the authorization configuration may be user-level and can be configured by the user himself
|
||||||
PluginAuthMode_Supported PluginAuthMode = 3
|
PluginAuthMode_Supported PluginAuthMode = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1046,32 +1046,32 @@ type GetProductListRequest struct {
|
||||||
SortType product_common.SortType `thrift:"SortType,3,required" form:"sort_type,required" json:"sort_type,required"`
|
SortType product_common.SortType `thrift:"SortType,3,required" form:"sort_type,required" json:"sort_type,required"`
|
||||||
PageNum int32 `thrift:"PageNum,4,required" form:"page_num,required" json:"page_num,required"`
|
PageNum int32 `thrift:"PageNum,4,required" form:"page_num,required" json:"page_num,required"`
|
||||||
PageSize int32 `thrift:"PageSize,5,required" form:"page_size,required" json:"page_size,required"`
|
PageSize int32 `thrift:"PageSize,5,required" form:"page_size,required" json:"page_size,required"`
|
||||||
// 不为空则搜索
|
// non-empty search
|
||||||
Keyword *string `thrift:"Keyword,6,optional" form:"keyword" json:"keyword,omitempty"`
|
Keyword *string `thrift:"Keyword,6,optional" form:"keyword" json:"keyword,omitempty"`
|
||||||
// 公开方式:1-开源;2-闭源 , // 公开方式
|
// Open mode: 1-open source; 2-closed source,//open mode
|
||||||
PublishMode *product_common.ProductPublishMode `thrift:"PublishMode,7,optional" form:"publish_mode" json:"publish_mode,omitempty"`
|
PublishMode *product_common.ProductPublishMode `thrift:"PublishMode,7,optional" form:"publish_mode" json:"publish_mode,omitempty"`
|
||||||
// 发布渠道
|
// publish platforms
|
||||||
PublishPlatformIDs []int64 `thrift:"PublishPlatformIDs,8,optional" form:"PublishPlatformIDs" json:"PublishPlatformIDs,string,omitempty" query:"PublishPlatformIDs"`
|
PublishPlatformIDs []int64 `thrift:"PublishPlatformIDs,8,optional" form:"PublishPlatformIDs" json:"PublishPlatformIDs,string,omitempty" query:"PublishPlatformIDs"`
|
||||||
// 列表页 tab; 1-运营推荐
|
// List tab; 1 - Operational recommendations
|
||||||
Source *product_common.ProductListSource `thrift:"Source,9,optional" form:"source" json:"source,omitempty"`
|
Source *product_common.ProductListSource `thrift:"Source,9,optional" form:"source" json:"source,omitempty"`
|
||||||
// 个性化推荐场景, 传入当前的实体信息, 获取推荐的商品
|
// Personalized recommendation scenarios, enter current entity information, and obtain recommended products
|
||||||
CurrentEntityType *product_common.ProductEntityType `thrift:"CurrentEntityType,10,optional" form:"current_entity_type" json:"current_entity_type,omitempty"`
|
CurrentEntityType *product_common.ProductEntityType `thrift:"CurrentEntityType,10,optional" form:"current_entity_type" json:"current_entity_type,omitempty"`
|
||||||
// 当前实体 ID
|
// Current entity ID
|
||||||
CurrentEntityID *int64 `thrift:"CurrentEntityID,11,optional" json:"CurrentEntityID,string,omitempty" query:"current_entity_id"`
|
CurrentEntityID *int64 `thrift:"CurrentEntityID,11,optional" json:"CurrentEntityID,string,omitempty" query:"current_entity_id"`
|
||||||
// 当前实体版本
|
// Current entity version
|
||||||
CurrentEntityVersion *int64 `thrift:"CurrentEntityVersion,12,optional" json:"CurrentEntityVersion,string,omitempty" query:"current_entity_version"`
|
CurrentEntityVersion *int64 `thrift:"CurrentEntityVersion,12,optional" json:"CurrentEntityVersion,string,omitempty" query:"current_entity_version"`
|
||||||
// 专题场景
|
// thematic scenario
|
||||||
TopicID *int64 `thrift:"TopicID,13,optional" json:"TopicID,string,omitempty" query:"topic_id"`
|
TopicID *int64 `thrift:"TopicID,13,optional" json:"TopicID,string,omitempty" query:"topic_id"`
|
||||||
PreviewTopicID *string `thrift:"PreviewTopicID,14,optional" form:"preview_topic_id" json:"preview_topic_id,omitempty"`
|
PreviewTopicID *string `thrift:"PreviewTopicID,14,optional" form:"preview_topic_id" json:"preview_topic_id,omitempty"`
|
||||||
// 是否需要过滤出官方商品
|
// Do you need to filter out official products?
|
||||||
IsOfficial *bool `thrift:"IsOfficial,15,optional" form:"is_official" json:"is_official,omitempty"`
|
IsOfficial *bool `thrift:"IsOfficial,15,optional" form:"is_official" json:"is_official,omitempty"`
|
||||||
// 是否需要返回额外信息
|
// Do you need to return additional information?
|
||||||
NeedExtra *bool `thrift:"NeedExtra,16,optional" form:"need_extra" json:"need_extra,omitempty"`
|
NeedExtra *bool `thrift:"NeedExtra,16,optional" form:"need_extra" json:"need_extra,omitempty"`
|
||||||
// 商品类型列表, 优先使用该参数,其次使用 EntityType
|
// List of product types, use this parameter first, followed by EntityType
|
||||||
EntityTypes []product_common.ProductEntityType `thrift:"EntityTypes,17,optional" form:"entity_types" json:"entity_types,omitempty"`
|
EntityTypes []product_common.ProductEntityType `thrift:"EntityTypes,17,optional" form:"entity_types" json:"entity_types,omitempty"`
|
||||||
// true = 筛选免费的;false = 筛选付费的;不传则不区分免费和付费
|
// True = filter for free; false = filter for paid; if you don't pass it, you won't distinguish between free and paid.
|
||||||
IsFree *bool `thrift:"IsFree,18,optional" form:"is_free" json:"is_free,omitempty"`
|
IsFree *bool `thrift:"IsFree,18,optional" form:"is_free" json:"is_free,omitempty"`
|
||||||
// 插件类型
|
// plugin type
|
||||||
PluginType *product_common.PluginType `thrift:"PluginType,19,optional" form:"plugin_type" json:"plugin_type,omitempty"`
|
PluginType *product_common.PluginType `thrift:"PluginType,19,optional" form:"plugin_type" json:"plugin_type,omitempty"`
|
||||||
ClientIP *string `thrift:"ClientIP,101,optional" header:"Tt-Agw-Client-Ip" json:"ClientIP,omitempty"`
|
ClientIP *string `thrift:"ClientIP,101,optional" header:"Tt-Agw-Client-Ip" json:"ClientIP,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -4175,44 +4175,44 @@ func (p *ProductLabel) String() string {
|
||||||
|
|
||||||
type ProductMetaInfo struct {
|
type ProductMetaInfo struct {
|
||||||
ID int64 `thrift:"ID,1" form:"id" json:"id,string"`
|
ID int64 `thrift:"ID,1" form:"id" json:"id,string"`
|
||||||
// 商品/模板名称
|
// Product/Template Name
|
||||||
Name string `thrift:"Name,2" form:"name" json:"name"`
|
Name string `thrift:"Name,2" form:"name" json:"name"`
|
||||||
// 素材 ID,由 entity_type 来决定是 bot/plugin 的ID
|
// Creature ID, determined by entity_type is the ID of the bot/plugin
|
||||||
EntityID int64 `thrift:"EntityID,3" form:"entity_id" json:"entity_id,string"`
|
EntityID int64 `thrift:"EntityID,3" form:"entity_id" json:"entity_id,string"`
|
||||||
// 商品素材类型
|
// Product material type
|
||||||
EntityType product_common.ProductEntityType `thrift:"EntityType,4" form:"entity_type" json:"entity_type"`
|
EntityType product_common.ProductEntityType `thrift:"EntityType,4" form:"entity_type" json:"entity_type"`
|
||||||
// 商品/模板头像
|
// Product/template avatar
|
||||||
IconURL string `thrift:"IconURL,5" form:"icon_url" json:"icon_url"`
|
IconURL string `thrift:"IconURL,5" form:"icon_url" json:"icon_url"`
|
||||||
// 热度:模板热度=复制量(用于卡片展示/排序);商品热度=不同商品有独立的计算逻辑(仅用于排序)—— heat的计算有一定延迟
|
// Heat: Template heat = copy volume (used for card display/sorting); product heat = different products have independent calculation logic (only used for sorting) - the calculation of heat has a certain delay
|
||||||
Heat int32 `thrift:"Heat,6" form:"heat" json:"heat"`
|
Heat int32 `thrift:"Heat,6" form:"heat" json:"heat"`
|
||||||
FavoriteCount int32 `thrift:"FavoriteCount,7" form:"favorite_count" json:"favorite_count"`
|
FavoriteCount int32 `thrift:"FavoriteCount,7" form:"favorite_count" json:"favorite_count"`
|
||||||
// 废弃,使用UserInfo代替
|
// Obsolete, use UserInfo instead
|
||||||
Seller *SellerInfo `thrift:"Seller,8" form:"seller" json:"seller"`
|
Seller *SellerInfo `thrift:"Seller,8" form:"seller" json:"seller"`
|
||||||
// 商品描述
|
// Product description
|
||||||
Description string `thrift:"Description,9" form:"description" json:"description"`
|
Description string `thrift:"Description,9" form:"description" json:"description"`
|
||||||
ListedAt int64 `thrift:"ListedAt,10" form:"listed_at" json:"listed_at,string"`
|
ListedAt int64 `thrift:"ListedAt,10" form:"listed_at" json:"listed_at,string"`
|
||||||
Status product_common.ProductStatus `thrift:"Status,11" form:"status" json:"status"`
|
Status product_common.ProductStatus `thrift:"Status,11" form:"status" json:"status"`
|
||||||
// 商品/模板分类信息
|
// Product/template classification information
|
||||||
Category *ProductCategory `thrift:"Category,12,optional" form:"category" json:"category,omitempty"`
|
Category *ProductCategory `thrift:"Category,12,optional" form:"category" json:"category,omitempty"`
|
||||||
// 是否收藏
|
// Whether to collect
|
||||||
IsFavorited bool `thrift:"IsFavorited,13" form:"is_favorited" json:"is_favorited"`
|
IsFavorited bool `thrift:"IsFavorited,13" form:"is_favorited" json:"is_favorited"`
|
||||||
IsFree bool `thrift:"IsFree,14" form:"is_free" json:"is_free"`
|
IsFree bool `thrift:"IsFree,14" form:"is_free" json:"is_free"`
|
||||||
// 模板介绍/插件介绍(目前是富文本格式)
|
// Template introduction/plugin introduction (currently in rich text format)
|
||||||
Readme string `thrift:"Readme,15" form:"readme" json:"readme"`
|
Readme string `thrift:"Readme,15" form:"readme" json:"readme"`
|
||||||
EntityVersion *int64 `thrift:"EntityVersion,16,optional" form:"entity_version" json:"entity_version,string,omitempty"`
|
EntityVersion *int64 `thrift:"EntityVersion,16,optional" form:"entity_version" json:"entity_version,string,omitempty"`
|
||||||
Labels []*ProductLabel `thrift:"Labels,17,optional" form:"labels" json:"labels,omitempty"`
|
Labels []*ProductLabel `thrift:"Labels,17,optional" form:"labels" json:"labels,omitempty"`
|
||||||
UserInfo *product_common.UserInfo `thrift:"UserInfo,18" form:"user_info" json:"user_info"`
|
UserInfo *product_common.UserInfo `thrift:"UserInfo,18" form:"user_info" json:"user_info"`
|
||||||
MediumIconURL string `thrift:"MediumIconURL,19" form:"medium_icon_url" json:"medium_icon_url"`
|
MediumIconURL string `thrift:"MediumIconURL,19" form:"medium_icon_url" json:"medium_icon_url"`
|
||||||
OriginIconURL string `thrift:"OriginIconURL,20" form:"origin_icon_url" json:"origin_icon_url"`
|
OriginIconURL string `thrift:"OriginIconURL,20" form:"origin_icon_url" json:"origin_icon_url"`
|
||||||
// 模板封面
|
// Template cover
|
||||||
Covers []*product_common.ImageInfo `thrift:"Covers,21,optional" form:"covers" json:"covers,omitempty"`
|
Covers []*product_common.ImageInfo `thrift:"Covers,21,optional" form:"covers" json:"covers,omitempty"`
|
||||||
// 是否专业版特供
|
// Is the professional version specially available?
|
||||||
IsProfessional *bool `thrift:"IsProfessional,22,optional" form:"is_professional" json:"is_professional,omitempty"`
|
IsProfessional *bool `thrift:"IsProfessional,22,optional" form:"is_professional" json:"is_professional,omitempty"`
|
||||||
// 是否为模板
|
// Is it a template?
|
||||||
IsTemplate bool `thrift:"IsTemplate,23" form:"is_template" json:"is_template"`
|
IsTemplate bool `thrift:"IsTemplate,23" form:"is_template" json:"is_template"`
|
||||||
// 是否官方商品
|
// Is it an official product?
|
||||||
IsOfficial bool `thrift:"IsOfficial,24" form:"is_official" json:"is_official"`
|
IsOfficial bool `thrift:"IsOfficial,24" form:"is_official" json:"is_official"`
|
||||||
// 价格,当前只有模板有
|
// Price, currently only available in the template.
|
||||||
Price *marketplace_common.Price `thrift:"Price,25,optional" form:"price" json:"price,omitempty"`
|
Price *marketplace_common.Price `thrift:"Price,25,optional" form:"price" json:"price,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5520,9 +5520,9 @@ func (p *ProductMetaInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UserBehaviorInfo struct {
|
type UserBehaviorInfo struct {
|
||||||
// 用户主页需要返回最近浏览/使用商品的时间
|
// The user homepage needs to return the most recently viewed/used product time.
|
||||||
ViewedAt *int64 `thrift:"ViewedAt,1,optional" form:"viewed_at" json:"viewed_at,string,omitempty"`
|
ViewedAt *int64 `thrift:"ViewedAt,1,optional" form:"viewed_at" json:"viewed_at,string,omitempty"`
|
||||||
// 最近使用时间戳
|
// Recently used timestamp
|
||||||
UsedAt *int64 `thrift:"UsedAt,2,optional" form:"used_at" json:"used_at,string,omitempty"`
|
UsedAt *int64 `thrift:"UsedAt,2,optional" form:"used_at" json:"used_at,string,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5731,18 +5731,18 @@ type PluginExtraInfo struct {
|
||||||
Tools []*PluginToolInfo `thrift:"Tools,1,optional" form:"tools" json:"tools,omitempty"`
|
Tools []*PluginToolInfo `thrift:"Tools,1,optional" form:"tools" json:"tools,omitempty"`
|
||||||
TotalAPICount int32 `thrift:"TotalAPICount,2" form:"total_api_count" json:"total_api_count"`
|
TotalAPICount int32 `thrift:"TotalAPICount,2" form:"total_api_count" json:"total_api_count"`
|
||||||
BotsUseCount int32 `thrift:"BotsUseCount,3" form:"bots_use_count" json:"bots_use_count"`
|
BotsUseCount int32 `thrift:"BotsUseCount,3" form:"bots_use_count" json:"bots_use_count"`
|
||||||
// 是否有隐私声明, 目前只有 PublicGetProductDetail 会取数据
|
// Is there a privacy statement, currently only PublicGetProductDetail will take the data
|
||||||
HasPrivacyStatement *bool `thrift:"HasPrivacyStatement,4,optional" form:"has_private_statement" json:"has_private_statement,omitempty"`
|
HasPrivacyStatement *bool `thrift:"HasPrivacyStatement,4,optional" form:"has_private_statement" json:"has_private_statement,omitempty"`
|
||||||
// 隐私声明, 目前只有 PublicGetProductDetail 会取数据
|
// Privacy statement, currently only PublicGetProductDetail will access data
|
||||||
PrivacyStatement *string `thrift:"PrivacyStatement,5,optional" form:"private_statement" json:"private_statement,omitempty"`
|
PrivacyStatement *string `thrift:"PrivacyStatement,5,optional" form:"private_statement" json:"private_statement,omitempty"`
|
||||||
AssociatedBotsUseCount int32 `thrift:"AssociatedBotsUseCount,6" form:"associated_bots_use_count" json:"associated_bots_use_count"`
|
AssociatedBotsUseCount int32 `thrift:"AssociatedBotsUseCount,6" form:"associated_bots_use_count" json:"associated_bots_use_count"`
|
||||||
IsPremium bool `thrift:"IsPremium,7" form:"is_premium" json:"is_premium"`
|
IsPremium bool `thrift:"IsPremium,7" form:"is_premium" json:"is_premium"`
|
||||||
IsOfficial bool `thrift:"IsOfficial,8" form:"is_official" json:"is_official"`
|
IsOfficial bool `thrift:"IsOfficial,8" form:"is_official" json:"is_official"`
|
||||||
// 调用量
|
// call amount
|
||||||
CallAmount *int32 `thrift:"CallAmount,9,optional" form:"call_amount" json:"call_amount,omitempty"`
|
CallAmount *int32 `thrift:"CallAmount,9,optional" form:"call_amount" json:"call_amount,omitempty"`
|
||||||
// 成功率
|
// success rate
|
||||||
SuccessRate *float64 `thrift:"SuccessRate,10,optional" form:"success_rate" json:"success_rate,omitempty"`
|
SuccessRate *float64 `thrift:"SuccessRate,10,optional" form:"success_rate" json:"success_rate,omitempty"`
|
||||||
// 平均执行时长
|
// average execution time
|
||||||
AvgExecTime *float64 `thrift:"AvgExecTime,11,optional" form:"avg_exec_time" json:"avg_exec_time,omitempty"`
|
AvgExecTime *float64 `thrift:"AvgExecTime,11,optional" form:"avg_exec_time" json:"avg_exec_time,omitempty"`
|
||||||
IsDefaultIcon *bool `thrift:"IsDefaultIcon,12,optional" form:"is_default_icon" json:"is_default_icon,omitempty"`
|
IsDefaultIcon *bool `thrift:"IsDefaultIcon,12,optional" form:"is_default_icon" json:"is_default_icon,omitempty"`
|
||||||
SpaceID *int64 `thrift:"SpaceID,13,optional" form:"space_id" json:"space_id,string,omitempty"`
|
SpaceID *int64 `thrift:"SpaceID,13,optional" form:"space_id" json:"space_id,string,omitempty"`
|
||||||
|
|
@ -7096,7 +7096,7 @@ func (p *ToolParameter) String() string {
|
||||||
|
|
||||||
type CardInfo struct {
|
type CardInfo struct {
|
||||||
CardURL string `thrift:"CardURL,1" form:"card_url" json:"card_url"`
|
CardURL string `thrift:"CardURL,1" form:"card_url" json:"card_url"`
|
||||||
// 以下只有详情页返回
|
// Only the details page returns
|
||||||
CardID int64 `thrift:"CardID,2" form:"card_id" json:"card_id,string"`
|
CardID int64 `thrift:"CardID,2" form:"card_id" json:"card_id,string"`
|
||||||
MappingRule string `thrift:"MappingRule,3" form:"MappingRule" json:"MappingRule" query:"MappingRule"`
|
MappingRule string `thrift:"MappingRule,3" form:"MappingRule" json:"MappingRule" query:"MappingRule"`
|
||||||
MaxDisplayRows int64 `thrift:"MaxDisplayRows,4" form:"max_display_rows" json:"max_display_rows,string"`
|
MaxDisplayRows int64 `thrift:"MaxDisplayRows,4" form:"max_display_rows" json:"max_display_rows,string"`
|
||||||
|
|
@ -7605,15 +7605,15 @@ type PluginToolInfo struct {
|
||||||
Parameters []*ToolParameter `thrift:"Parameters,4,optional" form:"parameters" json:"parameters,omitempty"`
|
Parameters []*ToolParameter `thrift:"Parameters,4,optional" form:"parameters" json:"parameters,omitempty"`
|
||||||
CardInfo *CardInfo `thrift:"CardInfo,5,optional" form:"card_info" json:"card_info,omitempty"`
|
CardInfo *CardInfo `thrift:"CardInfo,5,optional" form:"card_info" json:"card_info,omitempty"`
|
||||||
Example *PluginToolExample `thrift:"Example,6,optional" form:"example" json:"example,omitempty"`
|
Example *PluginToolExample `thrift:"Example,6,optional" form:"example" json:"example,omitempty"`
|
||||||
// 调用量
|
// call amount
|
||||||
CallAmount *int32 `thrift:"CallAmount,7,optional" form:"call_amount" json:"call_amount,omitempty"`
|
CallAmount *int32 `thrift:"CallAmount,7,optional" form:"call_amount" json:"call_amount,omitempty"`
|
||||||
// 成功率
|
// success rate
|
||||||
SuccessRate *float64 `thrift:"SuccessRate,8,optional" form:"success_rate" json:"success_rate,omitempty"`
|
SuccessRate *float64 `thrift:"SuccessRate,8,optional" form:"success_rate" json:"success_rate,omitempty"`
|
||||||
// 平均执行时长
|
// average execution time
|
||||||
AvgExecTime *float64 `thrift:"AvgExecTime,9,optional" form:"avg_exec_time" json:"avg_exec_time,omitempty"`
|
AvgExecTime *float64 `thrift:"AvgExecTime,9,optional" form:"avg_exec_time" json:"avg_exec_time,omitempty"`
|
||||||
// tool 被bot引用数
|
// Number of tool bot references
|
||||||
BotsUseCount *int32 `thrift:"BotsUseCount,10,optional" form:"bots_use_count" json:"bots_use_count,omitempty"`
|
BotsUseCount *int32 `thrift:"BotsUseCount,10,optional" form:"bots_use_count" json:"bots_use_count,omitempty"`
|
||||||
// 运行模式
|
// operating mode
|
||||||
RunMode *PluginRunMode `thrift:"RunMode,11,optional" form:"run_mode" json:"run_mode,omitempty"`
|
RunMode *PluginRunMode `thrift:"RunMode,11,optional" form:"run_mode" json:"run_mode,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -9347,9 +9347,9 @@ func (p *BotVoiceInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UserQueryCollectConf struct {
|
type UserQueryCollectConf struct {
|
||||||
// bot用户query收集配置
|
// Bot user query collection configuration
|
||||||
IsCollected bool `thrift:"IsCollected,1" form:"is_collected" json:"is_collected"`
|
IsCollected bool `thrift:"IsCollected,1" form:"is_collected" json:"is_collected"`
|
||||||
// 隐私协议链接
|
// Privacy Policy Link
|
||||||
PrivatePolicy string `thrift:"PrivatePolicy,2" form:"private_policy" json:"private_policy"`
|
PrivatePolicy string `thrift:"PrivatePolicy,2" form:"private_policy" json:"private_policy"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -9533,39 +9533,39 @@ func (p *UserQueryCollectConf) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BotConfig struct {
|
type BotConfig struct {
|
||||||
// 模型
|
// model
|
||||||
Models []*ProductMaterial `thrift:"Models,1,optional" form:"models" json:"models,omitempty"`
|
Models []*ProductMaterial `thrift:"Models,1,optional" form:"models" json:"models,omitempty"`
|
||||||
// 插件
|
// plugin
|
||||||
Plugins []*ProductMaterial `thrift:"Plugins,2,optional" form:"plugins" json:"plugins,omitempty"`
|
Plugins []*ProductMaterial `thrift:"Plugins,2,optional" form:"plugins" json:"plugins,omitempty"`
|
||||||
// 知识库
|
// Knowledge Base
|
||||||
Knowledges []*ProductMaterial `thrift:"Knowledges,3,optional" form:"knowledges" json:"knowledges,omitempty"`
|
Knowledges []*ProductMaterial `thrift:"Knowledges,3,optional" form:"knowledges" json:"knowledges,omitempty"`
|
||||||
// 工作流
|
// Workflow
|
||||||
Workflows []*ProductMaterial `thrift:"Workflows,4,optional" form:"workflows" json:"workflows,omitempty"`
|
Workflows []*ProductMaterial `thrift:"Workflows,4,optional" form:"workflows" json:"workflows,omitempty"`
|
||||||
// 私有插件数量
|
// number of private plugins
|
||||||
PrivatePluginsCount *int32 `thrift:"PrivatePluginsCount,5,optional" form:"private_plugins_count" json:"private_plugins_count,omitempty"`
|
PrivatePluginsCount *int32 `thrift:"PrivatePluginsCount,5,optional" form:"private_plugins_count" json:"private_plugins_count,omitempty"`
|
||||||
// 私有知识库数量
|
// Number of private repositories
|
||||||
PrivateKnowledgesCount *int32 `thrift:"PrivateKnowledgesCount,6,optional" form:"private_knowledges_count" json:"private_knowledges_count,omitempty"`
|
PrivateKnowledgesCount *int32 `thrift:"PrivateKnowledgesCount,6,optional" form:"private_knowledges_count" json:"private_knowledges_count,omitempty"`
|
||||||
// 私有工作流数量
|
// number of private workflows
|
||||||
PrivateWorkflowsCount *int32 `thrift:"PrivateWorkflowsCount,7,optional" form:"private_workflows_count" json:"private_workflows_count,omitempty"`
|
PrivateWorkflowsCount *int32 `thrift:"PrivateWorkflowsCount,7,optional" form:"private_workflows_count" json:"private_workflows_count,omitempty"`
|
||||||
// 判断 multiagent 是否有 bot 节点
|
// Determine if the multiagent has a bot node
|
||||||
HasBotAgent *bool `thrift:"HasBotAgent,8,optional" form:"has_bot_agent" json:"has_bot_agent,omitempty"`
|
HasBotAgent *bool `thrift:"HasBotAgent,8,optional" form:"has_bot_agent" json:"has_bot_agent,omitempty"`
|
||||||
// bot 配置的声音列表
|
// List of sounds configured by bot
|
||||||
BotVoices []*BotVoiceInfo `thrift:"BotVoices,9,optional" form:"bot_voices" json:"bot_voices,omitempty"`
|
BotVoices []*BotVoiceInfo `thrift:"BotVoices,9,optional" form:"bot_voices" json:"bot_voices,omitempty"`
|
||||||
// 所有插件数量
|
// Number of all plugins
|
||||||
TotalPluginsCount *int32 `thrift:"TotalPluginsCount,10,optional" form:"total_plugins_count" json:"total_plugins_count,omitempty"`
|
TotalPluginsCount *int32 `thrift:"TotalPluginsCount,10,optional" form:"total_plugins_count" json:"total_plugins_count,omitempty"`
|
||||||
// 所有知识库数量
|
// Number of all knowledge bases
|
||||||
TotalKnowledgesCount *int32 `thrift:"TotalKnowledgesCount,11,optional" form:"total_knowledges_count" json:"total_knowledges_count,omitempty"`
|
TotalKnowledgesCount *int32 `thrift:"TotalKnowledgesCount,11,optional" form:"total_knowledges_count" json:"total_knowledges_count,omitempty"`
|
||||||
// 所有工作流数量
|
// Number of all workflows
|
||||||
TotalWorkflowsCount *int32 `thrift:"TotalWorkflowsCount,12,optional" form:"total_workflows_count" json:"total_workflows_count,omitempty"`
|
TotalWorkflowsCount *int32 `thrift:"TotalWorkflowsCount,12,optional" form:"total_workflows_count" json:"total_workflows_count,omitempty"`
|
||||||
// 时间胶囊模式
|
// Time Capsule Mode
|
||||||
TimeCapsuleMode *TimeCapsuleMode `thrift:"TimeCapsuleMode,13,optional" form:"time_capsule_mode" json:"time_capsule_mode,omitempty"`
|
TimeCapsuleMode *TimeCapsuleMode `thrift:"TimeCapsuleMode,13,optional" form:"time_capsule_mode" json:"time_capsule_mode,omitempty"`
|
||||||
// 文件盒模式
|
// File box mode
|
||||||
FileboxMode *FileboxInfoMode `thrift:"FileboxMode,14,optional" form:"filebox_mode" json:"filebox_mode,omitempty"`
|
FileboxMode *FileboxInfoMode `thrift:"FileboxMode,14,optional" form:"filebox_mode" json:"filebox_mode,omitempty"`
|
||||||
// 私有图片工作流数量
|
// Number of private image workflows
|
||||||
PrivateImageWorkflowCount *int32 `thrift:"PrivateImageWorkflowCount,15,optional" form:"private_image_workflow_count" json:"private_image_workflow_count,omitempty"`
|
PrivateImageWorkflowCount *int32 `thrift:"PrivateImageWorkflowCount,15,optional" form:"private_image_workflow_count" json:"private_image_workflow_count,omitempty"`
|
||||||
// 用户qeury收集配置
|
// User qeury collection configuration
|
||||||
UserQueryCollectConf *UserQueryCollectConf `thrift:"UserQueryCollectConf,16,optional" form:"user_query_collect_conf" json:"user_query_collect_conf,omitempty"`
|
UserQueryCollectConf *UserQueryCollectConf `thrift:"UserQueryCollectConf,16,optional" form:"user_query_collect_conf" json:"user_query_collect_conf,omitempty"`
|
||||||
// 是否关闭语音通话(默认是打开)
|
// Whether to turn off voice calls (the default is on)
|
||||||
IsCloseVoiceCall *bool `thrift:"IsCloseVoiceCall,17,optional" form:"is_close_voice_call" json:"is_close_voice_call,omitempty"`
|
IsCloseVoiceCall *bool `thrift:"IsCloseVoiceCall,17,optional" form:"is_close_voice_call" json:"is_close_voice_call,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10694,7 +10694,7 @@ func (p *BotConfig) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 消息涉及的bot信息,在home分享场景,消息属于多个bot
|
// The bot information involved in the message, sharing the scene in the home, the message belongs to multiple bots
|
||||||
type ConversationRelateBot struct {
|
type ConversationRelateBot struct {
|
||||||
ID int64 `thrift:"ID,1" form:"id" json:"id,string"`
|
ID int64 `thrift:"ID,1" form:"id" json:"id,string"`
|
||||||
Name string `thrift:"Name,2" form:"name" json:"name"`
|
Name string `thrift:"Name,2" form:"name" json:"name"`
|
||||||
|
|
@ -10969,7 +10969,7 @@ func (p *ConversationRelateBot) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 消息涉及的user信息,在home分享场景,消息属于多个user
|
// The user information involved in the message, sharing the scene in the home, the message belongs to multiple users
|
||||||
type ConversationRelateUser struct {
|
type ConversationRelateUser struct {
|
||||||
UserInfo *product_common.UserInfo `thrift:"UserInfo,1,optional" form:"user_info" json:"user_info,omitempty"`
|
UserInfo *product_common.UserInfo `thrift:"UserInfo,1,optional" form:"user_info" json:"user_info,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
@ -11118,21 +11118,21 @@ func (p *ConversationRelateUser) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type Conversation struct {
|
type Conversation struct {
|
||||||
// 对话示例
|
// conversation example
|
||||||
Snippets []string `thrift:"Snippets,1,optional" form:"snippets" json:"snippets,omitempty"`
|
Snippets []string `thrift:"Snippets,1,optional" form:"snippets" json:"snippets,omitempty"`
|
||||||
// 对话标题
|
// conversation title
|
||||||
Title *string `thrift:"Title,2,optional" form:"title" json:"title,omitempty"`
|
Title *string `thrift:"Title,2,optional" form:"title" json:"title,omitempty"`
|
||||||
// 对话ID,idGen生成
|
// Conversation ID, generated by idGen
|
||||||
ID *int64 `thrift:"ID,3,optional" form:"id" json:"id,string,omitempty"`
|
ID *int64 `thrift:"ID,3,optional" form:"id" json:"id,string,omitempty"`
|
||||||
// 是否需要生成对话
|
// Do you need to generate a conversation?
|
||||||
GenTitle *bool `thrift:"GenTitle,4,optional" form:"gen_title" json:"gen_title,omitempty"`
|
GenTitle *bool `thrift:"GenTitle,4,optional" form:"gen_title" json:"gen_title,omitempty"`
|
||||||
// 对话审核状态
|
// conversation moderation status
|
||||||
AuditStatus *product_common.AuditStatus `thrift:"AuditStatus,5,optional" form:"audit_status" json:"audit_status,omitempty"`
|
AuditStatus *product_common.AuditStatus `thrift:"AuditStatus,5,optional" form:"audit_status" json:"audit_status,omitempty"`
|
||||||
// 开场白
|
// opening statement
|
||||||
OpeningDialog *product_common.OpeningDialog `thrift:"OpeningDialog,6,optional" form:"opening_dialog" json:"opening_dialog,omitempty"`
|
OpeningDialog *product_common.OpeningDialog `thrift:"OpeningDialog,6,optional" form:"opening_dialog" json:"opening_dialog,omitempty"`
|
||||||
// 消息涉及的bot信息,key bot_id
|
// The bot information involved in the message, key bot_id
|
||||||
RelateBots map[string]*ConversationRelateBot `thrift:"RelateBots,7,optional" form:"relate_bots" json:"relate_bots,omitempty"`
|
RelateBots map[string]*ConversationRelateBot `thrift:"RelateBots,7,optional" form:"relate_bots" json:"relate_bots,omitempty"`
|
||||||
// 消息涉及的user信息,key user_id
|
// The user information involved in the message, key user_id
|
||||||
RelateUsers map[string]*ConversationRelateUser `thrift:"RelateUsers,8,optional" form:"relate_users" json:"relate_users,omitempty"`
|
RelateUsers map[string]*ConversationRelateUser `thrift:"RelateUsers,8,optional" form:"relate_users" json:"relate_users,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -11744,25 +11744,25 @@ func (p *Conversation) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BotExtraInfo struct {
|
type BotExtraInfo struct {
|
||||||
// 发布渠道
|
// publish platforms
|
||||||
PublishPlatforms []*BotPublishPlatform `thrift:"PublishPlatforms,1" form:"publish_platforms" json:"publish_platforms"`
|
PublishPlatforms []*BotPublishPlatform `thrift:"PublishPlatforms,1" form:"publish_platforms" json:"publish_platforms"`
|
||||||
// 用户数
|
// user count
|
||||||
UserCount int32 `thrift:"UserCount,2" form:"user_count" json:"user_count"`
|
UserCount int32 `thrift:"UserCount,2" form:"user_count" json:"user_count"`
|
||||||
// 公开方式
|
// public method
|
||||||
PublishMode product_common.ProductPublishMode `thrift:"PublishMode,3" form:"publish_mode" json:"publish_mode"`
|
PublishMode product_common.ProductPublishMode `thrift:"PublishMode,3" form:"publish_mode" json:"publish_mode"`
|
||||||
// 详情页特有
|
// Details page unique
|
||||||
ConversationSnippets [][]string `thrift:"ConversationSnippets,4,optional" form:"conversation_snippets" json:"conversation_snippets,omitempty"`
|
ConversationSnippets [][]string `thrift:"ConversationSnippets,4,optional" form:"conversation_snippets" json:"conversation_snippets,omitempty"`
|
||||||
// 配置
|
// configuration
|
||||||
Config *BotConfig `thrift:"Config,5,optional" form:"config" json:"config,omitempty"`
|
Config *BotConfig `thrift:"Config,5,optional" form:"config" json:"config,omitempty"`
|
||||||
// 白名单
|
// whitelist
|
||||||
IsInhouseUser *bool `thrift:"IsInhouseUser,6,optional" form:"is_inhouse_user" json:"is_inhouse_user,omitempty"`
|
IsInhouseUser *bool `thrift:"IsInhouseUser,6,optional" form:"is_inhouse_user" json:"is_inhouse_user,omitempty"`
|
||||||
// 复制创建 bot 数量
|
// Number of copy-created bots
|
||||||
DuplicateBotCount *int32 `thrift:"DuplicateBotCount,7,optional" form:"duplicate_bot_count" json:"duplicate_bot_count,omitempty"`
|
DuplicateBotCount *int32 `thrift:"DuplicateBotCount,7,optional" form:"duplicate_bot_count" json:"duplicate_bot_count,omitempty"`
|
||||||
// 分享对话
|
// Share the conversation
|
||||||
Conversations []*Conversation `thrift:"Conversations,8,optional" form:"conversations" json:"conversations,omitempty"`
|
Conversations []*Conversation `thrift:"Conversations,8,optional" form:"conversations" json:"conversations,omitempty"`
|
||||||
// 与 Bot 聊天的对话数
|
// Number of conversations with Bot
|
||||||
ChatConversationCount *int64 `thrift:"ChatConversationCount,9,optional" form:"chat_conversation_count" json:"chat_conversation_count,string,omitempty"`
|
ChatConversationCount *int64 `thrift:"ChatConversationCount,9,optional" form:"chat_conversation_count" json:"chat_conversation_count,string,omitempty"`
|
||||||
// 关联商品数
|
// number of related products
|
||||||
RelatedProductCount *int64 `thrift:"RelatedProductCount,10,optional" form:"related_product_count" json:"related_product_count,string,omitempty"`
|
RelatedProductCount *int64 `thrift:"RelatedProductCount,10,optional" form:"related_product_count" json:"related_product_count,string,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -12457,22 +12457,22 @@ type WorkflowParameter struct {
|
||||||
IsRequired bool `thrift:"IsRequired,3" form:"is_required" json:"is_required"`
|
IsRequired bool `thrift:"IsRequired,3" form:"is_required" json:"is_required"`
|
||||||
InputType product_common.InputType `thrift:"InputType,4" form:"input_type" json:"input_type"`
|
InputType product_common.InputType `thrift:"InputType,4" form:"input_type" json:"input_type"`
|
||||||
SubParameters []*WorkflowParameter `thrift:"SubParameters,5" form:"sub_parameters" json:"sub_parameters"`
|
SubParameters []*WorkflowParameter `thrift:"SubParameters,5" form:"sub_parameters" json:"sub_parameters"`
|
||||||
// 如果Type是数组,则有subtype
|
// If Type is an array, there is a subtype
|
||||||
SubType product_common.InputType `thrift:"SubType,6" form:"sub_type" json:"sub_type"`
|
SubType product_common.InputType `thrift:"SubType,6" form:"sub_type" json:"sub_type"`
|
||||||
// 如果入参是用户手输 就放这里
|
// If the imported parameter is the user's hand input, put it here
|
||||||
Value *string `thrift:"Value,7,optional" form:"value" json:"value,omitempty"`
|
Value *string `thrift:"Value,7,optional" form:"value" json:"value,omitempty"`
|
||||||
Format *product_common.PluginParamTypeFormat `thrift:"Format,8,optional" form:"format" json:"format,omitempty"`
|
Format *product_common.PluginParamTypeFormat `thrift:"Format,8,optional" form:"format" json:"format,omitempty"`
|
||||||
FromNodeId *string `thrift:"FromNodeId,9,optional" form:"from_node_id" json:"from_node_id,omitempty"`
|
FromNodeId *string `thrift:"FromNodeId,9,optional" form:"from_node_id" json:"from_node_id,omitempty"`
|
||||||
FromOutput []string `thrift:"FromOutput,10,optional" form:"from_output" json:"from_output,omitempty"`
|
FromOutput []string `thrift:"FromOutput,10,optional" form:"from_output" json:"from_output,omitempty"`
|
||||||
// InputType (+ AssistType) 定义一个变量的最终类型,仅需透传
|
// InputType (+ AssistType) defines the final type of a variable, which only needs to be passed through
|
||||||
AssistType *int64 `thrift:"AssistType,11,optional" form:"assist_type" json:"assist_type,omitempty"`
|
AssistType *int64 `thrift:"AssistType,11,optional" form:"assist_type" json:"assist_type,omitempty"`
|
||||||
// 展示名称( store 独有的,用于详情页 GUI 展示参数)
|
// Display name (unique to the store, used for details page GUI display parameters)
|
||||||
ShowName *string `thrift:"ShowName,12,optional" form:"show_name" json:"show_name,omitempty"`
|
ShowName *string `thrift:"ShowName,12,optional" form:"show_name" json:"show_name,omitempty"`
|
||||||
// 如果InputType是数组,则有subassisttype
|
// If the InputType is an array, there is a subassistant type
|
||||||
SubAssistType *int64 `thrift:"SubAssistType,13,optional" form:"sub_assist_type" json:"sub_assist_type,omitempty"`
|
SubAssistType *int64 `thrift:"SubAssistType,13,optional" form:"sub_assist_type" json:"sub_assist_type,omitempty"`
|
||||||
// 组件配置,由前端解析并渲染
|
// Component configuration, parsed and rendered by the front end
|
||||||
ComponentConfig *string `thrift:"ComponentConfig,14,optional" form:"component_config" json:"component_config,omitempty"`
|
ComponentConfig *string `thrift:"ComponentConfig,14,optional" form:"component_config" json:"component_config,omitempty"`
|
||||||
// 组件配置类型,前端展示需要
|
// Component configuration type, required for front-end display
|
||||||
ComponentType *string `thrift:"ComponentType,15,optional" form:"component_type" json:"component_type,omitempty"`
|
ComponentType *string `thrift:"ComponentType,15,optional" form:"component_type" json:"component_type,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -13368,9 +13368,9 @@ func (p *WorkflowParameter) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type WorkflowTerminatePlan struct {
|
type WorkflowTerminatePlan struct {
|
||||||
// 对应 workflow 结束节点的回答模式:1-返回变量,由Bot生成回答;2-使用设定的内容直接回答
|
// The answer mode corresponding to the end node of the workflow: 1 - Return the variable, and the Bot generates the answer; 2 - Use the set content to answer directly
|
||||||
TerminatePlanType int32 `thrift:"TerminatePlanType,1" form:"terminate_plan_type" json:"terminate_plan_type"`
|
TerminatePlanType int32 `thrift:"TerminatePlanType,1" form:"terminate_plan_type" json:"terminate_plan_type"`
|
||||||
// 对应 terminate_plan_type = 2 的场景配置的返回内容
|
// Return content of scene configuration corresponding to terminate_plan_type = 2
|
||||||
Content string `thrift:"Content,2" form:"content" json:"content"`
|
Content string `thrift:"Content,2" form:"content" json:"content"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -13856,9 +13856,9 @@ type WorkflowNodeInfo struct {
|
||||||
NodeID string `thrift:"NodeID,1" form:"node_id" json:"node_id"`
|
NodeID string `thrift:"NodeID,1" form:"node_id" json:"node_id"`
|
||||||
NodeType product_common.WorkflowNodeType `thrift:"NodeType,2" form:"node_type" json:"node_type"`
|
NodeType product_common.WorkflowNodeType `thrift:"NodeType,2" form:"node_type" json:"node_type"`
|
||||||
NodeParam *WorkflowNodeParam `thrift:"NodeParam,3,optional" form:"node_param" json:"node_param,omitempty"`
|
NodeParam *WorkflowNodeParam `thrift:"NodeParam,3,optional" form:"node_param" json:"node_param,omitempty"`
|
||||||
// 节点icon
|
// Node icon
|
||||||
NodeIconURL string `thrift:"NodeIconURL,4" form:"node_icon_url" json:"node_icon_url"`
|
NodeIconURL string `thrift:"NodeIconURL,4" form:"node_icon_url" json:"node_icon_url"`
|
||||||
// 展示名称( store 独有的,用于详情页 GUI 展示消息节点的名称)
|
// Presentation name (unique to the store, the name used for the details page GUI display message node)
|
||||||
ShowName *string `thrift:"ShowName,5,optional" form:"show_name" json:"show_name,omitempty"`
|
ShowName *string `thrift:"ShowName,5,optional" form:"show_name" json:"show_name,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -14193,7 +14193,7 @@ func (p *WorkflowNodeInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type WorkflowEntity struct {
|
type WorkflowEntity struct {
|
||||||
// 商品ID
|
// Product ID
|
||||||
ProductID int64 `thrift:"ProductID,1" form:"product_id" json:"product_id,string"`
|
ProductID int64 `thrift:"ProductID,1" form:"product_id" json:"product_id,string"`
|
||||||
Name string `thrift:"Name,2" form:"name" json:"name"`
|
Name string `thrift:"Name,2" form:"name" json:"name"`
|
||||||
EntityID int64 `thrift:"EntityID,3" form:"entity_id" json:"entity_id,string"`
|
EntityID int64 `thrift:"EntityID,3" form:"entity_id" json:"entity_id,string"`
|
||||||
|
|
@ -14203,13 +14203,13 @@ type WorkflowEntity struct {
|
||||||
EntityName string `thrift:"EntityName,7" form:"entity_name" json:"entity_name"`
|
EntityName string `thrift:"EntityName,7" form:"entity_name" json:"entity_name"`
|
||||||
Readme string `thrift:"Readme,8" form:"readme" json:"readme"`
|
Readme string `thrift:"Readme,8" form:"readme" json:"readme"`
|
||||||
Category *ProductCategory `thrift:"Category,9" form:"category" json:"category"`
|
Category *ProductCategory `thrift:"Category,9" form:"category" json:"category"`
|
||||||
// 推荐分类 ,
|
// Recommended categories,
|
||||||
RecommendedCategory *ProductCategory `thrift:"RecommendedCategory,10,optional" form:"recommended_category" json:"recommended_category,omitempty"`
|
RecommendedCategory *ProductCategory `thrift:"RecommendedCategory,10,optional" form:"recommended_category" json:"recommended_category,omitempty"`
|
||||||
Nodes []*WorkflowNodeInfo `thrift:"Nodes,11,optional" form:"nodes" json:"nodes,omitempty"`
|
Nodes []*WorkflowNodeInfo `thrift:"Nodes,11,optional" form:"nodes" json:"nodes,omitempty"`
|
||||||
Desc string `thrift:"Desc,12" form:"desc" json:"desc"`
|
Desc string `thrift:"Desc,12" form:"desc" json:"desc"`
|
||||||
// 入参 图片icon
|
// Imported parameters Picture icon
|
||||||
CaseInputIconURL *string `thrift:"CaseInputIconURL,13,optional" form:"case_input_icon_url" json:"case_input_icon_url,omitempty"`
|
CaseInputIconURL *string `thrift:"CaseInputIconURL,13,optional" form:"case_input_icon_url" json:"case_input_icon_url,omitempty"`
|
||||||
// 出参 图片icon
|
// Exported parameters Image icon
|
||||||
CaseOutputIconURL *string `thrift:"CaseOutputIconURL,14,optional" form:"case_output_icon_url" json:"case_output_icon_url,omitempty"`
|
CaseOutputIconURL *string `thrift:"CaseOutputIconURL,14,optional" form:"case_output_icon_url" json:"case_output_icon_url,omitempty"`
|
||||||
LatestPublishCommitID *string `thrift:"LatestPublishCommitID,15,optional" form:"latest_publish_commit_id" json:"latest_publish_commit_id,omitempty"`
|
LatestPublishCommitID *string `thrift:"LatestPublishCommitID,15,optional" form:"latest_publish_commit_id" json:"latest_publish_commit_id,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
@ -15044,10 +15044,10 @@ func (p *WorkflowEntity) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type WorkflowGUIConfig struct {
|
type WorkflowGUIConfig struct {
|
||||||
// 用于将 workflow 的输入/输出/中间消息节点节点转为用户可视化配置
|
// Used to convert the input/output/intermediate message node of a workflow into a user visual configuration
|
||||||
StartNode *WorkflowNodeInfo `thrift:"StartNode,1" form:"start_node" json:"start_node"`
|
StartNode *WorkflowNodeInfo `thrift:"StartNode,1" form:"start_node" json:"start_node"`
|
||||||
EndNode *WorkflowNodeInfo `thrift:"EndNode,2" form:"end_node" json:"end_node"`
|
EndNode *WorkflowNodeInfo `thrift:"EndNode,2" form:"end_node" json:"end_node"`
|
||||||
// 消息节点会输出中间过程,也需要展示
|
// The message node will output the intermediate process, which also needs to be displayed.
|
||||||
MessageNodes []*WorkflowNodeInfo `thrift:"MessageNodes,3,optional" form:"message_nodes" json:"message_nodes,omitempty"`
|
MessageNodes []*WorkflowNodeInfo `thrift:"MessageNodes,3,optional" form:"message_nodes" json:"message_nodes,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -15320,25 +15320,25 @@ func (p *WorkflowGUIConfig) String() string {
|
||||||
type WorkflowExtraInfo struct {
|
type WorkflowExtraInfo struct {
|
||||||
RelatedWorkflows []*WorkflowEntity `thrift:"RelatedWorkflows,1" form:"related_workflows" json:"related_workflows"`
|
RelatedWorkflows []*WorkflowEntity `thrift:"RelatedWorkflows,1" form:"related_workflows" json:"related_workflows"`
|
||||||
DuplicateCount *int32 `thrift:"DuplicateCount,2,optional" form:"duplicate_count" json:"duplicate_count,omitempty"`
|
DuplicateCount *int32 `thrift:"DuplicateCount,2,optional" form:"duplicate_count" json:"duplicate_count,omitempty"`
|
||||||
// workflow画布信息
|
// Workflow canvas information
|
||||||
WorkflowSchema *string `thrift:"WorkflowSchema,3,optional" form:"workflow_schema" json:"workflow_schema,omitempty"`
|
WorkflowSchema *string `thrift:"WorkflowSchema,3,optional" form:"workflow_schema" json:"workflow_schema,omitempty"`
|
||||||
// /api/workflowV2/query schema_json
|
// /api/workflowV2/query schema_json
|
||||||
RecommendedCategory *ProductCategory `thrift:"RecommendedCategory,4,optional" form:"recommended_category" json:"recommended_category,omitempty"`
|
RecommendedCategory *ProductCategory `thrift:"RecommendedCategory,4,optional" form:"recommended_category" json:"recommended_category,omitempty"`
|
||||||
Nodes []*WorkflowNodeInfo `thrift:"Nodes,5,optional" form:"nodes" json:"nodes,omitempty"`
|
Nodes []*WorkflowNodeInfo `thrift:"Nodes,5,optional" form:"nodes" json:"nodes,omitempty"`
|
||||||
StartNode *WorkflowNodeInfo `thrift:"StartNode,6,optional" form:"start_node" json:"start_node,omitempty"`
|
StartNode *WorkflowNodeInfo `thrift:"StartNode,6,optional" form:"start_node" json:"start_node,omitempty"`
|
||||||
// 实体名称(用于展示)
|
// Entity name (for presentation)
|
||||||
EntityName *string `thrift:"EntityName,7,optional" form:"entity_name" json:"entity_name,omitempty"`
|
EntityName *string `thrift:"EntityName,7,optional" form:"entity_name" json:"entity_name,omitempty"`
|
||||||
// 用例图入参
|
// Use case diagrams imported parameters
|
||||||
CaseInputIconURL *string `thrift:"CaseInputIconURL,8,optional" form:"case_input_icon_url" json:"case_input_icon_url,omitempty"`
|
CaseInputIconURL *string `thrift:"CaseInputIconURL,8,optional" form:"case_input_icon_url" json:"case_input_icon_url,omitempty"`
|
||||||
// 用例图出参
|
// Use case diagram exported parameters
|
||||||
CaseOutputIconURL *string `thrift:"CaseOutputIconURL,9,optional" form:"case_output_icon_url" json:"case_output_icon_url,omitempty"`
|
CaseOutputIconURL *string `thrift:"CaseOutputIconURL,9,optional" form:"case_output_icon_url" json:"case_output_icon_url,omitempty"`
|
||||||
// 案例执行ID
|
// case execution ID
|
||||||
CaseExecuteID *int64 `thrift:"CaseExecuteID,10,optional" form:"case_execute_id" json:"case_execute_id,string,omitempty"`
|
CaseExecuteID *int64 `thrift:"CaseExecuteID,10,optional" form:"case_execute_id" json:"case_execute_id,string,omitempty"`
|
||||||
HoverText *string `thrift:"HoverText,11,optional" form:"hover_text" json:"hover_text,omitempty"`
|
HoverText *string `thrift:"HoverText,11,optional" form:"hover_text" json:"hover_text,omitempty"`
|
||||||
LatestPublishCommitID *string `thrift:"LatestPublishCommitID,12,optional" form:"latest_publish_commit_id" json:"latest_publish_commit_id,omitempty"`
|
LatestPublishCommitID *string `thrift:"LatestPublishCommitID,12,optional" form:"latest_publish_commit_id" json:"latest_publish_commit_id,omitempty"`
|
||||||
// 试运行次数,从数仓取
|
// Practice running times, take from the number of warehouses
|
||||||
UsedCount *int32 `thrift:"UsedCount,13,optional" form:"used_count" json:"used_count,omitempty"`
|
UsedCount *int32 `thrift:"UsedCount,13,optional" form:"used_count" json:"used_count,omitempty"`
|
||||||
// 用于将 workflow 的输入/输出/中间消息节点节点转为用户可视化配置
|
// Used to convert the input/output/intermediate message node of a workflow into a user visual configuration
|
||||||
GUIConfig *WorkflowGUIConfig `thrift:"GUIConfig,14,optional" form:"gui_config" json:"gui_config,omitempty"`
|
GUIConfig *WorkflowGUIConfig `thrift:"GUIConfig,14,optional" form:"gui_config" json:"gui_config,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -16453,13 +16453,13 @@ func (p *SocialScenePlayerInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SocialSceneExtraInfo struct {
|
type SocialSceneExtraInfo struct {
|
||||||
// 角色
|
// role
|
||||||
Players []*SocialScenePlayerInfo `thrift:"Players,1,optional" form:"players" json:"players,omitempty"`
|
Players []*SocialScenePlayerInfo `thrift:"Players,1,optional" form:"players" json:"players,omitempty"`
|
||||||
// 使用过的人数
|
// Number of people used
|
||||||
UsedCount int64 `thrift:"UsedCount,2" form:"used_count" json:"used_count,string"`
|
UsedCount int64 `thrift:"UsedCount,2" form:"used_count" json:"used_count,string"`
|
||||||
// 开始过的次数
|
// number of times started
|
||||||
StartedCount int64 `thrift:"StartedCount,3" form:"started_count" json:"started_count,string"`
|
StartedCount int64 `thrift:"StartedCount,3" form:"started_count" json:"started_count,string"`
|
||||||
// 开闭源
|
// publish_mode
|
||||||
PublishMode product_common.ProductPublishMode `thrift:"PublishMode,4" form:"publish_mode" json:"publish_mode"`
|
PublishMode product_common.ProductPublishMode `thrift:"PublishMode,4" form:"publish_mode" json:"publish_mode"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -16762,13 +16762,13 @@ func (p *SocialSceneExtraInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ProjectConfig struct {
|
type ProjectConfig struct {
|
||||||
// 插件数量
|
// number of plugins
|
||||||
PluginCount int32 `thrift:"PluginCount,1" form:"plugin_count" json:"plugin_count"`
|
PluginCount int32 `thrift:"PluginCount,1" form:"plugin_count" json:"plugin_count"`
|
||||||
// 工作流数量
|
// number of workflows
|
||||||
WorkflowCount int32 `thrift:"WorkflowCount,2" form:"workflow_count" json:"workflow_count"`
|
WorkflowCount int32 `thrift:"WorkflowCount,2" form:"workflow_count" json:"workflow_count"`
|
||||||
// 知识库数量
|
// Number of knowledge bases
|
||||||
KnowledgeCount int32 `thrift:"KnowledgeCount,3" form:"knowledge_count" json:"knowledge_count"`
|
KnowledgeCount int32 `thrift:"KnowledgeCount,3" form:"knowledge_count" json:"knowledge_count"`
|
||||||
// 数据库数量
|
// Number of databases
|
||||||
DatabaseCount int32 `thrift:"DatabaseCount,4" form:"database_count" json:"database_count"`
|
DatabaseCount int32 `thrift:"DatabaseCount,4" form:"database_count" json:"database_count"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -17040,20 +17040,20 @@ func (p *ProjectConfig) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ProjectExtraInfo struct {
|
type ProjectExtraInfo struct {
|
||||||
// Project 上架为模板前生成一个模板副本,使用或者复制模板,需要用 TemplateProjectID 和 TemplateProjectVersion
|
// Generate a copy of the template before Project is put on the shelves. To use or copy the template, you need to use TemplateProjectID and TemplateProjectVersion
|
||||||
TemplateProjectID int64 `thrift:"TemplateProjectID,1" form:"template_project_id" json:"template_project_id,string"`
|
TemplateProjectID int64 `thrift:"TemplateProjectID,1" form:"template_project_id" json:"template_project_id,string"`
|
||||||
TemplateProjectVersion int64 `thrift:"TemplateProjectVersion,2" form:"template_project_version" json:"template_project_version,string"`
|
TemplateProjectVersion int64 `thrift:"TemplateProjectVersion,2" form:"template_project_version" json:"template_project_version,string"`
|
||||||
// Project 绑定的 UI 支持的预览类型
|
// Project-bound UI supported preview types
|
||||||
PreviewTypes []product_common.UIPreviewType `thrift:"PreviewTypes,3" form:"preview_types" json:"preview_types"`
|
PreviewTypes []product_common.UIPreviewType `thrift:"PreviewTypes,3" form:"preview_types" json:"preview_types"`
|
||||||
// 用户数
|
// user count
|
||||||
UserCount int32 `thrift:"UserCount,4" form:"user_count" json:"user_count"`
|
UserCount int32 `thrift:"UserCount,4" form:"user_count" json:"user_count"`
|
||||||
// 运行数
|
// number of runs
|
||||||
ExecuteCount int32 `thrift:"ExecuteCount,5" form:"execute_count" json:"execute_count"`
|
ExecuteCount int32 `thrift:"ExecuteCount,5" form:"execute_count" json:"execute_count"`
|
||||||
// 发布渠道
|
// publish platforms
|
||||||
PublishPlatforms []*BotPublishPlatform `thrift:"PublishPlatforms,6" form:"publish_platforms" json:"publish_platforms"`
|
PublishPlatforms []*BotPublishPlatform `thrift:"PublishPlatforms,6" form:"publish_platforms" json:"publish_platforms"`
|
||||||
// 近实时复制量,从数仓接口获取(复制 - 上报埋点 - 数仓计算落库)
|
// Near real-time copy volume, obtained from the data warehouse interface (copy-report event tracking-data warehouse calculation drop library)
|
||||||
DupliacateCount int32 `thrift:"DupliacateCount,7" form:"duplicate_count" json:"duplicate_count"`
|
DupliacateCount int32 `thrift:"DupliacateCount,7" form:"duplicate_count" json:"duplicate_count"`
|
||||||
// 配置
|
// configuration
|
||||||
Config *ProjectConfig `thrift:"Config,8,optional" form:"config" json:"config,omitempty"`
|
Config *ProjectConfig `thrift:"Config,8,optional" form:"config" json:"config,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -17552,7 +17552,7 @@ type GetProductDetailRequest struct {
|
||||||
ProductID *int64 `thrift:"ProductID,1,optional" json:"ProductID,string,omitempty" query:"product_id"`
|
ProductID *int64 `thrift:"ProductID,1,optional" json:"ProductID,string,omitempty" query:"product_id"`
|
||||||
EntityType *product_common.ProductEntityType `thrift:"EntityType,2,optional" form:"entity_type" json:"entity_type,omitempty"`
|
EntityType *product_common.ProductEntityType `thrift:"EntityType,2,optional" form:"entity_type" json:"entity_type,omitempty"`
|
||||||
EntityID *int64 `thrift:"EntityID,3,optional" json:"EntityID,string,omitempty" query:"entity_id"`
|
EntityID *int64 `thrift:"EntityID,3,optional" json:"EntityID,string,omitempty" query:"entity_id"`
|
||||||
// 是否查看最新的审核失败草稿
|
// Whether to check the latest audit failure draft
|
||||||
NeedAuditFailed *bool `thrift:"NeedAuditFailed,4,optional" form:"need_audit_failed" json:"need_audit_failed,omitempty"`
|
NeedAuditFailed *bool `thrift:"NeedAuditFailed,4,optional" form:"need_audit_failed" json:"need_audit_failed,omitempty"`
|
||||||
ClientIP *string `thrift:"ClientIP,101,optional" header:"Tt-Agw-Client-Ip" json:"ClientIP,omitempty"`
|
ClientIP *string `thrift:"ClientIP,101,optional" header:"Tt-Agw-Client-Ip" json:"ClientIP,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -18511,7 +18511,7 @@ func (p *Price) String() string {
|
||||||
|
|
||||||
type SKUInfo struct {
|
type SKUInfo struct {
|
||||||
ID int64 `thrift:"ID,1" form:"id" json:"id,string"`
|
ID int64 `thrift:"ID,1" form:"id" json:"id,string"`
|
||||||
// 待废弃
|
// to be abandoned
|
||||||
Price []*Price `thrift:"Price,2" form:"price" json:"price"`
|
Price []*Price `thrift:"Price,2" form:"price" json:"price"`
|
||||||
Description string `thrift:"Description,3" form:"description" json:"description"`
|
Description string `thrift:"Description,3" form:"description" json:"description"`
|
||||||
PriceV2 []*marketplace_common.Price `thrift:"PriceV2,4" form:"price_v2" json:"price_v2"`
|
PriceV2 []*marketplace_common.Price `thrift:"PriceV2,4" form:"price_v2" json:"price_v2"`
|
||||||
|
|
@ -19313,7 +19313,7 @@ func (p *SellAttr) String() string {
|
||||||
type SellInfo struct {
|
type SellInfo struct {
|
||||||
SKUs map[int64]*SKUInfo `thrift:"SKUs,1" form:"skus" json:"skus,string"`
|
SKUs map[int64]*SKUInfo `thrift:"SKUs,1" form:"skus" json:"skus,string"`
|
||||||
Attr []*SellAttr `thrift:"Attr,2" form:"attr" json:"attr"`
|
Attr []*SellAttr `thrift:"Attr,2" form:"attr" json:"attr"`
|
||||||
// Key 是 attrkey:attrvalue 路径,value 是 skuID
|
// Key is attrkey: attrvalue path, value is skuID
|
||||||
SKUAttrRef map[string]int64 `thrift:"SKUAttrRef,3" form:"sku_attr_ref" json:"sku_attr_ref,string"`
|
SKUAttrRef map[string]int64 `thrift:"SKUAttrRef,3" form:"sku_attr_ref" json:"sku_attr_ref,string"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -19623,12 +19623,12 @@ type Topic struct {
|
||||||
Name string `thrift:"Name,2" form:"name" json:"name"`
|
Name string `thrift:"Name,2" form:"name" json:"name"`
|
||||||
Description string `thrift:"Description,3" form:"description" json:"description"`
|
Description string `thrift:"Description,3" form:"description" json:"description"`
|
||||||
BannerURL string `thrift:"BannerURL,4" form:"banner_url" json:"banner_url"`
|
BannerURL string `thrift:"BannerURL,4" form:"banner_url" json:"banner_url"`
|
||||||
// 背景小图,前端优先加载
|
// Small background image, front-end priority loading
|
||||||
BannerURLSmall string `thrift:"BannerURLSmall,5" form:"banner_url_small" json:"banner_url_small"`
|
BannerURLSmall string `thrift:"BannerURLSmall,5" form:"banner_url_small" json:"banner_url_small"`
|
||||||
Reason string `thrift:"Reason,6" form:"reason" json:"reason"`
|
Reason string `thrift:"Reason,6" form:"reason" json:"reason"`
|
||||||
// 运营提供的专题介绍文档,用户可见
|
// The presentation document provided by the operation is visible to users
|
||||||
IntroductionURL string `thrift:"IntroductionURL,7" form:"introduction_url" json:"introduction_url"`
|
IntroductionURL string `thrift:"IntroductionURL,7" form:"introduction_url" json:"introduction_url"`
|
||||||
// 用户是否收藏专题
|
// Does the user collect the topic?
|
||||||
IsFavorite bool `thrift:"IsFavorite,8" form:"is_favorite" json:"is_favorite"`
|
IsFavorite bool `thrift:"IsFavorite,8" form:"is_favorite" json:"is_favorite"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -20076,7 +20076,7 @@ func (p *Topic) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ProductDataIndicator struct {
|
type ProductDataIndicator struct {
|
||||||
// 数据分析指标,来源数仓,比如模板购买量、复制量等
|
// Data analytics metrics, source number, such as template purchases, replicas, etc
|
||||||
PurchaseCount *int32 `thrift:"PurchaseCount,1,optional" form:"purchase_count" json:"purchase_count,omitempty"`
|
PurchaseCount *int32 `thrift:"PurchaseCount,1,optional" form:"purchase_count" json:"purchase_count,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -20227,17 +20227,17 @@ func (p *ProductDataIndicator) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetProductDetailData struct {
|
type GetProductDetailData struct {
|
||||||
// 下架的商品只返回非 optional 字段
|
// Products removed from the shelves only return non-optional fields
|
||||||
MetaInfo *ProductMetaInfo `thrift:"MetaInfo,1,required" form:"meta_info,required" json:"meta_info,required"`
|
MetaInfo *ProductMetaInfo `thrift:"MetaInfo,1,required" form:"meta_info,required" json:"meta_info,required"`
|
||||||
// 用以区分主/客态
|
// To distinguish between host and guest states
|
||||||
IsOwner bool `thrift:"IsOwner,2,required" form:"is_owner,required" json:"is_owner,required"`
|
IsOwner bool `thrift:"IsOwner,2,required" form:"is_owner,required" json:"is_owner,required"`
|
||||||
// 审核状态,主态下返回需要关注,如果主态且审核中,需要展示审核中状态
|
// Audit status, return in the main state, you need to pay attention. If the main state is under review, you need to show the status under review.
|
||||||
AuditStatus product_common.ProductDraftStatus `thrift:"AuditStatus,3" form:"audit_status" json:"audit_status"`
|
AuditStatus product_common.ProductDraftStatus `thrift:"AuditStatus,3" form:"audit_status" json:"audit_status"`
|
||||||
SellInfo *SellInfo `thrift:"SellInfo,4,optional" form:"sell_info" json:"sell_info,omitempty"`
|
SellInfo *SellInfo `thrift:"SellInfo,4,optional" form:"sell_info" json:"sell_info,omitempty"`
|
||||||
SpaceID *int64 `thrift:"SpaceID,5,optional" form:"space_id" json:"space_id,string,omitempty"`
|
SpaceID *int64 `thrift:"SpaceID,5,optional" form:"space_id" json:"space_id,string,omitempty"`
|
||||||
// 详情页返回
|
// Details page Back
|
||||||
Topic *Topic `thrift:"Topic,6,optional" form:"topic" json:"topic,omitempty"`
|
Topic *Topic `thrift:"Topic,6,optional" form:"topic" json:"topic,omitempty"`
|
||||||
// 详情页返回
|
// Details page Back
|
||||||
CanDuplicate *bool `thrift:"CanDuplicate,7,optional" form:"can_duplicate" json:"can_duplicate,omitempty"`
|
CanDuplicate *bool `thrift:"CanDuplicate,7,optional" form:"can_duplicate" json:"can_duplicate,omitempty"`
|
||||||
CommercialSetting *product_common.CommercialSetting `thrift:"CommercialSetting,8,optional" form:"commercial_setting" json:"commercial_setting,omitempty"`
|
CommercialSetting *product_common.CommercialSetting `thrift:"CommercialSetting,8,optional" form:"commercial_setting" json:"commercial_setting,omitempty"`
|
||||||
PluginExtra *PluginExtraInfo `thrift:"PluginExtra,20,optional" form:"plugin_extra" json:"plugin_extra,omitempty"`
|
PluginExtra *PluginExtraInfo `thrift:"PluginExtra,20,optional" form:"plugin_extra" json:"plugin_extra,omitempty"`
|
||||||
|
|
@ -21071,23 +21071,23 @@ func (p *GetProductDetailData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetUserFavoriteListV2Request struct {
|
type GetUserFavoriteListV2Request struct {
|
||||||
// 第一页不传,后续调用时传上一次返回的cursor_id
|
// The first page is not passed, and the last returned cursor_id is passed when subsequent calls are made
|
||||||
CursorID *string `thrift:"CursorID,1,optional" json:"CursorID,omitempty" query:"cursor_id"`
|
CursorID *string `thrift:"CursorID,1,optional" json:"CursorID,omitempty" query:"cursor_id"`
|
||||||
PageSize int32 `thrift:"PageSize,2,required" json:"PageSize,required" query:"page_size,required"`
|
PageSize int32 `thrift:"PageSize,2,required" json:"PageSize,required" query:"page_size,required"`
|
||||||
EntityType *product_common.ProductEntityType `thrift:"EntityType,3,optional" json:"EntityType,omitempty" query:"entity_type"`
|
EntityType *product_common.ProductEntityType `thrift:"EntityType,3,optional" json:"EntityType,omitempty" query:"entity_type"`
|
||||||
SortType product_common.SortType `thrift:"SortType,4,required" json:"SortType,required" query:"sort_type,required"`
|
SortType product_common.SortType `thrift:"SortType,4,required" json:"SortType,required" query:"sort_type,required"`
|
||||||
// 不为空则搜索
|
// Search keyword,optional
|
||||||
Keyword *string `thrift:"Keyword,5,optional" json:"Keyword,omitempty" query:"keyword"`
|
Keyword *string `thrift:"Keyword,5,optional" json:"Keyword,omitempty" query:"keyword"`
|
||||||
// 列表页 tab
|
// List page tab
|
||||||
Source *product_common.FavoriteListSource `thrift:"Source,6,optional" json:"Source,omitempty" query:"source"`
|
Source *product_common.FavoriteListSource `thrift:"Source,6,optional" json:"Source,omitempty" query:"source"`
|
||||||
// 是否需要查询用户对Bot的触发器配置,为true时,才会返回EntityUserTriggerConfig
|
// Whether you need to query the user's trigger configuration for the Bot, when true, it will return EntityUserTriggerConfig
|
||||||
NeedUserTriggerConfig *bool `thrift:"NeedUserTriggerConfig,7,optional" json:"NeedUserTriggerConfig,omitempty" query:"need_user_trigger_config"`
|
NeedUserTriggerConfig *bool `thrift:"NeedUserTriggerConfig,7,optional" json:"NeedUserTriggerConfig,omitempty" query:"need_user_trigger_config"`
|
||||||
// 筛选收藏时间
|
// Filter collection time
|
||||||
BeginAt *int64 `thrift:"BeginAt,8,optional" json:"BeginAt,string,omitempty" query:"begin_at"`
|
BeginAt *int64 `thrift:"BeginAt,8,optional" json:"BeginAt,string,omitempty" query:"begin_at"`
|
||||||
// 筛选收藏时间
|
// Filter collection time
|
||||||
EndAt *int64 `thrift:"EndAt,9,optional" json:"EndAt,string,omitempty" query:"end_at"`
|
EndAt *int64 `thrift:"EndAt,9,optional" json:"EndAt,string,omitempty" query:"end_at"`
|
||||||
EntityTypes []product_common.ProductEntityType `thrift:"EntityTypes,10,optional" json:"EntityTypes,omitempty" query:"entity_types"`
|
EntityTypes []product_common.ProductEntityType `thrift:"EntityTypes,10,optional" json:"EntityTypes,omitempty" query:"entity_types"`
|
||||||
// 组织ID,企业版想获取用户收藏的所有内容时需传递
|
// Organization ID, Enterprise Edition needs to be passed when you want to get all the content in the user's collection
|
||||||
OrganizationID *int64 `thrift:"OrganizationID,11,optional" json:"OrganizationID,omitempty" query:"organization_id"`
|
OrganizationID *int64 `thrift:"OrganizationID,11,optional" json:"OrganizationID,omitempty" query:"organization_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -22164,7 +22164,7 @@ type GetUserFavoriteListDataV2 struct {
|
||||||
FavoriteEntities []*product_common.FavoriteEntity `thrift:"FavoriteEntities,1" form:"favorite_entities" json:"favorite_entities"`
|
FavoriteEntities []*product_common.FavoriteEntity `thrift:"FavoriteEntities,1" form:"favorite_entities" json:"favorite_entities"`
|
||||||
CursorID string `thrift:"CursorID,2" form:"cursor_id" json:"cursor_id"`
|
CursorID string `thrift:"CursorID,2" form:"cursor_id" json:"cursor_id"`
|
||||||
HasMore bool `thrift:"HasMore,3" form:"has_more" json:"has_more"`
|
HasMore bool `thrift:"HasMore,3" form:"has_more" json:"has_more"`
|
||||||
// 用户定时任务配置,对应flow.bot.task服务的TriggerEnabled
|
// User timed task configuration, corresponding to flow.bot TriggerEnabled of the task service
|
||||||
EntityUserTriggerConfig map[int64]*UserTriggerConfig `thrift:"EntityUserTriggerConfig,4" form:"entity_user_trigger_config" json:"entity_user_trigger_config"`
|
EntityUserTriggerConfig map[int64]*UserTriggerConfig `thrift:"EntityUserTriggerConfig,4" form:"entity_user_trigger_config" json:"entity_user_trigger_config"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -23347,9 +23347,9 @@ func (p *DuplicateProductResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type DuplicateProductData struct {
|
type DuplicateProductData struct {
|
||||||
// 复制后的新id
|
// New ID after copy
|
||||||
NewEntityID int64 `thrift:"NewEntityID,1" form:"new_entity_id" json:"new_entity_id,string"`
|
NewEntityID int64 `thrift:"NewEntityID,1" form:"new_entity_id" json:"new_entity_id,string"`
|
||||||
// workflow对应的插件id
|
// Plugin ID for workflow
|
||||||
NewPluginID *int64 `thrift:"NewPluginID,2,optional" form:"new_plugin_id" json:"new_plugin_id,string,omitempty"`
|
NewPluginID *int64 `thrift:"NewPluginID,2,optional" form:"new_plugin_id" json:"new_plugin_id,string,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,11 +13,11 @@ import (
|
||||||
type AuditStatus int64
|
type AuditStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 审核中
|
// Under review.
|
||||||
AuditStatus_Auditing AuditStatus = 0
|
AuditStatus_Auditing AuditStatus = 0
|
||||||
// 审核通过
|
// approved
|
||||||
AuditStatus_Success AuditStatus = 1
|
AuditStatus_Success AuditStatus = 1
|
||||||
// 审核失败
|
// audit failed
|
||||||
AuditStatus_Failed AuditStatus = 2
|
AuditStatus_Failed AuditStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -225,11 +225,11 @@ func (p *OrderByType) Value() (driver.Value, error) {
|
||||||
type PermissionType int64
|
type PermissionType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
//不能查看详情
|
//Can't view details
|
||||||
PermissionType_NoDetail PermissionType = 1
|
PermissionType_NoDetail PermissionType = 1
|
||||||
//可以查看详情
|
//You can check the details.
|
||||||
PermissionType_Detail PermissionType = 2
|
PermissionType_Detail PermissionType = 2
|
||||||
//可以查看和操作
|
//Can be viewed and operated
|
||||||
PermissionType_Operate PermissionType = 3
|
PermissionType_Operate PermissionType = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -635,13 +635,13 @@ func (p *UserLabel) String() string {
|
||||||
|
|
||||||
type User struct {
|
type User struct {
|
||||||
UserID int64 `thrift:"user_id,1" form:"user_id" json:"user_id,string" query:"user_id"`
|
UserID int64 `thrift:"user_id,1" form:"user_id" json:"user_id,string" query:"user_id"`
|
||||||
// 用户昵称
|
// user nickname
|
||||||
Nickname string `thrift:"nickname,2" form:"nickname" json:"nickname" query:"nickname"`
|
Nickname string `thrift:"nickname,2" form:"nickname" json:"nickname" query:"nickname"`
|
||||||
// 用户头像
|
// user avatar
|
||||||
AvatarURL string `thrift:"avatar_url,3" form:"avatar_url" json:"avatar_url" query:"avatar_url"`
|
AvatarURL string `thrift:"avatar_url,3" form:"avatar_url" json:"avatar_url" query:"avatar_url"`
|
||||||
// 用户名
|
// user name
|
||||||
UserUniqueName string `thrift:"user_unique_name,4" form:"user_unique_name" json:"user_unique_name" query:"user_unique_name"`
|
UserUniqueName string `thrift:"user_unique_name,4" form:"user_unique_name" json:"user_unique_name" query:"user_unique_name"`
|
||||||
// 用户标签
|
// user tag
|
||||||
UserLabel *UserLabel `thrift:"user_label,5" form:"user_label" json:"user_label" query:"user_label"`
|
UserLabel *UserLabel `thrift:"user_label,5" form:"user_label" json:"user_label" query:"user_label"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1225,11 +1225,11 @@ func (p *AuditInfo) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 审核结果
|
// Audit results
|
||||||
type AuditData struct {
|
type AuditData struct {
|
||||||
// true:机审校验不通过
|
// True: The machine audit verification failed
|
||||||
CheckNotPass bool `thrift:"check_not_pass,1" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
CheckNotPass bool `thrift:"check_not_pass,1" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
||||||
// 机审校验不通过文案
|
// The machine audit verification failed the copy.
|
||||||
CheckNotPassMsg *string `thrift:"check_not_pass_msg,2,optional" form:"check_not_pass_msg" json:"check_not_pass_msg,omitempty" query:"check_not_pass_msg"`
|
CheckNotPassMsg *string `thrift:"check_not_pass_msg,2,optional" form:"check_not_pass_msg" json:"check_not_pass_msg,omitempty" query:"check_not_pass_msg"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -15,11 +15,11 @@ const (
|
||||||
IntelligenceStatus_Using IntelligenceStatus = 1
|
IntelligenceStatus_Using IntelligenceStatus = 1
|
||||||
IntelligenceStatus_Deleted IntelligenceStatus = 2
|
IntelligenceStatus_Deleted IntelligenceStatus = 2
|
||||||
IntelligenceStatus_Banned IntelligenceStatus = 3
|
IntelligenceStatus_Banned IntelligenceStatus = 3
|
||||||
// 迁移失败
|
// Migration failed
|
||||||
IntelligenceStatus_MoveFailed IntelligenceStatus = 4
|
IntelligenceStatus_MoveFailed IntelligenceStatus = 4
|
||||||
// 复制中
|
// Copying
|
||||||
IntelligenceStatus_Copying IntelligenceStatus = 5
|
IntelligenceStatus_Copying IntelligenceStatus = 5
|
||||||
// 复制失败
|
// Copy failed
|
||||||
IntelligenceStatus_CopyFailed IntelligenceStatus = 6
|
IntelligenceStatus_CopyFailed IntelligenceStatus = 6
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,12 @@
|
||||||
package intelligence
|
package intelligence
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/project"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/publish"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/task"
|
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/project"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/publish"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/task"
|
||||||
)
|
)
|
||||||
|
|
||||||
type IntelligenceService interface {
|
type IntelligenceService interface {
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,12 @@
|
||||||
package intelligence
|
package intelligence
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/intelligence/common"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/intelligence/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type OrderBy int64
|
type OrderBy int64
|
||||||
|
|
@ -190,7 +190,7 @@ func (p *BotMode) Value() (driver.Value, error) {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetDraftIntelligenceListOption struct {
|
type GetDraftIntelligenceListOption struct {
|
||||||
// 是否需要个人版本Bot数据
|
//need personal version Bot data
|
||||||
NeedReplica bool `thrift:"need_replica,1" form:"need_replica" json:"need_replica" query:"need_replica"`
|
NeedReplica bool `thrift:"need_replica,1" form:"need_replica" json:"need_replica" query:"need_replica"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1435,9 +1435,9 @@ func (p *IntelligencePublishInfo) String() string {
|
||||||
|
|
||||||
type IntelligencePermissionInfo struct {
|
type IntelligencePermissionInfo struct {
|
||||||
InCollaboration bool `thrift:"in_collaboration,1" form:"in_collaboration" json:"in_collaboration" query:"in_collaboration"`
|
InCollaboration bool `thrift:"in_collaboration,1" form:"in_collaboration" json:"in_collaboration" query:"in_collaboration"`
|
||||||
// 当前用户是否可删除
|
// can delete
|
||||||
CanDelete bool `thrift:"can_delete,2" form:"can_delete" json:"can_delete" query:"can_delete"`
|
CanDelete bool `thrift:"can_delete,2" form:"can_delete" json:"can_delete" query:"can_delete"`
|
||||||
// 当前用户是否可查看,当前判断逻辑为用户是否在bot所在空间
|
// Whether the current user can view it, the current judgment logic is whether the user is in the space where the bot is located
|
||||||
CanView bool `thrift:"can_view,3" form:"can_view" json:"can_view" query:"can_view"`
|
CanView bool `thrift:"can_view,3" form:"can_view" json:"can_view" query:"can_view"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1665,9 +1665,9 @@ func (p *IntelligencePermissionInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type FavoriteInfo struct {
|
type FavoriteInfo struct {
|
||||||
// 是否收藏;收藏列表使用
|
// Whether to collect; use the collection list
|
||||||
IsFav bool `thrift:"is_fav,1" form:"is_fav" json:"is_fav" query:"is_fav"`
|
IsFav bool `thrift:"is_fav,1" form:"is_fav" json:"is_fav" query:"is_fav"`
|
||||||
// 收藏时间;收藏列表使用
|
// Collection time; collection list use
|
||||||
FavTime string `thrift:"fav_time,2" form:"fav_time" json:"fav_time" query:"fav_time"`
|
FavTime string `thrift:"fav_time,2" form:"fav_time" json:"fav_time" query:"fav_time"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1851,9 +1851,9 @@ func (p *FavoriteInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type OtherInfo struct {
|
type OtherInfo struct {
|
||||||
// 最近打开时间;最近打开筛选时使用
|
// Last opened time; used when recently opened filter
|
||||||
RecentlyOpenTime string `thrift:"recently_open_time,1" form:"recently_open_time" json:"recently_open_time" query:"recently_open_time"`
|
RecentlyOpenTime string `thrift:"recently_open_time,1" form:"recently_open_time" json:"recently_open_time" query:"recently_open_time"`
|
||||||
// 仅bot类型返回
|
// Only bot type returns
|
||||||
BotMode BotMode `thrift:"bot_mode,2" form:"bot_mode" json:"bot_mode" query:"bot_mode"`
|
BotMode BotMode `thrift:"bot_mode,2" form:"bot_mode" json:"bot_mode" query:"bot_mode"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2037,15 +2037,15 @@ func (p *OtherInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type Intelligence struct {
|
type Intelligence struct {
|
||||||
// 基本信息
|
// Basic information
|
||||||
BasicInfo *common.IntelligenceBasicInfo `thrift:"basic_info,1" form:"basic_info" json:"basic_info" query:"basic_info"`
|
BasicInfo *common.IntelligenceBasicInfo `thrift:"basic_info,1" form:"basic_info" json:"basic_info" query:"basic_info"`
|
||||||
// 智能体类型
|
// Agent Type
|
||||||
Type common.IntelligenceType `thrift:"type,2" form:"type" json:"type" query:"type"`
|
Type common.IntelligenceType `thrift:"type,2" form:"type" json:"type" query:"type"`
|
||||||
// 智能体发布信息,可选
|
// Agent publishes information, optional
|
||||||
PublishInfo *IntelligencePublishInfo `thrift:"publish_info,3" form:"publish_info" json:"publish_info" query:"publish_info"`
|
PublishInfo *IntelligencePublishInfo `thrift:"publish_info,3" form:"publish_info" json:"publish_info" query:"publish_info"`
|
||||||
// 智能体所有者信息,可选
|
// Agent owner information, optional
|
||||||
OwnerInfo *common.User `thrift:"owner_info,4" form:"owner_info" json:"owner_info" query:"owner_info"`
|
OwnerInfo *common.User `thrift:"owner_info,4" form:"owner_info" json:"owner_info" query:"owner_info"`
|
||||||
// 当前用户对智能体的权限信息,可选
|
// The current user's permission information to the agent, optional
|
||||||
PermissionInfo *IntelligencePermissionInfo `thrift:"permission_info,5" form:"permission_info" json:"permission_info" query:"permission_info"`
|
PermissionInfo *IntelligencePermissionInfo `thrift:"permission_info,5" form:"permission_info" json:"permission_info" query:"permission_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2384,7 +2384,7 @@ func (p *Intelligence) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// For前端
|
// For the front end
|
||||||
type IntelligenceData struct {
|
type IntelligenceData struct {
|
||||||
BasicInfo *common.IntelligenceBasicInfo `thrift:"basic_info,1" form:"basic_info" json:"basic_info" query:"basic_info"`
|
BasicInfo *common.IntelligenceBasicInfo `thrift:"basic_info,1" form:"basic_info" json:"basic_info" query:"basic_info"`
|
||||||
Type common.IntelligenceType `thrift:"type,2" form:"type" json:"type" query:"type"`
|
Type common.IntelligenceType `thrift:"type,2" form:"type" json:"type" query:"type"`
|
||||||
|
|
@ -3466,7 +3466,7 @@ func (p *GetDraftIntelligenceListResponse) String() string {
|
||||||
type GetDraftIntelligenceInfoRequest struct {
|
type GetDraftIntelligenceInfoRequest struct {
|
||||||
IntelligenceID int64 `thrift:"intelligence_id,1" form:"intelligence_id" json:"intelligence_id,string" query:"intelligence_id"`
|
IntelligenceID int64 `thrift:"intelligence_id,1" form:"intelligence_id" json:"intelligence_id,string" query:"intelligence_id"`
|
||||||
IntelligenceType common.IntelligenceType `thrift:"intelligence_type,2" form:"intelligence_type" json:"intelligence_type" query:"intelligence_type"`
|
IntelligenceType common.IntelligenceType `thrift:"intelligence_type,2" form:"intelligence_type" json:"intelligence_type" query:"intelligence_type"`
|
||||||
// 预览版本时传入
|
// Pass in when previewing the version
|
||||||
Version *int64 `thrift:"version,3,optional" form:"version" json:"version,string,omitempty" query:"version"`
|
Version *int64 `thrift:"version,3,optional" form:"version" json:"version,string,omitempty" query:"version"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -4344,9 +4344,9 @@ func (p *GetDraftIntelligenceInfoResponse) String() string {
|
||||||
type GetUserRecentlyEditIntelligenceRequest struct {
|
type GetUserRecentlyEditIntelligenceRequest struct {
|
||||||
Size int32 `thrift:"size,1" form:"size" json:"size" query:"size"`
|
Size int32 `thrift:"size,1" form:"size" json:"size" query:"size"`
|
||||||
Types []common.IntelligenceType `thrift:"types,2,optional" form:"types" json:"types,omitempty" query:"types"`
|
Types []common.IntelligenceType `thrift:"types,2,optional" form:"types" json:"types,omitempty" query:"types"`
|
||||||
// 企业id
|
// Enterprise ID
|
||||||
EnterpriseID *string `thrift:"enterprise_id,3,optional" form:"enterprise_id" json:"enterprise_id,omitempty" query:"enterprise_id"`
|
EnterpriseID *string `thrift:"enterprise_id,3,optional" form:"enterprise_id" json:"enterprise_id,omitempty" query:"enterprise_id"`
|
||||||
// 组织id
|
// organization id
|
||||||
OrganizationID *string `thrift:"organization_id,4,optional" form:"organization_id" json:"organization_id,omitempty" query:"organization_id"`
|
OrganizationID *string `thrift:"organization_id,4,optional" form:"organization_id" json:"organization_id,omitempty" query:"organization_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,19 +3,19 @@
|
||||||
package document
|
package document
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/common"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
// 获取表格结构、预览数据
|
// Get table structure, preview data
|
||||||
type GetDocumentTableInfoRequest struct {
|
type GetDocumentTableInfoRequest struct {
|
||||||
// 如果为第一次本地文件上传的表格,传递该值
|
// If the table is uploaded for the first local file, pass the value
|
||||||
TosURI *string `thrift:"tos_uri,2,optional" form:"tos_uri" json:"tos_uri,omitempty" query:"tos_uri"`
|
TosURI *string `thrift:"tos_uri,2,optional" form:"tos_uri" json:"tos_uri,omitempty" query:"tos_uri"`
|
||||||
// 如果为已有 document 的表格,传递该值
|
// If it is a document with an existing table, pass the value
|
||||||
DocumentID *int64 `thrift:"document_id,3,optional" form:"document_id" json:"document_id,string,omitempty"`
|
DocumentID *int64 `thrift:"document_id,3,optional" form:"document_id" json:"document_id,string,omitempty"`
|
||||||
// 创建人[http接口不需要传递]
|
// Creator [http interface does not need to be passed]
|
||||||
CreatorID int64 `thrift:"creator_id,4" form:"creator_id" json:"creator_id" query:"creator_id"`
|
CreatorID int64 `thrift:"creator_id,4" form:"creator_id" json:"creator_id" query:"creator_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -848,9 +848,9 @@ type GetTableSchemaInfoResponse struct {
|
||||||
Code int32 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int32 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
SheetList []*common.DocTableSheet `thrift:"sheet_list,3" form:"sheet_list" json:"sheet_list" query:"sheet_list"`
|
SheetList []*common.DocTableSheet `thrift:"sheet_list,3" form:"sheet_list" json:"sheet_list" query:"sheet_list"`
|
||||||
// 选中的 sheet 的 schema, 不选择默认返回第一个 sheet
|
// The schema of the selected sheet, not selected to return the first sheet by default
|
||||||
TableMeta []*common.DocTableColumn `thrift:"table_meta,4" form:"table_meta" json:"table_meta" query:"table_meta"`
|
TableMeta []*common.DocTableColumn `thrift:"table_meta,4" form:"table_meta" json:"table_meta" query:"table_meta"`
|
||||||
// knowledge table 场景中会返回
|
// The knowledge table will return
|
||||||
PreviewData []map[int64]string `thrift:"preview_data,5" form:"preview_data" json:"preview_data" query:"preview_data"`
|
PreviewData []map[int64]string `thrift:"preview_data,5" form:"preview_data" json:"preview_data" query:"preview_data"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"-" json:"-" query:"-"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,11 +3,11 @@
|
||||||
package kvmemory
|
package kvmemory
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"fmt"
|
||||||
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/project_memory"
|
"github.com/coze-dev/coze-studio/backend/api/model/project_memory"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/table"
|
"github.com/coze-dev/coze-studio/backend/api/model/table"
|
||||||
"fmt"
|
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type KVItem struct {
|
type KVItem struct {
|
||||||
|
|
@ -1448,7 +1448,7 @@ type SetKvMemoryReq struct {
|
||||||
UserID *int64 `thrift:"user_id,2,optional" form:"user_id" json:"user_id,omitempty" query:"user_id"`
|
UserID *int64 `thrift:"user_id,2,optional" form:"user_id" json:"user_id,omitempty" query:"user_id"`
|
||||||
Data []*KVItem `thrift:"data,3,required" form:"data,required" json:"data,required" query:"data,required"`
|
Data []*KVItem `thrift:"data,3,required" form:"data,required" json:"data,required" query:"data,required"`
|
||||||
ConnectorID *int64 `thrift:"connector_id,4,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
ConnectorID *int64 `thrift:"connector_id,4,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
||||||
// 引用信息
|
// citation information
|
||||||
RefInfo *table.RefInfo `thrift:"ref_info,5,optional" form:"ref_info" json:"ref_info,omitempty" query:"ref_info"`
|
RefInfo *table.RefInfo `thrift:"ref_info,5,optional" form:"ref_info" json:"ref_info,omitempty" query:"ref_info"`
|
||||||
ProjectID *string `thrift:"project_id,6,optional" form:"project_id" json:"project_id,omitempty" query:"project_id"`
|
ProjectID *string `thrift:"project_id,6,optional" form:"project_id" json:"project_id,omitempty" query:"project_id"`
|
||||||
ProjectVersion *int64 `thrift:"ProjectVersion,7,optional" form:"ProjectVersion" json:"ProjectVersion,omitempty" query:"ProjectVersion"`
|
ProjectVersion *int64 `thrift:"ProjectVersion,7,optional" form:"ProjectVersion" json:"ProjectVersion,omitempty" query:"ProjectVersion"`
|
||||||
|
|
@ -3041,7 +3041,7 @@ type DelProfileMemoryRequest struct {
|
||||||
BotID int64 `thrift:"bot_id,2" form:"bot_id" json:"bot_id,string"`
|
BotID int64 `thrift:"bot_id,2" form:"bot_id" json:"bot_id,string"`
|
||||||
Keywords []string `thrift:"keywords,3" form:"keywords" json:"keywords" query:"keywords"`
|
Keywords []string `thrift:"keywords,3" form:"keywords" json:"keywords" query:"keywords"`
|
||||||
ConnectorID *int64 `thrift:"connector_id,4,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
ConnectorID *int64 `thrift:"connector_id,4,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
||||||
// 引用信息
|
// citation information
|
||||||
RefInfo *table.RefInfo `thrift:"ref_info,5,optional" form:"ref_info" json:"ref_info,omitempty" query:"ref_info"`
|
RefInfo *table.RefInfo `thrift:"ref_info,5,optional" form:"ref_info" json:"ref_info,omitempty" query:"ref_info"`
|
||||||
ProjectID string `thrift:"project_id,6" form:"project_id" json:"project_id" query:"project_id"`
|
ProjectID string `thrift:"project_id,6" form:"project_id" json:"project_id" query:"project_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
|
|
@ -3499,7 +3499,7 @@ type GetProfileMemoryRequest struct {
|
||||||
Keywords []string `thrift:"keywords,3" form:"keywords" json:"keywords" query:"keywords"`
|
Keywords []string `thrift:"keywords,3" form:"keywords" json:"keywords" query:"keywords"`
|
||||||
ConnectorID *int64 `thrift:"connector_id,4,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
ConnectorID *int64 `thrift:"connector_id,4,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
||||||
Version *string `thrift:"version,5,optional" form:"version" json:"version,omitempty" query:"version"`
|
Version *string `thrift:"version,5,optional" form:"version" json:"version,omitempty" query:"version"`
|
||||||
// 引用信息
|
// citation information
|
||||||
RefInfo *table.RefInfo `thrift:"ref_info,6,optional" form:"ref_info" json:"ref_info,omitempty" query:"ref_info"`
|
RefInfo *table.RefInfo `thrift:"ref_info,6,optional" form:"ref_info" json:"ref_info,omitempty" query:"ref_info"`
|
||||||
Ext *string `thrift:"ext,7,optional" form:"ext" json:"ext,omitempty" query:"ext"`
|
Ext *string `thrift:"ext,7,optional" form:"ext" json:"ext,omitempty" query:"ext"`
|
||||||
ProjectID *string `thrift:"project_id,8,optional" form:"project_id" json:"project_id,omitempty" query:"project_id"`
|
ProjectID *string `thrift:"project_id,8,optional" form:"project_id" json:"project_id,omitempty" query:"project_id"`
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -3,10 +3,10 @@
|
||||||
package bot_open_api
|
package bot_open_api
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type OauthAuthorizationCodeReq struct {
|
type OauthAuthorizationCodeReq struct {
|
||||||
|
|
|
||||||
|
|
@ -15,9 +15,9 @@ import (
|
||||||
type VisibilityType int64
|
type VisibilityType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 不可见
|
// invisible
|
||||||
VisibilityType_Invisible VisibilityType = 0
|
VisibilityType_Invisible VisibilityType = 0
|
||||||
// 可见
|
// visible
|
||||||
VisibilityType_Visible VisibilityType = 1
|
VisibilityType_Visible VisibilityType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -112,11 +112,11 @@ func (p *TabStatus) Value() (driver.Value, error) {
|
||||||
type PublishResultStatus int64
|
type PublishResultStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 成功
|
// success
|
||||||
PublishResultStatus_Success PublishResultStatus = 1
|
PublishResultStatus_Success PublishResultStatus = 1
|
||||||
// 失败
|
// fail
|
||||||
PublishResultStatus_Failed PublishResultStatus = 2
|
PublishResultStatus_Failed PublishResultStatus = 2
|
||||||
// 审批中
|
// in approval
|
||||||
PublishResultStatus_InReview PublishResultStatus = 3
|
PublishResultStatus_InReview PublishResultStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -219,9 +219,9 @@ func (p *AgentType) Value() (driver.Value, error) {
|
||||||
type ReferenceInfoStatus int64
|
type ReferenceInfoStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 1:有可用更新
|
// 1: Updates are available
|
||||||
ReferenceInfoStatus_HasUpdates ReferenceInfoStatus = 1
|
ReferenceInfoStatus_HasUpdates ReferenceInfoStatus = 1
|
||||||
// 2:被删除
|
// 2: Deleted
|
||||||
ReferenceInfoStatus_IsDelete ReferenceInfoStatus = 2
|
ReferenceInfoStatus_IsDelete ReferenceInfoStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -399,11 +399,11 @@ func (p *RecognitionMode) Value() (driver.Value, error) {
|
||||||
type IndependentTiming int64
|
type IndependentTiming int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 判断用户输入(前置)
|
// Determine user input (front)
|
||||||
IndependentTiming_Pre IndependentTiming = 1
|
IndependentTiming_Pre IndependentTiming = 1
|
||||||
// 判断节点输出(后置)
|
// Determine node output (postfix)
|
||||||
IndependentTiming_Post IndependentTiming = 2
|
IndependentTiming_Post IndependentTiming = 2
|
||||||
// 前置模式和后置模式支持同时选择
|
// Front mode and rear mode support simultaneous selection
|
||||||
IndependentTiming_PreAndPost IndependentTiming = 3
|
IndependentTiming_PreAndPost IndependentTiming = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -449,9 +449,9 @@ func (p *IndependentTiming) Value() (driver.Value, error) {
|
||||||
type IndependentRecognitionModelType int64
|
type IndependentRecognitionModelType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 小模型
|
// Small model
|
||||||
IndependentRecognitionModelType_SLM IndependentRecognitionModelType = 0
|
IndependentRecognitionModelType_SLM IndependentRecognitionModelType = 0
|
||||||
// 大模型
|
// Large model
|
||||||
IndependentRecognitionModelType_LLM IndependentRecognitionModelType = 1
|
IndependentRecognitionModelType_LLM IndependentRecognitionModelType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -584,13 +584,13 @@ func (p *BotMode) Value() (driver.Value, error) {
|
||||||
type HistoryType int64
|
type HistoryType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 废弃
|
// abandoned
|
||||||
HistoryType_SUBMIT HistoryType = 1
|
HistoryType_SUBMIT HistoryType = 1
|
||||||
// 发布
|
// publish
|
||||||
HistoryType_FLAG HistoryType = 2
|
HistoryType_FLAG HistoryType = 2
|
||||||
// 提交
|
// submit
|
||||||
HistoryType_COMMIT HistoryType = 4
|
HistoryType_COMMIT HistoryType = 4
|
||||||
// 提交和发布
|
// Submit and publish
|
||||||
HistoryType_COMMITANDFLAG HistoryType = 5
|
HistoryType_COMMITANDFLAG HistoryType = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -912,25 +912,25 @@ const (
|
||||||
ModelClass_StableDiffusion ModelClass = 6
|
ModelClass_StableDiffusion ModelClass = 6
|
||||||
ModelClass_ByteArtist ModelClass = 7
|
ModelClass_ByteArtist ModelClass = 7
|
||||||
ModelClass_Maas ModelClass = 9
|
ModelClass_Maas ModelClass = 9
|
||||||
// 废弃:千帆(百度云)
|
// Abandoned: Qianfan (Baidu Cloud)
|
||||||
ModelClass_QianFan ModelClass = 10
|
ModelClass_QianFan ModelClass = 10
|
||||||
// name:Google Gemini
|
// name:Google Gemini
|
||||||
ModelClass_Gemini ModelClass = 11
|
ModelClass_Gemini ModelClass = 11
|
||||||
// name: Moonshot
|
// name: Moonshot
|
||||||
ModelClass_Moonshot ModelClass = 12
|
ModelClass_Moonshot ModelClass = 12
|
||||||
// name:智谱
|
// Name: Zhipu
|
||||||
ModelClass_GLM ModelClass = 13
|
ModelClass_GLM ModelClass = 13
|
||||||
// name: 火山方舟
|
// Name: Volcano Ark
|
||||||
ModelClass_MaaSAutoSync ModelClass = 14
|
ModelClass_MaaSAutoSync ModelClass = 14
|
||||||
// name:通义千问
|
// Name: Tongyi Qianwen
|
||||||
ModelClass_QWen ModelClass = 15
|
ModelClass_QWen ModelClass = 15
|
||||||
// name: Cohere
|
// name: Cohere
|
||||||
ModelClass_Cohere ModelClass = 16
|
ModelClass_Cohere ModelClass = 16
|
||||||
// name: 百川智能
|
// Name: Baichuan Intelligent
|
||||||
ModelClass_Baichuan ModelClass = 17
|
ModelClass_Baichuan ModelClass = 17
|
||||||
// name:文心一言
|
// Name: ERNIE Bot
|
||||||
ModelClass_Ernie ModelClass = 18
|
ModelClass_Ernie ModelClass = 18
|
||||||
// name: 幻方
|
// Name: Magic Square
|
||||||
ModelClass_DeekSeek ModelClass = 19
|
ModelClass_DeekSeek ModelClass = 19
|
||||||
// name: Llama
|
// name: Llama
|
||||||
ModelClass_Llama ModelClass = 20
|
ModelClass_Llama ModelClass = 20
|
||||||
|
|
@ -1056,7 +1056,7 @@ const (
|
||||||
ModelTagClass_ModelUserRight ModelTagClass = 2
|
ModelTagClass_ModelUserRight ModelTagClass = 2
|
||||||
ModelTagClass_ModelFeature ModelTagClass = 3
|
ModelTagClass_ModelFeature ModelTagClass = 3
|
||||||
ModelTagClass_ModelFunction ModelTagClass = 4
|
ModelTagClass_ModelFunction ModelTagClass = 4
|
||||||
// 本期不做
|
// Do not do this issue
|
||||||
ModelTagClass_Custom ModelTagClass = 20
|
ModelTagClass_Custom ModelTagClass = 20
|
||||||
ModelTagClass_Others ModelTagClass = 100
|
ModelTagClass_Others ModelTagClass = 100
|
||||||
)
|
)
|
||||||
|
|
@ -1255,11 +1255,11 @@ type CommitStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
CommitStatus_Undefined CommitStatus = 0
|
CommitStatus_Undefined CommitStatus = 0
|
||||||
// 已是最新,同主草稿相同
|
// It is the latest, the same as the main draft
|
||||||
CommitStatus_Uptodate CommitStatus = 1
|
CommitStatus_Uptodate CommitStatus = 1
|
||||||
// 落后主草稿
|
// Behind the main draft
|
||||||
CommitStatus_Behind CommitStatus = 2
|
CommitStatus_Behind CommitStatus = 2
|
||||||
// 无个人草稿
|
// No personal draft
|
||||||
CommitStatus_NoDraftReplica CommitStatus = 3
|
CommitStatus_NoDraftReplica CommitStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1309,15 +1309,15 @@ func (p *CommitStatus) Value() (driver.Value, error) {
|
||||||
type ConfigStatus int64
|
type ConfigStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 已配置
|
// Configured
|
||||||
ConfigStatus_Configured ConfigStatus = 1
|
ConfigStatus_Configured ConfigStatus = 1
|
||||||
// 未配置
|
// Not configured
|
||||||
ConfigStatus_NotConfigured ConfigStatus = 2
|
ConfigStatus_NotConfigured ConfigStatus = 2
|
||||||
// Token发生变化
|
// Token changes
|
||||||
ConfigStatus_Disconnected ConfigStatus = 3
|
ConfigStatus_Disconnected ConfigStatus = 3
|
||||||
// 配置中,授权中
|
// Configuring, authorizing
|
||||||
ConfigStatus_Configuring ConfigStatus = 4
|
ConfigStatus_Configuring ConfigStatus = 4
|
||||||
// 需要重新配置
|
// Need to reconfigure
|
||||||
ConfigStatus_NeedReconfiguring ConfigStatus = 5
|
ConfigStatus_NeedReconfiguring ConfigStatus = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1371,19 +1371,19 @@ func (p *ConfigStatus) Value() (driver.Value, error) {
|
||||||
type BindType int64
|
type BindType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 无需绑定
|
// No binding required
|
||||||
BindType_NoBindRequired BindType = 1
|
BindType_NoBindRequired BindType = 1
|
||||||
// Auth绑定
|
// Auth binding
|
||||||
BindType_AuthBind BindType = 2
|
BindType_AuthBind BindType = 2
|
||||||
// Kv绑定=
|
// Kv binding =
|
||||||
BindType_KvBind BindType = 3
|
BindType_KvBind BindType = 3
|
||||||
// Kv并Auth授权
|
// Kv and Auth authorization
|
||||||
BindType_KvAuthBind BindType = 4
|
BindType_KvAuthBind BindType = 4
|
||||||
// api渠道绑定
|
// API channel binding
|
||||||
BindType_ApiBind BindType = 5
|
BindType_ApiBind BindType = 5
|
||||||
BindType_WebSDKBind BindType = 6
|
BindType_WebSDKBind BindType = 6
|
||||||
BindType_StoreBind BindType = 7
|
BindType_StoreBind BindType = 7
|
||||||
// 授权和配置各一个按钮
|
// One button each for authorization and configuration
|
||||||
BindType_AuthAndConfig BindType = 8
|
BindType_AuthAndConfig BindType = 8
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1491,11 +1491,11 @@ func (p *AllowPublishStatus) Value() (driver.Value, error) {
|
||||||
type BotConnectorStatus int64
|
type BotConnectorStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 正常
|
// Normal
|
||||||
BotConnectorStatus_Normal BotConnectorStatus = 0
|
BotConnectorStatus_Normal BotConnectorStatus = 0
|
||||||
// 审核中
|
// Under review.
|
||||||
BotConnectorStatus_InReview BotConnectorStatus = 1
|
BotConnectorStatus_InReview BotConnectorStatus = 1
|
||||||
// 已下线
|
// offline
|
||||||
BotConnectorStatus_Offline BotConnectorStatus = 2
|
BotConnectorStatus_Offline BotConnectorStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1541,11 +1541,11 @@ func (p *BotConnectorStatus) Value() (driver.Value, error) {
|
||||||
type UserAuthStatus int64
|
type UserAuthStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 已授权
|
// Authorized
|
||||||
UserAuthStatus_Authorized UserAuthStatus = 1
|
UserAuthStatus_Authorized UserAuthStatus = 1
|
||||||
// 未授权
|
// unauthorized
|
||||||
UserAuthStatus_UnAuthorized UserAuthStatus = 2
|
UserAuthStatus_UnAuthorized UserAuthStatus = 2
|
||||||
// 授权中
|
// Authorizing
|
||||||
UserAuthStatus_Authorizing UserAuthStatus = 3
|
UserAuthStatus_Authorizing UserAuthStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1595,7 +1595,7 @@ type DraftBotCreateRequest struct {
|
||||||
IconURI string `thrift:"icon_uri,4" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
IconURI string `thrift:"icon_uri,4" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
||||||
Visibility VisibilityType `thrift:"visibility,5" form:"visibility" json:"visibility" query:"visibility"`
|
Visibility VisibilityType `thrift:"visibility,5" form:"visibility" json:"visibility" query:"visibility"`
|
||||||
MonetizationConf *MonetizationConf `thrift:"monetization_conf,6,optional" form:"monetization_conf" json:"monetization_conf,omitempty" query:"monetization_conf"`
|
MonetizationConf *MonetizationConf `thrift:"monetization_conf,6,optional" form:"monetization_conf" json:"monetization_conf,omitempty" query:"monetization_conf"`
|
||||||
// 创建来源 navi:导航栏 space:空间
|
// Create source navi: navbar space: space
|
||||||
CreateFrom *string `thrift:"create_from,7,optional" form:"create_from" json:"create_from,omitempty" query:"create_from"`
|
CreateFrom *string `thrift:"create_from,7,optional" form:"create_from" json:"create_from,omitempty" query:"create_from"`
|
||||||
BusinessType *bot_common.BusinessType `thrift:"business_type,9,optional" form:"business_type" json:"business_type,omitempty" query:"business_type"`
|
BusinessType *bot_common.BusinessType `thrift:"business_type,9,optional" form:"business_type" json:"business_type,omitempty" query:"business_type"`
|
||||||
}
|
}
|
||||||
|
|
@ -2234,9 +2234,9 @@ func (p *MonetizationConf) String() string {
|
||||||
|
|
||||||
type DraftBotCreateData struct {
|
type DraftBotCreateData struct {
|
||||||
BotID int64 `thrift:"bot_id,1" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
BotID int64 `thrift:"bot_id,1" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
||||||
// true:机审校验不通过
|
// True: The machine audit verification failed
|
||||||
CheckNotPass bool `thrift:"check_not_pass,2" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
CheckNotPass bool `thrift:"check_not_pass,2" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
||||||
// 机审校验不通过文案
|
// The machine audit verification failed the copy.
|
||||||
CheckNotPassMsg *string `thrift:"check_not_pass_msg,3,optional" form:"check_not_pass_msg" json:"check_not_pass_msg,omitempty" query:"check_not_pass_msg"`
|
CheckNotPassMsg *string `thrift:"check_not_pass_msg,3,optional" form:"check_not_pass_msg" json:"check_not_pass_msg,omitempty" query:"check_not_pass_msg"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3761,14 +3761,14 @@ func (p *UserLabel) String() string {
|
||||||
|
|
||||||
type Creator struct {
|
type Creator struct {
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id,string" query:"id"`
|
ID int64 `thrift:"id,1" form:"id" json:"id,string" query:"id"`
|
||||||
// 昵称
|
// nickname
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
AvatarURL string `thrift:"avatar_url,3" form:"avatar_url" json:"avatar_url" query:"avatar_url"`
|
AvatarURL string `thrift:"avatar_url,3" form:"avatar_url" json:"avatar_url" query:"avatar_url"`
|
||||||
// 是否是自己创建的
|
// Did you create it yourself?
|
||||||
Self bool `thrift:"self,4" form:"self" json:"self" query:"self"`
|
Self bool `thrift:"self,4" form:"self" json:"self" query:"self"`
|
||||||
// 用户名
|
// user name
|
||||||
UserUniqueName string `thrift:"user_unique_name,5" form:"user_unique_name" json:"user_unique_name" query:"user_unique_name"`
|
UserUniqueName string `thrift:"user_unique_name,5" form:"user_unique_name" json:"user_unique_name" query:"user_unique_name"`
|
||||||
// 用户标签
|
// user tag
|
||||||
UserLabel *UserLabel `thrift:"user_label,6" form:"user_label" json:"user_label" query:"user_label"`
|
UserLabel *UserLabel `thrift:"user_label,6" form:"user_label" json:"user_label" query:"user_label"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7058,19 +7058,19 @@ func (p *PublishDraftBotResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishDraftBotData struct {
|
type PublishDraftBotData struct {
|
||||||
// key代表connector_name 枚举 飞书="feishu" -- 废弃
|
// Key represents connector_name enumeration Feishu = "feishu" -- obsolete
|
||||||
ConnectorBindResult map[string][]*ConnectorBindResult `thrift:"connector_bind_result,1" form:"connector_bind_result" json:"connector_bind_result" query:"connector_bind_result"`
|
ConnectorBindResult map[string][]*ConnectorBindResult `thrift:"connector_bind_result,1" form:"connector_bind_result" json:"connector_bind_result" query:"connector_bind_result"`
|
||||||
// key代表connector_id,value是发布结果
|
// The key represents connector_id, and the value is the published result
|
||||||
PublishResult map[string]*ConnectorBindResult `thrift:"publish_result,2" form:"publish_result" json:"publish_result" query:"publish_result"`
|
PublishResult map[string]*ConnectorBindResult `thrift:"publish_result,2" form:"publish_result" json:"publish_result" query:"publish_result"`
|
||||||
// true:机审校验不通过
|
// True: The machine audit verification failed
|
||||||
CheckNotPass bool `thrift:"check_not_pass,3" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
CheckNotPass bool `thrift:"check_not_pass,3" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
||||||
// 上架bot market结果
|
// Added bot marketing results
|
||||||
SubmitBotMarketResult *SubmitBotMarketResult `thrift:"submit_bot_market_result,4,optional" form:"submit_bot_market_result" json:"submit_bot_market_result,omitempty" query:"submit_bot_market_result"`
|
SubmitBotMarketResult *SubmitBotMarketResult `thrift:"submit_bot_market_result,4,optional" form:"submit_bot_market_result" json:"submit_bot_market_result,omitempty" query:"submit_bot_market_result"`
|
||||||
// 是否命中人审
|
// In human moderation
|
||||||
HitManualCheck *bool `thrift:"hit_manual_check,5,optional" form:"hit_manual_check" json:"hit_manual_check,omitempty" query:"hit_manual_check"`
|
HitManualCheck *bool `thrift:"hit_manual_check,5,optional" form:"hit_manual_check" json:"hit_manual_check,omitempty" query:"hit_manual_check"`
|
||||||
// 机审校验不通过原因的starlingKey列表
|
// starlingKey list of reasons why the machine audit failed
|
||||||
NotPassReason []string `thrift:"not_pass_reason,6,optional" form:"not_pass_reason" json:"not_pass_reason,omitempty" query:"not_pass_reason"`
|
NotPassReason []string `thrift:"not_pass_reason,6,optional" form:"not_pass_reason" json:"not_pass_reason,omitempty" query:"not_pass_reason"`
|
||||||
// 发布bot计费结果
|
// Publish bot billing results
|
||||||
PublishMonetizationResult *bool `thrift:"publish_monetization_result,7,optional" form:"publish_monetization_result" json:"publish_monetization_result,omitempty" query:"publish_monetization_result"`
|
PublishMonetizationResult *bool `thrift:"publish_monetization_result,7,optional" form:"publish_monetization_result" json:"publish_monetization_result,omitempty" query:"publish_monetization_result"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7614,11 +7614,11 @@ func (p *PublishDraftBotData) String() string {
|
||||||
|
|
||||||
type ConnectorBindResult struct {
|
type ConnectorBindResult struct {
|
||||||
Connector *Connector `thrift:"connector,1" form:"connector" json:"connector" query:"connector"`
|
Connector *Connector `thrift:"connector,1" form:"connector" json:"connector" query:"connector"`
|
||||||
// 发布调用下游返回的状态码,前端不消费
|
// The status code returned downstream of the publish call is not consumed by the front end.
|
||||||
Code int64 `thrift:"code,2" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,2" form:"code" json:"code" query:"code"`
|
||||||
// 发布状态的附加文案,前端按照markdown格式解析
|
// Additional copy of the release status, the front end is parsed in markdown format
|
||||||
Msg string `thrift:"msg,3" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,3" form:"msg" json:"msg" query:"msg"`
|
||||||
// 发布结果状态
|
// post result status
|
||||||
PublishResultStatus *PublishResultStatus `thrift:"publish_result_status,4,optional" form:"publish_result_status" json:"publish_result_status,omitempty" query:"publish_result_status"`
|
PublishResultStatus *PublishResultStatus `thrift:"publish_result_status,4,optional" form:"publish_result_status" json:"publish_result_status,omitempty" query:"publish_result_status"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7908,7 +7908,7 @@ func (p *ConnectorBindResult) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type Connector struct {
|
type Connector struct {
|
||||||
// connector_name 枚举 飞书="feishu"
|
// connector_name enumeration Feishu = "feishu"
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
AppID string `thrift:"app_id,2" form:"app_id" json:"app_id" query:"app_id"`
|
AppID string `thrift:"app_id,2" form:"app_id" json:"app_id" query:"app_id"`
|
||||||
AppSecret string `thrift:"app_secret,3" form:"app_secret" json:"app_secret" query:"app_secret"`
|
AppSecret string `thrift:"app_secret,3" form:"app_secret" json:"app_secret" query:"app_secret"`
|
||||||
|
|
@ -8268,9 +8268,9 @@ func (p *Connector) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SubmitBotMarketResult struct {
|
type SubmitBotMarketResult struct {
|
||||||
// 上架状态,0-成功
|
// Shelf status, 0-success
|
||||||
ResultCode *int64 `thrift:"result_code,1,optional" form:"result_code" json:"result_code,omitempty" query:"result_code"`
|
ResultCode *int64 `thrift:"result_code,1,optional" form:"result_code" json:"result_code,omitempty" query:"result_code"`
|
||||||
// 上架结果的文案
|
// msg
|
||||||
Msg *string `thrift:"msg,2,optional" form:"msg" json:"msg,omitempty" query:"msg"`
|
Msg *string `thrift:"msg,2,optional" form:"msg" json:"msg,omitempty" query:"msg"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8486,7 +8486,7 @@ type AgentInfo struct {
|
||||||
ReferenceID *string `thrift:"reference_id,8,optional" form:"reference_id" json:"reference_id,omitempty" query:"reference_id"`
|
ReferenceID *string `thrift:"reference_id,8,optional" form:"reference_id" json:"reference_id,omitempty" query:"reference_id"`
|
||||||
FirstVersion *string `thrift:"first_version,9,optional" form:"first_version" json:"first_version,omitempty" query:"first_version"`
|
FirstVersion *string `thrift:"first_version,9,optional" form:"first_version" json:"first_version,omitempty" query:"first_version"`
|
||||||
CurrentVersion *string `thrift:"current_version,10,optional" form:"current_version" json:"current_version,omitempty" query:"current_version"`
|
CurrentVersion *string `thrift:"current_version,10,optional" form:"current_version" json:"current_version,omitempty" query:"current_version"`
|
||||||
// 1:有可用更新 2:被删除
|
// 1: Available update 2: Removed
|
||||||
ReferenceInfoStatus *ReferenceInfoStatus `thrift:"reference_info_status,11,optional" form:"reference_info_status" json:"reference_info_status,omitempty" query:"reference_info_status"`
|
ReferenceInfoStatus *ReferenceInfoStatus `thrift:"reference_info_status,11,optional" form:"reference_info_status" json:"reference_info_status,omitempty" query:"reference_info_status"`
|
||||||
Description *string `thrift:"description,12,optional" form:"description" json:"description,omitempty" query:"description"`
|
Description *string `thrift:"description,12,optional" form:"description" json:"description,omitempty" query:"description"`
|
||||||
UpdateType *ReferenceUpdateType `thrift:"update_type,13,optional" form:"update_type" json:"update_type,omitempty" query:"update_type"`
|
UpdateType *ReferenceUpdateType `thrift:"update_type,13,optional" form:"update_type" json:"update_type,omitempty" query:"update_type"`
|
||||||
|
|
@ -9761,25 +9761,25 @@ func (p *Intent) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// agent 工作区间各个模块的信息
|
// Information about each module in the agent workspace
|
||||||
type AgentWorkInfo struct {
|
type AgentWorkInfo struct {
|
||||||
// agent prompt 前端信息,server不需要感知
|
// The agent prompts the front-end information, the server does not need to perceive
|
||||||
Prompt *string `thrift:"prompt,1,optional" form:"prompt" json:"prompt,omitempty" query:"prompt"`
|
Prompt *string `thrift:"prompt,1,optional" form:"prompt" json:"prompt,omitempty" query:"prompt"`
|
||||||
// 模型配置
|
// model configuration
|
||||||
OtherInfo *string `thrift:"other_info,2,optional" form:"other_info" json:"other_info,omitempty" query:"other_info"`
|
OtherInfo *string `thrift:"other_info,2,optional" form:"other_info" json:"other_info,omitempty" query:"other_info"`
|
||||||
// plugin 信息
|
// Plugin information
|
||||||
Tools *string `thrift:"tools,3,optional" form:"tools" json:"tools,omitempty" query:"tools"`
|
Tools *string `thrift:"tools,3,optional" form:"tools" json:"tools,omitempty" query:"tools"`
|
||||||
// dataset 信息
|
// Dataset information
|
||||||
Dataset *string `thrift:"dataset,4,optional" form:"dataset" json:"dataset,omitempty" query:"dataset"`
|
Dataset *string `thrift:"dataset,4,optional" form:"dataset" json:"dataset,omitempty" query:"dataset"`
|
||||||
// workflow 信息
|
// Workflow information
|
||||||
Workflow *string `thrift:"workflow,5,optional" form:"workflow" json:"workflow,omitempty" query:"workflow"`
|
Workflow *string `thrift:"workflow,5,optional" form:"workflow" json:"workflow,omitempty" query:"workflow"`
|
||||||
// 同bot的 system_info_all
|
// system_info_all with bot
|
||||||
SystemInfoAll *string `thrift:"system_info_all,6,optional" form:"system_info_all" json:"system_info_all,omitempty" query:"system_info_all"`
|
SystemInfoAll *string `thrift:"system_info_all,6,optional" form:"system_info_all" json:"system_info_all,omitempty" query:"system_info_all"`
|
||||||
// 回溯配置
|
// backtrack configuration
|
||||||
JumpConfig *JumpConfig `thrift:"jump_config,7,optional" form:"jump_config" json:"jump_config,omitempty" query:"jump_config"`
|
JumpConfig *JumpConfig `thrift:"jump_config,7,optional" form:"jump_config" json:"jump_config,omitempty" query:"jump_config"`
|
||||||
// 推荐回复配置
|
// Referral Configuration
|
||||||
SuggestReply *string `thrift:"suggest_reply,8,optional" form:"suggest_reply" json:"suggest_reply,omitempty" query:"suggest_reply"`
|
SuggestReply *string `thrift:"suggest_reply,8,optional" form:"suggest_reply" json:"suggest_reply,omitempty" query:"suggest_reply"`
|
||||||
// hook配置
|
// Hook configuration
|
||||||
HookInfo *string `thrift:"hook_info,9,optional" form:"hook_info" json:"hook_info,omitempty" query:"hook_info"`
|
HookInfo *string `thrift:"hook_info,9,optional" form:"hook_info" json:"hook_info,omitempty" query:"hook_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10604,7 +10604,7 @@ func (p *JumpConfig) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type IndependentModeConfig struct {
|
type IndependentModeConfig struct {
|
||||||
// 判断时机
|
// Judge timing
|
||||||
JudgeTiming IndependentTiming `thrift:"judge_timing,1" form:"judge_timing" json:"judge_timing" query:"judge_timing"`
|
JudgeTiming IndependentTiming `thrift:"judge_timing,1" form:"judge_timing" json:"judge_timing" query:"judge_timing"`
|
||||||
HistoryRound int32 `thrift:"history_round,2" form:"history_round" json:"history_round" query:"history_round"`
|
HistoryRound int32 `thrift:"history_round,2" form:"history_round" json:"history_round" query:"history_round"`
|
||||||
ModelType IndependentRecognitionModelType `thrift:"model_type,3" form:"model_type" json:"model_type" query:"model_type"`
|
ModelType IndependentRecognitionModelType `thrift:"model_type,3" form:"model_type" json:"model_type" query:"model_type"`
|
||||||
|
|
@ -11225,25 +11225,25 @@ type PublishDraftBotRequest struct {
|
||||||
SpaceID int64 `thrift:"space_id,1,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
SpaceID int64 `thrift:"space_id,1,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
||||||
BotID int64 `thrift:"bot_id,2,required" form:"bot_id,required" json:"bot_id,string,required" query:"bot_id,required"`
|
BotID int64 `thrift:"bot_id,2,required" form:"bot_id,required" json:"bot_id,string,required" query:"bot_id,required"`
|
||||||
WorkInfo *WorkInfo `thrift:"work_info,3" form:"work_info" json:"work_info" query:"work_info"`
|
WorkInfo *WorkInfo `thrift:"work_info,3" form:"work_info" json:"work_info" query:"work_info"`
|
||||||
// key代表connector_name 枚举 飞书="feishu" -- 废弃
|
// Key represents connector_name enumeration Feishu = "feishu" -- obsolete
|
||||||
ConnectorList map[string][]*Connector `thrift:"connector_list,4" form:"connector_list" json:"connector_list" query:"connector_list"`
|
ConnectorList map[string][]*Connector `thrift:"connector_list,4" form:"connector_list" json:"connector_list" query:"connector_list"`
|
||||||
// key代表connector_id,value是发布的参数
|
// The key represents connector_id, and the value is the published parameter
|
||||||
Connectors map[string]map[string]string `thrift:"connectors,5" form:"connectors" json:"connectors" query:"connectors"`
|
Connectors map[string]map[string]string `thrift:"connectors,5" form:"connectors" json:"connectors" query:"connectors"`
|
||||||
// 默认0
|
// Default 0
|
||||||
BotMode *BotMode `thrift:"botMode,6,optional" form:"botMode" json:"botMode,omitempty" query:"botMode"`
|
BotMode *BotMode `thrift:"botMode,6,optional" form:"botMode" json:"botMode,omitempty" query:"botMode"`
|
||||||
Agents []*AgentInfo `thrift:"agents,7,optional" form:"agents" json:"agents,omitempty" query:"agents"`
|
Agents []*AgentInfo `thrift:"agents,7,optional" form:"agents" json:"agents,omitempty" query:"agents"`
|
||||||
CanvasData *string `thrift:"canvas_data,8,optional" form:"canvas_data" json:"canvas_data,omitempty" query:"canvas_data"`
|
CanvasData *string `thrift:"canvas_data,8,optional" form:"canvas_data" json:"canvas_data,omitempty" query:"canvas_data"`
|
||||||
BotTagInfo []*BotTagInfo `thrift:"bot_tag_info,9,optional" form:"bot_tag_info" json:"bot_tag_info,omitempty" query:"bot_tag_info"`
|
BotTagInfo []*BotTagInfo `thrift:"bot_tag_info,9,optional" form:"bot_tag_info" json:"bot_tag_info,omitempty" query:"bot_tag_info"`
|
||||||
// 发布到market的配置
|
// Configuration published to the market
|
||||||
SubmitBotMarketConfig *SubmitBotMarketConfig `thrift:"submit_bot_market_config,10,optional" form:"submit_bot_market_config" json:"submit_bot_market_config,omitempty" query:"submit_bot_market_config"`
|
SubmitBotMarketConfig *SubmitBotMarketConfig `thrift:"submit_bot_market_config,10,optional" form:"submit_bot_market_config" json:"submit_bot_market_config,omitempty" query:"submit_bot_market_config"`
|
||||||
PublishID *string `thrift:"publish_id,11,optional" form:"publish_id" json:"publish_id,omitempty" query:"publish_id"`
|
PublishID *string `thrift:"publish_id,11,optional" form:"publish_id" json:"publish_id,omitempty" query:"publish_id"`
|
||||||
// 指定发布某个CommitVersion
|
// Specify the release of a CommitVersion
|
||||||
CommitVersion *string `thrift:"commit_version,12,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
CommitVersion *string `thrift:"commit_version,12,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
||||||
// 发布类型,线上发布/预发布
|
// Release type, online release/pre-release
|
||||||
PublishType *PublishType `thrift:"publish_type,13,optional" form:"publish_type" json:"publish_type,omitempty" query:"publish_type"`
|
PublishType *PublishType `thrift:"publish_type,13,optional" form:"publish_type" json:"publish_type,omitempty" query:"publish_type"`
|
||||||
// 预发布其他信息
|
// Pre-release other information
|
||||||
PrePublishExt *string `thrift:"pre_publish_ext,14,optional" form:"pre_publish_ext" json:"pre_publish_ext,omitempty" query:"pre_publish_ext"`
|
PrePublishExt *string `thrift:"pre_publish_ext,14,optional" form:"pre_publish_ext" json:"pre_publish_ext,omitempty" query:"pre_publish_ext"`
|
||||||
// 替换原workinfo中的 history_info
|
// Replace the history_info in the original workinfo
|
||||||
HistoryInfo *string `thrift:"history_info,15,optional" form:"history_info" json:"history_info,omitempty" query:"history_info"`
|
HistoryInfo *string `thrift:"history_info,15,optional" form:"history_info" json:"history_info,omitempty" query:"history_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -12276,11 +12276,11 @@ func (p *PublishDraftBotRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SubmitBotMarketConfig struct {
|
type SubmitBotMarketConfig struct {
|
||||||
// 是否发布到market
|
// Whether to publish to the market
|
||||||
NeedSubmit *bool `thrift:"need_submit,1,optional" form:"need_submit" json:"need_submit,omitempty" query:"need_submit"`
|
NeedSubmit *bool `thrift:"need_submit,1,optional" form:"need_submit" json:"need_submit,omitempty" query:"need_submit"`
|
||||||
// 是否开源
|
// Is it open source?
|
||||||
OpenSource *bool `thrift:"open_source,2,optional" form:"open_source" json:"open_source,omitempty" query:"open_source"`
|
OpenSource *bool `thrift:"open_source,2,optional" form:"open_source" json:"open_source,omitempty" query:"open_source"`
|
||||||
// 分类
|
// classification
|
||||||
CategoryID *string `thrift:"category_id,3,optional" form:"category_id" json:"category_id,omitempty" query:"category_id"`
|
CategoryID *string `thrift:"category_id,3,optional" form:"category_id" json:"category_id,omitempty" query:"category_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -12540,7 +12540,7 @@ func (p *SubmitBotMarketConfig) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 工作区间各个模块的信息
|
// Information for each module in the workspace
|
||||||
type WorkInfo struct {
|
type WorkInfo struct {
|
||||||
MessageInfo *string `thrift:"message_info,1,optional" form:"message_info" json:"message_info,omitempty" query:"message_info"`
|
MessageInfo *string `thrift:"message_info,1,optional" form:"message_info" json:"message_info,omitempty" query:"message_info"`
|
||||||
Prompt *string `thrift:"prompt,2,optional" form:"prompt" json:"prompt,omitempty" query:"prompt"`
|
Prompt *string `thrift:"prompt,2,optional" form:"prompt" json:"prompt,omitempty" query:"prompt"`
|
||||||
|
|
@ -12558,13 +12558,13 @@ type WorkInfo struct {
|
||||||
SuggestReply *string `thrift:"suggest_reply,14,optional" form:"suggest_reply" json:"suggest_reply,omitempty" query:"suggest_reply"`
|
SuggestReply *string `thrift:"suggest_reply,14,optional" form:"suggest_reply" json:"suggest_reply,omitempty" query:"suggest_reply"`
|
||||||
Tts *string `thrift:"tts,15,optional" form:"tts" json:"tts,omitempty" query:"tts"`
|
Tts *string `thrift:"tts,15,optional" form:"tts" json:"tts,omitempty" query:"tts"`
|
||||||
BackgroundImageInfoList *string `thrift:"background_image_info_list,16,optional" form:"background_image_info_list" json:"background_image_info_list,omitempty" query:"background_image_info_list"`
|
BackgroundImageInfoList *string `thrift:"background_image_info_list,16,optional" form:"background_image_info_list" json:"background_image_info_list,omitempty" query:"background_image_info_list"`
|
||||||
// 快捷指令
|
// Quick Instruction
|
||||||
Shortcuts *playground.ShortcutStruct `thrift:"shortcuts,17,optional" form:"shortcuts" json:"shortcuts,omitempty" query:"shortcuts"`
|
Shortcuts *playground.ShortcutStruct `thrift:"shortcuts,17,optional" form:"shortcuts" json:"shortcuts,omitempty" query:"shortcuts"`
|
||||||
// hook配置
|
// Hook configuration
|
||||||
HookInfo *string `thrift:"hook_info,18,optional" form:"hook_info" json:"hook_info,omitempty" query:"hook_info"`
|
HookInfo *string `thrift:"hook_info,18,optional" form:"hook_info" json:"hook_info,omitempty" query:"hook_info"`
|
||||||
// 用户query收集配置
|
// User query collection configuration
|
||||||
UserQueryCollectConf *UserQueryCollectConf `thrift:"user_query_collect_conf,19,optional" form:"user_query_collect_conf" json:"user_query_collect_conf,omitempty" query:"user_query_collect_conf"`
|
UserQueryCollectConf *UserQueryCollectConf `thrift:"user_query_collect_conf,19,optional" form:"user_query_collect_conf" json:"user_query_collect_conf,omitempty" query:"user_query_collect_conf"`
|
||||||
//workflow模式编排数据
|
//Workflow pattern orchestration data
|
||||||
LayoutInfo *LayoutInfo `thrift:"layout_info,20,optional" form:"layout_info" json:"layout_info,omitempty" query:"layout_info"`
|
LayoutInfo *LayoutInfo `thrift:"layout_info,20,optional" form:"layout_info" json:"layout_info,omitempty" query:"layout_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -13751,9 +13751,9 @@ func (p *WorkInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UserQueryCollectConf struct {
|
type UserQueryCollectConf struct {
|
||||||
// 是否开启收集开关
|
// Whether to turn on the collection switch
|
||||||
IsCollected bool `thrift:"IsCollected,1" form:"is_collected" json:"is_collected"`
|
IsCollected bool `thrift:"IsCollected,1" form:"is_collected" json:"is_collected"`
|
||||||
// 隐私协议链接
|
// Privacy Policy Link
|
||||||
PrivatePolicy string `thrift:"PrivatePolicy,2" form:"private_policy" json:"private_policy"`
|
PrivatePolicy string `thrift:"PrivatePolicy,2" form:"private_policy" json:"private_policy"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -14980,17 +14980,17 @@ func (p *ListDraftBotHistoryData) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 如果保存历史信息
|
// If historical information is preserved
|
||||||
type HistoryInfo struct {
|
type HistoryInfo struct {
|
||||||
Version string `thrift:"version,1" form:"version" json:"version" query:"version"`
|
Version string `thrift:"version,1" form:"version" json:"version" query:"version"`
|
||||||
HistoryType HistoryType `thrift:"history_type,2" form:"history_type" json:"history_type" query:"history_type"`
|
HistoryType HistoryType `thrift:"history_type,2" form:"history_type" json:"history_type" query:"history_type"`
|
||||||
// 对历史记录补充的其他信息
|
// Additional information added to the historical record
|
||||||
Info string `thrift:"info,3" form:"info" json:"info" query:"info"`
|
Info string `thrift:"info,3" form:"info" json:"info" query:"info"`
|
||||||
CreateTime string `thrift:"create_time,4" form:"create_time" json:"create_time" query:"create_time"`
|
CreateTime string `thrift:"create_time,4" form:"create_time" json:"create_time" query:"create_time"`
|
||||||
ConnectorInfos []*ConnectorInfo `thrift:"connector_infos,5" form:"connector_infos" json:"connector_infos" query:"connector_infos"`
|
ConnectorInfos []*ConnectorInfo `thrift:"connector_infos,5" form:"connector_infos" json:"connector_infos" query:"connector_infos"`
|
||||||
Creator *Creator `thrift:"creator,6" form:"creator" json:"creator" query:"creator"`
|
Creator *Creator `thrift:"creator,6" form:"creator" json:"creator" query:"creator"`
|
||||||
PublishID *string `thrift:"publish_id,7,optional" form:"publish_id" json:"publish_id,omitempty" query:"publish_id"`
|
PublishID *string `thrift:"publish_id,7,optional" form:"publish_id" json:"publish_id,omitempty" query:"publish_id"`
|
||||||
// 提交时填写的说明
|
// Instructions to fill in when submitting
|
||||||
CommitRemark *string `thrift:"commit_remark,8,optional" form:"commit_remark" json:"commit_remark,omitempty" query:"commit_remark"`
|
CommitRemark *string `thrift:"commit_remark,8,optional" form:"commit_remark" json:"commit_remark,omitempty" query:"commit_remark"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -17596,9 +17596,9 @@ func (p *GetUploadAuthTokenRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UploadFileRequest struct {
|
type UploadFileRequest struct {
|
||||||
// 文件相关描述
|
// Document related description
|
||||||
FileHead *CommonFileInfo `thrift:"file_head,1" form:"file_head" json:"file_head" query:"file_head"`
|
FileHead *CommonFileInfo `thrift:"file_head,1" form:"file_head" json:"file_head" query:"file_head"`
|
||||||
// 文件数据
|
// file data
|
||||||
Data string `thrift:"data,2" form:"data" json:"data" query:"data"`
|
Data string `thrift:"data,2" form:"data" json:"data" query:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -17787,11 +17787,11 @@ func (p *UploadFileRequest) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 上传文件,文件头
|
// Upload file, file header
|
||||||
type CommonFileInfo struct {
|
type CommonFileInfo struct {
|
||||||
// 文件类型,后缀
|
// File type, suffix
|
||||||
FileType string `thrift:"file_type,1" form:"file_type" json:"file_type" query:"file_type"`
|
FileType string `thrift:"file_type,1" form:"file_type" json:"file_type" query:"file_type"`
|
||||||
// 业务类型
|
// business type
|
||||||
BizType FileBizType `thrift:"biz_type,2" form:"biz_type" json:"biz_type" query:"biz_type"`
|
BizType FileBizType `thrift:"biz_type,2" form:"biz_type" json:"biz_type" query:"biz_type"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -17977,7 +17977,7 @@ func (p *CommonFileInfo) String() string {
|
||||||
type UploadFileResponse struct {
|
type UploadFileResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
// 数据
|
// data
|
||||||
Data *UploadFileData `thrift:"data,3" form:"data" json:"data" query:"data"`
|
Data *UploadFileData `thrift:"data,3" form:"data" json:"data" query:"data"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -18215,11 +18215,11 @@ type GetTypeListRequest struct {
|
||||||
Voice *bool `thrift:"voice,2,optional" form:"voice" json:"voice,omitempty" query:"voice"`
|
Voice *bool `thrift:"voice,2,optional" form:"voice" json:"voice,omitempty" query:"voice"`
|
||||||
RawModel *bool `thrift:"raw_model,3,optional" form:"raw_model" json:"raw_model,omitempty" query:"raw_model"`
|
RawModel *bool `thrift:"raw_model,3,optional" form:"raw_model" json:"raw_model,omitempty" query:"raw_model"`
|
||||||
SpaceID *string `thrift:"space_id,4,optional" form:"space_id" json:"space_id,omitempty" query:"space_id"`
|
SpaceID *string `thrift:"space_id,4,optional" form:"space_id" json:"space_id,omitempty" query:"space_id"`
|
||||||
// 当前bot使用的模型ID,用于处理cici/doubao同步过来的bot模型不能展示的问题
|
// The model ID used by the current bot to handle issues that cannot be displayed by the bot model synchronized by cici/doubao
|
||||||
CurModelID *string `thrift:"cur_model_id,5,optional" form:"cur_model_id" json:"cur_model_id,omitempty" query:"cur_model_id"`
|
CurModelID *string `thrift:"cur_model_id,5,optional" form:"cur_model_id" json:"cur_model_id,omitempty" query:"cur_model_id"`
|
||||||
// 兼容MultiAgent,有多个cur_model_id
|
// Compatible with MultiAgent, with multiple cur_model_id
|
||||||
CurModelIds []string `thrift:"cur_model_ids,6,optional" form:"cur_model_ids" json:"cur_model_ids,omitempty" query:"cur_model_ids"`
|
CurModelIds []string `thrift:"cur_model_ids,6,optional" form:"cur_model_ids" json:"cur_model_ids,omitempty" query:"cur_model_ids"`
|
||||||
// 模型场景
|
// model scenario
|
||||||
ModelScene *ModelScene `thrift:"model_scene,7,optional" form:"model_scene" json:"model_scene,omitempty" query:"model_scene"`
|
ModelScene *ModelScene `thrift:"model_scene,7,optional" form:"model_scene" json:"model_scene,omitempty" query:"model_scene"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -18721,29 +18721,29 @@ func (p *GetTypeListRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ModelQuota struct {
|
type ModelQuota struct {
|
||||||
// 最大总 token 数量
|
// Maximum total number of tokens
|
||||||
TokenLimit int32 `thrift:"token_limit,1" form:"token_limit" json:"token_limit" query:"token_limit"`
|
TokenLimit int32 `thrift:"token_limit,1" form:"token_limit" json:"token_limit" query:"token_limit"`
|
||||||
// 最终回复最大 token 数量
|
// Final reply maximum number of tokens
|
||||||
TokenResp int32 `thrift:"token_resp,2" form:"token_resp" json:"token_resp" query:"token_resp"`
|
TokenResp int32 `thrift:"token_resp,2" form:"token_resp" json:"token_resp" query:"token_resp"`
|
||||||
// Prompt 系统最大 token 数量
|
// Prompt system maximum number of tokens
|
||||||
TokenSystem int32 `thrift:"token_system,3" form:"token_system" json:"token_system" query:"token_system"`
|
TokenSystem int32 `thrift:"token_system,3" form:"token_system" json:"token_system" query:"token_system"`
|
||||||
// Prompt 用户输入最大 token 数量
|
// Prompt user to enter maximum number of tokens
|
||||||
TokenUserIn int32 `thrift:"token_user_in,4" form:"token_user_in" json:"token_user_in" query:"token_user_in"`
|
TokenUserIn int32 `thrift:"token_user_in,4" form:"token_user_in" json:"token_user_in" query:"token_user_in"`
|
||||||
// Prompt 工具输入最大 token 数量
|
// Prompt tool to enter maximum number of tokens
|
||||||
TokenToolsIn int32 `thrift:"token_tools_in,5" form:"token_tools_in" json:"token_tools_in" query:"token_tools_in"`
|
TokenToolsIn int32 `thrift:"token_tools_in,5" form:"token_tools_in" json:"token_tools_in" query:"token_tools_in"`
|
||||||
// Prompt 工具输出最大 token 数量
|
// Prompt tool output maximum number of tokens
|
||||||
TokenToolsOut int32 `thrift:"token_tools_out,6" form:"token_tools_out" json:"token_tools_out" query:"token_tools_out"`
|
TokenToolsOut int32 `thrift:"token_tools_out,6" form:"token_tools_out" json:"token_tools_out" query:"token_tools_out"`
|
||||||
// Prompt 数据最大 token 数量
|
// Prompt data maximum number of tokens
|
||||||
TokenData int32 `thrift:"token_data,7" form:"token_data" json:"token_data" query:"token_data"`
|
TokenData int32 `thrift:"token_data,7" form:"token_data" json:"token_data" query:"token_data"`
|
||||||
// Prompt 历史最大 token 数量
|
// Prompt history maximum number of tokens
|
||||||
TokenHistory int32 `thrift:"token_history,8" form:"token_history" json:"token_history" query:"token_history"`
|
TokenHistory int32 `thrift:"token_history,8" form:"token_history" json:"token_history" query:"token_history"`
|
||||||
// Prompt 历史最大 token 数量
|
// Prompt history maximum number of tokens
|
||||||
TokenCutSwitch bool `thrift:"token_cut_switch,9" form:"token_cut_switch" json:"token_cut_switch" query:"token_cut_switch"`
|
TokenCutSwitch bool `thrift:"token_cut_switch,9" form:"token_cut_switch" json:"token_cut_switch" query:"token_cut_switch"`
|
||||||
// 输入成本
|
// input cost
|
||||||
PriceIn float64 `thrift:"price_in,10" form:"price_in" json:"price_in" query:"price_in"`
|
PriceIn float64 `thrift:"price_in,10" form:"price_in" json:"price_in" query:"price_in"`
|
||||||
// 输出成本
|
// output cost
|
||||||
PriceOut float64 `thrift:"price_out,11" form:"price_out" json:"price_out" query:"price_out"`
|
PriceOut float64 `thrift:"price_out,11" form:"price_out" json:"price_out" query:"price_out"`
|
||||||
// systemprompt输入限制,如果没有传,对输入不做限制
|
// Systemprompt input restrictions, if not passed, no input restrictions
|
||||||
SystemPromptLimit *int32 `thrift:"system_prompt_limit,12,optional" form:"system_prompt_limit" json:"system_prompt_limit,omitempty" query:"system_prompt_limit"`
|
SystemPromptLimit *int32 `thrift:"system_prompt_limit,12,optional" form:"system_prompt_limit" json:"system_prompt_limit,omitempty" query:"system_prompt_limit"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -19878,9 +19878,9 @@ func (p *ModelParamClass) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type Option struct {
|
type Option struct {
|
||||||
// option展示的值
|
// The value displayed by the option
|
||||||
Label string `thrift:"label,1" form:"label" json:"label" query:"label"`
|
Label string `thrift:"label,1" form:"label" json:"label" query:"label"`
|
||||||
// 填入的值
|
// Filled in value
|
||||||
Value string `thrift:"value,2" form:"value" json:"value" query:"value"`
|
Value string `thrift:"value,2" form:"value" json:"value" query:"value"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -20064,25 +20064,25 @@ func (p *Option) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ModelParameter struct {
|
type ModelParameter struct {
|
||||||
// 配置字段,如max_tokens
|
// Configuration fields, such as max_tokens
|
||||||
Name string `thrift:"name,1,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,1,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
// 配置字段展示名称
|
// Configure field display name
|
||||||
Label string `thrift:"label,2" form:"label" json:"label" query:"label"`
|
Label string `thrift:"label,2" form:"label" json:"label" query:"label"`
|
||||||
// 配置字段详情描述
|
// Configuration field detail description
|
||||||
Desc string `thrift:"desc,3" form:"desc" json:"desc" query:"desc"`
|
Desc string `thrift:"desc,3" form:"desc" json:"desc" query:"desc"`
|
||||||
// 类型
|
// type
|
||||||
Type ModelParamType `thrift:"type,4,required" form:"type,required" json:"type,required" query:"type,required"`
|
Type ModelParamType `thrift:"type,4,required" form:"type,required" json:"type,required" query:"type,required"`
|
||||||
// 数值类型参数,允许设置的最小值
|
// Numerical type parameters, the minimum value allowed to be set
|
||||||
Min string `thrift:"min,5" form:"min" json:"min" query:"min"`
|
Min string `thrift:"min,5" form:"min" json:"min" query:"min"`
|
||||||
// 数值类型参数,允许设置的最大值
|
// Numerical type parameter, the maximum value allowed to be set
|
||||||
Max string `thrift:"max,6" form:"max" json:"max" query:"max"`
|
Max string `thrift:"max,6" form:"max" json:"max" query:"max"`
|
||||||
// float类型参数的精度
|
// Precision of float type parameters
|
||||||
Precision int32 `thrift:"precision,7" form:"precision" json:"precision" query:"precision"`
|
Precision int32 `thrift:"precision,7" form:"precision" json:"precision" query:"precision"`
|
||||||
// 参数默认值{"default": xx, "creative":xx}
|
// Parameter default {"default": xx, "creative": xx}
|
||||||
DefaultVal *ModelParamDefaultValue `thrift:"default_val,8,required" form:"default_val,required" json:"default_val,required" query:"default_val,required"`
|
DefaultVal *ModelParamDefaultValue `thrift:"default_val,8,required" form:"default_val,required" json:"default_val,required" query:"default_val,required"`
|
||||||
// 枚举值,如response_format支持text,markdown,json
|
// Enumeration values such as response_format support text, markdown, json
|
||||||
Options []*Option `thrift:"options,9" form:"options" json:"options" query:"options"`
|
Options []*Option `thrift:"options,9" form:"options" json:"options" query:"options"`
|
||||||
// 参数分类,"Generation diversity", "Input and output length", "Output format"
|
// Parameter classification, "Generation diversity", "Input and output length", "Output format"
|
||||||
ParamClass *ModelParamClass `thrift:"param_class,10" form:"param_class" json:"param_class" query:"param_class"`
|
ParamClass *ModelParamClass `thrift:"param_class,10" form:"param_class" json:"param_class" query:"param_class"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -21435,21 +21435,21 @@ func (p *ModelSeriesInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ModelStatusDetails struct {
|
type ModelStatusDetails struct {
|
||||||
// 是否为新模型
|
// Is it a new model?
|
||||||
IsNewModel bool `thrift:"is_new_model,1" form:"is_new_model" json:"is_new_model" query:"is_new_model"`
|
IsNewModel bool `thrift:"is_new_model,1" form:"is_new_model" json:"is_new_model" query:"is_new_model"`
|
||||||
// 是否是高级模型
|
// Is it a high-level model?
|
||||||
IsAdvancedModel bool `thrift:"is_advanced_model,2" form:"is_advanced_model" json:"is_advanced_model" query:"is_advanced_model"`
|
IsAdvancedModel bool `thrift:"is_advanced_model,2" form:"is_advanced_model" json:"is_advanced_model" query:"is_advanced_model"`
|
||||||
// 是否是免费模型
|
// Is it a free model?
|
||||||
IsFreeModel bool `thrift:"is_free_model,3" form:"is_free_model" json:"is_free_model" query:"is_free_model"`
|
IsFreeModel bool `thrift:"is_free_model,3" form:"is_free_model" json:"is_free_model" query:"is_free_model"`
|
||||||
// 是否即将下架
|
// Will it be removed from the shelves soon?
|
||||||
IsUpcomingDeprecated bool `thrift:"is_upcoming_deprecated,11" form:"is_upcoming_deprecated" json:"is_upcoming_deprecated" query:"is_upcoming_deprecated"`
|
IsUpcomingDeprecated bool `thrift:"is_upcoming_deprecated,11" form:"is_upcoming_deprecated" json:"is_upcoming_deprecated" query:"is_upcoming_deprecated"`
|
||||||
// 下架日期
|
// removal date
|
||||||
DeprecatedDate string `thrift:"deprecated_date,12" form:"deprecated_date" json:"deprecated_date" query:"deprecated_date"`
|
DeprecatedDate string `thrift:"deprecated_date,12" form:"deprecated_date" json:"deprecated_date" query:"deprecated_date"`
|
||||||
// 下架替换的模型
|
// Remove the replacement model from the shelves.
|
||||||
ReplaceModelName string `thrift:"replace_model_name,13" form:"replace_model_name" json:"replace_model_name" query:"replace_model_name"`
|
ReplaceModelName string `thrift:"replace_model_name,13" form:"replace_model_name" json:"replace_model_name" query:"replace_model_name"`
|
||||||
// 最近更新信息
|
// Recently updated information
|
||||||
UpdateInfo string `thrift:"update_info,21" form:"update_info" json:"update_info" query:"update_info"`
|
UpdateInfo string `thrift:"update_info,21" form:"update_info" json:"update_info" query:"update_info"`
|
||||||
// 模型特色
|
// Model Features
|
||||||
ModelFeature ModelTagValue `thrift:"model_feature,22" form:"model_feature" json:"model_feature" query:"model_feature"`
|
ModelFeature ModelTagValue `thrift:"model_feature,22" form:"model_feature" json:"model_feature" query:"model_feature"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -21897,19 +21897,19 @@ func (p *ModelStatusDetails) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ModelAbility struct {
|
type ModelAbility struct {
|
||||||
// 是否展示cot
|
// Do you want to show cot?
|
||||||
CotDisplay *bool `thrift:"cot_display,1,optional" form:"cot_display" json:"cot_display,omitempty" query:"cot_display"`
|
CotDisplay *bool `thrift:"cot_display,1,optional" form:"cot_display" json:"cot_display,omitempty" query:"cot_display"`
|
||||||
// 是否支持function call
|
// Supports function calls
|
||||||
FunctionCall *bool `thrift:"function_call,2,optional" form:"function_call" json:"function_call,omitempty" query:"function_call"`
|
FunctionCall *bool `thrift:"function_call,2,optional" form:"function_call" json:"function_call,omitempty" query:"function_call"`
|
||||||
// 是否支持图片理解
|
// Does it support picture understanding?
|
||||||
ImageUnderstanding *bool `thrift:"image_understanding,3,optional" form:"image_understanding" json:"image_understanding,omitempty" query:"image_understanding"`
|
ImageUnderstanding *bool `thrift:"image_understanding,3,optional" form:"image_understanding" json:"image_understanding,omitempty" query:"image_understanding"`
|
||||||
// 是否支持视频理解
|
// Does it support video understanding?
|
||||||
VideoUnderstanding *bool `thrift:"video_understanding,4,optional" form:"video_understanding" json:"video_understanding,omitempty" query:"video_understanding"`
|
VideoUnderstanding *bool `thrift:"video_understanding,4,optional" form:"video_understanding" json:"video_understanding,omitempty" query:"video_understanding"`
|
||||||
// 是否支持音频理解
|
// Does it support audio understanding?
|
||||||
AudioUnderstanding *bool `thrift:"audio_understanding,5,optional" form:"audio_understanding" json:"audio_understanding,omitempty" query:"audio_understanding"`
|
AudioUnderstanding *bool `thrift:"audio_understanding,5,optional" form:"audio_understanding" json:"audio_understanding,omitempty" query:"audio_understanding"`
|
||||||
// 是否支持多模态
|
// Does it support multimodality?
|
||||||
SupportMultiModal *bool `thrift:"support_multi_modal,6,optional" form:"support_multi_modal" json:"support_multi_modal,omitempty" query:"support_multi_modal"`
|
SupportMultiModal *bool `thrift:"support_multi_modal,6,optional" form:"support_multi_modal" json:"support_multi_modal,omitempty" query:"support_multi_modal"`
|
||||||
// 是否支持续写
|
// Whether to support continuation
|
||||||
PrefillResp *bool `thrift:"prefill_resp,7,optional" form:"prefill_resp" json:"prefill_resp,omitempty" query:"prefill_resp"`
|
PrefillResp *bool `thrift:"prefill_resp,7,optional" form:"prefill_resp" json:"prefill_resp,omitempty" query:"prefill_resp"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -22393,32 +22393,32 @@ type Model struct {
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
ModelType int64 `thrift:"model_type,2" form:"model_type" json:"model_type" query:"model_type"`
|
ModelType int64 `thrift:"model_type,2" form:"model_type" json:"model_type" query:"model_type"`
|
||||||
ModelClass ModelClass `thrift:"model_class,3" form:"model_class" json:"model_class" query:"model_class"`
|
ModelClass ModelClass `thrift:"model_class,3" form:"model_class" json:"model_class" query:"model_class"`
|
||||||
// model icon的url
|
// Model icon url
|
||||||
ModelIcon string `thrift:"model_icon,4" form:"model_icon" json:"model_icon" query:"model_icon"`
|
ModelIcon string `thrift:"model_icon,4" form:"model_icon" json:"model_icon" query:"model_icon"`
|
||||||
ModelInputPrice float64 `thrift:"model_input_price,5" form:"model_input_price" json:"model_input_price" query:"model_input_price"`
|
ModelInputPrice float64 `thrift:"model_input_price,5" form:"model_input_price" json:"model_input_price" query:"model_input_price"`
|
||||||
ModelOutputPrice float64 `thrift:"model_output_price,6" form:"model_output_price" json:"model_output_price" query:"model_output_price"`
|
ModelOutputPrice float64 `thrift:"model_output_price,6" form:"model_output_price" json:"model_output_price" query:"model_output_price"`
|
||||||
ModelQuota *ModelQuota `thrift:"model_quota,7" form:"model_quota" json:"model_quota" query:"model_quota"`
|
ModelQuota *ModelQuota `thrift:"model_quota,7" form:"model_quota" json:"model_quota" query:"model_quota"`
|
||||||
// model真实名,前端计算token用
|
// Model real name, front-end calculation token
|
||||||
ModelName string `thrift:"model_name,8" form:"model_name" json:"model_name" query:"model_name"`
|
ModelName string `thrift:"model_name,8" form:"model_name" json:"model_name" query:"model_name"`
|
||||||
ModelClassName string `thrift:"model_class_name,9" form:"model_class_name" json:"model_class_name" query:"model_class_name"`
|
ModelClassName string `thrift:"model_class_name,9" form:"model_class_name" json:"model_class_name" query:"model_class_name"`
|
||||||
IsOffline bool `thrift:"is_offline,10" form:"is_offline" json:"is_offline" query:"is_offline"`
|
IsOffline bool `thrift:"is_offline,10" form:"is_offline" json:"is_offline" query:"is_offline"`
|
||||||
ModelParams []*ModelParameter `thrift:"model_params,11" form:"model_params" json:"model_params" query:"model_params"`
|
ModelParams []*ModelParameter `thrift:"model_params,11" form:"model_params" json:"model_params" query:"model_params"`
|
||||||
ModelDesc []*ModelDescGroup `thrift:"model_desc,12,optional" form:"model_desc" json:"model_desc,omitempty" query:"model_desc"`
|
ModelDesc []*ModelDescGroup `thrift:"model_desc,12,optional" form:"model_desc" json:"model_desc,omitempty" query:"model_desc"`
|
||||||
// 模型功能配置
|
// model function configuration
|
||||||
FuncConfig map[bot_common.ModelFuncConfigType]bot_common.ModelFuncConfigStatus `thrift:"func_config,13,optional" form:"func_config" json:"func_config,omitempty" query:"func_config"`
|
FuncConfig map[bot_common.ModelFuncConfigType]bot_common.ModelFuncConfigStatus `thrift:"func_config,13,optional" form:"func_config" json:"func_config,omitempty" query:"func_config"`
|
||||||
// 方舟模型节点名称
|
// Ark model node name
|
||||||
EndpointName *string `thrift:"endpoint_name,14,optional" form:"endpoint_name" json:"endpoint_name,omitempty" query:"endpoint_name"`
|
EndpointName *string `thrift:"endpoint_name,14,optional" form:"endpoint_name" json:"endpoint_name,omitempty" query:"endpoint_name"`
|
||||||
// 模型标签
|
// model label
|
||||||
ModelTagList []*ModelTag `thrift:"model_tag_list,15,optional" form:"model_tag_list" json:"model_tag_list,omitempty" query:"model_tag_list"`
|
ModelTagList []*ModelTag `thrift:"model_tag_list,15,optional" form:"model_tag_list" json:"model_tag_list,omitempty" query:"model_tag_list"`
|
||||||
// user prompt是否必须有且不能为空
|
// User prompt must have and cannot be empty
|
||||||
IsUpRequired *bool `thrift:"is_up_required,16,optional" form:"is_up_required" json:"is_up_required,omitempty" query:"is_up_required"`
|
IsUpRequired *bool `thrift:"is_up_required,16,optional" form:"is_up_required" json:"is_up_required,omitempty" query:"is_up_required"`
|
||||||
// 模型简要描述
|
// Model brief description
|
||||||
ModelBriefDesc string `thrift:"model_brief_desc,17" form:"model_brief_desc" json:"model_brief_desc" query:"model_brief_desc"`
|
ModelBriefDesc string `thrift:"model_brief_desc,17" form:"model_brief_desc" json:"model_brief_desc" query:"model_brief_desc"`
|
||||||
// 模型系列
|
// Model series
|
||||||
ModelSeries *ModelSeriesInfo `thrift:"model_series,18" form:"model_series" json:"model_series" query:"model_series"`
|
ModelSeries *ModelSeriesInfo `thrift:"model_series,18" form:"model_series" json:"model_series" query:"model_series"`
|
||||||
// 模型状态
|
// model state
|
||||||
ModelStatusDetails *ModelStatusDetails `thrift:"model_status_details,19" form:"model_status_details" json:"model_status_details" query:"model_status_details"`
|
ModelStatusDetails *ModelStatusDetails `thrift:"model_status_details,19" form:"model_status_details" json:"model_status_details" query:"model_status_details"`
|
||||||
// 模型能力
|
// model capability
|
||||||
ModelAbility *ModelAbility `thrift:"model_ability,20" form:"model_ability" json:"model_ability" query:"model_ability"`
|
ModelAbility *ModelAbility `thrift:"model_ability,20" form:"model_ability" json:"model_ability" query:"model_ability"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -24458,9 +24458,9 @@ func (p *GetTypeListResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UploadFileData struct {
|
type UploadFileData struct {
|
||||||
// 文件url
|
// File URL
|
||||||
UploadURL string `thrift:"upload_url,1" form:"upload_url" json:"upload_url" query:"upload_url"`
|
UploadURL string `thrift:"upload_url,1" form:"upload_url" json:"upload_url" query:"upload_url"`
|
||||||
// 文件uri,提交使用这个
|
// File URI, submit using this
|
||||||
UploadURI string `thrift:"upload_uri,2" form:"upload_uri" json:"upload_uri" query:"upload_uri"`
|
UploadURI string `thrift:"upload_uri,2" form:"upload_uri" json:"upload_uri" query:"upload_uri"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -25239,7 +25239,7 @@ func (p *Committer) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检查草稿是否可以提交返回
|
// Check if the draft can be submitted and returned.
|
||||||
type CheckDraftBotCommitResponse struct {
|
type CheckDraftBotCommitResponse struct {
|
||||||
Code *int64 `thrift:"code,1,optional" form:"code" json:"code,omitempty" query:"code"`
|
Code *int64 `thrift:"code,1,optional" form:"code" json:"code,omitempty" query:"code"`
|
||||||
Msg *string `thrift:"msg,2,optional" form:"msg" json:"msg,omitempty" query:"msg"`
|
Msg *string `thrift:"msg,2,optional" form:"msg" json:"msg,omitempty" query:"msg"`
|
||||||
|
|
@ -25501,11 +25501,11 @@ func (p *CheckDraftBotCommitResponse) String() string {
|
||||||
|
|
||||||
type CheckDraftBotCommitData struct {
|
type CheckDraftBotCommitData struct {
|
||||||
Status *CommitStatus `thrift:"status,1,optional" form:"status" json:"status,omitempty" query:"status"`
|
Status *CommitStatus `thrift:"status,1,optional" form:"status" json:"status,omitempty" query:"status"`
|
||||||
// 主草稿版本
|
// master draft version
|
||||||
BaseCommitVersion *string `thrift:"base_commit_version,2,optional" form:"base_commit_version" json:"base_commit_version,omitempty" query:"base_commit_version"`
|
BaseCommitVersion *string `thrift:"base_commit_version,2,optional" form:"base_commit_version" json:"base_commit_version,omitempty" query:"base_commit_version"`
|
||||||
// 主草稿提交信息
|
// Master Draft Submission Information
|
||||||
BaseCommitter *Committer `thrift:"base_committer,3,optional" form:"base_committer" json:"base_committer,omitempty" query:"base_committer"`
|
BaseCommitter *Committer `thrift:"base_committer,3,optional" form:"base_committer" json:"base_committer,omitempty" query:"base_committer"`
|
||||||
// 个人草稿版本
|
// Personal draft version
|
||||||
CommitVersion *string `thrift:"commit_version,4,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
CommitVersion *string `thrift:"commit_version,4,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -25818,7 +25818,7 @@ func (p *CheckDraftBotCommitData) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检查草稿是否可以提交请求
|
// Check if the draft can be submitted to the request
|
||||||
type CheckDraftBotCommitRequest struct {
|
type CheckDraftBotCommitRequest struct {
|
||||||
SpaceID string `thrift:"space_id,1,required" form:"space_id,required" json:"space_id,required" query:"space_id,required"`
|
SpaceID string `thrift:"space_id,1,required" form:"space_id,required" json:"space_id,required" query:"space_id,required"`
|
||||||
BotID string `thrift:"bot_id,2,required" form:"bot_id,required" json:"bot_id,required" query:"bot_id,required"`
|
BotID string `thrift:"bot_id,2,required" form:"bot_id,required" json:"bot_id,required" query:"bot_id,required"`
|
||||||
|
|
@ -26639,9 +26639,9 @@ func (p *GetOnboardingResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type OnboardingContent struct {
|
type OnboardingContent struct {
|
||||||
// 开场白
|
// opening statement
|
||||||
Prologue *string `thrift:"prologue,1,optional" form:"prologue" json:"prologue,omitempty" query:"prologue"`
|
Prologue *string `thrift:"prologue,1,optional" form:"prologue" json:"prologue,omitempty" query:"prologue"`
|
||||||
// 建议问题
|
// suggestion question
|
||||||
SuggestedQuestions []string `thrift:"suggested_questions,2,optional" form:"suggested_questions" json:"suggested_questions,omitempty" query:"suggested_questions"`
|
SuggestedQuestions []string `thrift:"suggested_questions,2,optional" form:"suggested_questions" json:"suggested_questions,omitempty" query:"suggested_questions"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -27576,49 +27576,49 @@ func (p *PublishConnectorListRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishConnectorInfo struct {
|
type PublishConnectorInfo struct {
|
||||||
// 发布平台 connector_id
|
// Publishing Platform connector_id
|
||||||
ID string `thrift:"id,1,required" form:"id,required" json:"id,required" query:"id,required"`
|
ID string `thrift:"id,1,required" form:"id,required" json:"id,required" query:"id,required"`
|
||||||
// 发布平台名称
|
// publishing platform name
|
||||||
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
// 发布平台图标
|
// publishing platform icon
|
||||||
Icon string `thrift:"icon,3,required" form:"icon,required" json:"icon,required" query:"icon,required"`
|
Icon string `thrift:"icon,3,required" form:"icon,required" json:"icon,required" query:"icon,required"`
|
||||||
// 发布平台描述
|
// Publish Platform Description
|
||||||
Desc string `thrift:"desc,4,required" form:"desc,required" json:"desc,required" query:"desc,required"`
|
Desc string `thrift:"desc,4,required" form:"desc,required" json:"desc,required" query:"desc,required"`
|
||||||
// 分享链接
|
// share link
|
||||||
ShareLink string `thrift:"share_link,5,required" form:"share_link,required" json:"share_link,required" query:"share_link,required"`
|
ShareLink string `thrift:"share_link,5,required" form:"share_link,required" json:"share_link,required" query:"share_link,required"`
|
||||||
// 配置状态 1:已绑定 2:未绑定
|
// Configuration Status 1: Bound 2: Unbound
|
||||||
ConfigStatus ConfigStatus `thrift:"config_status,6,required" form:"config_status,required" json:"config_status,required" query:"config_status,required"`
|
ConfigStatus ConfigStatus `thrift:"config_status,6,required" form:"config_status,required" json:"config_status,required" query:"config_status,required"`
|
||||||
// 最近发布时间
|
// Last Post
|
||||||
LastPublishTime int64 `thrift:"last_publish_time,7,required" form:"last_publish_time,required" json:"last_publish_time,required" query:"last_publish_time,required"`
|
LastPublishTime int64 `thrift:"last_publish_time,7,required" form:"last_publish_time,required" json:"last_publish_time,required" query:"last_publish_time,required"`
|
||||||
// 绑定类型 1:无需绑定 2:Auth 3: kv值
|
// Binding type 1: No binding required 2: Auth 3: kv value
|
||||||
BindType BindType `thrift:"bind_type,8,required" form:"bind_type,required" json:"bind_type,required" query:"bind_type,required"`
|
BindType BindType `thrift:"bind_type,8,required" form:"bind_type,required" json:"bind_type,required" query:"bind_type,required"`
|
||||||
// 绑定信息 key字段名 value是值
|
// Binding information key field name value is value
|
||||||
BindInfo map[string]string `thrift:"bind_info,9,required" form:"bind_info,required" json:"bind_info,required" query:"bind_info,required"`
|
BindInfo map[string]string `thrift:"bind_info,9,required" form:"bind_info,required" json:"bind_info,required" query:"bind_info,required"`
|
||||||
// 绑定id信息,用于解绑使用
|
// Bind id information for unbinding and use
|
||||||
BindID *string `thrift:"bind_id,10,optional" form:"bind_id" json:"bind_id,omitempty" query:"bind_id"`
|
BindID *string `thrift:"bind_id,10,optional" form:"bind_id" json:"bind_id,omitempty" query:"bind_id"`
|
||||||
// 用户授权登陆信息
|
// user authorization login information
|
||||||
AuthLoginInfo *AuthLoginInfo `thrift:"auth_login_info,11,optional" form:"auth_login_info" json:"auth_login_info,omitempty" query:"auth_login_info"`
|
AuthLoginInfo *AuthLoginInfo `thrift:"auth_login_info,11,optional" form:"auth_login_info" json:"auth_login_info,omitempty" query:"auth_login_info"`
|
||||||
// 是否为上次发布
|
// Is it the last release?
|
||||||
IsLastPublished *bool `thrift:"is_last_published,12,optional" form:"is_last_published" json:"is_last_published,omitempty" query:"is_last_published"`
|
IsLastPublished *bool `thrift:"is_last_published,12,optional" form:"is_last_published" json:"is_last_published,omitempty" query:"is_last_published"`
|
||||||
// bot渠道状态
|
// bot channel status
|
||||||
ConnectorStatus *BotConnectorStatus `thrift:"connector_status,13,optional" form:"connector_status" json:"connector_status,omitempty" query:"connector_status"`
|
ConnectorStatus *BotConnectorStatus `thrift:"connector_status,13,optional" form:"connector_status" json:"connector_status,omitempty" query:"connector_status"`
|
||||||
// 隐私政策
|
// Privacy Policy
|
||||||
PrivacyPolicy *string `thrift:"privacy_policy,14,optional" form:"privacy_policy" json:"privacy_policy,omitempty" query:"privacy_policy"`
|
PrivacyPolicy *string `thrift:"privacy_policy,14,optional" form:"privacy_policy" json:"privacy_policy,omitempty" query:"privacy_policy"`
|
||||||
// 用户协议
|
// User Agreement
|
||||||
UserAgreement *string `thrift:"user_agreement,15,optional" form:"user_agreement" json:"user_agreement,omitempty" query:"user_agreement"`
|
UserAgreement *string `thrift:"user_agreement,15,optional" form:"user_agreement" json:"user_agreement,omitempty" query:"user_agreement"`
|
||||||
// 渠道是否允许发布
|
// Is the channel allowed to publish?
|
||||||
AllowPunish *AllowPublishStatus `thrift:"allow_punish,16,optional" form:"allow_punish" json:"allow_punish,omitempty" query:"allow_punish"`
|
AllowPunish *AllowPublishStatus `thrift:"allow_punish,16,optional" form:"allow_punish" json:"allow_punish,omitempty" query:"allow_punish"`
|
||||||
// 不允许发布原因
|
// Reason for not allowing posting
|
||||||
NotAllowReason *string `thrift:"not_allow_reason,17,optional" form:"not_allow_reason" json:"not_allow_reason,omitempty" query:"not_allow_reason"`
|
NotAllowReason *string `thrift:"not_allow_reason,17,optional" form:"not_allow_reason" json:"not_allow_reason,omitempty" query:"not_allow_reason"`
|
||||||
// 配置状态toast
|
// Configuration status toast
|
||||||
ConfigStatusToast *string `thrift:"config_status_toast,18,optional" form:"config_status_toast" json:"config_status_toast,omitempty" query:"config_status_toast"`
|
ConfigStatusToast *string `thrift:"config_status_toast,18,optional" form:"config_status_toast" json:"config_status_toast,omitempty" query:"config_status_toast"`
|
||||||
// 品牌 ID
|
// Brand ID
|
||||||
BrandID *int64 `thrift:"brand_id,19,optional" form:"brand_id" json:"brand_id,omitempty" query:"brand_id"`
|
BrandID *int64 `thrift:"brand_id,19,optional" form:"brand_id" json:"brand_id,omitempty" query:"brand_id"`
|
||||||
// 支持商业化
|
// Support commercialization
|
||||||
SupportMonetization *bool `thrift:"support_monetization,20,optional" form:"support_monetization" json:"support_monetization,omitempty" query:"support_monetization"`
|
SupportMonetization *bool `thrift:"support_monetization,20,optional" form:"support_monetization" json:"support_monetization,omitempty" query:"support_monetization"`
|
||||||
// 1: 已授权,2:未授权. 目前仅 bind_type == 8 时这个字段才有
|
// 1: Authorized, 2: Unauthorized. Currently this field is only available bind_type == 8
|
||||||
AuthStatus *UserAuthStatus `thrift:"auth_status,21,optional" form:"auth_status" json:"auth_status,omitempty" query:"auth_status"`
|
AuthStatus *UserAuthStatus `thrift:"auth_status,21,optional" form:"auth_status" json:"auth_status,omitempty" query:"auth_status"`
|
||||||
// 补全信息按钮的 url
|
// URL of the complete info button
|
||||||
ToCompleteInfoURL *string `thrift:"to_complete_info_url,22,optional" form:"to_complete_info_url" json:"to_complete_info_url,omitempty" query:"to_complete_info_url"`
|
ToCompleteInfoURL *string `thrift:"to_complete_info_url,22,optional" form:"to_complete_info_url" json:"to_complete_info_url,omitempty" query:"to_complete_info_url"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -28918,7 +28918,7 @@ func (p *PublishConnectorInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SubmitBotMarketOption struct {
|
type SubmitBotMarketOption struct {
|
||||||
// 是否可以公开编排
|
// Is it possible to publicly orchestrate?
|
||||||
CanOpenSource *bool `thrift:"can_open_source,1,optional" form:"can_open_source" json:"can_open_source,omitempty" query:"can_open_source"`
|
CanOpenSource *bool `thrift:"can_open_source,1,optional" form:"can_open_source" json:"can_open_source,omitempty" query:"can_open_source"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -29320,7 +29320,7 @@ func (p *ConnectorBrandInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishTips struct {
|
type PublishTips struct {
|
||||||
// 成本承担提醒
|
// cost-bearing reminder
|
||||||
CostTips *string `thrift:"cost_tips,1,optional" form:"cost_tips" json:"cost_tips,omitempty" query:"cost_tips"`
|
CostTips *string `thrift:"cost_tips,1,optional" form:"cost_tips" json:"cost_tips,omitempty" query:"cost_tips"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -29475,11 +29475,11 @@ type PublishConnectorListResponse struct {
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
PublishConnectorList []*PublishConnectorInfo `thrift:"publish_connector_list,3" form:"publish_connector_list" json:"publish_connector_list" query:"publish_connector_list"`
|
PublishConnectorList []*PublishConnectorInfo `thrift:"publish_connector_list,3" form:"publish_connector_list" json:"publish_connector_list" query:"publish_connector_list"`
|
||||||
SubmitBotMarketOption *SubmitBotMarketOption `thrift:"submit_bot_market_option,4,optional" form:"submit_bot_market_option" json:"submit_bot_market_option,omitempty" query:"submit_bot_market_option"`
|
SubmitBotMarketOption *SubmitBotMarketOption `thrift:"submit_bot_market_option,4,optional" form:"submit_bot_market_option" json:"submit_bot_market_option,omitempty" query:"submit_bot_market_option"`
|
||||||
// 上次提交market的配置
|
// The configuration of the last submitted market
|
||||||
LastSubmitConfig *SubmitBotMarketConfig `thrift:"last_submit_config,5,optional" form:"last_submit_config" json:"last_submit_config,omitempty" query:"last_submit_config"`
|
LastSubmitConfig *SubmitBotMarketConfig `thrift:"last_submit_config,5,optional" form:"last_submit_config" json:"last_submit_config,omitempty" query:"last_submit_config"`
|
||||||
// 渠道品牌信息
|
// Channel brand information
|
||||||
ConnectorBrandInfoMap map[int64]*ConnectorBrandInfo `thrift:"connector_brand_info_map,6" form:"connector_brand_info_map" json:"connector_brand_info_map" query:"connector_brand_info_map"`
|
ConnectorBrandInfoMap map[int64]*ConnectorBrandInfo `thrift:"connector_brand_info_map,6" form:"connector_brand_info_map" json:"connector_brand_info_map" query:"connector_brand_info_map"`
|
||||||
// 发布提醒
|
// post alert
|
||||||
PublishTips *PublishTips `thrift:"publish_tips,7,optional" form:"publish_tips" json:"publish_tips,omitempty" query:"publish_tips"`
|
PublishTips *PublishTips `thrift:"publish_tips,7,optional" form:"publish_tips" json:"publish_tips,omitempty" query:"publish_tips"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,13 +3,13 @@
|
||||||
package memory
|
package memory
|
||||||
|
|
||||||
import (
|
import (
|
||||||
|
"context"
|
||||||
|
"fmt"
|
||||||
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/knowledge/document"
|
"github.com/coze-dev/coze-studio/backend/api/model/knowledge/document"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/kvmemory"
|
"github.com/coze-dev/coze-studio/backend/api/model/kvmemory"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/project_memory"
|
"github.com/coze-dev/coze-studio/backend/api/model/project_memory"
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/table"
|
"github.com/coze-dev/coze-studio/backend/api/model/table"
|
||||||
"context"
|
|
||||||
"fmt"
|
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
|
||||||
)
|
)
|
||||||
|
|
||||||
type MemoryService interface {
|
type MemoryService interface {
|
||||||
|
|
|
||||||
|
|
@ -3,25 +3,25 @@
|
||||||
package playground
|
package playground
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/ocean/cloud/bot_common"
|
|
||||||
"context"
|
"context"
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/ocean/cloud/bot_common"
|
||||||
)
|
)
|
||||||
|
|
||||||
// 分支
|
// branch
|
||||||
type Branch int64
|
type Branch int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
Branch_Undefined Branch = 0
|
Branch_Undefined Branch = 0
|
||||||
// 草稿
|
// draft
|
||||||
Branch_PersonalDraft Branch = 1
|
Branch_PersonalDraft Branch = 1
|
||||||
// space草稿
|
// Space draft
|
||||||
Branch_Base Branch = 2
|
Branch_Base Branch = 2
|
||||||
// 线上版本,diff场景下使用
|
// Online version, used in diff scenarios
|
||||||
Branch_Publish Branch = 3
|
Branch_Publish Branch = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -71,11 +71,11 @@ func (p *Branch) Value() (driver.Value, error) {
|
||||||
type DataSetType int64
|
type DataSetType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 文本
|
// Text
|
||||||
DataSetType_Text DataSetType = 0
|
DataSetType_Text DataSetType = 0
|
||||||
// 表格
|
// table
|
||||||
DataSetType_Table DataSetType = 1
|
DataSetType_Table DataSetType = 1
|
||||||
// 图片
|
// image
|
||||||
DataSetType_Image DataSetType = 2
|
DataSetType_Image DataSetType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -121,9 +121,9 @@ func (p *DataSetType) Value() (driver.Value, error) {
|
||||||
type BotMarketStatus int64
|
type BotMarketStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 下架
|
// offline
|
||||||
BotMarketStatus_Offline BotMarketStatus = 0
|
BotMarketStatus_Offline BotMarketStatus = 0
|
||||||
// 上架
|
// put on the shelves
|
||||||
BotMarketStatus_Online BotMarketStatus = 1
|
BotMarketStatus_Online BotMarketStatus = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -212,11 +212,11 @@ func (p *ConnectorDynamicStatus) Value() (driver.Value, error) {
|
||||||
type AuditStatus int64
|
type AuditStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 审核中
|
// Under review.
|
||||||
AuditStatus_Auditing AuditStatus = 0
|
AuditStatus_Auditing AuditStatus = 0
|
||||||
// 审核通过
|
// approved
|
||||||
AuditStatus_Success AuditStatus = 1
|
AuditStatus_Success AuditStatus = 1
|
||||||
// 审核失败
|
// audit failed
|
||||||
AuditStatus_Failed AuditStatus = 2
|
AuditStatus_Failed AuditStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -262,9 +262,9 @@ func (p *AuditStatus) Value() (driver.Value, error) {
|
||||||
type ScopeType int64
|
type ScopeType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 企业下所有的(企业下生效)
|
// All under the enterprise (effective under the enterprise)
|
||||||
ScopeType_All ScopeType = 0
|
ScopeType_All ScopeType = 0
|
||||||
// 我加入的(企业&个人都生效,不传默认Self)
|
// I joined (both companies and individuals are valid, no default self is passed on)
|
||||||
ScopeType_Self ScopeType = 1
|
ScopeType_Self ScopeType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -306,9 +306,9 @@ func (p *ScopeType) Value() (driver.Value, error) {
|
||||||
type SpaceType int64
|
type SpaceType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 个人
|
// individual
|
||||||
SpaceType_Personal SpaceType = 1
|
SpaceType_Personal SpaceType = 1
|
||||||
// 小组
|
// group
|
||||||
SpaceType_Team SpaceType = 2
|
SpaceType_Team SpaceType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -392,7 +392,7 @@ func (p *SpaceMode) Value() (driver.Value, error) {
|
||||||
type SpaceTag int64
|
type SpaceTag int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 专业版
|
// Professional Edition
|
||||||
SpaceTag_Professional SpaceTag = 1
|
SpaceTag_Professional SpaceTag = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -430,13 +430,13 @@ func (p *SpaceTag) Value() (driver.Value, error) {
|
||||||
type SpaceRoleType int64
|
type SpaceRoleType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 默认
|
// default
|
||||||
SpaceRoleType_Default SpaceRoleType = 0
|
SpaceRoleType_Default SpaceRoleType = 0
|
||||||
// owner
|
// owner
|
||||||
SpaceRoleType_Owner SpaceRoleType = 1
|
SpaceRoleType_Owner SpaceRoleType = 1
|
||||||
// 管理员
|
// administrator
|
||||||
SpaceRoleType_Admin SpaceRoleType = 2
|
SpaceRoleType_Admin SpaceRoleType = 2
|
||||||
// 普通成员
|
// ordinary member
|
||||||
SpaceRoleType_Member SpaceRoleType = 3
|
SpaceRoleType_Member SpaceRoleType = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -483,17 +483,17 @@ func (p *SpaceRoleType) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 申请管理列表
|
// Application management list
|
||||||
type SpaceApplyStatus int64
|
type SpaceApplyStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 所有
|
// all
|
||||||
SpaceApplyStatus_All SpaceApplyStatus = 0
|
SpaceApplyStatus_All SpaceApplyStatus = 0
|
||||||
// 已加入
|
// Joined
|
||||||
SpaceApplyStatus_Joined SpaceApplyStatus = 1
|
SpaceApplyStatus_Joined SpaceApplyStatus = 1
|
||||||
// 确认中
|
// Confirming
|
||||||
SpaceApplyStatus_Confirming SpaceApplyStatus = 2
|
SpaceApplyStatus_Confirming SpaceApplyStatus = 2
|
||||||
// 已拒绝
|
// Rejected
|
||||||
SpaceApplyStatus_Rejected SpaceApplyStatus = 3
|
SpaceApplyStatus_Rejected SpaceApplyStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1066,14 +1066,14 @@ func (p *UpdateDraftBotInfoAgwResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UpdateDraftBotInfoAgwData struct {
|
type UpdateDraftBotInfoAgwData struct {
|
||||||
// 是否有变更
|
// Is there any change?
|
||||||
HasChange *bool `thrift:"has_change,1,optional" form:"has_change" json:"has_change,omitempty" query:"has_change"`
|
HasChange *bool `thrift:"has_change,1,optional" form:"has_change" json:"has_change,omitempty" query:"has_change"`
|
||||||
// true:机审校验不通过
|
// True: The machine audit verification failed
|
||||||
CheckNotPass bool `thrift:"check_not_pass,2" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
CheckNotPass bool `thrift:"check_not_pass,2" form:"check_not_pass" json:"check_not_pass" query:"check_not_pass"`
|
||||||
// 当前是在哪个分支
|
// Which branch is it currently on?
|
||||||
Branch *Branch `thrift:"branch,3,optional" form:"branch" json:"branch,omitempty" query:"branch"`
|
Branch *Branch `thrift:"branch,3,optional" form:"branch" json:"branch,omitempty" query:"branch"`
|
||||||
SameWithOnline *bool `thrift:"same_with_online,4,optional" form:"same_with_online" json:"same_with_online,omitempty" query:"same_with_online"`
|
SameWithOnline *bool `thrift:"same_with_online,4,optional" form:"same_with_online" json:"same_with_online,omitempty" query:"same_with_online"`
|
||||||
// 机审校验不通过文案
|
// The machine audit verification failed the copy.
|
||||||
CheckNotPassMsg *string `thrift:"check_not_pass_msg,5,optional" form:"check_not_pass_msg" json:"check_not_pass_msg,omitempty" query:"check_not_pass_msg"`
|
CheckNotPassMsg *string `thrift:"check_not_pass_msg,5,optional" form:"check_not_pass_msg" json:"check_not_pass_msg,omitempty" query:"check_not_pass_msg"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1688,11 +1688,11 @@ func (p *UpdateDraftBotInfoAgwRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetDraftBotInfoAgwRequest struct {
|
type GetDraftBotInfoAgwRequest struct {
|
||||||
// 草稿bot_id
|
// Draft bot_id
|
||||||
BotID int64 `thrift:"bot_id,1,required" form:"bot_id,required" json:"bot_id,string,required" query:"bot_id,required"`
|
BotID int64 `thrift:"bot_id,1,required" form:"bot_id,required" json:"bot_id,string,required" query:"bot_id,required"`
|
||||||
// 查历史记录,历史版本的id,对应 bot_draft_history的id
|
// Check the history, the id of the historical version, corresponding to the id of the bot_draft_history
|
||||||
Version *string `thrift:"version,2,optional" form:"version" json:"version,omitempty" query:"version"`
|
Version *string `thrift:"version,2,optional" form:"version" json:"version,omitempty" query:"version"`
|
||||||
// 查询指定commit_version版本,预发布使用,貌似和version是同一个东西,但是获取逻辑有区别
|
// Query specifies commit_version version, pre-release use, seems to be the same thing as version, but the acquisition logic is different
|
||||||
CommitVersion *string `thrift:"commit_version,3,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
CommitVersion *string `thrift:"commit_version,3,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
@ -2316,45 +2316,45 @@ func (p *GetDraftBotInfoAgwResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetDraftBotInfoAgwData struct {
|
type GetDraftBotInfoAgwData struct {
|
||||||
// 核心bot数据
|
// core bot data
|
||||||
BotInfo *bot_common.BotInfo `thrift:"bot_info,1,required" form:"bot_info,required" json:"bot_info,required" query:"bot_info,required"`
|
BotInfo *bot_common.BotInfo `thrift:"bot_info,1,required" form:"bot_info,required" json:"bot_info,required" query:"bot_info,required"`
|
||||||
// bot选项信息
|
// bot option information
|
||||||
BotOptionData *BotOptionData `thrift:"bot_option_data,2,optional" form:"bot_option_data" json:"bot_option_data,omitempty" query:"bot_option_data"`
|
BotOptionData *BotOptionData `thrift:"bot_option_data,2,optional" form:"bot_option_data" json:"bot_option_data,omitempty" query:"bot_option_data"`
|
||||||
// 是否有未发布的变更
|
// Are there any unpublished changes?
|
||||||
HasUnpublishedChange *bool `thrift:"has_unpublished_change,3,optional" form:"has_unpublished_change" json:"has_unpublished_change,omitempty" query:"has_unpublished_change"`
|
HasUnpublishedChange *bool `thrift:"has_unpublished_change,3,optional" form:"has_unpublished_change" json:"has_unpublished_change,omitempty" query:"has_unpublished_change"`
|
||||||
// bot上架后的商品状态
|
// The product status after the bot is put on the shelves
|
||||||
BotMarketStatus *BotMarketStatus `thrift:"bot_market_status,4,optional" form:"bot_market_status" json:"bot_market_status,omitempty" query:"bot_market_status"`
|
BotMarketStatus *BotMarketStatus `thrift:"bot_market_status,4,optional" form:"bot_market_status" json:"bot_market_status,omitempty" query:"bot_market_status"`
|
||||||
// bot是否处于多人协作模式
|
// Is the bot in multiplayer cooperative mode?
|
||||||
InCollaboration *bool `thrift:"in_collaboration,5,optional" form:"in_collaboration" json:"in_collaboration,omitempty" query:"in_collaboration"`
|
InCollaboration *bool `thrift:"in_collaboration,5,optional" form:"in_collaboration" json:"in_collaboration,omitempty" query:"in_collaboration"`
|
||||||
// commit内容是否和线上内容一致
|
// Is the content committed consistent with the online content?
|
||||||
SameWithOnline *bool `thrift:"same_with_online,6,optional" form:"same_with_online" json:"same_with_online,omitempty" query:"same_with_online"`
|
SameWithOnline *bool `thrift:"same_with_online,6,optional" form:"same_with_online" json:"same_with_online,omitempty" query:"same_with_online"`
|
||||||
// for前端,权限相关,当前用户是否可编辑此bot
|
// For frontend, permission related, can the current user edit this bot
|
||||||
Editable *bool `thrift:"editable,7,optional" form:"editable" json:"editable,omitempty" query:"editable"`
|
Editable *bool `thrift:"editable,7,optional" form:"editable" json:"editable,omitempty" query:"editable"`
|
||||||
// for前端,权限相关,当前用户是否可删除此bot
|
// For frontend, permission related, can the current user delete this bot
|
||||||
Deletable *bool `thrift:"deletable,8,optional" form:"deletable" json:"deletable,omitempty" query:"deletable"`
|
Deletable *bool `thrift:"deletable,8,optional" form:"deletable" json:"deletable,omitempty" query:"deletable"`
|
||||||
// 是最新发布版本时传发布人
|
// Is the publisher of the latest release version
|
||||||
Publisher *UserInfo `thrift:"publisher,9,optional" form:"publisher" json:"publisher,omitempty" query:"publisher"`
|
Publisher *UserInfo `thrift:"publisher,9,optional" form:"publisher" json:"publisher,omitempty" query:"publisher"`
|
||||||
// 是否已发布
|
// Has it been published?
|
||||||
HasPublish bool `thrift:"has_publish,10" form:"has_publish" json:"has_publish" query:"has_publish"`
|
HasPublish bool `thrift:"has_publish,10" form:"has_publish" json:"has_publish" query:"has_publish"`
|
||||||
// 空间id
|
// Space ID
|
||||||
SpaceID int64 `thrift:"space_id,11" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,11" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
// 发布的业务线详情
|
// Published business line details
|
||||||
Connectors []*BotConnectorInfo `thrift:"connectors,12" form:"connectors" json:"connectors" query:"connectors"`
|
Connectors []*BotConnectorInfo `thrift:"connectors,12" form:"connectors" json:"connectors" query:"connectors"`
|
||||||
// 获取的是什么分支的内容
|
// What branch did you get the content of?
|
||||||
Branch *Branch `thrift:"branch,13,optional" form:"branch" json:"branch,omitempty" query:"branch"`
|
Branch *Branch `thrift:"branch,13,optional" form:"branch" json:"branch,omitempty" query:"branch"`
|
||||||
// 如果branch=PersonalDraft,则为checkout/rebase的版本号;如果branch=base,则为提交的版本
|
// If branch=PersonalDraft, the version number of checkout/rebase; if branch = base, the committed version
|
||||||
CommitVersion *string `thrift:"commit_version,14,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
CommitVersion *string `thrift:"commit_version,14,optional" form:"commit_version" json:"commit_version,omitempty" query:"commit_version"`
|
||||||
// for前端,最近一次的提交人
|
// For the front end, the most recent author
|
||||||
CommitterName *string `thrift:"committer_name,15,optional" form:"committer_name" json:"committer_name,omitempty" query:"committer_name"`
|
CommitterName *string `thrift:"committer_name,15,optional" form:"committer_name" json:"committer_name,omitempty" query:"committer_name"`
|
||||||
// for前端,提交时间
|
// For frontend, commit time
|
||||||
CommitTime *string `thrift:"commit_time,16,optional" form:"commit_time" json:"commit_time,omitempty" query:"commit_time"`
|
CommitTime *string `thrift:"commit_time,16,optional" form:"commit_time" json:"commit_time,omitempty" query:"commit_time"`
|
||||||
// for前端,发布时间
|
// For frontend, release time
|
||||||
PublishTime *string `thrift:"publish_time,17,optional" form:"publish_time" json:"publish_time,omitempty" query:"publish_time"`
|
PublishTime *string `thrift:"publish_time,17,optional" form:"publish_time" json:"publish_time,omitempty" query:"publish_time"`
|
||||||
// 多人协作相关操作权限
|
// Multi-person collaboration related operation permissions
|
||||||
CollaboratorStatus *BotCollaboratorStatus `thrift:"collaborator_status,18,optional" form:"collaborator_status" json:"collaborator_status,omitempty" query:"collaborator_status"`
|
CollaboratorStatus *BotCollaboratorStatus `thrift:"collaborator_status,18,optional" form:"collaborator_status" json:"collaborator_status,omitempty" query:"collaborator_status"`
|
||||||
// 最近一次审核详情
|
// Details of the most recent review
|
||||||
LatestAuditInfo *AuditInfo `thrift:"latest_audit_info,19,optional" form:"latest_audit_info" json:"latest_audit_info,omitempty" query:"latest_audit_info"`
|
LatestAuditInfo *AuditInfo `thrift:"latest_audit_info,19,optional" form:"latest_audit_info" json:"latest_audit_info,omitempty" query:"latest_audit_info"`
|
||||||
// 抖音分身的bot会有appId
|
// Douyin's doppelganger bot will have appId.
|
||||||
AppID *string `thrift:"app_id,20,optional" form:"app_id" json:"app_id,omitempty" query:"app_id"`
|
AppID *string `thrift:"app_id,20,optional" form:"app_id" json:"app_id,omitempty" query:"app_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3530,17 +3530,17 @@ func (p *GetDraftBotInfoAgwData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BotOptionData struct {
|
type BotOptionData struct {
|
||||||
// 模型详情
|
// model details
|
||||||
ModelDetailMap map[int64]*ModelDetail `thrift:"model_detail_map,1,optional" form:"model_detail_map" json:"model_detail_map,omitempty" query:"model_detail_map"`
|
ModelDetailMap map[int64]*ModelDetail `thrift:"model_detail_map,1,optional" form:"model_detail_map" json:"model_detail_map,omitempty" query:"model_detail_map"`
|
||||||
// 插件详情
|
// plugin details
|
||||||
PluginDetailMap map[int64]*PluginDetal `thrift:"plugin_detail_map,2,optional" form:"plugin_detail_map" json:"plugin_detail_map,omitempty" query:"plugin_detail_map"`
|
PluginDetailMap map[int64]*PluginDetal `thrift:"plugin_detail_map,2,optional" form:"plugin_detail_map" json:"plugin_detail_map,omitempty" query:"plugin_detail_map"`
|
||||||
// 插件API详情
|
// Plugin API Details
|
||||||
PluginAPIDetailMap map[int64]*PluginAPIDetal `thrift:"plugin_api_detail_map,3,optional" form:"plugin_api_detail_map" json:"plugin_api_detail_map,omitempty" query:"plugin_api_detail_map"`
|
PluginAPIDetailMap map[int64]*PluginAPIDetal `thrift:"plugin_api_detail_map,3,optional" form:"plugin_api_detail_map" json:"plugin_api_detail_map,omitempty" query:"plugin_api_detail_map"`
|
||||||
// workflow详情
|
// Workflow Details
|
||||||
WorkflowDetailMap map[int64]*WorkflowDetail `thrift:"workflow_detail_map,4,optional" form:"workflow_detail_map" json:"workflow_detail_map,omitempty" query:"workflow_detail_map"`
|
WorkflowDetailMap map[int64]*WorkflowDetail `thrift:"workflow_detail_map,4,optional" form:"workflow_detail_map" json:"workflow_detail_map,omitempty" query:"workflow_detail_map"`
|
||||||
// knowledge详情
|
// Knowledge Details
|
||||||
KnowledgeDetailMap map[string]*KnowledgeDetail `thrift:"knowledge_detail_map,5,optional" form:"knowledge_detail_map" json:"knowledge_detail_map,omitempty" query:"knowledge_detail_map"`
|
KnowledgeDetailMap map[string]*KnowledgeDetail `thrift:"knowledge_detail_map,5,optional" form:"knowledge_detail_map" json:"knowledge_detail_map,omitempty" query:"knowledge_detail_map"`
|
||||||
// 快捷指令list
|
// Quick command list
|
||||||
ShortcutCommandList []*ShortcutCommand `thrift:"shortcut_command_list,6,optional" form:"shortcut_command_list" json:"shortcut_command_list,omitempty" query:"shortcut_command_list"`
|
ShortcutCommandList []*ShortcutCommand `thrift:"shortcut_command_list,6,optional" form:"shortcut_command_list" json:"shortcut_command_list,omitempty" query:"shortcut_command_list"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4131,13 +4131,13 @@ func (p *BotOptionData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ModelDetail struct {
|
type ModelDetail struct {
|
||||||
// 模型展示名(对用户)
|
// Model display name (to the user)
|
||||||
Name *string `thrift:"name,1,optional" form:"name" json:"name,omitempty" query:"name"`
|
Name *string `thrift:"name,1,optional" form:"name" json:"name,omitempty" query:"name"`
|
||||||
// 模型名(对内部)
|
// Model name (for internal)
|
||||||
ModelName *string `thrift:"model_name,2,optional" form:"model_name" json:"model_name,omitempty" query:"model_name"`
|
ModelName *string `thrift:"model_name,2,optional" form:"model_name" json:"model_name,omitempty" query:"model_name"`
|
||||||
// 模型ID
|
// Model ID
|
||||||
ModelID *int64 `thrift:"model_id,3,optional" form:"model_id" json:"model_id,string,omitempty" query:"model_id"`
|
ModelID *int64 `thrift:"model_id,3,optional" form:"model_id" json:"model_id,string,omitempty" query:"model_id"`
|
||||||
// 模型类别
|
// Model Category
|
||||||
ModelFamily *int64 `thrift:"model_family,4,optional" form:"model_family" json:"model_family,omitempty" query:"model_family"`
|
ModelFamily *int64 `thrift:"model_family,4,optional" form:"model_family" json:"model_family,omitempty" query:"model_family"`
|
||||||
// IconURL
|
// IconURL
|
||||||
ModelIconURL *string `thrift:"model_icon_url,5,optional" form:"model_icon_url" json:"model_icon_url,omitempty" query:"model_icon_url"`
|
ModelIconURL *string `thrift:"model_icon_url,5,optional" form:"model_icon_url" json:"model_icon_url,omitempty" query:"model_icon_url"`
|
||||||
|
|
@ -5395,7 +5395,7 @@ type PluginParameter struct {
|
||||||
IsRequired *bool `thrift:"is_required,3,optional" form:"is_required" json:"is_required,omitempty" query:"is_required"`
|
IsRequired *bool `thrift:"is_required,3,optional" form:"is_required" json:"is_required,omitempty" query:"is_required"`
|
||||||
Type *string `thrift:"type,4,optional" form:"type" json:"type,omitempty" query:"type"`
|
Type *string `thrift:"type,4,optional" form:"type" json:"type,omitempty" query:"type"`
|
||||||
SubParameters []*PluginParameter `thrift:"sub_parameters,5,optional" form:"sub_parameters" json:"sub_parameters,omitempty" query:"sub_parameters"`
|
SubParameters []*PluginParameter `thrift:"sub_parameters,5,optional" form:"sub_parameters" json:"sub_parameters,omitempty" query:"sub_parameters"`
|
||||||
// 如果Type是数组,则有subtype
|
// If Type is an array, there is a subtype
|
||||||
SubType *string `thrift:"sub_type,6,optional" form:"sub_type" json:"sub_type,omitempty" query:"sub_type"`
|
SubType *string `thrift:"sub_type,6,optional" form:"sub_type" json:"sub_type,omitempty" query:"sub_type"`
|
||||||
AssistType *int64 `thrift:"assist_type,7,optional" form:"assist_type" json:"assist_type,omitempty" query:"assist_type"`
|
AssistType *int64 `thrift:"assist_type,7,optional" form:"assist_type" json:"assist_type,omitempty" query:"assist_type"`
|
||||||
}
|
}
|
||||||
|
|
@ -5902,9 +5902,9 @@ type WorkflowDetail struct {
|
||||||
Description *string `thrift:"description,3,optional" form:"description" json:"description,omitempty" query:"description"`
|
Description *string `thrift:"description,3,optional" form:"description" json:"description,omitempty" query:"description"`
|
||||||
IconURL *string `thrift:"icon_url,4,optional" form:"icon_url" json:"icon_url,omitempty" query:"icon_url"`
|
IconURL *string `thrift:"icon_url,4,optional" form:"icon_url" json:"icon_url,omitempty" query:"icon_url"`
|
||||||
Status *int64 `thrift:"status,5,optional" form:"status" json:"status,omitempty" query:"status"`
|
Status *int64 `thrift:"status,5,optional" form:"status" json:"status,omitempty" query:"status"`
|
||||||
// 类型,1:官方模版
|
// Type 1: Official Template
|
||||||
Type *int64 `thrift:"type,6,optional" form:"type" json:"type,omitempty" query:"type"`
|
Type *int64 `thrift:"type,6,optional" form:"type" json:"type,omitempty" query:"type"`
|
||||||
// workfklow对应的插件id
|
// Plugin ID corresponding to workfklow
|
||||||
PluginID *int64 `thrift:"plugin_id,7,optional" form:"plugin_id" json:"plugin_id,string,omitempty" query:"plugin_id"`
|
PluginID *int64 `thrift:"plugin_id,7,optional" form:"plugin_id" json:"plugin_id,string,omitempty" query:"plugin_id"`
|
||||||
IsOfficial *bool `thrift:"is_official,8,optional" form:"is_official" json:"is_official,omitempty" query:"is_official"`
|
IsOfficial *bool `thrift:"is_official,8,optional" form:"is_official" json:"is_official,omitempty" query:"is_official"`
|
||||||
APIDetail *PluginAPIDetal `thrift:"api_detail,9,optional" form:"api_detail" json:"api_detail,omitempty" query:"api_detail"`
|
APIDetail *PluginAPIDetal `thrift:"api_detail,9,optional" form:"api_detail" json:"api_detail,omitempty" query:"api_detail"`
|
||||||
|
|
@ -6801,11 +6801,11 @@ func (p *KnowledgeDetail) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UserInfo struct {
|
type UserInfo struct {
|
||||||
// 用户id
|
// user id
|
||||||
UserID int64 `thrift:"user_id,1" form:"user_id" json:"user_id,string" query:"user_id"`
|
UserID int64 `thrift:"user_id,1" form:"user_id" json:"user_id,string" query:"user_id"`
|
||||||
// 用户名称
|
// user name
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
// 用户图标
|
// user icon
|
||||||
IconURL string `thrift:"icon_url,3" form:"icon_url" json:"icon_url" query:"icon_url"`
|
IconURL string `thrift:"icon_url,3" form:"icon_url" json:"icon_url" query:"icon_url"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7363,11 +7363,11 @@ func (p *BotConnectorInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BotCollaboratorStatus struct {
|
type BotCollaboratorStatus struct {
|
||||||
// 当前用户是否可以提交
|
// Can the current user submit?
|
||||||
Commitable bool `thrift:"commitable,1" form:"commitable" json:"commitable" query:"commitable"`
|
Commitable bool `thrift:"commitable,1" form:"commitable" json:"commitable" query:"commitable"`
|
||||||
// 当前用户是否可运维
|
// Is the current user operable?
|
||||||
Operateable bool `thrift:"operateable,2" form:"operateable" json:"operateable" query:"operateable"`
|
Operateable bool `thrift:"operateable,2" form:"operateable" json:"operateable" query:"operateable"`
|
||||||
// 当前用户是否可管理协作者
|
// Can the current user manage collaborators?
|
||||||
Manageable bool `thrift:"manageable,3" form:"manageable" json:"manageable" query:"manageable"`
|
Manageable bool `thrift:"manageable,3" form:"manageable" json:"manageable" query:"manageable"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8041,11 +8041,11 @@ func (p *AuditResult) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Onboarding json结构
|
// Onboarding json structure
|
||||||
type OnboardingContent struct {
|
type OnboardingContent struct {
|
||||||
// 开场白(C端使用场景,只有1个;后台场景,可能为多个)
|
// Introductory remarks (C-end usage scenarios, only 1; background scenarios, possibly multiple)
|
||||||
Prologue *string `thrift:"prologue,1,optional" form:"prologue" json:"prologue,omitempty" query:"prologue"`
|
Prologue *string `thrift:"prologue,1,optional" form:"prologue" json:"prologue,omitempty" query:"prologue"`
|
||||||
// 建议问题
|
// suggestion question
|
||||||
SuggestedQuestions []string `thrift:"suggested_questions,2,optional" form:"suggested_questions" json:"suggested_questions,omitempty" query:"suggested_questions"`
|
SuggestedQuestions []string `thrift:"suggested_questions,2,optional" form:"suggested_questions" json:"suggested_questions,omitempty" query:"suggested_questions"`
|
||||||
SuggestedQuestionsShowMode *bot_common.SuggestedQuestionsShowMode `thrift:"suggested_questions_show_mode,3,optional" form:"suggested_questions_show_mode" json:"suggested_questions_show_mode,omitempty" query:"suggested_questions_show_mode"`
|
SuggestedQuestionsShowMode *bot_common.SuggestedQuestionsShowMode `thrift:"suggested_questions_show_mode,3,optional" form:"suggested_questions_show_mode" json:"suggested_questions_show_mode,omitempty" query:"suggested_questions_show_mode"`
|
||||||
}
|
}
|
||||||
|
|
@ -8328,17 +8328,17 @@ func (p *OnboardingContent) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetSpaceListV2Request struct {
|
type GetSpaceListV2Request struct {
|
||||||
// 搜索词
|
// Search term
|
||||||
SearchWord *string `thrift:"search_word,1,optional" form:"search_word" json:"search_word,omitempty" query:"search_word"`
|
SearchWord *string `thrift:"search_word,1,optional" form:"search_word" json:"search_word,omitempty" query:"search_word"`
|
||||||
// 企业id
|
// Enterprise ID
|
||||||
EnterpriseID *int64 `thrift:"enterprise_id,2,optional" form:"enterprise_id" json:"enterprise_id,string,omitempty" query:"enterprise_id"`
|
EnterpriseID *int64 `thrift:"enterprise_id,2,optional" form:"enterprise_id" json:"enterprise_id,string,omitempty" query:"enterprise_id"`
|
||||||
// 组织id
|
// organization id
|
||||||
OrganizationID *int64 `thrift:"organization_id,3,optional" form:"organization_id" json:"organization_id,string,omitempty" query:"organization_id"`
|
OrganizationID *int64 `thrift:"organization_id,3,optional" form:"organization_id" json:"organization_id,string,omitempty" query:"organization_id"`
|
||||||
// 范围类型
|
// range type
|
||||||
ScopeType *ScopeType `thrift:"scope_type,4,optional" form:"scope_type" json:"scope_type,omitempty" query:"scope_type"`
|
ScopeType *ScopeType `thrift:"scope_type,4,optional" form:"scope_type" json:"scope_type,omitempty" query:"scope_type"`
|
||||||
// 分页信息
|
// paging information
|
||||||
Page *int32 `thrift:"page,5,optional" form:"page" json:"page,omitempty" query:"page"`
|
Page *int32 `thrift:"page,5,optional" form:"page" json:"page,omitempty" query:"page"`
|
||||||
// 分页大小 -- page 和 size不传则认为不分页
|
// Paging size -- if page and size are not passed on, it is considered not paging
|
||||||
Size *int32 `thrift:"size,6,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int32 `thrift:"size,6,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
@ -9276,47 +9276,47 @@ func (p *ConnectorInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type BotSpaceV2 struct {
|
type BotSpaceV2 struct {
|
||||||
// 空间id,新建为0
|
// Space id, newly created as 0
|
||||||
ID int64 `thrift:"id,1" form:"id" json:"id,string" query:"id"`
|
ID int64 `thrift:"id,1" form:"id" json:"id,string" query:"id"`
|
||||||
// 发布平台
|
// publishing platform
|
||||||
AppIds []*AppIDInfo `thrift:"app_ids,2" form:"app_ids" json:"app_ids" query:"app_ids"`
|
AppIds []*AppIDInfo `thrift:"app_ids,2" form:"app_ids" json:"app_ids" query:"app_ids"`
|
||||||
// 空间名称
|
// space name
|
||||||
Name string `thrift:"name,3" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,3" form:"name" json:"name" query:"name"`
|
||||||
// 空间描述
|
// spatial description
|
||||||
Description string `thrift:"description,4" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,4" form:"description" json:"description" query:"description"`
|
||||||
// 图标url
|
// icon url
|
||||||
IconURL string `thrift:"icon_url,5" form:"icon_url" json:"icon_url" query:"icon_url"`
|
IconURL string `thrift:"icon_url,5" form:"icon_url" json:"icon_url" query:"icon_url"`
|
||||||
// 空间类型
|
// space type
|
||||||
SpaceType SpaceType `thrift:"space_type,6" form:"space_type" json:"space_type" query:"space_type"`
|
SpaceType SpaceType `thrift:"space_type,6" form:"space_type" json:"space_type" query:"space_type"`
|
||||||
// 发布平台
|
// publishing platform
|
||||||
Connectors []*ConnectorInfo `thrift:"connectors,7" form:"connectors" json:"connectors" query:"connectors"`
|
Connectors []*ConnectorInfo `thrift:"connectors,7" form:"connectors" json:"connectors" query:"connectors"`
|
||||||
// 是否隐藏新建,复制删除按钮
|
// Whether to hide New, Copy Delete buttons
|
||||||
HideOperation bool `thrift:"hide_operation,8" form:"hide_operation" json:"hide_operation" query:"hide_operation"`
|
HideOperation bool `thrift:"hide_operation,8" form:"hide_operation" json:"hide_operation" query:"hide_operation"`
|
||||||
// 在team中的角色 1-owner 2-admin 3-member
|
// Role in team 1-owner 2-admin 3-member
|
||||||
RoleType int32 `thrift:"role_type,9" form:"role_type" json:"role_type" query:"role_type"`
|
RoleType int32 `thrift:"role_type,9" form:"role_type" json:"role_type" query:"role_type"`
|
||||||
// 空间模式
|
// Spatial Mode
|
||||||
SpaceMode *SpaceMode `thrift:"space_mode,10,optional" form:"space_mode" json:"space_mode,omitempty" query:"space_mode"`
|
SpaceMode *SpaceMode `thrift:"space_mode,10,optional" form:"space_mode" json:"space_mode,omitempty" query:"space_mode"`
|
||||||
// 是否显示端侧插件创建入口
|
// Whether to display the end-side plug-in creation entry
|
||||||
DisplayLocalPlugin bool `thrift:"display_local_plugin,11" form:"display_local_plugin" json:"display_local_plugin" query:"display_local_plugin"`
|
DisplayLocalPlugin bool `thrift:"display_local_plugin,11" form:"display_local_plugin" json:"display_local_plugin" query:"display_local_plugin"`
|
||||||
// 角色类型,枚举
|
// Role type, enumeration
|
||||||
SpaceRoleType SpaceRoleType `thrift:"space_role_type,12" form:"space_role_type" json:"space_role_type" query:"space_role_type"`
|
SpaceRoleType SpaceRoleType `thrift:"space_role_type,12" form:"space_role_type" json:"space_role_type" query:"space_role_type"`
|
||||||
// 空间标签
|
// spatial label
|
||||||
SpaceTag *SpaceTag `thrift:"space_tag,13,optional" form:"space_tag" json:"space_tag,omitempty" query:"space_tag"`
|
SpaceTag *SpaceTag `thrift:"space_tag,13,optional" form:"space_tag" json:"space_tag,omitempty" query:"space_tag"`
|
||||||
// 企业id
|
// Enterprise ID
|
||||||
EnterpriseID *int64 `thrift:"enterprise_id,14,optional" form:"enterprise_id" json:"enterprise_id,string,omitempty" query:"enterprise_id"`
|
EnterpriseID *int64 `thrift:"enterprise_id,14,optional" form:"enterprise_id" json:"enterprise_id,string,omitempty" query:"enterprise_id"`
|
||||||
// 组织id
|
// organization id
|
||||||
OrganizationID *int64 `thrift:"organization_id,15,optional" form:"organization_id" json:"organization_id,string,omitempty" query:"organization_id"`
|
OrganizationID *int64 `thrift:"organization_id,15,optional" form:"organization_id" json:"organization_id,string,omitempty" query:"organization_id"`
|
||||||
// 空间owner uid
|
// Space owner uid
|
||||||
OwnerUserID *int64 `thrift:"owner_user_id,16,optional" form:"owner_user_id" json:"owner_user_id,string,omitempty" query:"owner_user_id"`
|
OwnerUserID *int64 `thrift:"owner_user_id,16,optional" form:"owner_user_id" json:"owner_user_id,string,omitempty" query:"owner_user_id"`
|
||||||
// 空间owner昵称
|
// Space owner nickname
|
||||||
OwnerName *string `thrift:"owner_name,17,optional" form:"owner_name" json:"owner_name,omitempty" query:"owner_name"`
|
OwnerName *string `thrift:"owner_name,17,optional" form:"owner_name" json:"owner_name,omitempty" query:"owner_name"`
|
||||||
// 空间owner用户名
|
// Space owner username
|
||||||
OwnerUserName *string `thrift:"owner_user_name,18,optional" form:"owner_user_name" json:"owner_user_name,omitempty" query:"owner_user_name"`
|
OwnerUserName *string `thrift:"owner_user_name,18,optional" form:"owner_user_name" json:"owner_user_name,omitempty" query:"owner_user_name"`
|
||||||
// 空间owner图像
|
// Space owner image
|
||||||
OwnerIconURL *string `thrift:"owner_icon_url,19,optional" form:"owner_icon_url" json:"owner_icon_url,omitempty" query:"owner_icon_url"`
|
OwnerIconURL *string `thrift:"owner_icon_url,19,optional" form:"owner_icon_url" json:"owner_icon_url,omitempty" query:"owner_icon_url"`
|
||||||
// 当前访问用户加入空间状态
|
// The current visiting user joins the space status
|
||||||
SpaceApplyStatus *SpaceApplyStatus `thrift:"space_apply_status,20,optional" form:"space_apply_status" json:"space_apply_status,omitempty" query:"space_apply_status"`
|
SpaceApplyStatus *SpaceApplyStatus `thrift:"space_apply_status,20,optional" form:"space_apply_status" json:"space_apply_status,omitempty" query:"space_apply_status"`
|
||||||
// 空间成员总数,只有组织空间才查询
|
// The total number of space members, only the organization space can be queried.
|
||||||
TotalMemberNum *int64 `thrift:"total_member_num,21,optional" form:"total_member_num" json:"total_member_num,omitempty" query:"total_member_num"`
|
TotalMemberNum *int64 `thrift:"total_member_num,21,optional" form:"total_member_num" json:"total_member_num,omitempty" query:"total_member_num"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10489,19 +10489,19 @@ func (p *BotSpaceV2) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type SpaceInfo struct {
|
type SpaceInfo struct {
|
||||||
// 用户加入空间列表
|
// User joins space list
|
||||||
BotSpaceList []*BotSpaceV2 `thrift:"bot_space_list,1" form:"bot_space_list" json:"bot_space_list" query:"bot_space_list"`
|
BotSpaceList []*BotSpaceV2 `thrift:"bot_space_list,1" form:"bot_space_list" json:"bot_space_list" query:"bot_space_list"`
|
||||||
// 是否有个人空间
|
// Is there any personal space available?
|
||||||
HasPersonalSpace bool `thrift:"has_personal_space,2" form:"has_personal_space" json:"has_personal_space" query:"has_personal_space"`
|
HasPersonalSpace bool `thrift:"has_personal_space,2" form:"has_personal_space" json:"has_personal_space" query:"has_personal_space"`
|
||||||
// 个人创建team空间数量
|
// Number of team spaces created by individuals
|
||||||
TeamSpaceNum int32 `thrift:"team_space_num,3" form:"team_space_num" json:"team_space_num" query:"team_space_num"`
|
TeamSpaceNum int32 `thrift:"team_space_num,3" form:"team_space_num" json:"team_space_num" query:"team_space_num"`
|
||||||
// 个人最大能创建的空间数量
|
// The maximum number of spaces an individual can create
|
||||||
MaxTeamSpaceNum int32 `thrift:"max_team_space_num,4" form:"max_team_space_num" json:"max_team_space_num" query:"max_team_space_num"`
|
MaxTeamSpaceNum int32 `thrift:"max_team_space_num,4" form:"max_team_space_num" json:"max_team_space_num" query:"max_team_space_num"`
|
||||||
// 最近使用空间列表
|
// list of recently used spaces
|
||||||
RecentlyUsedSpaceList []*BotSpaceV2 `thrift:"recently_used_space_list,5" form:"recently_used_space_list" json:"recently_used_space_list" query:"recently_used_space_list"`
|
RecentlyUsedSpaceList []*BotSpaceV2 `thrift:"recently_used_space_list,5" form:"recently_used_space_list" json:"recently_used_space_list" query:"recently_used_space_list"`
|
||||||
// 分页时生效
|
// Effective when paging
|
||||||
Total *int32 `thrift:"total,6,optional" form:"total" json:"total,omitempty" query:"total"`
|
Total *int32 `thrift:"total,6,optional" form:"total" json:"total,omitempty" query:"total"`
|
||||||
// 分页时生效
|
// Effective when paging
|
||||||
HasMore *bool `thrift:"has_more,7,optional" form:"has_more" json:"has_more,omitempty" query:"has_more"`
|
HasMore *bool `thrift:"has_more,7,optional" form:"has_more" json:"has_more,omitempty" query:"has_more"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -11583,7 +11583,7 @@ func (p *GetImagexShortUrlResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetImagexShortUrlData struct {
|
type GetImagexShortUrlData struct {
|
||||||
//审核状态,key uri,value url 和 审核状态
|
//Audit status, key uri, value url and, audit status
|
||||||
URLInfo map[string]*UrlInfo `thrift:"url_info,1" form:"url_info" json:"url_info" query:"url_info"`
|
URLInfo map[string]*UrlInfo `thrift:"url_info,1" form:"url_info" json:"url_info" query:"url_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -12192,15 +12192,15 @@ func (p *GetImagexShortUrlRequest) String() string {
|
||||||
|
|
||||||
type UserBasicInfo struct {
|
type UserBasicInfo struct {
|
||||||
UserId int64 `thrift:"UserId,1,required" form:"user_id,required" json:"user_id,string,required"`
|
UserId int64 `thrift:"UserId,1,required" form:"user_id,required" json:"user_id,string,required"`
|
||||||
// 昵称
|
// nickname
|
||||||
Username string `thrift:"Username,3,required" form:"user_name,required" json:"user_name,required"`
|
Username string `thrift:"Username,3,required" form:"user_name,required" json:"user_name,required"`
|
||||||
// 头像
|
// avatar
|
||||||
UserAvatar string `thrift:"UserAvatar,4,required" form:"user_avatar,required" json:"user_avatar,required"`
|
UserAvatar string `thrift:"UserAvatar,4,required" form:"user_avatar,required" json:"user_avatar,required"`
|
||||||
// 用户名
|
// user name
|
||||||
UserUniqueName *string `thrift:"UserUniqueName,5,optional" form:"user_unique_name" json:"user_unique_name,omitempty"`
|
UserUniqueName *string `thrift:"UserUniqueName,5,optional" form:"user_unique_name" json:"user_unique_name,omitempty"`
|
||||||
// 用户标签
|
// user tag
|
||||||
UserLabel *bot_common.UserLabel `thrift:"UserLabel,6,optional" form:"user_label" json:"user_label,omitempty"`
|
UserLabel *bot_common.UserLabel `thrift:"UserLabel,6,optional" form:"user_label" json:"user_label,omitempty"`
|
||||||
// 用户创建时间
|
// user creation time
|
||||||
CreateTime *int64 `thrift:"CreateTime,7,optional" form:"create_time" json:"create_time,omitempty"`
|
CreateTime *int64 `thrift:"CreateTime,7,optional" form:"create_time" json:"create_time,omitempty"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -12614,9 +12614,9 @@ func (p *UserBasicInfo) String() string {
|
||||||
type MGetUserBasicInfoRequest struct {
|
type MGetUserBasicInfoRequest struct {
|
||||||
UserIds []string `thrift:"UserIds,1,required" form:"user_ids,required" json:"user_ids,string,required"`
|
UserIds []string `thrift:"UserIds,1,required" form:"user_ids,required" json:"user_ids,string,required"`
|
||||||
NeedUserStatus *bool `thrift:"NeedUserStatus,2,optional" form:"need_user_status" json:"need_user_status,omitempty"`
|
NeedUserStatus *bool `thrift:"NeedUserStatus,2,optional" form:"need_user_status" json:"need_user_status,omitempty"`
|
||||||
// 是否需要企业认证信息,前端通过AGW调用时默认为true
|
// Whether enterprise authentication information is required, the default is true when the front end is called through AGW
|
||||||
NeedEnterpriseIdentity *bool `thrift:"NeedEnterpriseIdentity,3,optional" form:"need_enterprise_identity" json:"need_enterprise_identity,omitempty"`
|
NeedEnterpriseIdentity *bool `thrift:"NeedEnterpriseIdentity,3,optional" form:"need_enterprise_identity" json:"need_enterprise_identity,omitempty"`
|
||||||
// 是否需要火山用户名
|
// Do you need a volcano username?
|
||||||
NeedVolcanoUserName *bool `thrift:"NeedVolcanoUserName,4,optional" form:"need_volcano_user_name" json:"need_volcano_user_name,omitempty"`
|
NeedVolcanoUserName *bool `thrift:"NeedVolcanoUserName,4,optional" form:"need_volcano_user_name" json:"need_volcano_user_name,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
@ -14595,7 +14595,7 @@ type ReportUserBehaviorRequest struct {
|
||||||
ResourceID int64 `thrift:"ResourceID,1,required" form:"resource_id,required" json:"resource_id,string,required"`
|
ResourceID int64 `thrift:"ResourceID,1,required" form:"resource_id,required" json:"resource_id,string,required"`
|
||||||
ResourceType SpaceResourceType `thrift:"ResourceType,2,required" form:"resource_type,required" json:"resource_type,required"`
|
ResourceType SpaceResourceType `thrift:"ResourceType,2,required" form:"resource_type,required" json:"resource_type,required"`
|
||||||
BehaviorType BehaviorType `thrift:"BehaviorType,3,required" form:"behavior_type,required" json:"behavior_type,required"`
|
BehaviorType BehaviorType `thrift:"BehaviorType,3,required" form:"behavior_type,required" json:"behavior_type,required"`
|
||||||
// 本需求必传
|
// This requirement must be passed on
|
||||||
SpaceID *int64 `thrift:"SpaceID,4,optional" form:"space_id" json:"space_id,string,omitempty"`
|
SpaceID *int64 `thrift:"SpaceID,4,optional" form:"space_id" json:"space_id,string,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
@ -15882,9 +15882,9 @@ func (p *GetFileUrlsResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UploadFileOpenRequest struct {
|
type UploadFileOpenRequest struct {
|
||||||
// 文件类型
|
// file type
|
||||||
ContentType string `thrift:"ContentType,1,required" header:"Content-Type,required" json:"ContentType,required"`
|
ContentType string `thrift:"ContentType,1,required" header:"Content-Type,required" json:"ContentType,required"`
|
||||||
// 二进制数据
|
// binary data
|
||||||
Data []byte `thrift:"Data,2,required" json:"Data,required" raw_body:",required"`
|
Data []byte `thrift:"Data,2,required" json:"Data,required" raw_body:",required"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -16437,13 +16437,13 @@ func (p *UploadFileOpenResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type File struct {
|
type File struct {
|
||||||
// 文件URI
|
// File URI
|
||||||
URI string `thrift:"URI,1" form:"uri" json:"uri"`
|
URI string `thrift:"URI,1" form:"uri" json:"uri"`
|
||||||
// 文件字节数
|
// file bytes
|
||||||
Bytes int64 `thrift:"Bytes,2" form:"bytes" json:"bytes"`
|
Bytes int64 `thrift:"Bytes,2" form:"bytes" json:"bytes"`
|
||||||
// 上传时间戳,单位s
|
// Upload timestamp in s
|
||||||
CreatedAt int64 `thrift:"CreatedAt,3" form:"CreatedAt" json:"CreatedAt" query:"CreatedAt"`
|
CreatedAt int64 `thrift:"CreatedAt,3" form:"CreatedAt" json:"CreatedAt" query:"CreatedAt"`
|
||||||
// 文件名
|
// file name
|
||||||
FileName string `thrift:"FileName,4" form:"file_name" json:"file_name"`
|
FileName string `thrift:"FileName,4" form:"file_name" json:"file_name"`
|
||||||
URL string `thrift:"URL,5" form:"url" json:"url"`
|
URL string `thrift:"URL,5" form:"url" json:"url"`
|
||||||
}
|
}
|
||||||
|
|
@ -16762,9 +16762,9 @@ func (p *File) String() string {
|
||||||
type GetBotOnlineInfoReq struct {
|
type GetBotOnlineInfoReq struct {
|
||||||
// botId
|
// botId
|
||||||
BotID int64 `thrift:"bot_id,1,required" form:"bot_id,required" json:"bot_id,string,required" query:"bot_id,required"`
|
BotID int64 `thrift:"bot_id,1,required" form:"bot_id,required" json:"bot_id,string,required" query:"bot_id,required"`
|
||||||
// 先保留,不暴露且不使用该字段
|
// Keep it first, don't expose it, and don't use the field
|
||||||
ConnectorID *string `thrift:"connector_id,2,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
ConnectorID *string `thrift:"connector_id,2,optional" form:"connector_id" json:"connector_id,omitempty" query:"connector_id"`
|
||||||
// bot版本,不传则获取最新版本
|
// bot version, get the latest version if you don't pass it on.
|
||||||
Version *string `thrift:"version,3,optional" form:"version" json:"version,omitempty" query:"version"`
|
Version *string `thrift:"version,3,optional" form:"version" json:"version,omitempty" query:"version"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -17291,7 +17291,7 @@ type PlaygroundService interface {
|
||||||
UpdateBotPopupInfo(ctx context.Context, request *UpdateBotPopupInfoRequest) (r *UpdateBotPopupInfoResponse, err error)
|
UpdateBotPopupInfo(ctx context.Context, request *UpdateBotPopupInfoRequest) (r *UpdateBotPopupInfoResponse, err error)
|
||||||
|
|
||||||
ReportUserBehavior(ctx context.Context, request *ReportUserBehaviorRequest) (r *ReportUserBehaviorResponse, err error)
|
ReportUserBehavior(ctx context.Context, request *ReportUserBehaviorRequest) (r *ReportUserBehaviorResponse, err error)
|
||||||
// 创建快捷指令
|
// Create shortcut instructions
|
||||||
CreateUpdateShortcutCommand(ctx context.Context, req *CreateUpdateShortcutCommandRequest) (r *CreateUpdateShortcutCommandResponse, err error)
|
CreateUpdateShortcutCommand(ctx context.Context, req *CreateUpdateShortcutCommandRequest) (r *CreateUpdateShortcutCommandResponse, err error)
|
||||||
|
|
||||||
GetFileUrls(ctx context.Context, req *GetFileUrlsRequest) (r *GetFileUrlsResponse, err error)
|
GetFileUrls(ctx context.Context, req *GetFileUrlsRequest) (r *GetFileUrlsResponse, err error)
|
||||||
|
|
@ -17309,7 +17309,7 @@ type PlaygroundService interface {
|
||||||
MGetUserBasicInfo(ctx context.Context, request *MGetUserBasicInfoRequest) (r *MGetUserBasicInfoResponse, err error)
|
MGetUserBasicInfo(ctx context.Context, request *MGetUserBasicInfoRequest) (r *MGetUserBasicInfoResponse, err error)
|
||||||
//openapi
|
//openapi
|
||||||
GetBotOnlineInfo(ctx context.Context, request *GetBotOnlineInfoReq) (r *GetBotOnlineInfoResp, err error)
|
GetBotOnlineInfo(ctx context.Context, request *GetBotOnlineInfoReq) (r *GetBotOnlineInfoResp, err error)
|
||||||
// File 相关 OpenAPI
|
// File related OpenAPI
|
||||||
UploadFileOpen(ctx context.Context, request *UploadFileOpenRequest) (r *UploadFileOpenResponse, err error)
|
UploadFileOpen(ctx context.Context, request *UploadFileOpenRequest) (r *UploadFileOpenResponse, err error)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,25 +3,25 @@
|
||||||
package playground
|
package playground
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type ActionKey int64
|
type ActionKey int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
//复制
|
//copy
|
||||||
ActionKey_Copy ActionKey = 1
|
ActionKey_Copy ActionKey = 1
|
||||||
//删除
|
//delete
|
||||||
ActionKey_Delete ActionKey = 2
|
ActionKey_Delete ActionKey = 2
|
||||||
//启用/禁用
|
//enable/disable
|
||||||
ActionKey_EnableSwitch ActionKey = 3
|
ActionKey_EnableSwitch ActionKey = 3
|
||||||
//编辑
|
//edit
|
||||||
ActionKey_Edit ActionKey = 4
|
ActionKey_Edit ActionKey = 4
|
||||||
// 跨空间复制
|
//Cross-space copy
|
||||||
ActionKey_CrossSpaceCopy ActionKey = 10
|
ActionKey_CrossSpaceCopy ActionKey = 10
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -75,9 +75,9 @@ func (p *ActionKey) Value() (driver.Value, error) {
|
||||||
type ResourcePublishStatus int64
|
type ResourcePublishStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
//未发布
|
//unpublished
|
||||||
ResourcePublishStatus_UnPublished ResourcePublishStatus = 1
|
ResourcePublishStatus_UnPublished ResourcePublishStatus = 1
|
||||||
//已发布
|
//Published
|
||||||
ResourcePublishStatus_Published ResourcePublishStatus = 2
|
ResourcePublishStatus_Published ResourcePublishStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -2629,7 +2629,7 @@ func (p *DeletePromptResourceResponse) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 参数优先级从上往下
|
// Parameter priority from top to bottom
|
||||||
type SyncPromptResourceToEsRequest struct {
|
type SyncPromptResourceToEsRequest struct {
|
||||||
SyncAll *bool `thrift:"SyncAll,1,optional" form:"SyncAll" json:"SyncAll,omitempty" query:"SyncAll"`
|
SyncAll *bool `thrift:"SyncAll,1,optional" form:"SyncAll" json:"SyncAll,omitempty" query:"SyncAll"`
|
||||||
PromptResourceIDList []int64 `thrift:"PromptResourceIDList,2,optional" form:"PromptResourceIDList" json:"PromptResourceIDList,omitempty" query:"PromptResourceIDList"`
|
PromptResourceIDList []int64 `thrift:"PromptResourceIDList,2,optional" form:"PromptResourceIDList" json:"PromptResourceIDList,omitempty" query:"PromptResourceIDList"`
|
||||||
|
|
@ -3137,9 +3137,9 @@ func (p *SyncPromptResourceToEsResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type MGetDisplayResourceInfoRequest struct {
|
type MGetDisplayResourceInfoRequest struct {
|
||||||
// 最大传一页的数量,实现方可以限制最大100个
|
// The maximum number of one page can be transferred, and the implementer can limit the maximum to 100.
|
||||||
ResIDs []int64 `thrift:"ResIDs,1" form:"ResIDs" json:"ResIDs" query:"ResIDs"`
|
ResIDs []int64 `thrift:"ResIDs,1" form:"ResIDs" json:"ResIDs" query:"ResIDs"`
|
||||||
// 当前的用户,实现方用于判断权限
|
// The current user, the implementation is used to determine the authority
|
||||||
CurrentUserID int64 `thrift:"CurrentUserID,2" form:"CurrentUserID" json:"CurrentUserID" query:"CurrentUserID"`
|
CurrentUserID int64 `thrift:"CurrentUserID,2" form:"CurrentUserID" json:"CurrentUserID" query:"CurrentUserID"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3612,9 +3612,9 @@ func (p *MGetDisplayResourceInfoResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResourceAction struct {
|
type ResourceAction struct {
|
||||||
// 一个操作对应一个唯一的key,key由资源侧约束
|
// An operation corresponds to a unique key, and the key is constrained by the resource side
|
||||||
Key ActionKey `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
Key ActionKey `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
||||||
//ture=可以操作该Action,false=置灰
|
//ture = can operate this Action, false = grey out
|
||||||
Enable bool `thrift:"Enable,2,required" json:"enable" form:"Enable,required" query:"Enable,required"`
|
Enable bool `thrift:"Enable,2,required" json:"enable" form:"Enable,required" query:"Enable,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3812,29 +3812,29 @@ func (p *ResourceAction) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 展示用,实现方提供展示信息
|
// For display, the implementer provides display information
|
||||||
type DisplayResourceInfo struct {
|
type DisplayResourceInfo struct {
|
||||||
// 资源id
|
// Resource ID
|
||||||
ResID *int64 `thrift:"ResID,1,optional" form:"ResID" json:"ResID,omitempty" query:"ResID"`
|
ResID *int64 `thrift:"ResID,1,optional" form:"ResID" json:"ResID,omitempty" query:"ResID"`
|
||||||
// 资源描述
|
// resource description
|
||||||
Desc *string `thrift:"Desc,5,optional" form:"Desc" json:"Desc,omitempty" query:"Desc"`
|
Desc *string `thrift:"Desc,5,optional" form:"Desc" json:"Desc,omitempty" query:"Desc"`
|
||||||
// 资源Icon,完整url
|
// Resource Icon, full url
|
||||||
Icon *string `thrift:"Icon,6,optional" form:"Icon" json:"Icon,omitempty" query:"Icon"`
|
Icon *string `thrift:"Icon,6,optional" form:"Icon" json:"Icon,omitempty" query:"Icon"`
|
||||||
// 资源状态,各类型资源自身定义
|
// Resource status, each type of resource defines itself
|
||||||
BizResStatus *int32 `thrift:"BizResStatus,12,optional" form:"BizResStatus" json:"BizResStatus,omitempty" query:"BizResStatus"`
|
BizResStatus *int32 `thrift:"BizResStatus,12,optional" form:"BizResStatus" json:"BizResStatus,omitempty" query:"BizResStatus"`
|
||||||
// 是否开启多人编辑
|
// Whether to enable multi-person editing
|
||||||
CollaborationEnable *bool `thrift:"CollaborationEnable,13,optional" form:"CollaborationEnable" json:"CollaborationEnable,omitempty" query:"CollaborationEnable"`
|
CollaborationEnable *bool `thrift:"CollaborationEnable,13,optional" form:"CollaborationEnable" json:"CollaborationEnable,omitempty" query:"CollaborationEnable"`
|
||||||
// 业务携带的扩展信息,以res_type区分,每个res_type定义的schema和含义不一样,使用前需要判断res_type
|
// Business carry extended information to res_type distinguish, each res_type defined schema and meaning is not the same, need to judge before use res_type
|
||||||
BizExtend map[string]string `thrift:"BizExtend,16,optional" form:"BizExtend" json:"BizExtend,omitempty" query:"BizExtend"`
|
BizExtend map[string]string `thrift:"BizExtend,16,optional" form:"BizExtend" json:"BizExtend,omitempty" query:"BizExtend"`
|
||||||
// 不同类型的不同操作按钮,由资源实现方和前端约定。返回则展示,要隐藏某个按钮,则不要返回;
|
// Different types of different operation buttons are agreed upon by the resource implementer and the front end. Return is displayed, if you want to hide a button, do not return;
|
||||||
Actions []*ResourceAction `thrift:"Actions,17,optional" form:"Actions" json:"Actions,omitempty" query:"Actions"`
|
Actions []*ResourceAction `thrift:"Actions,17,optional" form:"Actions" json:"Actions,omitempty" query:"Actions"`
|
||||||
// 是否禁止进详情页
|
// Whether to ban entering the details page
|
||||||
DetailDisable *bool `thrift:"DetailDisable,18,optional" form:"DetailDisable" json:"DetailDisable,omitempty" query:"DetailDisable"`
|
DetailDisable *bool `thrift:"DetailDisable,18,optional" form:"DetailDisable" json:"DetailDisable,omitempty" query:"DetailDisable"`
|
||||||
// 资源名称
|
// resource name
|
||||||
Name *string `thrift:"Name,19,optional" form:"Name" json:"Name,omitempty" query:"Name"`
|
Name *string `thrift:"Name,19,optional" form:"Name" json:"Name,omitempty" query:"Name"`
|
||||||
// 资源发布状态,1-未发布,2-已发布
|
// Resource release status, 1 - unpublished, 2 - published
|
||||||
PublishStatus *ResourcePublishStatus `thrift:"PublishStatus,20,optional" form:"PublishStatus" json:"PublishStatus,omitempty" query:"PublishStatus"`
|
PublishStatus *ResourcePublishStatus `thrift:"PublishStatus,20,optional" form:"PublishStatus" json:"PublishStatus,omitempty" query:"PublishStatus"`
|
||||||
// 最近编辑时间, unix秒级时间戳
|
// Last edited, unix timestamp
|
||||||
EditTime *int64 `thrift:"EditTime,21,optional" form:"EditTime" json:"EditTime,omitempty" query:"EditTime"`
|
EditTime *int64 `thrift:"EditTime,21,optional" form:"EditTime" json:"EditTime,omitempty" query:"EditTime"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,19 +3,19 @@
|
||||||
package playground
|
package playground
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type SendType int64
|
type SendType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 直接发query
|
// Send query directly
|
||||||
SendType_SendTypeQuery SendType = 0
|
SendType_SendTypeQuery SendType = 0
|
||||||
// 使用面板
|
// use panel
|
||||||
SendType_SendTypePanel SendType = 1
|
SendType_SendTypePanel SendType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -57,9 +57,9 @@ func (p *SendType) Value() (driver.Value, error) {
|
||||||
type ToolType int64
|
type ToolType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 使用WorkFlow
|
// Using WorkFlow
|
||||||
ToolType_ToolTypeWorkFlow ToolType = 1
|
ToolType_ToolTypeWorkFlow ToolType = 1
|
||||||
// 使用插件
|
// use plug-ins
|
||||||
ToolType_ToolTypePlugin ToolType = 2
|
ToolType_ToolTypePlugin ToolType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -636,9 +636,9 @@ func (p *CreateShortcutCommandResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ShortcutStruct struct {
|
type ShortcutStruct struct {
|
||||||
// 快捷指令ID列表 实体上绑定的
|
// Shortcut ID list, bound on the entity
|
||||||
ShortcutSort []string `thrift:"shortcut_sort,16,optional" form:"shortcut_sort" json:"shortcut_sort,omitempty" query:"shortcut_sort"`
|
ShortcutSort []string `thrift:"shortcut_sort,16,optional" form:"shortcut_sort" json:"shortcut_sort,omitempty" query:"shortcut_sort"`
|
||||||
// 快捷指令内容list
|
// Quick command content list
|
||||||
ShortcutList []*ShortcutCommand `thrift:"shortcut_list,17,optional" form:"shortcut_list" json:"shortcut_list,omitempty" query:"shortcut_list"`
|
ShortcutList []*ShortcutCommand `thrift:"shortcut_list,17,optional" form:"shortcut_list" json:"shortcut_list,omitempty" query:"shortcut_list"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -884,34 +884,34 @@ func (p *ShortcutStruct) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ShortcutCommand struct {
|
type ShortcutCommand struct {
|
||||||
// 绑定实体ID
|
// Binding Entity ID
|
||||||
ObjectID int64 `thrift:"object_id,2" form:"object_id" json:"object_id,string" query:"object_id"`
|
ObjectID int64 `thrift:"object_id,2" form:"object_id" json:"object_id,string" query:"object_id"`
|
||||||
// 命令名称
|
// command name
|
||||||
CommandName string `thrift:"command_name,3" form:"command_name" json:"command_name" query:"command_name"`
|
CommandName string `thrift:"command_name,3" form:"command_name" json:"command_name" query:"command_name"`
|
||||||
// 快捷指令
|
// Quick Instruction
|
||||||
ShortcutCommand string `thrift:"shortcut_command,4" form:"shortcut_command" json:"shortcut_command" query:"shortcut_command"`
|
ShortcutCommand string `thrift:"shortcut_command,4" form:"shortcut_command" json:"shortcut_command" query:"shortcut_command"`
|
||||||
// 描述
|
// describe
|
||||||
Description string `thrift:"description,5" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,5" form:"description" json:"description" query:"description"`
|
||||||
// 发送类型
|
// Send type
|
||||||
SendType SendType `thrift:"send_type,6" form:"send_type" json:"send_type" query:"send_type"`
|
SendType SendType `thrift:"send_type,6" form:"send_type" json:"send_type" query:"send_type"`
|
||||||
// 使用工具type
|
// Use tool type
|
||||||
ToolType ToolType `thrift:"tool_type,7" form:"tool_type" json:"tool_type" query:"tool_type"`
|
ToolType ToolType `thrift:"tool_type,7" form:"tool_type" json:"tool_type" query:"tool_type"`
|
||||||
WorkFlowID string `thrift:"work_flow_id,8" form:"work_flow_id" json:"work_flow_id" query:"work_flow_id"`
|
WorkFlowID string `thrift:"work_flow_id,8" form:"work_flow_id" json:"work_flow_id" query:"work_flow_id"`
|
||||||
PluginID string `thrift:"plugin_id,9" form:"plugin_id" json:"plugin_id" query:"plugin_id"`
|
PluginID string `thrift:"plugin_id,9" form:"plugin_id" json:"plugin_id" query:"plugin_id"`
|
||||||
PluginAPIName string `thrift:"plugin_api_name,10" form:"plugin_api_name" json:"plugin_api_name" query:"plugin_api_name"`
|
PluginAPIName string `thrift:"plugin_api_name,10" form:"plugin_api_name" json:"plugin_api_name" query:"plugin_api_name"`
|
||||||
// 模板query
|
// Template query
|
||||||
TemplateQuery string `thrift:"template_query,11" form:"template_query" json:"template_query" query:"template_query"`
|
TemplateQuery string `thrift:"template_query,11" form:"template_query" json:"template_query" query:"template_query"`
|
||||||
// panel参数
|
// Panel parameters
|
||||||
ComponentsList []*Components `thrift:"components_list,12" form:"components_list" json:"components_list" query:"components_list"`
|
ComponentsList []*Components `thrift:"components_list,12" form:"components_list" json:"components_list" query:"components_list"`
|
||||||
// 表单的schema
|
// Form schema
|
||||||
CardSchema string `thrift:"card_schema,15" form:"card_schema" json:"card_schema" query:"card_schema"`
|
CardSchema string `thrift:"card_schema,15" form:"card_schema" json:"card_schema" query:"card_schema"`
|
||||||
// 指令ID
|
// Instruction ID
|
||||||
CommandID int64 `thrift:"command_id,16" form:"command_id" json:"command_id,string" query:"command_id"`
|
CommandID int64 `thrift:"command_id,16" form:"command_id" json:"command_id,string" query:"command_id"`
|
||||||
//工具信息 包含name+变量列表+...
|
//Tool information, including name + variable list +...
|
||||||
ToolInfo *ToolInfo `thrift:"tool_info,17" form:"tool_info" json:"tool_info" query:"tool_info"`
|
ToolInfo *ToolInfo `thrift:"tool_info,17" form:"tool_info" json:"tool_info" query:"tool_info"`
|
||||||
// 指令图标
|
// command icon
|
||||||
ShortcutIcon *ShortcutFileInfo `thrift:"shortcut_icon,18" form:"shortcut_icon" json:"shortcut_icon" query:"shortcut_icon"`
|
ShortcutIcon *ShortcutFileInfo `thrift:"shortcut_icon,18" form:"shortcut_icon" json:"shortcut_icon" query:"shortcut_icon"`
|
||||||
//multi的指令时,该指令由哪个节点执行
|
//Multi instruction, which node executes the instruction
|
||||||
AgentID *string `thrift:"agent_id,21,optional" form:"agent_id" json:"agent_id,omitempty" query:"agent_id"`
|
AgentID *string `thrift:"agent_id,21,optional" form:"agent_id" json:"agent_id,omitempty" query:"agent_id"`
|
||||||
PluginAPIID int64 `thrift:"plugin_api_id,22" form:"plugin_api_id" json:"plugin_api_id,string" query:"plugin_api_id"`
|
PluginAPIID int64 `thrift:"plugin_api_id,22" form:"plugin_api_id" json:"plugin_api_id,string" query:"plugin_api_id"`
|
||||||
}
|
}
|
||||||
|
|
@ -1983,17 +1983,17 @@ func (p *ShortcutFileInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type Components struct {
|
type Components struct {
|
||||||
// panel参数
|
// Panel parameters
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
Description string `thrift:"description,2" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,2" form:"description" json:"description" query:"description"`
|
||||||
InputType InputType `thrift:"input_type,3" form:"input_type" json:"input_type" query:"input_type"`
|
InputType InputType `thrift:"input_type,3" form:"input_type" json:"input_type" query:"input_type"`
|
||||||
// 请求工具时,参数的key
|
// When requesting the tool, the key of the parameter
|
||||||
Parameter string `thrift:"parameter,4" form:"parameter" json:"parameter" query:"parameter"`
|
Parameter string `thrift:"parameter,4" form:"parameter" json:"parameter" query:"parameter"`
|
||||||
Options []string `thrift:"options,5" form:"options" json:"options" query:"options"`
|
Options []string `thrift:"options,5" form:"options" json:"options" query:"options"`
|
||||||
DefaultValue *DefaultValue `thrift:"default_value,6" form:"default_value" json:"default_value" query:"default_value"`
|
DefaultValue *DefaultValue `thrift:"default_value,6" form:"default_value" json:"default_value" query:"default_value"`
|
||||||
// 是否隐藏不展示
|
// Whether to hide or not to show
|
||||||
Hide bool `thrift:"hide,7" form:"hide" json:"hide" query:"hide"`
|
Hide bool `thrift:"hide,7" form:"hide" json:"hide" query:"hide"`
|
||||||
// input_type为MixUpload时,支持哪些类型
|
// What types are supported input_type MixUpload
|
||||||
UploadOptions []InputType `thrift:"upload_options,8" form:"upload_options" json:"upload_options" query:"upload_options"`
|
UploadOptions []InputType `thrift:"upload_options,8" form:"upload_options" json:"upload_options" query:"upload_options"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2672,7 +2672,7 @@ func (p *DefaultValue) String() string {
|
||||||
|
|
||||||
type ToolInfo struct {
|
type ToolInfo struct {
|
||||||
ToolName string `thrift:"tool_name,1" form:"tool_name" json:"tool_name" query:"tool_name"`
|
ToolName string `thrift:"tool_name,1" form:"tool_name" json:"tool_name" query:"tool_name"`
|
||||||
// 变量列表 插件&workFLow
|
// Variable lists, plugins & workFLow
|
||||||
ToolParamsList []*ToolParams `thrift:"tool_params_list,2" form:"tool_params_list" json:"tool_params_list" query:"tool_params_list"`
|
ToolParamsList []*ToolParams `thrift:"tool_params_list,2" form:"tool_params_list" json:"tool_params_list" query:"tool_params_list"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2876,14 +2876,14 @@ func (p *ToolInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ToolParams struct {
|
type ToolParams struct {
|
||||||
// 参数列表
|
// parameter list
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
Required bool `thrift:"required,2" form:"required" json:"required" query:"required"`
|
Required bool `thrift:"required,2" form:"required" json:"required" query:"required"`
|
||||||
Desc string `thrift:"desc,3" form:"desc" json:"desc" query:"desc"`
|
Desc string `thrift:"desc,3" form:"desc" json:"desc" query:"desc"`
|
||||||
Type string `thrift:"type,4" form:"type" json:"type" query:"type"`
|
Type string `thrift:"type,4" form:"type" json:"type" query:"type"`
|
||||||
// 默认值
|
// default value
|
||||||
DefaultValue string `thrift:"default_value,6" form:"default_value" json:"default_value" query:"default_value"`
|
DefaultValue string `thrift:"default_value,6" form:"default_value" json:"default_value" query:"default_value"`
|
||||||
// 是否是panel参数
|
// Is it a panel parameter?
|
||||||
ReferComponent bool `thrift:"refer_component,8" form:"refer_component" json:"refer_component" query:"refer_component"`
|
ReferComponent bool `thrift:"refer_component,8" form:"refer_component" json:"refer_component" query:"refer_component"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,31 +3,31 @@
|
||||||
package plugin_develop
|
package plugin_develop
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/plugin_develop_common"
|
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/plugin_develop_common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type GetPlaygroundPluginListRequest struct {
|
type GetPlaygroundPluginListRequest struct {
|
||||||
// 页码
|
// page number
|
||||||
Page *int32 `thrift:"page,1,optional" form:"page" json:"page,omitempty"`
|
Page *int32 `thrift:"page,1,optional" form:"page" json:"page,omitempty"`
|
||||||
// 每页大小
|
// page size
|
||||||
Size *int32 `thrift:"size,2,optional" form:"size" json:"size,omitempty"`
|
Size *int32 `thrift:"size,2,optional" form:"size" json:"size,omitempty"`
|
||||||
// ignore
|
// ignore
|
||||||
Name *string `thrift:"name,4,optional" form:"name" json:"name,omitempty"`
|
Name *string `thrift:"name,4,optional" form:"name" json:"name,omitempty"`
|
||||||
// 空间id
|
// Space ID
|
||||||
SpaceID *int64 `thrift:"space_id,5,optional" form:"space_id" json:"space_id,string,omitempty"`
|
SpaceID *int64 `thrift:"space_id,5,optional" form:"space_id" json:"space_id,string,omitempty"`
|
||||||
// 如果存在,则根据插件id查询,无分页逻辑
|
// If present, query according to plug-in id, no paging logic
|
||||||
PluginIds []string `thrift:"plugin_ids,6" form:"plugin_ids" json:"plugin_ids"`
|
PluginIds []string `thrift:"plugin_ids,6" form:"plugin_ids" json:"plugin_ids"`
|
||||||
// 长度为1 ,且为workflow时,返回已发布的workflow列表,默认返回已发布的plugin列表
|
// When the length is 1 and it is a workflow, return the list of published workflows, and return the list of published plugins by default
|
||||||
PluginTypes []int32 `thrift:"plugin_types,7" form:"plugin_types" json:"plugin_types"`
|
PluginTypes []int32 `thrift:"plugin_types,7" form:"plugin_types" json:"plugin_types"`
|
||||||
// ignore
|
// ignore
|
||||||
ChannelID *int32 `thrift:"channel_id,8,optional" form:"channel_id" json:"channel_id,omitempty"`
|
ChannelID *int32 `thrift:"channel_id,8,optional" form:"channel_id" json:"channel_id,omitempty"`
|
||||||
// ignore
|
// ignore
|
||||||
SelfCreated *bool `thrift:"self_created,9,optional" form:"self_created" json:"self_created,omitempty"`
|
SelfCreated *bool `thrift:"self_created,9,optional" form:"self_created" json:"self_created,omitempty"`
|
||||||
// 排序
|
// sort
|
||||||
OrderBy *int32 `thrift:"order_by,10,optional" form:"order_by" json:"order_by,omitempty"`
|
OrderBy *int32 `thrift:"order_by,10,optional" form:"order_by" json:"order_by,omitempty"`
|
||||||
// ignore
|
// ignore
|
||||||
IsGetOffline *bool `thrift:"is_get_offline,11,optional" form:"is_get_offline" json:"is_get_offline,omitempty"`
|
IsGetOffline *bool `thrift:"is_get_offline,11,optional" form:"is_get_offline" json:"is_get_offline,omitempty"`
|
||||||
|
|
@ -1095,13 +1095,13 @@ func (p *GetPlaygroundPluginListResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetPluginAPIsRequest struct {
|
type GetPluginAPIsRequest struct {
|
||||||
// 插件id
|
// Plugin ID
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
||||||
// 如果存在,则根据工具id查询,无分页逻辑
|
// If present, query according to tool id, no paging logic
|
||||||
APIIds []string `thrift:"api_ids,2" form:"api_ids" json:"api_ids" query:"api_ids"`
|
APIIds []string `thrift:"api_ids,2" form:"api_ids" json:"api_ids" query:"api_ids"`
|
||||||
// 页码
|
// page number
|
||||||
Page int32 `thrift:"page,3" form:"page" json:"page" query:"page"`
|
Page int32 `thrift:"page,3" form:"page" json:"page" query:"page"`
|
||||||
// 每页大小
|
// page size
|
||||||
Size int32 `thrift:"size,4" form:"size" json:"size" query:"size"`
|
Size int32 `thrift:"size,4" form:"size" json:"size" query:"size"`
|
||||||
// ignore
|
// ignore
|
||||||
Order *plugin_develop_common.APIListOrder `thrift:"order,5" form:"order" json:"order" query:"order"`
|
Order *plugin_develop_common.APIListOrder `thrift:"order,5" form:"order" json:"order" query:"order"`
|
||||||
|
|
@ -1955,7 +1955,7 @@ func (p *GetPluginAPIsResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetUpdatedAPIsRequest struct {
|
type GetUpdatedAPIsRequest struct {
|
||||||
// 插件id
|
// Plugin ID
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -2158,11 +2158,11 @@ func (p *GetUpdatedAPIsRequest) String() string {
|
||||||
type GetUpdatedAPIsResponse struct {
|
type GetUpdatedAPIsResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
// 新创建的工具名
|
// Newly created tool name
|
||||||
CreatedAPINames []string `thrift:"created_api_names,3" form:"created_api_names" json:"created_api_names" query:"created_api_names"`
|
CreatedAPINames []string `thrift:"created_api_names,3" form:"created_api_names" json:"created_api_names" query:"created_api_names"`
|
||||||
// 被删除的工具名
|
// Deleted tool name
|
||||||
DeletedAPINames []string `thrift:"deleted_api_names,4" form:"deleted_api_names" json:"deleted_api_names" query:"deleted_api_names"`
|
DeletedAPINames []string `thrift:"deleted_api_names,4" form:"deleted_api_names" json:"deleted_api_names" query:"deleted_api_names"`
|
||||||
// 被更新的工具名
|
// updated tool name
|
||||||
UpdatedAPINames []string `thrift:"updated_api_names,5" form:"updated_api_names" json:"updated_api_names" query:"updated_api_names"`
|
UpdatedAPINames []string `thrift:"updated_api_names,5" form:"updated_api_names" json:"updated_api_names" query:"updated_api_names"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"BaseResp" json:"BaseResp,omitempty" query:"BaseResp"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"BaseResp" json:"BaseResp,omitempty" query:"BaseResp"`
|
||||||
}
|
}
|
||||||
|
|
@ -2591,7 +2591,7 @@ func (p *GetUpdatedAPIsResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetPluginInfoRequest struct {
|
type GetPluginInfoRequest struct {
|
||||||
// 目前只支持插件openapi插件的信息
|
// Currently only plugins are supported OpenAPI plugin information
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
||||||
// ignore
|
// ignore
|
||||||
PreviewVersionTsx *string `thrift:"preview_version_tsx,2,optional" form:"preview_version_tsx" json:"preview_version_tsx,omitempty" query:"preview_version_tsx"`
|
PreviewVersionTsx *string `thrift:"preview_version_tsx,2,optional" form:"preview_version_tsx" json:"preview_version_tsx,omitempty" query:"preview_version_tsx"`
|
||||||
|
|
@ -2853,11 +2853,11 @@ type GetPluginInfoResponse struct {
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
MetaInfo *plugin_develop_common.PluginMetaInfo `thrift:"meta_info,3" form:"meta_info" json:"meta_info" query:"meta_info"`
|
MetaInfo *plugin_develop_common.PluginMetaInfo `thrift:"meta_info,3" form:"meta_info" json:"meta_info" query:"meta_info"`
|
||||||
CodeInfo *plugin_develop_common.CodeInfo `thrift:"code_info,4" form:"code_info" json:"code_info" query:"code_info"`
|
CodeInfo *plugin_develop_common.CodeInfo `thrift:"code_info,4" form:"code_info" json:"code_info" query:"code_info"`
|
||||||
// 0 无更新 1 有更新未发布
|
// 0 No updates 1 Yes updates Not released
|
||||||
Status bool `thrift:"status,5" form:"status" json:"status" query:"status"`
|
Status bool `thrift:"status,5" form:"status" json:"status" query:"status"`
|
||||||
// 是否已发布
|
// Has it been published?
|
||||||
Published bool `thrift:"published,6" form:"published" json:"published" query:"published"`
|
Published bool `thrift:"published,6" form:"published" json:"published" query:"published"`
|
||||||
// 创建人信息
|
// creator information
|
||||||
Creator *plugin_develop_common.Creator `thrift:"creator,7" form:"creator" json:"creator" query:"creator"`
|
Creator *plugin_develop_common.Creator `thrift:"creator,7" form:"creator" json:"creator" query:"creator"`
|
||||||
// ignore
|
// ignore
|
||||||
StatisticData *plugin_develop_common.PluginStatisticData `thrift:"statistic_data,8" form:"statistic_data" json:"statistic_data" query:"statistic_data"`
|
StatisticData *plugin_develop_common.PluginStatisticData `thrift:"statistic_data,8" form:"statistic_data" json:"statistic_data" query:"statistic_data"`
|
||||||
|
|
@ -4572,27 +4572,27 @@ func (p *UpdatePluginResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type RegisterPluginMetaRequest struct {
|
type RegisterPluginMetaRequest struct {
|
||||||
// 插件名
|
// plugin name
|
||||||
Name string `thrift:"name,1,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,1,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
// 插件描述
|
// Plugin description
|
||||||
Desc string `thrift:"desc,2,required" form:"desc,required" json:"desc,required" query:"desc,required"`
|
Desc string `thrift:"desc,2,required" form:"desc,required" json:"desc,required" query:"desc,required"`
|
||||||
// 插件服务地址前缀
|
// Plugin service address prefix
|
||||||
URL *string `thrift:"url,3,optional" form:"url" json:"url,omitempty" query:"url"`
|
URL *string `thrift:"url,3,optional" form:"url" json:"url,omitempty" query:"url"`
|
||||||
// 插件图标
|
// plugin icon
|
||||||
Icon *plugin_develop_common.PluginIcon `thrift:"icon,4,required" form:"icon,required" json:"icon,required" query:"icon,required"`
|
Icon *plugin_develop_common.PluginIcon `thrift:"icon,4,required" form:"icon,required" json:"icon,required" query:"icon,required"`
|
||||||
// 插件授权类型
|
// plug-in authorization type
|
||||||
AuthType *plugin_develop_common.AuthorizationType `thrift:"auth_type,5,optional" form:"auth_type" json:"auth_type,omitempty" query:"auth_type"`
|
AuthType *plugin_develop_common.AuthorizationType `thrift:"auth_type,5,optional" form:"auth_type" json:"auth_type,omitempty" query:"auth_type"`
|
||||||
// 子授权类型为api/token时,token参数位置
|
// When the sub-authorization type is api/token, the token parameter position
|
||||||
Location *plugin_develop_common.AuthorizationServiceLocation `thrift:"location,6,optional" form:"location" json:"location,omitempty" query:"location"`
|
Location *plugin_develop_common.AuthorizationServiceLocation `thrift:"location,6,optional" form:"location" json:"location,omitempty" query:"location"`
|
||||||
// 子授权类型为api/token时,token参数key
|
// When the sub-authorization type is api/token, the token parameter key
|
||||||
Key *string `thrift:"key,7,optional" form:"key" json:"key,omitempty" query:"key"`
|
Key *string `thrift:"key,7,optional" form:"key" json:"key,omitempty" query:"key"`
|
||||||
// 子授权类型为api/token时,token参数value
|
// When the sub-authorization type is api/token, the token parameter value
|
||||||
ServiceToken *string `thrift:"service_token,8,optional" form:"service_token" json:"service_token,omitempty" query:"service_token"`
|
ServiceToken *string `thrift:"service_token,8,optional" form:"service_token" json:"service_token,omitempty" query:"service_token"`
|
||||||
// 授权类型为oauth是,oauth信息,见GetOAuthSchema返回值
|
// The authorization type is oauth Yes, oauth information, see GetOAuthSchema return value
|
||||||
OauthInfo *string `thrift:"oauth_info,9,optional" form:"oauth_info" json:"oauth_info,omitempty" query:"oauth_info"`
|
OauthInfo *string `thrift:"oauth_info,9,optional" form:"oauth_info" json:"oauth_info,omitempty" query:"oauth_info"`
|
||||||
// 空间id
|
// Space ID
|
||||||
SpaceID int64 `thrift:"space_id,10,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
SpaceID int64 `thrift:"space_id,10,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
||||||
// 插件公共参数,key为参数位置,value为参数列表
|
// Plugin public parameters, key is the parameter position, value is the parameter list
|
||||||
CommonParams map[plugin_develop_common.ParameterLocation][]*plugin_develop_common.CommonParamSchema `thrift:"common_params,11,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
CommonParams map[plugin_develop_common.ParameterLocation][]*plugin_develop_common.CommonParamSchema `thrift:"common_params,11,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
||||||
// ignore
|
// ignore
|
||||||
CreationMethod *plugin_develop_common.CreationMethod `thrift:"creation_method,12,optional" form:"creation_method" json:"creation_method,omitempty" query:"creation_method"`
|
CreationMethod *plugin_develop_common.CreationMethod `thrift:"creation_method,12,optional" form:"creation_method" json:"creation_method,omitempty" query:"creation_method"`
|
||||||
|
|
@ -4600,9 +4600,9 @@ type RegisterPluginMetaRequest struct {
|
||||||
IdeCodeRuntime *string `thrift:"ide_code_runtime,13,optional" form:"ide_code_runtime" json:"ide_code_runtime,omitempty" query:"ide_code_runtime"`
|
IdeCodeRuntime *string `thrift:"ide_code_runtime,13,optional" form:"ide_code_runtime" json:"ide_code_runtime,omitempty" query:"ide_code_runtime"`
|
||||||
// ignore
|
// ignore
|
||||||
PluginType *plugin_develop_common.PluginType `thrift:"plugin_type,14,optional" form:"plugin_type" json:"plugin_type,omitempty" query:"plugin_type"`
|
PluginType *plugin_develop_common.PluginType `thrift:"plugin_type,14,optional" form:"plugin_type" json:"plugin_type,omitempty" query:"plugin_type"`
|
||||||
// 应用id
|
// App ID
|
||||||
ProjectID *int64 `thrift:"project_id,15,optional" form:"project_id" json:"project_id,string,omitempty" query:"project_id"`
|
ProjectID *int64 `thrift:"project_id,15,optional" form:"project_id" json:"project_id,string,omitempty" query:"project_id"`
|
||||||
// 二级授权类型,0:api/token of service,10:client credentials of oauth
|
// Level 2 authorization type, 0: api/token of service, 10: client credentials of oauth
|
||||||
SubAuthType *int32 `thrift:"sub_auth_type,16,optional" form:"sub_auth_type" json:"sub_auth_type,omitempty" query:"sub_auth_type"`
|
SubAuthType *int32 `thrift:"sub_auth_type,16,optional" form:"sub_auth_type" json:"sub_auth_type,omitempty" query:"sub_auth_type"`
|
||||||
// ignore
|
// ignore
|
||||||
AuthPayload *string `thrift:"auth_payload,17,optional" form:"auth_payload" json:"auth_payload,omitempty" query:"auth_payload"`
|
AuthPayload *string `thrift:"auth_payload,17,optional" form:"auth_payload" json:"auth_payload,omitempty" query:"auth_payload"`
|
||||||
|
|
@ -6078,22 +6078,22 @@ type UpdatePluginMetaRequest struct {
|
||||||
URL *string `thrift:"url,4,optional" form:"url" json:"url,omitempty" query:"url"`
|
URL *string `thrift:"url,4,optional" form:"url" json:"url,omitempty" query:"url"`
|
||||||
Icon *plugin_develop_common.PluginIcon `thrift:"icon,5,optional" form:"icon" json:"icon,omitempty" query:"icon"`
|
Icon *plugin_develop_common.PluginIcon `thrift:"icon,5,optional" form:"icon" json:"icon,omitempty" query:"icon"`
|
||||||
AuthType *plugin_develop_common.AuthorizationType `thrift:"auth_type,6,optional" form:"auth_type" json:"auth_type,omitempty" query:"auth_type"`
|
AuthType *plugin_develop_common.AuthorizationType `thrift:"auth_type,6,optional" form:"auth_type" json:"auth_type,omitempty" query:"auth_type"`
|
||||||
// 子授权类型为api/token时,token参数位置
|
// When the sub-authorization type is api/token, the token parameter position
|
||||||
Location *plugin_develop_common.AuthorizationServiceLocation `thrift:"location,7,optional" form:"location" json:"location,omitempty" query:"location"`
|
Location *plugin_develop_common.AuthorizationServiceLocation `thrift:"location,7,optional" form:"location" json:"location,omitempty" query:"location"`
|
||||||
// 子授权类型为api/token时,token参数key
|
// When the sub-authorization type is api/token, the token parameter key
|
||||||
Key *string `thrift:"key,8,optional" form:"key" json:"key,omitempty" query:"key"`
|
Key *string `thrift:"key,8,optional" form:"key" json:"key,omitempty" query:"key"`
|
||||||
// 子授权类型为api/token时,token参数value
|
// When the sub-authorization type is api/token, the token parameter value
|
||||||
ServiceToken *string `thrift:"service_token,9,optional" form:"service_token" json:"service_token,omitempty" query:"service_token"`
|
ServiceToken *string `thrift:"service_token,9,optional" form:"service_token" json:"service_token,omitempty" query:"service_token"`
|
||||||
// 子授权类型为oauth时,oauth信息,见GetOAuthSchema返回值
|
// When the sub-authorization type is oauth, for oauth information, see GetOAuthSchema return value
|
||||||
OauthInfo *string `thrift:"oauth_info,10,optional" form:"oauth_info" json:"oauth_info,omitempty" query:"oauth_info"`
|
OauthInfo *string `thrift:"oauth_info,10,optional" form:"oauth_info" json:"oauth_info,omitempty" query:"oauth_info"`
|
||||||
// json序列化
|
// JSON serialization
|
||||||
CommonParams map[plugin_develop_common.ParameterLocation][]*plugin_develop_common.CommonParamSchema `thrift:"common_params,11,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
CommonParams map[plugin_develop_common.ParameterLocation][]*plugin_develop_common.CommonParamSchema `thrift:"common_params,11,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
||||||
// ignore
|
// ignore
|
||||||
CreationMethod *plugin_develop_common.CreationMethod `thrift:"creation_method,12,optional" form:"creation_method" json:"creation_method,omitempty" query:"creation_method"`
|
CreationMethod *plugin_develop_common.CreationMethod `thrift:"creation_method,12,optional" form:"creation_method" json:"creation_method,omitempty" query:"creation_method"`
|
||||||
// ignore
|
// ignore
|
||||||
EditVersion *int32 `thrift:"edit_version,13,optional" form:"edit_version" json:"edit_version,omitempty" query:"edit_version"`
|
EditVersion *int32 `thrift:"edit_version,13,optional" form:"edit_version" json:"edit_version,omitempty" query:"edit_version"`
|
||||||
PluginType *plugin_develop_common.PluginType `thrift:"plugin_type,14,optional" form:"plugin_type" json:"plugin_type,omitempty" query:"plugin_type"`
|
PluginType *plugin_develop_common.PluginType `thrift:"plugin_type,14,optional" form:"plugin_type" json:"plugin_type,omitempty" query:"plugin_type"`
|
||||||
// 二级授权类型
|
// Level 2 authorization type
|
||||||
SubAuthType *int32 `thrift:"sub_auth_type,15,optional" form:"sub_auth_type" json:"sub_auth_type,omitempty" query:"sub_auth_type"`
|
SubAuthType *int32 `thrift:"sub_auth_type,15,optional" form:"sub_auth_type" json:"sub_auth_type,omitempty" query:"sub_auth_type"`
|
||||||
// ignore
|
// ignore
|
||||||
AuthPayload *string `thrift:"auth_payload,16,optional" form:"auth_payload" json:"auth_payload,omitempty" query:"auth_payload"`
|
AuthPayload *string `thrift:"auth_payload,16,optional" form:"auth_payload" json:"auth_payload,omitempty" query:"auth_payload"`
|
||||||
|
|
@ -7511,9 +7511,9 @@ func (p *UpdatePluginMetaResponse) String() string {
|
||||||
|
|
||||||
type PublishPluginRequest struct {
|
type PublishPluginRequest struct {
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
||||||
// 隐私声明状态
|
// Privacy Statement Status
|
||||||
PrivacyStatus bool `thrift:"privacy_status,2" form:"privacy_status" json:"privacy_status" query:"privacy_status"`
|
PrivacyStatus bool `thrift:"privacy_status,2" form:"privacy_status" json:"privacy_status" query:"privacy_status"`
|
||||||
// 隐私声明内容
|
// Privacy Statement Content
|
||||||
PrivacyInfo string `thrift:"privacy_info,3" form:"privacy_info" json:"privacy_info" query:"privacy_info"`
|
PrivacyInfo string `thrift:"privacy_info,3" form:"privacy_info" json:"privacy_info" query:"privacy_info"`
|
||||||
VersionName string `thrift:"version_name,4" form:"version_name" json:"version_name" query:"version_name"`
|
VersionName string `thrift:"version_name,4" form:"version_name" json:"version_name" query:"version_name"`
|
||||||
VersionDesc string `thrift:"version_desc,5" form:"version_desc" json:"version_desc" query:"version_desc"`
|
VersionDesc string `thrift:"version_desc,5" form:"version_desc" json:"version_desc" query:"version_desc"`
|
||||||
|
|
@ -8173,7 +8173,7 @@ func (p *PublishPluginResponse) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// bot引用plugin
|
// Bot reference plugin
|
||||||
type GetBotDefaultParamsRequest struct {
|
type GetBotDefaultParamsRequest struct {
|
||||||
SpaceID int64 `thrift:"space_id,1" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,1" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
BotID int64 `thrift:"bot_id,2" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
BotID int64 `thrift:"bot_id,2" form:"bot_id" json:"bot_id,string" query:"bot_id"`
|
||||||
|
|
@ -10130,8 +10130,8 @@ type DeleteBotDefaultParamsRequest struct {
|
||||||
DevID string `thrift:"dev_id,2" form:"dev_id" json:"dev_id" query:"dev_id"`
|
DevID string `thrift:"dev_id,2" form:"dev_id" json:"dev_id" query:"dev_id"`
|
||||||
PluginID int64 `thrift:"plugin_id,3" form:"plugin_id" json:"plugin_id,string" query:"plugin_id"`
|
PluginID int64 `thrift:"plugin_id,3" form:"plugin_id" json:"plugin_id,string" query:"plugin_id"`
|
||||||
APIName string `thrift:"api_name,4" form:"api_name" json:"api_name" query:"api_name"`
|
APIName string `thrift:"api_name,4" form:"api_name" json:"api_name" query:"api_name"`
|
||||||
// bot删除工具时: DeleteBot = false , APIName要设置
|
// Bot removal tool when: DeleteBot = false, APIName to set
|
||||||
// 删除bot时 : DeleteBot = true , APIName为空
|
// Delete bot: DeleteBot = true, APIName is empty
|
||||||
DeleteBot bool `thrift:"delete_bot,5" form:"delete_bot" json:"delete_bot" query:"delete_bot"`
|
DeleteBot bool `thrift:"delete_bot,5" form:"delete_bot" json:"delete_bot" query:"delete_bot"`
|
||||||
SpaceID int64 `thrift:"space_id,6" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,6" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
PluginReferrerID string `thrift:"plugin_referrer_id,7" form:"plugin_referrer_id" json:"plugin_referrer_id" query:"plugin_referrer_id"`
|
PluginReferrerID string `thrift:"plugin_referrer_id,7" form:"plugin_referrer_id" json:"plugin_referrer_id" query:"plugin_referrer_id"`
|
||||||
|
|
@ -14418,7 +14418,7 @@ type GetOAuthSchemaResponse struct {
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
OauthSchema string `thrift:"oauth_schema,3" form:"oauth_schema" json:"oauth_schema" query:"oauth_schema"`
|
OauthSchema string `thrift:"oauth_schema,3" form:"oauth_schema" json:"oauth_schema" query:"oauth_schema"`
|
||||||
IdeConf string `thrift:"ide_conf,4" form:"ide_conf" json:"ide_conf" query:"ide_conf"`
|
IdeConf string `thrift:"ide_conf,4" form:"ide_conf" json:"ide_conf" query:"ide_conf"`
|
||||||
// 约定的json
|
// The agreed json
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"BaseResp" json:"BaseResp,omitempty" query:"BaseResp"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"BaseResp" json:"BaseResp,omitempty" query:"BaseResp"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -15341,7 +15341,7 @@ func (p *GetUserAuthorityResponse) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取授权状态--plugin debug区
|
// Get authorization status--plugin debug area
|
||||||
type GetOAuthStatusRequest struct {
|
type GetOAuthStatusRequest struct {
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
|
|
@ -15541,11 +15541,11 @@ func (p *GetOAuthStatusRequest) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type GetOAuthStatusResponse struct {
|
type GetOAuthStatusResponse struct {
|
||||||
// 是否为授权插件
|
// Is it an authorized plugin?
|
||||||
IsOauth bool `thrift:"is_oauth,1" form:"is_oauth" json:"is_oauth" query:"is_oauth"`
|
IsOauth bool `thrift:"is_oauth,1" form:"is_oauth" json:"is_oauth" query:"is_oauth"`
|
||||||
// 用户授权状态
|
// user authorization status
|
||||||
Status plugin_develop_common.OAuthStatus `thrift:"status,2" form:"status" json:"status" query:"status"`
|
Status plugin_develop_common.OAuthStatus `thrift:"status,2" form:"status" json:"status" query:"status"`
|
||||||
// 未授权,返回授权url
|
// Unauthorized, return the authorized url.
|
||||||
Content string `thrift:"content,3" form:"content" json:"content" query:"content"`
|
Content string `thrift:"content,3" form:"content" json:"content" query:"content"`
|
||||||
Code int64 `thrift:"code,253" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,253" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,254" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,254" form:"msg" json:"msg" query:"msg"`
|
||||||
|
|
@ -16427,9 +16427,9 @@ func (p *CheckAndLockPluginEditResponse) String() string {
|
||||||
type GetPluginPublishHistoryRequest struct {
|
type GetPluginPublishHistoryRequest struct {
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required" query:"plugin_id,required"`
|
||||||
SpaceID int64 `thrift:"space_id,2,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
SpaceID int64 `thrift:"space_id,2,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
||||||
// 翻页,第几页
|
// Turn the page, what page?
|
||||||
Page *int32 `thrift:"page,3,optional" form:"page" json:"page,omitempty" query:"page"`
|
Page *int32 `thrift:"page,3,optional" form:"page" json:"page,omitempty" query:"page"`
|
||||||
// 翻页,每页几条
|
// Flip pages, a few entries per page
|
||||||
Size *int32 `thrift:"size,4,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int32 `thrift:"size,4,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -16793,9 +16793,9 @@ func (p *GetPluginPublishHistoryRequest) String() string {
|
||||||
type GetPluginPublishHistoryResponse struct {
|
type GetPluginPublishHistoryResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
// 时间倒序
|
// reverse time
|
||||||
PluginPublishInfoList []*plugin_develop_common.PluginPublishInfo `thrift:"plugin_publish_info_list,3" form:"plugin_publish_info_list" json:"plugin_publish_info_list" query:"plugin_publish_info_list"`
|
PluginPublishInfoList []*plugin_develop_common.PluginPublishInfo `thrift:"plugin_publish_info_list,3" form:"plugin_publish_info_list" json:"plugin_publish_info_list" query:"plugin_publish_info_list"`
|
||||||
// 总共多少条,大于 page x size 说明还有下一页
|
// How many in total, greater than page x size description and next page
|
||||||
Total int32 `thrift:"total,4" form:"total" json:"total" query:"total"`
|
Total int32 `thrift:"total,4" form:"total" json:"total" query:"total"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255" form:"BaseResp" json:"BaseResp" query:"BaseResp"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255" form:"BaseResp" json:"BaseResp" query:"BaseResp"`
|
||||||
}
|
}
|
||||||
|
|
@ -20032,14 +20032,14 @@ type GetDevPluginListRequest struct {
|
||||||
SpaceID int64 `thrift:"space_id,5" form:"space_id" json:"space_id,string"`
|
SpaceID int64 `thrift:"space_id,5" form:"space_id" json:"space_id,string"`
|
||||||
ScopeType *plugin_develop_common.ScopeType `thrift:"scope_type,6,optional" form:"scope_type" json:"scope_type,omitempty" query:"scope_type"`
|
ScopeType *plugin_develop_common.ScopeType `thrift:"scope_type,6,optional" form:"scope_type" json:"scope_type,omitempty" query:"scope_type"`
|
||||||
OrderBy *plugin_develop_common.OrderBy `thrift:"order_by,7,optional" form:"order_by" json:"order_by,omitempty" query:"order_by"`
|
OrderBy *plugin_develop_common.OrderBy `thrift:"order_by,7,optional" form:"order_by" json:"order_by,omitempty" query:"order_by"`
|
||||||
// 发布状态筛选:true:已发布, false:未发布
|
// Release status filter: true: published, false: not published
|
||||||
PublishStatus *bool `thrift:"publish_status,8,optional" form:"publish_status" json:"publish_status,omitempty" query:"publish_status"`
|
PublishStatus *bool `thrift:"publish_status,8,optional" form:"publish_status" json:"publish_status,omitempty" query:"publish_status"`
|
||||||
// 插件名或工具名
|
// Plugin name or tool name
|
||||||
Name *string `thrift:"name,9,optional" form:"name" json:"name,omitempty" query:"name"`
|
Name *string `thrift:"name,9,optional" form:"name" json:"name,omitempty" query:"name"`
|
||||||
// 插件种类筛选 端/云
|
// Plugin Type Filter, End/Cloud
|
||||||
PluginTypeForFilter *plugin_develop_common.PluginTypeForFilter `thrift:"plugin_type_for_filter,10,optional" form:"plugin_type_for_filter" json:"plugin_type_for_filter,omitempty" query:"plugin_type_for_filter"`
|
PluginTypeForFilter *plugin_develop_common.PluginTypeForFilter `thrift:"plugin_type_for_filter,10,optional" form:"plugin_type_for_filter" json:"plugin_type_for_filter,omitempty" query:"plugin_type_for_filter"`
|
||||||
ProjectID int64 `thrift:"project_id,11" form:"project_id" json:"project_id,string"`
|
ProjectID int64 `thrift:"project_id,11" form:"project_id" json:"project_id,string"`
|
||||||
// 插件id列表
|
// plugin id list
|
||||||
PluginIds []int64 `thrift:"plugin_ids,12" form:"plugin_ids" json:"plugin_ids"`
|
PluginIds []int64 `thrift:"plugin_ids,12" form:"plugin_ids" json:"plugin_ids"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -21683,8 +21683,8 @@ type Convert2OpenAPIResponse struct {
|
||||||
// ignore
|
// ignore
|
||||||
DuplicateAPIInfos []*plugin_develop_common.DuplicateAPIInfo `thrift:"duplicate_api_infos,6" form:"duplicate_api_infos" json:"duplicate_api_infos" query:"duplicate_api_infos"`
|
DuplicateAPIInfos []*plugin_develop_common.DuplicateAPIInfo `thrift:"duplicate_api_infos,6" form:"duplicate_api_infos" json:"duplicate_api_infos" query:"duplicate_api_infos"`
|
||||||
// BaseResp.StatusCode
|
// BaseResp.StatusCode
|
||||||
// DuplicateAPIPath: 导入的文件中有重复的API Path,且 request.MergeSamePaths = false
|
// DuplicateAPIPath: Duplicate API Path in imported file with request. MergeSamePaths = false
|
||||||
// InvalidParam: 其他错误
|
// InvalidParam: Other errors
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"BaseResp" json:"BaseResp,omitempty" query:"BaseResp"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,optional" form:"BaseResp" json:"BaseResp,omitempty" query:"BaseResp"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -22707,14 +22707,14 @@ func (p *BatchCreateAPIRequest) String() string {
|
||||||
type BatchCreateAPIResponse struct {
|
type BatchCreateAPIResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
// PathsToReplace表示要覆盖的tools,
|
// PathsToReplace represents the tools to override,
|
||||||
// 如果BaseResp.StatusCode = DuplicateAPIPath,那么PathsToReplace不为空
|
// If BaseResp. StatusCode = DuplicateAPIPath, then PathsToReplace is not empty
|
||||||
PathsDuplicated []*plugin_develop_common.PluginAPIInfo `thrift:"paths_duplicated,3,optional" form:"paths_duplicated" json:"paths_duplicated,omitempty" query:"paths_duplicated"`
|
PathsDuplicated []*plugin_develop_common.PluginAPIInfo `thrift:"paths_duplicated,3,optional" form:"paths_duplicated" json:"paths_duplicated,omitempty" query:"paths_duplicated"`
|
||||||
PathsCreated []*plugin_develop_common.PluginAPIInfo `thrift:"paths_created,4,optional" form:"paths_created" json:"paths_created,omitempty" query:"paths_created"`
|
PathsCreated []*plugin_develop_common.PluginAPIInfo `thrift:"paths_created,4,optional" form:"paths_created" json:"paths_created,omitempty" query:"paths_created"`
|
||||||
EditVersion int32 `thrift:"edit_version,5" form:"edit_version" json:"edit_version" query:"edit_version"`
|
EditVersion int32 `thrift:"edit_version,5" form:"edit_version" json:"edit_version" query:"edit_version"`
|
||||||
// BaseResp.StatusCode
|
// BaseResp.StatusCode
|
||||||
// DuplicateAPIPath: 有重复的API Path,且 request.ReplaceDupPath = false
|
// DuplicateAPIPath: There is a duplicate API Path with request. ReplaceDupPath = false
|
||||||
// InvalidParam: 其他错误
|
// InvalidParam: Other errors
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -23151,7 +23151,7 @@ func (p *BatchCreateAPIResponse) String() string {
|
||||||
|
|
||||||
type RevokeAuthTokenRequest struct {
|
type RevokeAuthTokenRequest struct {
|
||||||
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required"`
|
PluginID int64 `thrift:"plugin_id,1,required" form:"plugin_id,required" json:"plugin_id,string,required"`
|
||||||
// 如果不传使用uid赋值 bot_id = connector_uid
|
// If not passed using uid assignment bot_id = connector_uid
|
||||||
BotID *int64 `thrift:"bot_id,2,optional" form:"bot_id" json:"bot_id,string,omitempty"`
|
BotID *int64 `thrift:"bot_id,2,optional" form:"bot_id" json:"bot_id,string,omitempty"`
|
||||||
ContextType *int32 `thrift:"context_type,3,optional" form:"context_type" json:"context_type,omitempty"`
|
ContextType *int32 `thrift:"context_type,3,optional" form:"context_type" json:"context_type,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
|
|
@ -23615,11 +23615,11 @@ func (p *RevokeAuthTokenResponse) String() string {
|
||||||
|
|
||||||
type OAuthPluginInfo struct {
|
type OAuthPluginInfo struct {
|
||||||
PluginID int64 `thrift:"plugin_id,1" form:"plugin_id" json:"plugin_id,string" query:"plugin_id"`
|
PluginID int64 `thrift:"plugin_id,1" form:"plugin_id" json:"plugin_id,string" query:"plugin_id"`
|
||||||
// 用户授权状态
|
// user authorization status
|
||||||
Status plugin_develop_common.OAuthStatus `thrift:"status,2" form:"status" json:"status" query:"status"`
|
Status plugin_develop_common.OAuthStatus `thrift:"status,2" form:"status" json:"status" query:"status"`
|
||||||
// 插件name
|
// Plugin name
|
||||||
Name string `thrift:"name,3" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,3" form:"name" json:"name" query:"name"`
|
||||||
// 插件头像
|
// plugin avatar
|
||||||
PluginIcon string `thrift:"plugin_icon,4" form:"plugin_icon" json:"plugin_icon" query:"plugin_icon"`
|
PluginIcon string `thrift:"plugin_icon,4" form:"plugin_icon" json:"plugin_icon" query:"plugin_icon"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -24400,17 +24400,17 @@ type PluginDevelopService interface {
|
||||||
GetOAuthSchema(ctx context.Context, request *GetOAuthSchemaRequest) (r *GetOAuthSchemaResponse, err error)
|
GetOAuthSchema(ctx context.Context, request *GetOAuthSchemaRequest) (r *GetOAuthSchemaResponse, err error)
|
||||||
|
|
||||||
GetOAuthSchemaAPI(ctx context.Context, request *GetOAuthSchemaRequest) (r *GetOAuthSchemaResponse, err error)
|
GetOAuthSchemaAPI(ctx context.Context, request *GetOAuthSchemaRequest) (r *GetOAuthSchemaResponse, err error)
|
||||||
// 获取已发布 workflow、plugin 列表,或者多个插件的详情
|
// Get a list of published workflows, plugins, or details of multiple plugins
|
||||||
GetPlaygroundPluginList(ctx context.Context, request *GetPlaygroundPluginListRequest) (r *GetPlaygroundPluginListResponse, err error)
|
GetPlaygroundPluginList(ctx context.Context, request *GetPlaygroundPluginListRequest) (r *GetPlaygroundPluginListResponse, err error)
|
||||||
// 通过 code 创建插件
|
// Creating plugins with code
|
||||||
RegisterPlugin(ctx context.Context, request *RegisterPluginRequest) (r *RegisterPluginResponse, err error)
|
RegisterPlugin(ctx context.Context, request *RegisterPluginRequest) (r *RegisterPluginResponse, err error)
|
||||||
// 通过 UI 创建插件
|
// Create plugins through UI
|
||||||
RegisterPluginMeta(ctx context.Context, request *RegisterPluginMetaRequest) (r *RegisterPluginMetaResponse, err error)
|
RegisterPluginMeta(ctx context.Context, request *RegisterPluginMetaRequest) (r *RegisterPluginMetaResponse, err error)
|
||||||
// 获取插件工具列表,或者多个工具详情
|
// Get a list of plug-in tools, or multiple tool details
|
||||||
GetPluginAPIs(ctx context.Context, request *GetPluginAPIsRequest) (r *GetPluginAPIsResponse, err error)
|
GetPluginAPIs(ctx context.Context, request *GetPluginAPIsRequest) (r *GetPluginAPIsResponse, err error)
|
||||||
// 获取插件详情
|
// Get plugin details
|
||||||
GetPluginInfo(ctx context.Context, request *GetPluginInfoRequest) (r *GetPluginInfoResponse, err error)
|
GetPluginInfo(ctx context.Context, request *GetPluginInfoRequest) (r *GetPluginInfoResponse, err error)
|
||||||
// 与最近一次发布版本相比,更新的工具列表
|
// Updated list of tools compared to the most recent release
|
||||||
GetUpdatedAPIs(ctx context.Context, request *GetUpdatedAPIsRequest) (r *GetUpdatedAPIsResponse, err error)
|
GetUpdatedAPIs(ctx context.Context, request *GetUpdatedAPIsRequest) (r *GetUpdatedAPIsResponse, err error)
|
||||||
|
|
||||||
GetOAuthStatus(ctx context.Context, request *GetOAuthStatusRequest) (r *GetOAuthStatusResponse, err error)
|
GetOAuthStatus(ctx context.Context, request *GetOAuthStatusRequest) (r *GetOAuthStatusResponse, err error)
|
||||||
|
|
@ -24418,23 +24418,23 @@ type PluginDevelopService interface {
|
||||||
CheckAndLockPluginEdit(ctx context.Context, request *CheckAndLockPluginEditRequest) (r *CheckAndLockPluginEditResponse, err error)
|
CheckAndLockPluginEdit(ctx context.Context, request *CheckAndLockPluginEditRequest) (r *CheckAndLockPluginEditResponse, err error)
|
||||||
|
|
||||||
UnlockPluginEdit(ctx context.Context, request *UnlockPluginEditRequest) (r *UnlockPluginEditResponse, err error)
|
UnlockPluginEdit(ctx context.Context, request *UnlockPluginEditRequest) (r *UnlockPluginEditResponse, err error)
|
||||||
// 通过 code 更新插件
|
// Update plugins via code
|
||||||
UpdatePlugin(ctx context.Context, request *UpdatePluginRequest) (r *UpdatePluginResponse, err error)
|
UpdatePlugin(ctx context.Context, request *UpdatePluginRequest) (r *UpdatePluginResponse, err error)
|
||||||
// 删除工具
|
// removal tool
|
||||||
DeleteAPI(ctx context.Context, request *DeleteAPIRequest) (r *DeleteAPIResponse, err error)
|
DeleteAPI(ctx context.Context, request *DeleteAPIRequest) (r *DeleteAPIResponse, err error)
|
||||||
// 删除插件
|
// Remove plugin
|
||||||
DelPlugin(ctx context.Context, request *DelPluginRequest) (r *DelPluginResponse, err error)
|
DelPlugin(ctx context.Context, request *DelPluginRequest) (r *DelPluginResponse, err error)
|
||||||
// 发布插件
|
// publishing plugin
|
||||||
PublishPlugin(ctx context.Context, request *PublishPluginRequest) (r *PublishPluginResponse, err error)
|
PublishPlugin(ctx context.Context, request *PublishPluginRequest) (r *PublishPluginResponse, err error)
|
||||||
// 通过UI更新插件
|
// Update plugins via UI
|
||||||
UpdatePluginMeta(ctx context.Context, request *UpdatePluginMetaRequest) (r *UpdatePluginMetaResponse, err error)
|
UpdatePluginMeta(ctx context.Context, request *UpdatePluginMetaRequest) (r *UpdatePluginMetaResponse, err error)
|
||||||
|
|
||||||
GetBotDefaultParams(ctx context.Context, request *GetBotDefaultParamsRequest) (r *GetBotDefaultParamsResponse, err error)
|
GetBotDefaultParams(ctx context.Context, request *GetBotDefaultParamsRequest) (r *GetBotDefaultParamsResponse, err error)
|
||||||
|
|
||||||
UpdateBotDefaultParams(ctx context.Context, request *UpdateBotDefaultParamsRequest) (r *UpdateBotDefaultParamsResponse, err error)
|
UpdateBotDefaultParams(ctx context.Context, request *UpdateBotDefaultParamsRequest) (r *UpdateBotDefaultParamsResponse, err error)
|
||||||
// 创建工具
|
// creation tool
|
||||||
CreateAPI(ctx context.Context, request *CreateAPIRequest) (r *CreateAPIResponse, err error)
|
CreateAPI(ctx context.Context, request *CreateAPIRequest) (r *CreateAPIResponse, err error)
|
||||||
// 更新工具
|
// update tool
|
||||||
UpdateAPI(ctx context.Context, request *UpdateAPIRequest) (r *UpdateAPIResponse, err error)
|
UpdateAPI(ctx context.Context, request *UpdateAPIRequest) (r *UpdateAPIResponse, err error)
|
||||||
|
|
||||||
GetUserAuthority(ctx context.Context, request *GetUserAuthorityRequest) (r *GetUserAuthorityResponse, err error)
|
GetUserAuthority(ctx context.Context, request *GetUserAuthorityRequest) (r *GetUserAuthorityResponse, err error)
|
||||||
|
|
@ -24444,9 +24444,9 @@ type PluginDevelopService interface {
|
||||||
GetPluginNextVersion(ctx context.Context, request *GetPluginNextVersionRequest) (r *GetPluginNextVersionResponse, err error)
|
GetPluginNextVersion(ctx context.Context, request *GetPluginNextVersionRequest) (r *GetPluginNextVersionResponse, err error)
|
||||||
|
|
||||||
GetDevPluginList(ctx context.Context, request *GetDevPluginListRequest) (r *GetDevPluginListResponse, err error)
|
GetDevPluginList(ctx context.Context, request *GetDevPluginListRequest) (r *GetDevPluginListResponse, err error)
|
||||||
// 协议转换,如将 curl 、postman collection 协议转换为 openapi3 协议
|
// Protocol conversion, such as converting curl and mail carrier collection protocols to openapi3 protocols
|
||||||
Convert2OpenAPI(ctx context.Context, request *Convert2OpenAPIRequest) (r *Convert2OpenAPIResponse, err error)
|
Convert2OpenAPI(ctx context.Context, request *Convert2OpenAPIRequest) (r *Convert2OpenAPIResponse, err error)
|
||||||
// 批量创建工具,目前是配合 Convert2OpenAPI 接口使用
|
// Batch creation tool, currently used with the Convert2 OpenAPI interface
|
||||||
BatchCreateAPI(ctx context.Context, request *BatchCreateAPIRequest) (r *BatchCreateAPIResponse, err error)
|
BatchCreateAPI(ctx context.Context, request *BatchCreateAPIRequest) (r *BatchCreateAPIResponse, err error)
|
||||||
|
|
||||||
RevokeAuthToken(ctx context.Context, request *RevokeAuthTokenRequest) (r *RevokeAuthTokenResponse, err error)
|
RevokeAuthToken(ctx context.Context, request *RevokeAuthTokenRequest) (r *RevokeAuthTokenResponse, err error)
|
||||||
|
|
|
||||||
|
|
@ -9,13 +9,13 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
type WorkflowService interface {
|
type WorkflowService interface {
|
||||||
// 创建流程
|
// Create process
|
||||||
CreateWorkflow(ctx context.Context, request *CreateWorkflowRequest) (r *CreateWorkflowResponse, err error)
|
CreateWorkflow(ctx context.Context, request *CreateWorkflowRequest) (r *CreateWorkflowResponse, err error)
|
||||||
// 查询流程
|
// query process
|
||||||
GetCanvasInfo(ctx context.Context, request *GetCanvasInfoRequest) (r *GetCanvasInfoResponse, err error)
|
GetCanvasInfo(ctx context.Context, request *GetCanvasInfoRequest) (r *GetCanvasInfoResponse, err error)
|
||||||
|
|
||||||
GetHistorySchema(ctx context.Context, request *GetHistorySchemaRequest) (r *GetHistorySchemaResponse, err error)
|
GetHistorySchema(ctx context.Context, request *GetHistorySchemaRequest) (r *GetHistorySchemaResponse, err error)
|
||||||
// 保存流程
|
// save process
|
||||||
SaveWorkflow(ctx context.Context, request *SaveWorkflowRequest) (r *SaveWorkflowResponse, err error)
|
SaveWorkflow(ctx context.Context, request *SaveWorkflowRequest) (r *SaveWorkflowResponse, err error)
|
||||||
|
|
||||||
UpdateWorkflowMeta(ctx context.Context, request *UpdateWorkflowMetaRequest) (r *UpdateWorkflowMetaResponse, err error)
|
UpdateWorkflowMeta(ctx context.Context, request *UpdateWorkflowMetaRequest) (r *UpdateWorkflowMetaResponse, err error)
|
||||||
|
|
@ -25,7 +25,7 @@ type WorkflowService interface {
|
||||||
BatchDeleteWorkflow(ctx context.Context, request *BatchDeleteWorkflowRequest) (r *BatchDeleteWorkflowResponse, err error)
|
BatchDeleteWorkflow(ctx context.Context, request *BatchDeleteWorkflowRequest) (r *BatchDeleteWorkflowResponse, err error)
|
||||||
|
|
||||||
GetDeleteStrategy(ctx context.Context, request *GetDeleteStrategyRequest) (r *GetDeleteStrategyResponse, err error)
|
GetDeleteStrategy(ctx context.Context, request *GetDeleteStrategyRequest) (r *GetDeleteStrategyResponse, err error)
|
||||||
// 发布流程。该接口的用途是发布非 project 内部的流程。
|
// Publish process. The purpose of this interface is to publish processes that are not internal to the project.
|
||||||
PublishWorkflow(ctx context.Context, request *PublishWorkflowRequest) (r *PublishWorkflowResponse, err error)
|
PublishWorkflow(ctx context.Context, request *PublishWorkflowRequest) (r *PublishWorkflowResponse, err error)
|
||||||
|
|
||||||
CopyWorkflow(ctx context.Context, request *CopyWorkflowRequest) (r *CopyWorkflowResponse, err error)
|
CopyWorkflow(ctx context.Context, request *CopyWorkflowRequest) (r *CopyWorkflowResponse, err error)
|
||||||
|
|
@ -35,13 +35,13 @@ type WorkflowService interface {
|
||||||
GetReleasedWorkflows(ctx context.Context, request *GetReleasedWorkflowsRequest) (r *GetReleasedWorkflowsResponse, err error)
|
GetReleasedWorkflows(ctx context.Context, request *GetReleasedWorkflowsRequest) (r *GetReleasedWorkflowsResponse, err error)
|
||||||
|
|
||||||
GetWorkflowReferences(ctx context.Context, request *GetWorkflowReferencesRequest) (r *GetWorkflowReferencesResponse, err error)
|
GetWorkflowReferences(ctx context.Context, request *GetWorkflowReferencesRequest) (r *GetWorkflowReferencesResponse, err error)
|
||||||
// 获取示例流程列表
|
// Get a list of sample processes
|
||||||
GetExampleWorkFlowList(ctx context.Context, request *GetExampleWorkFlowListRequest) (r *GetExampleWorkFlowListResponse, err error)
|
GetExampleWorkFlowList(ctx context.Context, request *GetExampleWorkFlowListRequest) (r *GetExampleWorkFlowListResponse, err error)
|
||||||
// 获取流程列表。
|
// Gets a list of processes.
|
||||||
GetWorkFlowList(ctx context.Context, request *GetWorkFlowListRequest) (r *GetWorkFlowListResponse, err error)
|
GetWorkFlowList(ctx context.Context, request *GetWorkFlowListRequest) (r *GetWorkFlowListResponse, err error)
|
||||||
|
|
||||||
QueryWorkflowNodeTypes(ctx context.Context, request *QueryWorkflowNodeTypeRequest) (r *QueryWorkflowNodeTypeResponse, err error)
|
QueryWorkflowNodeTypes(ctx context.Context, request *QueryWorkflowNodeTypeRequest) (r *QueryWorkflowNodeTypeResponse, err error)
|
||||||
// 画布
|
// Canvas
|
||||||
NodeTemplateList(ctx context.Context, request *NodeTemplateListRequest) (r *NodeTemplateListResponse, err error)
|
NodeTemplateList(ctx context.Context, request *NodeTemplateListRequest) (r *NodeTemplateListResponse, err error)
|
||||||
|
|
||||||
NodePanelSearch(ctx context.Context, request *NodePanelSearchRequest) (r *NodePanelSearchResponse, err error)
|
NodePanelSearch(ctx context.Context, request *NodePanelSearchRequest) (r *NodePanelSearchResponse, err error)
|
||||||
|
|
@ -49,13 +49,13 @@ type WorkflowService interface {
|
||||||
GetLLMNodeFCSettingsMerged(ctx context.Context, req *GetLLMNodeFCSettingsMergedRequest) (r *GetLLMNodeFCSettingsMergedResponse, err error)
|
GetLLMNodeFCSettingsMerged(ctx context.Context, req *GetLLMNodeFCSettingsMergedRequest) (r *GetLLMNodeFCSettingsMergedResponse, err error)
|
||||||
|
|
||||||
GetLLMNodeFCSettingDetail(ctx context.Context, req *GetLLMNodeFCSettingDetailRequest) (r *GetLLMNodeFCSettingDetailResponse, err error)
|
GetLLMNodeFCSettingDetail(ctx context.Context, req *GetLLMNodeFCSettingDetailRequest) (r *GetLLMNodeFCSettingDetailResponse, err error)
|
||||||
// 试运行流程(test run)
|
// Practice running process (test run)
|
||||||
WorkFlowTestRun(ctx context.Context, request *WorkFlowTestRunRequest) (r *WorkFlowTestRunResponse, err error)
|
WorkFlowTestRun(ctx context.Context, request *WorkFlowTestRunRequest) (r *WorkFlowTestRunResponse, err error)
|
||||||
|
|
||||||
WorkFlowTestResume(ctx context.Context, request *WorkflowTestResumeRequest) (r *WorkflowTestResumeResponse, err error)
|
WorkFlowTestResume(ctx context.Context, request *WorkflowTestResumeRequest) (r *WorkflowTestResumeResponse, err error)
|
||||||
|
|
||||||
CancelWorkFlow(ctx context.Context, request *CancelWorkFlowRequest) (r *CancelWorkFlowResponse, err error)
|
CancelWorkFlow(ctx context.Context, request *CancelWorkFlowRequest) (r *CancelWorkFlowResponse, err error)
|
||||||
// 查看试运行执行历史。
|
// View practice run history.
|
||||||
GetWorkFlowProcess(ctx context.Context, request *GetWorkflowProcessRequest) (r *GetWorkflowProcessResponse, err error)
|
GetWorkFlowProcess(ctx context.Context, request *GetWorkflowProcessRequest) (r *GetWorkflowProcessResponse, err error)
|
||||||
|
|
||||||
GetNodeExecuteHistory(ctx context.Context, request *GetNodeExecuteHistoryRequest) (r *GetNodeExecuteHistoryResponse, err error)
|
GetNodeExecuteHistory(ctx context.Context, request *GetNodeExecuteHistoryRequest) (r *GetNodeExecuteHistoryResponse, err error)
|
||||||
|
|
@ -63,7 +63,7 @@ type WorkflowService interface {
|
||||||
GetApiDetail(ctx context.Context, request *GetApiDetailRequest) (r *GetApiDetailResponse, err error)
|
GetApiDetail(ctx context.Context, request *GetApiDetailRequest) (r *GetApiDetailResponse, err error)
|
||||||
|
|
||||||
WorkflowNodeDebugV2(ctx context.Context, request *WorkflowNodeDebugV2Request) (r *WorkflowNodeDebugV2Response, err error)
|
WorkflowNodeDebugV2(ctx context.Context, request *WorkflowNodeDebugV2Request) (r *WorkflowNodeDebugV2Response, err error)
|
||||||
// 文件上传
|
// file upload
|
||||||
GetWorkflowUploadAuthToken(ctx context.Context, request *GetUploadAuthTokenRequest) (r *GetUploadAuthTokenResponse, err error)
|
GetWorkflowUploadAuthToken(ctx context.Context, request *GetUploadAuthTokenRequest) (r *GetUploadAuthTokenResponse, err error)
|
||||||
|
|
||||||
SignImageURL(ctx context.Context, request *SignImageURLRequest) (r *SignImageURLResponse, err error)
|
SignImageURL(ctx context.Context, request *SignImageURLRequest) (r *SignImageURLResponse, err error)
|
||||||
|
|
@ -76,7 +76,7 @@ type WorkflowService interface {
|
||||||
|
|
||||||
ListProjectConversationDef(ctx context.Context, request *ListProjectConversationRequest) (r *ListProjectConversationResponse, err error)
|
ListProjectConversationDef(ctx context.Context, request *ListProjectConversationRequest) (r *ListProjectConversationResponse, err error)
|
||||||
// Trace
|
// Trace
|
||||||
// 列出历史执行的trace
|
// List traces of historical execution
|
||||||
ListRootSpans(ctx context.Context, req *ListRootSpansRequest) (r *ListRootSpansResponse, err error)
|
ListRootSpans(ctx context.Context, req *ListRootSpansRequest) (r *ListRootSpansResponse, err error)
|
||||||
|
|
||||||
GetTraceSDK(ctx context.Context, req *GetTraceSDKRequest) (r *GetTraceSDKResponse, err error)
|
GetTraceSDK(ctx context.Context, req *GetTraceSDKRequest) (r *GetTraceSDKResponse, err error)
|
||||||
|
|
@ -92,7 +92,7 @@ type WorkflowService interface {
|
||||||
CreateChatFlowRole(ctx context.Context, request *CreateChatFlowRoleRequest) (r *CreateChatFlowRoleResponse, err error)
|
CreateChatFlowRole(ctx context.Context, request *CreateChatFlowRoleRequest) (r *CreateChatFlowRoleResponse, err error)
|
||||||
|
|
||||||
DeleteChatFlowRole(ctx context.Context, request *DeleteChatFlowRoleRequest) (r *DeleteChatFlowRoleResponse, err error)
|
DeleteChatFlowRole(ctx context.Context, request *DeleteChatFlowRoleRequest) (r *DeleteChatFlowRoleResponse, err error)
|
||||||
// App 发布管理
|
// App Release Management
|
||||||
ListPublishWorkflow(ctx context.Context, request *ListPublishWorkflowRequest) (r *ListPublishWorkflowResponse, err error)
|
ListPublishWorkflow(ctx context.Context, request *ListPublishWorkflowRequest) (r *ListPublishWorkflowResponse, err error)
|
||||||
// Open API
|
// Open API
|
||||||
OpenAPIRunFlow(ctx context.Context, request *OpenAPIRunFlowRequest) (r *OpenAPIRunFlowResponse, err error)
|
OpenAPIRunFlow(ctx context.Context, request *OpenAPIRunFlowRequest) (r *OpenAPIRunFlowResponse, err error)
|
||||||
|
|
|
||||||
|
|
@ -3,21 +3,21 @@
|
||||||
package workflow
|
package workflow
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type FrontedTagType int64
|
type FrontedTagType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 文本
|
// Text
|
||||||
FrontedTagType_TEXT FrontedTagType = 0
|
FrontedTagType_TEXT FrontedTagType = 0
|
||||||
// 时间,用时间戳,单位是毫秒
|
// Time, with timestamp, in milliseconds
|
||||||
FrontedTagType_TIME FrontedTagType = 1
|
FrontedTagType_TIME FrontedTagType = 1
|
||||||
// 时间间隔,单位是毫秒
|
// Time interval, in milliseconds
|
||||||
FrontedTagType_TIME_DURATION FrontedTagType = 2
|
FrontedTagType_TIME_DURATION FrontedTagType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -229,11 +229,11 @@ func (p *TagType) Value() (driver.Value, error) {
|
||||||
type QueryScene int64
|
type QueryScene int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// doubao cici 全链路调试台
|
// Doubao cici full link debugging station
|
||||||
QueryScene_ALICE_OP QueryScene = 0
|
QueryScene_ALICE_OP QueryScene = 0
|
||||||
// doubao cici debug 功能
|
// Doubao cici debugging function
|
||||||
QueryScene_DOUBAO_CICI_DEBUG QueryScene = 1
|
QueryScene_DOUBAO_CICI_DEBUG QueryScene = 1
|
||||||
// workflow debug 功能
|
// Workflow debugging
|
||||||
QueryScene_WORKFLOW_DEBUG QueryScene = 2
|
QueryScene_WORKFLOW_DEBUG QueryScene = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -321,7 +321,7 @@ func (p *TenantLevel) Value() (driver.Value, error) {
|
||||||
type InputOutputType int64
|
type InputOutputType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 文本类型
|
// Text type
|
||||||
InputOutputType_TEXT InputOutputType = 0
|
InputOutputType_TEXT InputOutputType = 0
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1008,9 +1008,9 @@ func (p *FilterTag) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ListRootSpansRequest struct {
|
type ListRootSpansRequest struct {
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
StartAt int64 `thrift:"StartAt,2,required" json:"start_at" form:"start_at,required" `
|
StartAt int64 `thrift:"StartAt,2,required" json:"start_at" form:"start_at,required" `
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
EndAt int64 `thrift:"EndAt,3,required" json:"end_at" form:"end_at,required" `
|
EndAt int64 `thrift:"EndAt,3,required" json:"end_at" form:"end_at,required" `
|
||||||
Limit *int16 `thrift:"Limit,4,optional" json:"limit" form:"limit" `
|
Limit *int16 `thrift:"Limit,4,optional" json:"limit" form:"limit" `
|
||||||
DescByStartTime *bool `thrift:"DescByStartTime,5,optional" json:"desc_by_start_time" form:"desc_by_start_time" `
|
DescByStartTime *bool `thrift:"DescByStartTime,5,optional" json:"desc_by_start_time" form:"desc_by_start_time" `
|
||||||
|
|
@ -1018,7 +1018,7 @@ type ListRootSpansRequest struct {
|
||||||
WorkflowID string `thrift:"WorkflowID,7,required" json:"workflow_id" form:"workflow_id,required" `
|
WorkflowID string `thrift:"WorkflowID,7,required" json:"workflow_id" form:"workflow_id,required" `
|
||||||
Input *string `thrift:"Input,8,optional" json:"input" form:"input" `
|
Input *string `thrift:"Input,8,optional" json:"input" form:"input" `
|
||||||
Status *SpanStatus `thrift:"Status,9,optional" json:"status" form:"status" `
|
Status *SpanStatus `thrift:"Status,9,optional" json:"status" form:"status" `
|
||||||
// 正式运行/试运行/节点Debug
|
// Formal run/practice run/Node Debug
|
||||||
ExecuteMode *int32 `thrift:"ExecuteMode,10,optional" json:"execute_mode" form:"execute_mode" `
|
ExecuteMode *int32 `thrift:"ExecuteMode,10,optional" json:"execute_mode" form:"execute_mode" `
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
Base *base.Base `thrift:"Base,255,optional" form:"Base" json:"Base,omitempty" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -1661,9 +1661,9 @@ type Span struct {
|
||||||
Type string `thrift:"Type,7" json:"type" form:"Type" query:"Type"`
|
Type string `thrift:"Type,7" json:"type" form:"Type" query:"Type"`
|
||||||
Name string `thrift:"Name,8" json:"name" form:"Name" query:"Name"`
|
Name string `thrift:"Name,8" json:"name" form:"Name" query:"Name"`
|
||||||
ParentID string `thrift:"ParentID,9" json:"parent_id" form:"ParentID" query:"ParentID"`
|
ParentID string `thrift:"ParentID,9" json:"parent_id" form:"ParentID" query:"ParentID"`
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
Duration int64 `thrift:"Duration,10" json:"duration" form:"Duration" query:"Duration"`
|
Duration int64 `thrift:"Duration,10" json:"duration" form:"Duration" query:"Duration"`
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
StartTime int64 `thrift:"StartTime,11" json:"start_time" form:"StartTime" query:"StartTime"`
|
StartTime int64 `thrift:"StartTime,11" json:"start_time" form:"StartTime" query:"StartTime"`
|
||||||
StatusCode int32 `thrift:"StatusCode,12" json:"status_code" form:"StatusCode" query:"StatusCode"`
|
StatusCode int32 `thrift:"StatusCode,12" json:"status_code" form:"StatusCode" query:"StatusCode"`
|
||||||
Tags []*TraceTag `thrift:"Tags,13" json:"tags" form:"Tags" query:"Tags"`
|
Tags []*TraceTag `thrift:"Tags,13" json:"tags" form:"Tags" query:"Tags"`
|
||||||
|
|
@ -2951,9 +2951,9 @@ func (p *ListRootSpansResponse) String() string {
|
||||||
|
|
||||||
type GetTraceSDKRequest struct {
|
type GetTraceSDKRequest struct {
|
||||||
LogID *string `thrift:"LogID,2,optional" json:"log_id" query:"log_id" `
|
LogID *string `thrift:"LogID,2,optional" json:"log_id" query:"log_id" `
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
StartAt *int64 `thrift:"StartAt,4,optional" json:"start_at" query:"start_at" `
|
StartAt *int64 `thrift:"StartAt,4,optional" json:"start_at" query:"start_at" `
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
EndAt *int64 `thrift:"EndAt,5,optional" json:"end_at" query:"end_at" `
|
EndAt *int64 `thrift:"EndAt,5,optional" json:"end_at" query:"end_at" `
|
||||||
WorkflowID *int64 `thrift:"WorkflowID,6,optional" json:"workflow_id" query:"workflow_id" `
|
WorkflowID *int64 `thrift:"WorkflowID,6,optional" json:"workflow_id" query:"workflow_id" `
|
||||||
ExecuteID *int64 `thrift:"ExecuteID,7,optional" json:"execute_id" query:"execute_id" `
|
ExecuteID *int64 `thrift:"ExecuteID,7,optional" json:"execute_id" query:"execute_id" `
|
||||||
|
|
@ -3579,22 +3579,22 @@ func (p *GetTraceSDKResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type KeyScene struct {
|
type KeyScene struct {
|
||||||
// 场景,如"拆分搜索词"\"搜索"
|
// Scenarios such as "Split search terms"\ "Search"
|
||||||
Scene *string `thrift:"Scene,1,optional" json:"scene" form:"Scene" query:"Scene"`
|
Scene *string `thrift:"Scene,1,optional" json:"scene" form:"Scene" query:"Scene"`
|
||||||
// 状态信息
|
// status information
|
||||||
StatusMessage *string `thrift:"StatusMessage,2,optional" json:"status_message" form:"StatusMessage" query:"StatusMessage"`
|
StatusMessage *string `thrift:"StatusMessage,2,optional" json:"status_message" form:"StatusMessage" query:"StatusMessage"`
|
||||||
System *string `thrift:"System,3,optional" json:"system" form:"System" query:"System"`
|
System *string `thrift:"System,3,optional" json:"system" form:"System" query:"System"`
|
||||||
// 历史消息
|
// chat history
|
||||||
HistoryMessages []*MessageItem `thrift:"HistoryMessages,4,optional" json:"history_messages" form:"HistoryMessages" query:"HistoryMessages"`
|
HistoryMessages []*MessageItem `thrift:"HistoryMessages,4,optional" json:"history_messages" form:"HistoryMessages" query:"HistoryMessages"`
|
||||||
// 输入
|
// input
|
||||||
Input *KeySceneInput `thrift:"Input,5,optional" json:"input" form:"Input" query:"Input"`
|
Input *KeySceneInput `thrift:"Input,5,optional" json:"input" form:"Input" query:"Input"`
|
||||||
// 输出
|
// output
|
||||||
Output *KeySceneOutput `thrift:"Output,6,optional" json:"output" form:"Output" query:"Output"`
|
Output *KeySceneOutput `thrift:"Output,6,optional" json:"output" form:"Output" query:"Output"`
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
Duration *int64 `thrift:"Duration,7,optional" json:"duration" form:"Duration" query:"Duration"`
|
Duration *int64 `thrift:"Duration,7,optional" json:"duration" form:"Duration" query:"Duration"`
|
||||||
// 开始时间,用于排序,单位是毫秒
|
// Start time, used for sorting, in milliseconds
|
||||||
StartTime *int64 `thrift:"StartTime,8,optional" json:"start_time" form:"start_time" `
|
StartTime *int64 `thrift:"StartTime,8,optional" json:"start_time" form:"start_time" `
|
||||||
// 子场景
|
// subscene
|
||||||
SubKeyScenes []*KeyScene `thrift:"SubKeyScenes,9,optional" json:"sub_key_scenes" form:"SubKeyScenes" query:"SubKeyScenes"`
|
SubKeyScenes []*KeyScene `thrift:"SubKeyScenes,9,optional" json:"sub_key_scenes" form:"SubKeyScenes" query:"SubKeyScenes"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4671,9 +4671,9 @@ func (p *KeySceneOutput) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type TraceSummaryContent struct {
|
type TraceSummaryContent struct {
|
||||||
// 键
|
// key
|
||||||
Key *string `thrift:"Key,1,optional" json:"key" form:"Key" query:"Key"`
|
Key *string `thrift:"Key,1,optional" json:"key" form:"Key" query:"Key"`
|
||||||
// 内容
|
// content
|
||||||
Content *string `thrift:"Content,2,optional" json:"content" form:"Content" query:"Content"`
|
Content *string `thrift:"Content,2,optional" json:"content" form:"Content" query:"Content"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4879,9 +4879,9 @@ func (p *TraceSummaryContent) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type MessageItem struct {
|
type MessageItem struct {
|
||||||
// 角色
|
// role
|
||||||
Role *string `thrift:"Role,1,optional" json:"role" form:"Role" query:"Role"`
|
Role *string `thrift:"Role,1,optional" json:"role" form:"Role" query:"Role"`
|
||||||
// 内容
|
// content
|
||||||
Content *string `thrift:"Content,2,optional" json:"content" form:"Content" query:"Content"`
|
Content *string `thrift:"Content,2,optional" json:"content" form:"Content" query:"Content"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5258,13 +5258,13 @@ func (p *SpanSummary) String() string {
|
||||||
|
|
||||||
type FrontendTag struct {
|
type FrontendTag struct {
|
||||||
Key string `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
Key string `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
||||||
// 多语,如无配置时值沿用 key
|
// Multilingual, if there is no configuration value, use the key
|
||||||
KeyAlias *string `thrift:"KeyAlias,2,optional" json:"key_alias" form:"KeyAlias" query:"KeyAlias"`
|
KeyAlias *string `thrift:"KeyAlias,2,optional" json:"key_alias" form:"KeyAlias" query:"KeyAlias"`
|
||||||
TagType TagType `thrift:"TagType,3,required" json:"tag_type" form:"TagType,required" query:"TagType,required"`
|
TagType TagType `thrift:"TagType,3,required" json:"tag_type" form:"TagType,required" query:"TagType,required"`
|
||||||
Value *Value `thrift:"Value,4,optional" json:"value" form:"Value" query:"Value"`
|
Value *Value `thrift:"Value,4,optional" json:"value" form:"Value" query:"Value"`
|
||||||
// 前端类型,用于前端处理
|
// Front-end type for front-end processing
|
||||||
FrontendTagType *FrontedTagType `thrift:"FrontendTagType,5,optional" json:"frontend_tag_type" form:"FrontendTagType" query:"FrontendTagType"`
|
FrontendTagType *FrontedTagType `thrift:"FrontendTagType,5,optional" json:"frontend_tag_type" form:"FrontendTagType" query:"FrontendTagType"`
|
||||||
// 是否可复制
|
// Can it be copied?
|
||||||
CanCopy *bool `thrift:"canCopy,6,optional" json:"can_copy" form:"canCopy" query:"canCopy"`
|
CanCopy *bool `thrift:"canCopy,6,optional" json:"can_copy" form:"canCopy" query:"canCopy"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5681,18 +5681,18 @@ func (p *FrontendTag) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type TraceSummary struct {
|
type TraceSummary struct {
|
||||||
// 一级 System 的文本
|
// System 1 text
|
||||||
System *string `thrift:"System,1,optional" json:"system" form:"System" query:"System"`
|
System *string `thrift:"System,1,optional" json:"system" form:"System" query:"System"`
|
||||||
// 一级历史消息
|
// Level 1 chat history
|
||||||
HistoryMessages []*MessageItem `thrift:"HistoryMessages,2,optional" json:"history_messages" form:"HistoryMessages" query:"HistoryMessages"`
|
HistoryMessages []*MessageItem `thrift:"HistoryMessages,2,optional" json:"history_messages" form:"HistoryMessages" query:"HistoryMessages"`
|
||||||
KeyScenes []*KeyScene `thrift:"KeyScenes,3,optional" json:"key_scenes" form:"KeyScenes" query:"KeyScenes"`
|
KeyScenes []*KeyScene `thrift:"KeyScenes,3,optional" json:"key_scenes" form:"KeyScenes" query:"KeyScenes"`
|
||||||
// 输入
|
// input
|
||||||
Input *string `thrift:"Input,4,optional" json:"input" form:"Input" query:"Input"`
|
Input *string `thrift:"Input,4,optional" json:"input" form:"Input" query:"Input"`
|
||||||
// 输出
|
// output
|
||||||
Output *string `thrift:"Output,5,optional" json:"output" form:"Output" query:"Output"`
|
Output *string `thrift:"Output,5,optional" json:"output" form:"Output" query:"Output"`
|
||||||
// 一级当前对话的耗时, 单位是毫秒
|
// The duration of the current conversation, in milliseconds
|
||||||
Duration *int64 `thrift:"Duration,6,optional" json:"duration" form:"Duration" query:"Duration"`
|
Duration *int64 `thrift:"Duration,6,optional" json:"duration" form:"Duration" query:"Duration"`
|
||||||
// 用户ID
|
// user ID
|
||||||
UserID *string `thrift:"UserID,7,optional" json:"user_id" form:"UserID" query:"UserID"`
|
UserID *string `thrift:"UserID,7,optional" json:"user_id" form:"UserID" query:"UserID"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -6213,15 +6213,15 @@ func (p *TraceSummary) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type TraceHeader struct {
|
type TraceHeader struct {
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
Duration *int64 `thrift:"Duration,1,optional" json:"duration" form:"Duration" query:"Duration"`
|
Duration *int64 `thrift:"Duration,1,optional" json:"duration" form:"Duration" query:"Duration"`
|
||||||
// 输入消耗token数
|
// Enter the number of tokens consumed
|
||||||
Tokens *int32 `thrift:"Tokens,2,optional" form:"Tokens" json:"Tokens,omitempty" query:"Tokens"`
|
Tokens *int32 `thrift:"Tokens,2,optional" form:"Tokens" json:"Tokens,omitempty" query:"Tokens"`
|
||||||
StatusCode *int32 `thrift:"StatusCode,3,optional" json:"status_code" form:"StatusCode" query:"StatusCode"`
|
StatusCode *int32 `thrift:"StatusCode,3,optional" json:"status_code" form:"StatusCode" query:"StatusCode"`
|
||||||
Tags []*FrontendTag `thrift:"Tags,4,optional" json:"tags" form:"Tags" query:"Tags"`
|
Tags []*FrontendTag `thrift:"Tags,4,optional" json:"tags" form:"Tags" query:"Tags"`
|
||||||
// 消息ID
|
// Message ID
|
||||||
MessageID *string `thrift:"MessageID,5,optional" json:"message_id" form:"MessageID" query:"MessageID"`
|
MessageID *string `thrift:"MessageID,5,optional" json:"message_id" form:"MessageID" query:"MessageID"`
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
StartTime *int64 `thrift:"StartTime,6,optional" json:"start_time" form:"StartTime" query:"StartTime"`
|
StartTime *int64 `thrift:"StartTime,6,optional" json:"start_time" form:"StartTime" query:"StartTime"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7381,25 +7381,25 @@ type TraceFrontendSpan struct {
|
||||||
Name string `thrift:"Name,5" json:"name" form:"Name" query:"Name"`
|
Name string `thrift:"Name,5" json:"name" form:"Name" query:"Name"`
|
||||||
AliasName string `thrift:"AliasName,6" json:"alias_name" form:"AliasName" query:"AliasName"`
|
AliasName string `thrift:"AliasName,6" json:"alias_name" form:"AliasName" query:"AliasName"`
|
||||||
ParentID string `thrift:"ParentID,7" json:"parent_id" form:"ParentID" query:"ParentID"`
|
ParentID string `thrift:"ParentID,7" json:"parent_id" form:"ParentID" query:"ParentID"`
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
Duration int64 `thrift:"Duration,8" json:"duration" form:"Duration" query:"Duration"`
|
Duration int64 `thrift:"Duration,8" json:"duration" form:"Duration" query:"Duration"`
|
||||||
// 单位是毫秒
|
// It's in milliseconds.
|
||||||
StartTime int64 `thrift:"StartTime,9" json:"start_time" form:"StartTime" query:"StartTime"`
|
StartTime int64 `thrift:"StartTime,9" json:"start_time" form:"StartTime" query:"StartTime"`
|
||||||
StatusCode int32 `thrift:"StatusCode,10" json:"status_code" form:"StatusCode" query:"StatusCode"`
|
StatusCode int32 `thrift:"StatusCode,10" json:"status_code" form:"StatusCode" query:"StatusCode"`
|
||||||
Tags []*TraceTag `thrift:"Tags,11,optional" json:"tags" form:"Tags" query:"Tags"`
|
Tags []*TraceTag `thrift:"Tags,11,optional" json:"tags" form:"Tags" query:"Tags"`
|
||||||
// 节点详情
|
// node details
|
||||||
Summary *SpanSummary `thrift:"summary,12,optional" json:"summary" form:"summary" query:"summary"`
|
Summary *SpanSummary `thrift:"summary,12,optional" json:"summary" form:"summary" query:"summary"`
|
||||||
Input *SpanInputOutput `thrift:"Input,13,optional" json:"input" form:"Input" query:"Input"`
|
Input *SpanInputOutput `thrift:"Input,13,optional" json:"input" form:"Input" query:"Input"`
|
||||||
Output *SpanInputOutput `thrift:"Output,14,optional" json:"output" form:"Output" query:"Output"`
|
Output *SpanInputOutput `thrift:"Output,14,optional" json:"output" form:"Output" query:"Output"`
|
||||||
// 是否是入口节点
|
// Is it an entry node?
|
||||||
IsEntry *bool `thrift:"IsEntry,15,optional" json:"is_entry" form:"IsEntry" query:"IsEntry"`
|
IsEntry *bool `thrift:"IsEntry,15,optional" json:"is_entry" form:"IsEntry" query:"IsEntry"`
|
||||||
// 产品线
|
// product line
|
||||||
ProductLine *string `thrift:"ProductLine,16,optional" json:"product_line" form:"ProductLine" query:"ProductLine"`
|
ProductLine *string `thrift:"ProductLine,16,optional" json:"product_line" form:"ProductLine" query:"ProductLine"`
|
||||||
// 是否是关键节点
|
// Is it a key node?
|
||||||
IsKeySpan *bool `thrift:"IsKeySpan,17,optional" json:"is_key_span" form:"IsKeySpan" query:"IsKeySpan"`
|
IsKeySpan *bool `thrift:"IsKeySpan,17,optional" json:"is_key_span" form:"IsKeySpan" query:"IsKeySpan"`
|
||||||
// 节点负责人列表, 邮箱前缀
|
// Node owner list, mailbox prefix
|
||||||
OwnerList []string `thrift:"OwnerList,18,optional" json:"owner_list" form:"OwnerList" query:"OwnerList"`
|
OwnerList []string `thrift:"OwnerList,18,optional" json:"owner_list" form:"OwnerList" query:"OwnerList"`
|
||||||
// 节点详情文档
|
// Node Details Document
|
||||||
RundownDocURL *string `thrift:"RundownDocURL,19,optional" json:"rundown_doc_url" form:"RundownDocURL" query:"RundownDocURL"`
|
RundownDocURL *string `thrift:"RundownDocURL,19,optional" json:"rundown_doc_url" form:"RundownDocURL" query:"RundownDocURL"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -156,7 +156,7 @@ func (p *AppUserInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type User struct {
|
type User struct {
|
||||||
// 与原接口字段名对齐
|
// Align with the original interface field name
|
||||||
UserIDStr int64 `thrift:"user_id_str,1,required" form:"user_id_str,required" json:"user_id_str,string,required" query:"user_id_str,required"`
|
UserIDStr int64 `thrift:"user_id_str,1,required" form:"user_id_str,required" json:"user_id_str,string,required" query:"user_id_str,required"`
|
||||||
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
UserUniqueName string `thrift:"user_unique_name,3,required" form:"user_unique_name,required" json:"user_unique_name,required" query:"user_unique_name,required"`
|
UserUniqueName string `thrift:"user_unique_name,3,required" form:"user_unique_name,required" json:"user_unique_name,required" query:"user_unique_name,required"`
|
||||||
|
|
@ -3848,15 +3848,15 @@ func (p *UserUpdateProfileResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PassportService interface {
|
type PassportService interface {
|
||||||
// 邮箱密码注册
|
// Email password registration
|
||||||
PassportWebEmailRegisterV2Post(ctx context.Context, req *PassportWebEmailRegisterV2PostRequest) (r *PassportWebEmailRegisterV2PostResponse, err error)
|
PassportWebEmailRegisterV2Post(ctx context.Context, req *PassportWebEmailRegisterV2PostRequest) (r *PassportWebEmailRegisterV2PostResponse, err error)
|
||||||
// 退出登录
|
// log out
|
||||||
PassportWebLogoutGet(ctx context.Context, req *PassportWebLogoutGetRequest) (r *PassportWebLogoutGetResponse, err error)
|
PassportWebLogoutGet(ctx context.Context, req *PassportWebLogoutGetRequest) (r *PassportWebLogoutGetResponse, err error)
|
||||||
// 邮箱帐密登录
|
// Email account password login
|
||||||
PassportWebEmailLoginPost(ctx context.Context, req *PassportWebEmailLoginPostRequest) (r *PassportWebEmailLoginPostResponse, err error)
|
PassportWebEmailLoginPost(ctx context.Context, req *PassportWebEmailLoginPostRequest) (r *PassportWebEmailLoginPostResponse, err error)
|
||||||
// 通过邮箱重置密码
|
// Reset password via email
|
||||||
PassportWebEmailPasswordResetGet(ctx context.Context, req *PassportWebEmailPasswordResetGetRequest) (r *PassportWebEmailPasswordResetGetResponse, err error)
|
PassportWebEmailPasswordResetGet(ctx context.Context, req *PassportWebEmailPasswordResetGetRequest) (r *PassportWebEmailPasswordResetGetResponse, err error)
|
||||||
// 账号信息
|
// account information
|
||||||
PassportAccountInfoV2(ctx context.Context, req *PassportAccountInfoV2Request) (r *PassportAccountInfoV2Response, err error)
|
PassportAccountInfoV2(ctx context.Context, req *PassportAccountInfoV2Request) (r *PassportAccountInfoV2Response, err error)
|
||||||
|
|
||||||
UserUpdateAvatar(ctx context.Context, req *UserUpdateAvatarRequest) (r *UserUpdateAvatarResponse, err error)
|
UserUpdateAvatar(ctx context.Context, req *UserUpdateAvatarRequest) (r *UserUpdateAvatarResponse, err error)
|
||||||
|
|
|
||||||
|
|
@ -26,11 +26,11 @@ type PatSearchOption = string
|
||||||
type UserStatus = string
|
type UserStatus = string
|
||||||
|
|
||||||
type CreatePersonalAccessTokenAndPermissionRequest struct {
|
type CreatePersonalAccessTokenAndPermissionRequest struct {
|
||||||
// PAT名称
|
// PAT name
|
||||||
Name string `thrift:"name,1,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,1,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
// PAT自定义过期时间
|
// PAT custom expiration time
|
||||||
ExpireAt int64 `thrift:"expire_at,2" form:"expire_at" json:"expire_at" query:"expire_at"`
|
ExpireAt int64 `thrift:"expire_at,2" form:"expire_at" json:"expire_at" query:"expire_at"`
|
||||||
// PAT用户枚举过期时间 1、30、60、90、180、365、permanent
|
// PAT user enumeration expiration time 1, 30, 60, 90, 180, 365, permanent
|
||||||
DurationDay string `thrift:"duration_day,3" form:"duration_day" json:"duration_day" query:"duration_day"`
|
DurationDay string `thrift:"duration_day,3" form:"duration_day" json:"duration_day" query:"duration_day"`
|
||||||
// organization id
|
// organization id
|
||||||
OrganizationID string `thrift:"organization_id,4" form:"organization_id" json:"organization_id" query:"organization_id"`
|
OrganizationID string `thrift:"organization_id,4" form:"organization_id" json:"organization_id" query:"organization_id"`
|
||||||
|
|
@ -316,9 +316,9 @@ type PersonalAccessToken struct {
|
||||||
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
CreatedAt int64 `thrift:"created_at,3,required" form:"created_at,required" json:"created_at,required" query:"created_at,required"`
|
CreatedAt int64 `thrift:"created_at,3,required" form:"created_at,required" json:"created_at,required" query:"created_at,required"`
|
||||||
UpdatedAt int64 `thrift:"updated_at,4,required" form:"updated_at,required" json:"updated_at,required" query:"updated_at,required"`
|
UpdatedAt int64 `thrift:"updated_at,4,required" form:"updated_at,required" json:"updated_at,required" query:"updated_at,required"`
|
||||||
// -1 表示未使用
|
// -1 means unused
|
||||||
LastUsedAt int64 `thrift:"last_used_at,5,required" form:"last_used_at,required" json:"last_used_at,required" query:"last_used_at,required"`
|
LastUsedAt int64 `thrift:"last_used_at,5,required" form:"last_used_at,required" json:"last_used_at,required" query:"last_used_at,required"`
|
||||||
// -1 表示无限期
|
// -1 means indefinite
|
||||||
ExpireAt int64 `thrift:"expire_at,6,required" form:"expire_at,required" json:"expire_at,required" query:"expire_at,required"`
|
ExpireAt int64 `thrift:"expire_at,6,required" form:"expire_at,required" json:"expire_at,required" query:"expire_at,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -722,7 +722,7 @@ func (p *PersonalAccessToken) String() string {
|
||||||
|
|
||||||
type CreatePersonalAccessTokenAndPermissionResponseData struct {
|
type CreatePersonalAccessTokenAndPermissionResponseData struct {
|
||||||
PersonalAccessToken *PersonalAccessToken `thrift:"personal_access_token,1,required" form:"personal_access_token,required" json:"personal_access_token,required" query:"personal_access_token,required"`
|
PersonalAccessToken *PersonalAccessToken `thrift:"personal_access_token,1,required" form:"personal_access_token,required" json:"personal_access_token,required" query:"personal_access_token,required"`
|
||||||
// PAT token 明文
|
// PAT token plaintext
|
||||||
Token string `thrift:"token,2,required" form:"token,required" json:"token,required" query:"token,required"`
|
Token string `thrift:"token,2,required" form:"token,required" json:"token,required" query:"token,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1510,9 +1510,9 @@ type PersonalAccessTokenWithCreatorInfo struct {
|
||||||
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
CreatedAt int64 `thrift:"created_at,3,required" form:"created_at,required" json:"created_at,required" query:"created_at,required"`
|
CreatedAt int64 `thrift:"created_at,3,required" form:"created_at,required" json:"created_at,required" query:"created_at,required"`
|
||||||
UpdatedAt int64 `thrift:"updated_at,4,required" form:"updated_at,required" json:"updated_at,required" query:"updated_at,required"`
|
UpdatedAt int64 `thrift:"updated_at,4,required" form:"updated_at,required" json:"updated_at,required" query:"updated_at,required"`
|
||||||
// -1 表示未使用
|
// -1 means unused
|
||||||
LastUsedAt int64 `thrift:"last_used_at,5,required" form:"last_used_at,required" json:"last_used_at,required" query:"last_used_at,required"`
|
LastUsedAt int64 `thrift:"last_used_at,5,required" form:"last_used_at,required" json:"last_used_at,required" query:"last_used_at,required"`
|
||||||
// -1 表示无限期
|
// -1 means indefinite
|
||||||
ExpireAt int64 `thrift:"expire_at,6,required" form:"expire_at,required" json:"expire_at,required" query:"expire_at,required"`
|
ExpireAt int64 `thrift:"expire_at,6,required" form:"expire_at,required" json:"expire_at,required" query:"expire_at,required"`
|
||||||
CreatorName string `thrift:"creator_name,7" form:"creator_name" json:"creator_name" query:"creator_name"`
|
CreatorName string `thrift:"creator_name,7" form:"creator_name" json:"creator_name" query:"creator_name"`
|
||||||
CreatorUniqueName string `thrift:"creator_unique_name,8" form:"creator_unique_name" json:"creator_unique_name" query:"creator_unique_name"`
|
CreatorUniqueName string `thrift:"creator_unique_name,8" form:"creator_unique_name" json:"creator_unique_name" query:"creator_unique_name"`
|
||||||
|
|
@ -2442,9 +2442,9 @@ func (p *ListPersonalAccessTokensResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ListPersonalAccessTokensResponseData struct {
|
type ListPersonalAccessTokensResponseData struct {
|
||||||
// PAT 列表
|
// PAT list
|
||||||
PersonalAccessTokens []*PersonalAccessTokenWithCreatorInfo `thrift:"personal_access_tokens,1,required" form:"personal_access_tokens,required" json:"personal_access_tokens,required" query:"personal_access_tokens,required"`
|
PersonalAccessTokens []*PersonalAccessTokenWithCreatorInfo `thrift:"personal_access_tokens,1,required" form:"personal_access_tokens,required" json:"personal_access_tokens,required" query:"personal_access_tokens,required"`
|
||||||
// 是否还有更多数据
|
// Is there any more data?
|
||||||
HasMore bool `thrift:"has_more,2" form:"has_more" json:"has_more" query:"has_more"`
|
HasMore bool `thrift:"has_more,2" form:"has_more" json:"has_more" query:"has_more"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3563,7 +3563,7 @@ func (p *GetPersonalAccessTokenAndPermissionResponse) String() string {
|
||||||
type UpdatePersonalAccessTokenAndPermissionRequest struct {
|
type UpdatePersonalAccessTokenAndPermissionRequest struct {
|
||||||
// PAT Id
|
// PAT Id
|
||||||
ID int64 `thrift:"id,1,required" form:"id,required" json:"id,string,required" query:"id,required"`
|
ID int64 `thrift:"id,1,required" form:"id,required" json:"id,string,required" query:"id,required"`
|
||||||
// PAT 名称
|
// PAT name
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -150,7 +150,7 @@ func (p *ParameterLocation) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// plugin枚举值
|
// plugin enumeration value
|
||||||
type PluginParamTypeFormat int64
|
type PluginParamTypeFormat int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -394,13 +394,13 @@ func (p *ParameterType) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 默认入参的设置来源
|
// Default imported parameter settings source
|
||||||
type DefaultParamSource int64
|
type DefaultParamSource int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 默认用户输入
|
// default user input
|
||||||
DefaultParamSource_Input DefaultParamSource = 0
|
DefaultParamSource_Input DefaultParamSource = 0
|
||||||
// 引用变量
|
// reference variable
|
||||||
DefaultParamSource_Variable DefaultParamSource = 1
|
DefaultParamSource_Variable DefaultParamSource = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -439,7 +439,7 @@ func (p *DefaultParamSource) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 针对File类型参数的细分类型
|
// Subdivision types for File type parameters
|
||||||
type AssistParameterType int64
|
type AssistParameterType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -453,7 +453,7 @@ const (
|
||||||
AssistParameterType_AUDIO AssistParameterType = 8
|
AssistParameterType_AUDIO AssistParameterType = 8
|
||||||
AssistParameterType_ZIP AssistParameterType = 9
|
AssistParameterType_ZIP AssistParameterType = 9
|
||||||
AssistParameterType_VIDEO AssistParameterType = 10
|
AssistParameterType_VIDEO AssistParameterType = 10
|
||||||
// 语音
|
// voice
|
||||||
AssistParameterType_VOICE AssistParameterType = 12
|
AssistParameterType_VOICE AssistParameterType = 12
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -531,11 +531,11 @@ func (p *AssistParameterType) Value() (driver.Value, error) {
|
||||||
type PluginToolAuthType int64
|
type PluginToolAuthType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 强授权
|
// strong authorization
|
||||||
PluginToolAuthType_Required PluginToolAuthType = 0
|
PluginToolAuthType_Required PluginToolAuthType = 0
|
||||||
// 半匿名授权
|
// semi-anonymous authorization
|
||||||
PluginToolAuthType_Supported PluginToolAuthType = 1
|
PluginToolAuthType_Supported PluginToolAuthType = 1
|
||||||
// 不授权
|
// not authorized
|
||||||
PluginToolAuthType_Disable PluginToolAuthType = 2
|
PluginToolAuthType_Disable PluginToolAuthType = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -582,9 +582,9 @@ type PluginCardStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
PluginCardStatus_Latest PluginCardStatus = 1
|
PluginCardStatus_Latest PluginCardStatus = 1
|
||||||
// 主卡片版本有升级
|
// The main card version has been upgraded.
|
||||||
PluginCardStatus_NeedUpdate PluginCardStatus = 2
|
PluginCardStatus_NeedUpdate PluginCardStatus = 2
|
||||||
// 插件工具出参不匹配
|
// Plugin tool exported parameters do not match
|
||||||
PluginCardStatus_ParamMisMatch PluginCardStatus = 3
|
PluginCardStatus_ParamMisMatch PluginCardStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -697,9 +697,9 @@ const (
|
||||||
PluginStatus_PREPARED PluginStatus = 3
|
PluginStatus_PREPARED PluginStatus = 3
|
||||||
PluginStatus_PUBLISHED PluginStatus = 4
|
PluginStatus_PUBLISHED PluginStatus = 4
|
||||||
PluginStatus_OFFLINE PluginStatus = 5
|
PluginStatus_OFFLINE PluginStatus = 5
|
||||||
// 默认值
|
// default value
|
||||||
PluginStatus_Draft PluginStatus = 0
|
PluginStatus_Draft PluginStatus = 0
|
||||||
// 禁用
|
// disable
|
||||||
PluginStatus_BANNED PluginStatus = 6
|
PluginStatus_BANNED PluginStatus = 6
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -934,13 +934,13 @@ func (p *APIListOrderBy) Value() (driver.Value, error) {
|
||||||
type SpaceRoleType int64
|
type SpaceRoleType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 默认
|
// default
|
||||||
SpaceRoleType_Default SpaceRoleType = 0
|
SpaceRoleType_Default SpaceRoleType = 0
|
||||||
// owner
|
// owner
|
||||||
SpaceRoleType_Owner SpaceRoleType = 1
|
SpaceRoleType_Owner SpaceRoleType = 1
|
||||||
// 管理员
|
// administrator
|
||||||
SpaceRoleType_Admin SpaceRoleType = 2
|
SpaceRoleType_Admin SpaceRoleType = 2
|
||||||
// 普通成员
|
// ordinary member
|
||||||
SpaceRoleType_Member SpaceRoleType = 3
|
SpaceRoleType_Member SpaceRoleType = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1224,9 +1224,9 @@ func (p *PluginReferrerScene) Value() (driver.Value, error) {
|
||||||
type WorkflowResponseMode int64
|
type WorkflowResponseMode int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 模型总结
|
// model summary
|
||||||
WorkflowResponseMode_UseLLM WorkflowResponseMode = 0
|
WorkflowResponseMode_UseLLM WorkflowResponseMode = 0
|
||||||
// 不使用模型总结
|
// Do not use model summaries
|
||||||
WorkflowResponseMode_SkipLLM WorkflowResponseMode = 1
|
WorkflowResponseMode_SkipLLM WorkflowResponseMode = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1265,7 +1265,7 @@ func (p *WorkflowResponseMode) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 授权状态
|
// authorization status
|
||||||
type OAuthStatus int64
|
type OAuthStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
|
|
@ -1311,9 +1311,9 @@ func (p *OAuthStatus) Value() (driver.Value, error) {
|
||||||
type DebugOperation int64
|
type DebugOperation int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 调试,会保存调试状态,会校验返回值
|
// Debugging, the debugging state will be saved, and the return value will be checked.
|
||||||
DebugOperation_Debug DebugOperation = 1
|
DebugOperation_Debug DebugOperation = 1
|
||||||
// 仅解析返回值结构
|
// Parse only the return value structure
|
||||||
DebugOperation_Parse DebugOperation = 2
|
DebugOperation_Parse DebugOperation = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1355,9 +1355,9 @@ func (p *DebugOperation) Value() (driver.Value, error) {
|
||||||
type ScopeType int64
|
type ScopeType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 所有
|
// all
|
||||||
ScopeType_All ScopeType = 0
|
ScopeType_All ScopeType = 0
|
||||||
// 自己
|
// self
|
||||||
ScopeType_Self ScopeType = 1
|
ScopeType_Self ScopeType = 1
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1451,11 +1451,11 @@ func (p *OrderBy) Value() (driver.Value, error) {
|
||||||
type PluginTypeForFilter int64
|
type PluginTypeForFilter int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 包含PLUGIN和APP
|
// Includes PLUGIN and APP.
|
||||||
PluginTypeForFilter_CloudPlugin PluginTypeForFilter = 1
|
PluginTypeForFilter_CloudPlugin PluginTypeForFilter = 1
|
||||||
// 包含LOCAL
|
// Include LOCAL
|
||||||
PluginTypeForFilter_LocalPlugin PluginTypeForFilter = 2
|
PluginTypeForFilter_LocalPlugin PluginTypeForFilter = 2
|
||||||
// 包含WORKFLOW和IMAGEFLOW
|
// Includes WORKFLOW and IMAGEFLOW
|
||||||
PluginTypeForFilter_WorkflowPlugin PluginTypeForFilter = 3
|
PluginTypeForFilter_WorkflowPlugin PluginTypeForFilter = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -2514,31 +2514,31 @@ func (p *UserLabel) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PluginMetaInfo struct {
|
type PluginMetaInfo struct {
|
||||||
// 插件名
|
// plugin name
|
||||||
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,1" form:"name" json:"name" query:"name"`
|
||||||
// 插件描述
|
// Plugin description
|
||||||
Desc string `thrift:"desc,2" form:"desc" json:"desc" query:"desc"`
|
Desc string `thrift:"desc,2" form:"desc" json:"desc" query:"desc"`
|
||||||
// 插件服务地址前缀
|
// Plugin service address prefix
|
||||||
URL string `thrift:"url,3" form:"url" json:"url" query:"url"`
|
URL string `thrift:"url,3" form:"url" json:"url" query:"url"`
|
||||||
// 插件图标
|
// plugin icon
|
||||||
Icon *PluginIcon `thrift:"icon,4" form:"icon" json:"icon" query:"icon"`
|
Icon *PluginIcon `thrift:"icon,4" form:"icon" json:"icon" query:"icon"`
|
||||||
// 插件授权类型,0:无授权,1:service,3:oauth
|
// Plugin authorization type, 0: no authorization, 1: service, 3: oauth
|
||||||
AuthType []AuthorizationType `thrift:"auth_type,5" form:"auth_type" json:"auth_type" query:"auth_type"`
|
AuthType []AuthorizationType `thrift:"auth_type,5" form:"auth_type" json:"auth_type" query:"auth_type"`
|
||||||
// 子授权类型为api/token时,token参数位置
|
// When the sub-authorization type is api/token, the token parameter position
|
||||||
Location *AuthorizationServiceLocation `thrift:"location,6,optional" form:"location" json:"location,omitempty" query:"location"`
|
Location *AuthorizationServiceLocation `thrift:"location,6,optional" form:"location" json:"location,omitempty" query:"location"`
|
||||||
// 子授权类型为api/token时,token参数key
|
// When the sub-authorization type is api/token, the token parameter key
|
||||||
Key *string `thrift:"key,7,optional" form:"key" json:"key,omitempty" query:"key"`
|
Key *string `thrift:"key,7,optional" form:"key" json:"key,omitempty" query:"key"`
|
||||||
// 子授权类型为api/token时,token参数值
|
// When the sub-authorization type is api/token, the token parameter value
|
||||||
ServiceToken *string `thrift:"service_token,8,optional" form:"service_token" json:"service_token,omitempty" query:"service_token"`
|
ServiceToken *string `thrift:"service_token,8,optional" form:"service_token" json:"service_token,omitempty" query:"service_token"`
|
||||||
// 子授权类型为oauth时,oauth信息
|
// When the sub-authorization type is oauth, the oauth information
|
||||||
OauthInfo *string `thrift:"oauth_info,9,optional" form:"oauth_info" json:"oauth_info,omitempty" query:"oauth_info"`
|
OauthInfo *string `thrift:"oauth_info,9,optional" form:"oauth_info" json:"oauth_info,omitempty" query:"oauth_info"`
|
||||||
// 插件公共参数,key为参数位置,value为参数列表
|
// Plugin public parameters, key is the parameter position, value is the parameter list
|
||||||
CommonParams map[ParameterLocation][]*CommonParamSchema `thrift:"common_params,10,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
CommonParams map[ParameterLocation][]*CommonParamSchema `thrift:"common_params,10,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
||||||
// 子授权类型,0: api/token of service, 10: client credentials of oauth
|
// Sub-authorization type, 0: api/token of service, 10: client credentials of oauth
|
||||||
SubAuthType *int32 `thrift:"sub_auth_type,11,optional" form:"sub_auth_type" json:"sub_auth_type,omitempty" query:"sub_auth_type"`
|
SubAuthType *int32 `thrift:"sub_auth_type,11,optional" form:"sub_auth_type" json:"sub_auth_type,omitempty" query:"sub_auth_type"`
|
||||||
// 可忽略
|
// negligible
|
||||||
AuthPayload *string `thrift:"auth_payload,12,optional" form:"auth_payload" json:"auth_payload,omitempty" query:"auth_payload"`
|
AuthPayload *string `thrift:"auth_payload,12,optional" form:"auth_payload" json:"auth_payload,omitempty" query:"auth_payload"`
|
||||||
// 可忽略
|
// negligible
|
||||||
FixedExportIP bool `thrift:"fixed_export_ip,13" form:"fixed_export_ip" json:"fixed_export_ip" query:"fixed_export_ip"`
|
FixedExportIP bool `thrift:"fixed_export_ip,13" form:"fixed_export_ip" json:"fixed_export_ip" query:"fixed_export_ip"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3759,34 +3759,34 @@ type PluginInfoForPlayground struct {
|
||||||
ClientID string `thrift:"client_id,10" form:"client_id" json:"client_id" query:"client_id"`
|
ClientID string `thrift:"client_id,10" form:"client_id" json:"client_id" query:"client_id"`
|
||||||
ClientSecret string `thrift:"client_secret,11" form:"client_secret" json:"client_secret" query:"client_secret"`
|
ClientSecret string `thrift:"client_secret,11" form:"client_secret" json:"client_secret" query:"client_secret"`
|
||||||
PluginApis []*PluginApi `thrift:"plugin_apis,15" form:"plugin_apis" json:"plugin_apis" query:"plugin_apis"`
|
PluginApis []*PluginApi `thrift:"plugin_apis,15" form:"plugin_apis" json:"plugin_apis" query:"plugin_apis"`
|
||||||
// 插件标签
|
// plugin tag
|
||||||
Tag int64 `thrift:"tag,16" form:"tag" json:"tag" query:"tag"`
|
Tag int64 `thrift:"tag,16" form:"tag" json:"tag" query:"tag"`
|
||||||
CreateTime string `thrift:"create_time,17" form:"create_time" json:"create_time" query:"create_time"`
|
CreateTime string `thrift:"create_time,17" form:"create_time" json:"create_time" query:"create_time"`
|
||||||
UpdateTime string `thrift:"update_time,18" form:"update_time" json:"update_time" query:"update_time"`
|
UpdateTime string `thrift:"update_time,18" form:"update_time" json:"update_time" query:"update_time"`
|
||||||
// 创建人信息
|
// creator information
|
||||||
Creator *Creator `thrift:"creator,22" form:"creator" json:"creator" query:"creator"`
|
Creator *Creator `thrift:"creator,22" form:"creator" json:"creator" query:"creator"`
|
||||||
// 空间id
|
// Space ID
|
||||||
SpaceID string `thrift:"space_id,23" form:"space_id" json:"space_id" query:"space_id"`
|
SpaceID string `thrift:"space_id,23" form:"space_id" json:"space_id" query:"space_id"`
|
||||||
// 插件统计数据
|
// plugin statistics
|
||||||
StatisticData *PluginStatisticData `thrift:"statistic_data,24" form:"statistic_data" json:"statistic_data" query:"statistic_data"`
|
StatisticData *PluginStatisticData `thrift:"statistic_data,24" form:"statistic_data" json:"statistic_data" query:"statistic_data"`
|
||||||
CommonParams map[ParameterLocation][]*CommonParamSchema `thrift:"common_params,25,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
CommonParams map[ParameterLocation][]*CommonParamSchema `thrift:"common_params,25,optional" form:"common_params" json:"common_params,omitempty" query:"common_params"`
|
||||||
// plugin的商品状态
|
// Product status of the plugin
|
||||||
PluginProductStatus ProductStatus `thrift:"plugin_product_status,26" form:"plugin_product_status" json:"plugin_product_status" query:"plugin_product_status"`
|
PluginProductStatus ProductStatus `thrift:"plugin_product_status,26" form:"plugin_product_status" json:"plugin_product_status" query:"plugin_product_status"`
|
||||||
// plugin商品下架类型
|
// Plugin product removal type
|
||||||
PluginProductUnlistType ProductUnlistType `thrift:"plugin_product_unlist_type,27" form:"plugin_product_unlist_type" json:"plugin_product_unlist_type" query:"plugin_product_unlist_type"`
|
PluginProductUnlistType ProductUnlistType `thrift:"plugin_product_unlist_type,27" form:"plugin_product_unlist_type" json:"plugin_product_unlist_type" query:"plugin_product_unlist_type"`
|
||||||
// 素材id
|
// Material ID
|
||||||
MaterialID string `thrift:"material_id,28" form:"material_id" json:"material_id" query:"material_id"`
|
MaterialID string `thrift:"material_id,28" form:"material_id" json:"material_id" query:"material_id"`
|
||||||
// 渠道id
|
// Channel ID
|
||||||
ChannelID int32 `thrift:"channel_id,29" form:"channel_id" json:"channel_id" query:"channel_id"`
|
ChannelID int32 `thrift:"channel_id,29" form:"channel_id" json:"channel_id" query:"channel_id"`
|
||||||
// 插件创建方式
|
// Plugin creation method
|
||||||
CreationMethod CreationMethod `thrift:"creation_method,30" form:"creation_method" json:"creation_method" query:"creation_method"`
|
CreationMethod CreationMethod `thrift:"creation_method,30" form:"creation_method" json:"creation_method" query:"creation_method"`
|
||||||
// 是否为官方插件
|
// Is it an official plugin?
|
||||||
IsOfficial bool `thrift:"is_official,31" form:"is_official" json:"is_official" query:"is_official"`
|
IsOfficial bool `thrift:"is_official,31" form:"is_official" json:"is_official" query:"is_official"`
|
||||||
// 项目id
|
// Project ID
|
||||||
ProjectID string `thrift:"project_id,32" form:"project_id" json:"project_id" query:"project_id"`
|
ProjectID string `thrift:"project_id,32" form:"project_id" json:"project_id" query:"project_id"`
|
||||||
// 版本号,毫秒时间戳
|
// Version number, millisecond timestamp
|
||||||
VersionTs string `thrift:"version_ts,33" form:"version_ts" json:"version_ts" query:"version_ts"`
|
VersionTs string `thrift:"version_ts,33" form:"version_ts" json:"version_ts" query:"version_ts"`
|
||||||
// 版本名称
|
// version name
|
||||||
VersionName string `thrift:"version_name,34" form:"version_name" json:"version_name" query:"version_name"`
|
VersionName string `thrift:"version_name,34" form:"version_name" json:"version_name" query:"version_name"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5125,15 +5125,15 @@ type PluginApi struct {
|
||||||
Parameters []*PluginParameter `thrift:"parameters,3" form:"parameters" json:"parameters" query:"parameters"`
|
Parameters []*PluginParameter `thrift:"parameters,3" form:"parameters" json:"parameters" query:"parameters"`
|
||||||
PluginID string `thrift:"plugin_id,4" form:"plugin_id" json:"plugin_id" query:"plugin_id"`
|
PluginID string `thrift:"plugin_id,4" form:"plugin_id" json:"plugin_id" query:"plugin_id"`
|
||||||
PluginName string `thrift:"plugin_name,5" form:"plugin_name" json:"plugin_name" query:"plugin_name"`
|
PluginName string `thrift:"plugin_name,5" form:"plugin_name" json:"plugin_name" query:"plugin_name"`
|
||||||
// 序号和playground保持一致
|
// The serial number is the same as the playground
|
||||||
APIID string `thrift:"api_id,7" form:"api_id" json:"api_id" query:"api_id"`
|
APIID string `thrift:"api_id,7" form:"api_id" json:"api_id" query:"api_id"`
|
||||||
RecordID string `thrift:"record_id,8" form:"record_id" json:"record_id" query:"record_id"`
|
RecordID string `thrift:"record_id,8" form:"record_id" json:"record_id" query:"record_id"`
|
||||||
// 卡片绑定信息,未绑定则为nil
|
// Card binding information, nil if not bound.
|
||||||
CardBindingInfo *PresetCardBindingInfo `thrift:"card_binding_info,9,optional" form:"card_binding_info" json:"card_binding_info,omitempty" query:"card_binding_info"`
|
CardBindingInfo *PresetCardBindingInfo `thrift:"card_binding_info,9,optional" form:"card_binding_info" json:"card_binding_info,omitempty" query:"card_binding_info"`
|
||||||
// 调试api示例
|
// Debug API example
|
||||||
DebugExample *DebugExample `thrift:"debug_example,10,optional" form:"debug_example" json:"debug_example,omitempty" query:"debug_example"`
|
DebugExample *DebugExample `thrift:"debug_example,10,optional" form:"debug_example" json:"debug_example,omitempty" query:"debug_example"`
|
||||||
FunctionName *string `thrift:"function_name,11,optional" form:"function_name" json:"function_name,omitempty" query:"function_name"`
|
FunctionName *string `thrift:"function_name,11,optional" form:"function_name" json:"function_name,omitempty" query:"function_name"`
|
||||||
// 运行模式
|
// operating mode
|
||||||
RunMode RunMode `thrift:"run_mode,12" form:"run_mode" json:"run_mode" query:"run_mode"`
|
RunMode RunMode `thrift:"run_mode,12" form:"run_mode" json:"run_mode" query:"run_mode"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5763,12 +5763,12 @@ type Creator struct {
|
||||||
ID string `thrift:"id,1" form:"id" json:"id" query:"id"`
|
ID string `thrift:"id,1" form:"id" json:"id" query:"id"`
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
AvatarURL string `thrift:"avatar_url,3" form:"avatar_url" json:"avatar_url" query:"avatar_url"`
|
AvatarURL string `thrift:"avatar_url,3" form:"avatar_url" json:"avatar_url" query:"avatar_url"`
|
||||||
// 是否是自己创建的
|
// Did you create it yourself?
|
||||||
Self bool `thrift:"self,4" form:"self" json:"self" query:"self"`
|
Self bool `thrift:"self,4" form:"self" json:"self" query:"self"`
|
||||||
SpaceRolyType SpaceRoleType `thrift:"space_roly_type,5" form:"space_roly_type" json:"space_roly_type" query:"space_roly_type"`
|
SpaceRolyType SpaceRoleType `thrift:"space_roly_type,5" form:"space_roly_type" json:"space_roly_type" query:"space_roly_type"`
|
||||||
// 用户名
|
// user name
|
||||||
UserUniqueName string `thrift:"user_unique_name,6" form:"user_unique_name" json:"user_unique_name" query:"user_unique_name"`
|
UserUniqueName string `thrift:"user_unique_name,6" form:"user_unique_name" json:"user_unique_name" query:"user_unique_name"`
|
||||||
// 用户标签
|
// user tag
|
||||||
UserLabel *UserLabel `thrift:"user_label,7" form:"user_label" json:"user_label" query:"user_label"`
|
UserLabel *UserLabel `thrift:"user_label,7" form:"user_label" json:"user_label" query:"user_label"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -6367,15 +6367,15 @@ type PluginParameter struct {
|
||||||
Required bool `thrift:"required,3" form:"required" json:"required" query:"required"`
|
Required bool `thrift:"required,3" form:"required" json:"required" query:"required"`
|
||||||
Type string `thrift:"type,4" form:"type" json:"type" query:"type"`
|
Type string `thrift:"type,4" form:"type" json:"type" query:"type"`
|
||||||
SubParameters []*PluginParameter `thrift:"sub_parameters,5" form:"sub_parameters" json:"sub_parameters" query:"sub_parameters"`
|
SubParameters []*PluginParameter `thrift:"sub_parameters,5" form:"sub_parameters" json:"sub_parameters" query:"sub_parameters"`
|
||||||
// 如果Type是数组,则有subtype
|
// If Type is an array, there is a subtype
|
||||||
SubType string `thrift:"sub_type,6" form:"sub_type" json:"sub_type" query:"sub_type"`
|
SubType string `thrift:"sub_type,6" form:"sub_type" json:"sub_type" query:"sub_type"`
|
||||||
// 如果入参的值是引用的则有fromNodeId
|
// fromNodeId if the value of the imported parameter is a reference
|
||||||
FromNodeID *string `thrift:"from_node_id,7,optional" form:"from_node_id" json:"from_node_id,omitempty" query:"from_node_id"`
|
FromNodeID *string `thrift:"from_node_id,7,optional" form:"from_node_id" json:"from_node_id,omitempty" query:"from_node_id"`
|
||||||
// 具体引用哪个节点的key
|
// Which node's key is specifically referenced?
|
||||||
FromOutput []string `thrift:"from_output,8,optional" form:"from_output" json:"from_output,omitempty" query:"from_output"`
|
FromOutput []string `thrift:"from_output,8,optional" form:"from_output" json:"from_output,omitempty" query:"from_output"`
|
||||||
// 如果入参是用户手输 就放这里
|
// If the imported parameter is the user's hand input, put it here
|
||||||
Value *string `thrift:"value,9,optional" form:"value" json:"value,omitempty" query:"value"`
|
Value *string `thrift:"value,9,optional" form:"value" json:"value,omitempty" query:"value"`
|
||||||
// 格式化参数
|
// Format parameter
|
||||||
Format *PluginParamTypeFormat `thrift:"format,10,optional" form:"format" json:"format,omitempty" query:"format"`
|
Format *PluginParamTypeFormat `thrift:"format,10,optional" form:"format" json:"format,omitempty" query:"format"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7016,9 +7016,9 @@ type PluginAPIInfo struct {
|
||||||
APIExtend *APIExtend `thrift:"api_extend,14" form:"api_extend" json:"api_extend" query:"api_extend"`
|
APIExtend *APIExtend `thrift:"api_extend,14" form:"api_extend" json:"api_extend" query:"api_extend"`
|
||||||
// ignore
|
// ignore
|
||||||
CardBindingInfo *PresetCardBindingInfo `thrift:"card_binding_info,15,optional" form:"card_binding_info" json:"card_binding_info,omitempty" query:"card_binding_info"`
|
CardBindingInfo *PresetCardBindingInfo `thrift:"card_binding_info,15,optional" form:"card_binding_info" json:"card_binding_info,omitempty" query:"card_binding_info"`
|
||||||
// 调试示例
|
// Debugging example
|
||||||
DebugExample *DebugExample `thrift:"debug_example,16,optional" form:"debug_example" json:"debug_example,omitempty" query:"debug_example"`
|
DebugExample *DebugExample `thrift:"debug_example,16,optional" form:"debug_example" json:"debug_example,omitempty" query:"debug_example"`
|
||||||
// 调试示例状态
|
// Debug sample state
|
||||||
DebugExampleStatus DebugExampleStatus `thrift:"debug_example_status,17" form:"debug_example_status" json:"debug_example_status" query:"debug_example_status"`
|
DebugExampleStatus DebugExampleStatus `thrift:"debug_example_status,17" form:"debug_example_status" json:"debug_example_status" query:"debug_example_status"`
|
||||||
// ignore
|
// ignore
|
||||||
FunctionName string `thrift:"function_name,18" form:"function_name" json:"function_name" query:"function_name"`
|
FunctionName string `thrift:"function_name,18" form:"function_name" json:"function_name" query:"function_name"`
|
||||||
|
|
@ -7976,7 +7976,7 @@ func (p *PluginAPIInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type APIParameter struct {
|
type APIParameter struct {
|
||||||
// for前端,无实际意义
|
// For the front end, no practical significance
|
||||||
ID string `thrift:"id,1" form:"id" json:"id" query:"id"`
|
ID string `thrift:"id,1" form:"id" json:"id" query:"id"`
|
||||||
// parameter name
|
// parameter name
|
||||||
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
Name string `thrift:"name,2" form:"name" json:"name" query:"name"`
|
||||||
|
|
@ -7984,27 +7984,27 @@ type APIParameter struct {
|
||||||
Desc string `thrift:"desc,3" form:"desc" json:"desc" query:"desc"`
|
Desc string `thrift:"desc,3" form:"desc" json:"desc" query:"desc"`
|
||||||
// parameter type
|
// parameter type
|
||||||
Type ParameterType `thrift:"type,4" form:"type" json:"type" query:"type"`
|
Type ParameterType `thrift:"type,4" form:"type" json:"type" query:"type"`
|
||||||
// 可忽略
|
// negligible
|
||||||
SubType *ParameterType `thrift:"sub_type,5,optional" form:"sub_type" json:"sub_type,omitempty" query:"sub_type"`
|
SubType *ParameterType `thrift:"sub_type,5,optional" form:"sub_type" json:"sub_type,omitempty" query:"sub_type"`
|
||||||
// 参数位置
|
// parameter location
|
||||||
Location ParameterLocation `thrift:"location,6" form:"location" json:"location" query:"location"`
|
Location ParameterLocation `thrift:"location,6" form:"location" json:"location" query:"location"`
|
||||||
// 是否必填
|
// Is it required?
|
||||||
IsRequired bool `thrift:"is_required,7" form:"is_required" json:"is_required" query:"is_required"`
|
IsRequired bool `thrift:"is_required,7" form:"is_required" json:"is_required" query:"is_required"`
|
||||||
// 子参数
|
// sub-parameter
|
||||||
SubParameters []*APIParameter `thrift:"sub_parameters,8" form:"sub_parameters" json:"sub_parameters" query:"sub_parameters"`
|
SubParameters []*APIParameter `thrift:"sub_parameters,8" form:"sub_parameters" json:"sub_parameters" query:"sub_parameters"`
|
||||||
// 全局默认值
|
// global default
|
||||||
GlobalDefault *string `thrift:"global_default,9,optional" form:"global_default" json:"global_default,omitempty" query:"global_default"`
|
GlobalDefault *string `thrift:"global_default,9,optional" form:"global_default" json:"global_default,omitempty" query:"global_default"`
|
||||||
// 全局是否启用
|
// Is it enabled globally?
|
||||||
GlobalDisable bool `thrift:"global_disable,10" form:"global_disable" json:"global_disable" query:"global_disable"`
|
GlobalDisable bool `thrift:"global_disable,10" form:"global_disable" json:"global_disable" query:"global_disable"`
|
||||||
// 智能体内设置的默认值
|
// Default value set in the smart body
|
||||||
LocalDefault *string `thrift:"local_default,11,optional" form:"local_default" json:"local_default,omitempty" query:"local_default"`
|
LocalDefault *string `thrift:"local_default,11,optional" form:"local_default" json:"local_default,omitempty" query:"local_default"`
|
||||||
// 智能体内是否启用
|
// Is it enabled in the smart body?
|
||||||
LocalDisable bool `thrift:"local_disable,12" form:"local_disable" json:"local_disable" query:"local_disable"`
|
LocalDisable bool `thrift:"local_disable,12" form:"local_disable" json:"local_disable" query:"local_disable"`
|
||||||
// 可忽略
|
// negligible
|
||||||
DefaultParamSource *DefaultParamSource `thrift:"default_param_source,13,optional" form:"default_param_source" json:"default_param_source,omitempty" query:"default_param_source"`
|
DefaultParamSource *DefaultParamSource `thrift:"default_param_source,13,optional" form:"default_param_source" json:"default_param_source,omitempty" query:"default_param_source"`
|
||||||
// 引用variable的key
|
// Reference variable key
|
||||||
VariableRef *string `thrift:"variable_ref,14,optional" form:"variable_ref" json:"variable_ref,omitempty" query:"variable_ref"`
|
VariableRef *string `thrift:"variable_ref,14,optional" form:"variable_ref" json:"variable_ref,omitempty" query:"variable_ref"`
|
||||||
// 多模态辅助参数类型
|
// Multimodal auxiliary parameter types
|
||||||
AssistType *AssistParameterType `thrift:"assist_type,15,optional" form:"assist_type" json:"assist_type,omitempty" query:"assist_type"`
|
AssistType *AssistParameterType `thrift:"assist_type,15,optional" form:"assist_type" json:"assist_type,omitempty" query:"assist_type"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8849,7 +8849,7 @@ func (p *APIParameter) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PluginStatisticData struct {
|
type PluginStatisticData struct {
|
||||||
// 为空就不展示
|
// If it is empty, it will not be displayed.
|
||||||
BotQuote *int32 `thrift:"bot_quote,1,optional" form:"bot_quote" json:"bot_quote,omitempty" query:"bot_quote"`
|
BotQuote *int32 `thrift:"bot_quote,1,optional" form:"bot_quote" json:"bot_quote,omitempty" query:"bot_quote"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -9000,7 +9000,7 @@ func (p *PluginStatisticData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type APIExtend struct {
|
type APIExtend struct {
|
||||||
// tool维度授权类型
|
// Tool dimension authorization type
|
||||||
AuthMode PluginToolAuthType `thrift:"auth_mode,1" form:"auth_mode" json:"auth_mode" query:"auth_mode"`
|
AuthMode PluginToolAuthType `thrift:"auth_mode,1" form:"auth_mode" json:"auth_mode" query:"auth_mode"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -9139,12 +9139,12 @@ func (p *APIExtend) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 插件预置卡片绑定信息
|
// Plugin preset card binding information
|
||||||
type PresetCardBindingInfo struct {
|
type PresetCardBindingInfo struct {
|
||||||
CardID string `thrift:"card_id,1" form:"card_id" json:"card_id" query:"card_id"`
|
CardID string `thrift:"card_id,1" form:"card_id" json:"card_id" query:"card_id"`
|
||||||
CardVersionNum string `thrift:"card_version_num,2" form:"card_version_num" json:"card_version_num" query:"card_version_num"`
|
CardVersionNum string `thrift:"card_version_num,2" form:"card_version_num" json:"card_version_num" query:"card_version_num"`
|
||||||
Status PluginCardStatus `thrift:"status,3" form:"status" json:"status" query:"status"`
|
Status PluginCardStatus `thrift:"status,3" form:"status" json:"status" query:"status"`
|
||||||
// 缩略图
|
// thumbnail
|
||||||
Thumbnail string `thrift:"thumbnail,4" form:"thumbnail" json:"thumbnail" query:"thumbnail"`
|
Thumbnail string `thrift:"thumbnail,4" form:"thumbnail" json:"thumbnail" query:"thumbnail"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10150,11 +10150,11 @@ func (p *GetUserAuthorityData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type CheckAndLockPluginEditData struct {
|
type CheckAndLockPluginEditData struct {
|
||||||
// 是否已被占用
|
// Is it occupied?
|
||||||
Occupied bool `thrift:"Occupied,1" form:"Occupied" json:"Occupied" query:"Occupied"`
|
Occupied bool `thrift:"Occupied,1" form:"Occupied" json:"Occupied" query:"Occupied"`
|
||||||
// 如果已经被占用了,返回用户ID
|
// If it is already occupied, return the user ID.
|
||||||
User *Creator `thrift:"user,2" form:"user" json:"user" query:"user"`
|
User *Creator `thrift:"user,2" form:"user" json:"user" query:"user"`
|
||||||
// 是否强占成功
|
// Was it successful?
|
||||||
Seized bool `thrift:"Seized,3" form:"Seized" json:"Seized" query:"Seized"`
|
Seized bool `thrift:"Seized,3" form:"Seized" json:"Seized" query:"Seized"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -10388,13 +10388,13 @@ func (p *CheckAndLockPluginEditData) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PluginPublishInfo struct {
|
type PluginPublishInfo struct {
|
||||||
// 发布人
|
// publisher
|
||||||
PublisherID int64 `thrift:"publisher_id,1" form:"publisher_id" json:"publisher_id,string" query:"publisher_id"`
|
PublisherID int64 `thrift:"publisher_id,1" form:"publisher_id" json:"publisher_id,string" query:"publisher_id"`
|
||||||
// 版本,毫秒时间戳
|
// Version, millisecond timestamp
|
||||||
VersionTs int64 `thrift:"version_ts,2" form:"version_ts" json:"version_ts" query:"version_ts"`
|
VersionTs int64 `thrift:"version_ts,2" form:"version_ts" json:"version_ts" query:"version_ts"`
|
||||||
// 版本名称
|
// version name
|
||||||
VersionName string `thrift:"version_name,3" form:"version_name" json:"version_name" query:"version_name"`
|
VersionName string `thrift:"version_name,3" form:"version_name" json:"version_name" query:"version_name"`
|
||||||
// 版本描述
|
// version description
|
||||||
VersionDesc string `thrift:"version_desc,4" form:"version_desc" json:"version_desc" query:"version_desc"`
|
VersionDesc string `thrift:"version_desc,4" form:"version_desc" json:"version_desc" query:"version_desc"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,10 +3,10 @@
|
||||||
package project
|
package project
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/intelligence/common"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/intelligence/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type DraftProjectCreateRequest struct {
|
type DraftProjectCreateRequest struct {
|
||||||
|
|
@ -15,7 +15,7 @@ type DraftProjectCreateRequest struct {
|
||||||
Description string `thrift:"description,3" form:"description" json:"description" query:"description"`
|
Description string `thrift:"description,3" form:"description" json:"description" query:"description"`
|
||||||
IconURI string `thrift:"icon_uri,4" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
IconURI string `thrift:"icon_uri,4" form:"icon_uri" json:"icon_uri" query:"icon_uri"`
|
||||||
MonetizationConf *MonetizationConf `thrift:"monetization_conf,5,optional" form:"monetization_conf" json:"monetization_conf,omitempty" query:"monetization_conf"`
|
MonetizationConf *MonetizationConf `thrift:"monetization_conf,5,optional" form:"monetization_conf" json:"monetization_conf,omitempty" query:"monetization_conf"`
|
||||||
// 创建来源 navi:导航栏 space:空间
|
// Create source navi: navbar space: space
|
||||||
CreateFrom *string `thrift:"create_from,6,optional" form:"create_from" json:"create_from,omitempty" query:"create_from"`
|
CreateFrom *string `thrift:"create_from,6,optional" form:"create_from" json:"create_from,omitempty" query:"create_from"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,11 +3,11 @@
|
||||||
package project_memory
|
package project_memory
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
)
|
)
|
||||||
|
|
||||||
type VariableType int64
|
type VariableType int64
|
||||||
|
|
@ -59,7 +59,7 @@ const (
|
||||||
VariableChannel_System VariableChannel = 2
|
VariableChannel_System VariableChannel = 2
|
||||||
VariableChannel_Location VariableChannel = 3
|
VariableChannel_Location VariableChannel = 3
|
||||||
VariableChannel_Feishu VariableChannel = 4
|
VariableChannel_Feishu VariableChannel = 4
|
||||||
// 项目变量
|
// project variable
|
||||||
VariableChannel_APP VariableChannel = 5
|
VariableChannel_APP VariableChannel = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -159,9 +159,9 @@ type Variable struct {
|
||||||
Channel VariableChannel `thrift:"Channel,4" form:"Channel" json:"Channel" query:"Channel"`
|
Channel VariableChannel `thrift:"Channel,4" form:"Channel" json:"Channel" query:"Channel"`
|
||||||
Description string `thrift:"Description,5" form:"Description" json:"Description" query:"Description"`
|
Description string `thrift:"Description,5" form:"Description" json:"Description" query:"Description"`
|
||||||
Enable bool `thrift:"Enable,6" form:"Enable" json:"Enable" query:"Enable"`
|
Enable bool `thrift:"Enable,6" form:"Enable" json:"Enable" query:"Enable"`
|
||||||
//生效渠道
|
//effective channel
|
||||||
EffectiveChannelList []string `thrift:"EffectiveChannelList,7,optional" form:"EffectiveChannelList" json:"EffectiveChannelList,omitempty" query:"EffectiveChannelList"`
|
EffectiveChannelList []string `thrift:"EffectiveChannelList,7,optional" form:"EffectiveChannelList" json:"EffectiveChannelList,omitempty" query:"EffectiveChannelList"`
|
||||||
//新老数据都会有schema,除项目变量外其他默认为string
|
//New and old data will have schemas, except for project variables, the default is string.
|
||||||
Schema string `thrift:"Schema,8" form:"Schema" json:"Schema" query:"Schema"`
|
Schema string `thrift:"Schema,8" form:"Schema" json:"Schema" query:"Schema"`
|
||||||
IsReadOnly bool `thrift:"IsReadOnly,9" form:"IsReadOnly" json:"IsReadOnly" query:"IsReadOnly"`
|
IsReadOnly bool `thrift:"IsReadOnly,9" form:"IsReadOnly" json:"IsReadOnly" query:"IsReadOnly"`
|
||||||
}
|
}
|
||||||
|
|
@ -2711,7 +2711,7 @@ func (p *GetMemoryVariableMetaReq) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 应该是给workflow用的rpc接口,不需要鉴权,VariableChannel
|
// It should be the rpc interface for workflow, no authentication is required, VariableChannel
|
||||||
type GetMemoryVariableMetaResp struct {
|
type GetMemoryVariableMetaResp struct {
|
||||||
VariableMap map[VariableChannel][]*Variable `thrift:"VariableMap,1" form:"VariableMap" json:"VariableMap" query:"VariableMap"`
|
VariableMap map[VariableChannel][]*Variable `thrift:"VariableMap,1" form:"VariableMap" json:"VariableMap" query:"VariableMap"`
|
||||||
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
Code int64 `thrift:"code,253,required" form:"code,required" json:"code,required" query:"code,required"`
|
||||||
|
|
|
||||||
|
|
@ -3,26 +3,26 @@
|
||||||
package publish
|
package publish
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/intelligence/common"
|
|
||||||
"database/sql"
|
"database/sql"
|
||||||
"database/sql/driver"
|
"database/sql/driver"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/intelligence/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type ConnectorClassification int64
|
type ConnectorClassification int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// api或sdk
|
// API or SDK
|
||||||
ConnectorClassification_APIOrSDK ConnectorClassification = 1
|
ConnectorClassification_APIOrSDK ConnectorClassification = 1
|
||||||
// 社交平台
|
// social platform
|
||||||
ConnectorClassification_SocialPlatform ConnectorClassification = 2
|
ConnectorClassification_SocialPlatform ConnectorClassification = 2
|
||||||
// Coze商店/模板
|
// Coze Shop/Template
|
||||||
ConnectorClassification_Coze ConnectorClassification = 3
|
ConnectorClassification_Coze ConnectorClassification = 3
|
||||||
// 小程序
|
// Mini Program
|
||||||
ConnectorClassification_MiniProgram ConnectorClassification = 4
|
ConnectorClassification_MiniProgram ConnectorClassification = 4
|
||||||
// MCP扩展库
|
// MCP Extension Library
|
||||||
ConnectorClassification_CozeSpaceExtensionLibrary ConnectorClassification = 5
|
ConnectorClassification_CozeSpaceExtensionLibrary ConnectorClassification = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -76,15 +76,15 @@ func (p *ConnectorClassification) Value() (driver.Value, error) {
|
||||||
type ConnectorConfigStatus int64
|
type ConnectorConfigStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 已配置
|
// Configured
|
||||||
ConnectorConfigStatus_Configured ConnectorConfigStatus = 1
|
ConnectorConfigStatus_Configured ConnectorConfigStatus = 1
|
||||||
// 未配置
|
// Not configured
|
||||||
ConnectorConfigStatus_NotConfigured ConnectorConfigStatus = 2
|
ConnectorConfigStatus_NotConfigured ConnectorConfigStatus = 2
|
||||||
// Token发生变化
|
// Token changes
|
||||||
ConnectorConfigStatus_Disconnected ConnectorConfigStatus = 3
|
ConnectorConfigStatus_Disconnected ConnectorConfigStatus = 3
|
||||||
// 配置中,授权中
|
// Configuring, authorizing
|
||||||
ConnectorConfigStatus_Configuring ConnectorConfigStatus = 4
|
ConnectorConfigStatus_Configuring ConnectorConfigStatus = 4
|
||||||
// 需要重新配置
|
// Need to reconfigure
|
||||||
ConnectorConfigStatus_NeedReconfiguring ConnectorConfigStatus = 5
|
ConnectorConfigStatus_NeedReconfiguring ConnectorConfigStatus = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -138,11 +138,11 @@ func (p *ConnectorConfigStatus) Value() (driver.Value, error) {
|
||||||
type ConnectorStatus int64
|
type ConnectorStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 正常
|
// Normal
|
||||||
ConnectorStatus_Normal ConnectorStatus = 0
|
ConnectorStatus_Normal ConnectorStatus = 0
|
||||||
// 审核中
|
// Under review.
|
||||||
ConnectorStatus_InReview ConnectorStatus = 1
|
ConnectorStatus_InReview ConnectorStatus = 1
|
||||||
// 已下线
|
// offline
|
||||||
ConnectorStatus_Offline ConnectorStatus = 2
|
ConnectorStatus_Offline ConnectorStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -188,21 +188,21 @@ func (p *ConnectorStatus) Value() (driver.Value, error) {
|
||||||
type ConnectorBindType int64
|
type ConnectorBindType int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 无需绑定
|
// No binding required
|
||||||
ConnectorBindType_NoBindRequired ConnectorBindType = 1
|
ConnectorBindType_NoBindRequired ConnectorBindType = 1
|
||||||
// Auth绑定
|
// Auth binding
|
||||||
ConnectorBindType_AuthBind ConnectorBindType = 2
|
ConnectorBindType_AuthBind ConnectorBindType = 2
|
||||||
// Kv绑定
|
// Kv binding
|
||||||
ConnectorBindType_KvBind ConnectorBindType = 3
|
ConnectorBindType_KvBind ConnectorBindType = 3
|
||||||
// Kv并Auth授权
|
// Kv and Auth authorization
|
||||||
ConnectorBindType_KvAuthBind ConnectorBindType = 4
|
ConnectorBindType_KvAuthBind ConnectorBindType = 4
|
||||||
// api渠道绑定
|
// API channel binding
|
||||||
ConnectorBindType_ApiBind ConnectorBindType = 5
|
ConnectorBindType_ApiBind ConnectorBindType = 5
|
||||||
ConnectorBindType_WebSDKBind ConnectorBindType = 6
|
ConnectorBindType_WebSDKBind ConnectorBindType = 6
|
||||||
ConnectorBindType_StoreBind ConnectorBindType = 7
|
ConnectorBindType_StoreBind ConnectorBindType = 7
|
||||||
// 授权和配置各一个按钮
|
// One button each for authorization and configuration
|
||||||
ConnectorBindType_AuthAndConfig ConnectorBindType = 8
|
ConnectorBindType_AuthAndConfig ConnectorBindType = 8
|
||||||
// 模板渠道绑定
|
// template channel binding
|
||||||
ConnectorBindType_TemplateBind ConnectorBindType = 9
|
ConnectorBindType_TemplateBind ConnectorBindType = 9
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -272,11 +272,11 @@ func (p *ConnectorBindType) Value() (driver.Value, error) {
|
||||||
type UserAuthStatus int64
|
type UserAuthStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 已授权
|
// Authorized
|
||||||
UserAuthStatus_Authorized UserAuthStatus = 1
|
UserAuthStatus_Authorized UserAuthStatus = 1
|
||||||
// 未授权
|
// unauthorized
|
||||||
UserAuthStatus_UnAuthorized UserAuthStatus = 2
|
UserAuthStatus_UnAuthorized UserAuthStatus = 2
|
||||||
// 授权中
|
// Authorizing
|
||||||
UserAuthStatus_Authorizing UserAuthStatus = 3
|
UserAuthStatus_Authorizing UserAuthStatus = 3
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -322,17 +322,17 @@ func (p *UserAuthStatus) Value() (driver.Value, error) {
|
||||||
type PublishRecordStatus int64
|
type PublishRecordStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 打包中
|
// Packing
|
||||||
PublishRecordStatus_Packing PublishRecordStatus = 0
|
PublishRecordStatus_Packing PublishRecordStatus = 0
|
||||||
// 打包失败
|
// Packaging failed
|
||||||
PublishRecordStatus_PackFailed PublishRecordStatus = 1
|
PublishRecordStatus_PackFailed PublishRecordStatus = 1
|
||||||
// 审核中
|
// Under review.
|
||||||
PublishRecordStatus_Auditing PublishRecordStatus = 2
|
PublishRecordStatus_Auditing PublishRecordStatus = 2
|
||||||
// 审核未通过
|
// review disapproved
|
||||||
PublishRecordStatus_AuditNotPass PublishRecordStatus = 3
|
PublishRecordStatus_AuditNotPass PublishRecordStatus = 3
|
||||||
// 渠道发布中
|
// Channel is being released.
|
||||||
PublishRecordStatus_ConnectorPublishing PublishRecordStatus = 4
|
PublishRecordStatus_ConnectorPublishing PublishRecordStatus = 4
|
||||||
// 发布完成
|
// release complete
|
||||||
PublishRecordStatus_PublishDone PublishRecordStatus = 5
|
PublishRecordStatus_PublishDone PublishRecordStatus = 5
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -391,15 +391,15 @@ func (p *PublishRecordStatus) Value() (driver.Value, error) {
|
||||||
type ConnectorPublishStatus int64
|
type ConnectorPublishStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 发布中
|
// In release
|
||||||
ConnectorPublishStatus_Default ConnectorPublishStatus = 0
|
ConnectorPublishStatus_Default ConnectorPublishStatus = 0
|
||||||
// 审核中
|
// Under review.
|
||||||
ConnectorPublishStatus_Auditing ConnectorPublishStatus = 1
|
ConnectorPublishStatus_Auditing ConnectorPublishStatus = 1
|
||||||
// 成功
|
// success
|
||||||
ConnectorPublishStatus_Success ConnectorPublishStatus = 2
|
ConnectorPublishStatus_Success ConnectorPublishStatus = 2
|
||||||
// 失败
|
// fail
|
||||||
ConnectorPublishStatus_Failed ConnectorPublishStatus = 3
|
ConnectorPublishStatus_Failed ConnectorPublishStatus = 3
|
||||||
//禁用
|
//disable
|
||||||
ConnectorPublishStatus_Disable ConnectorPublishStatus = 4
|
ConnectorPublishStatus_Disable ConnectorPublishStatus = 4
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -1443,7 +1443,7 @@ func (p *PublishConnectorListResponse) String() string {
|
||||||
type PublishConnectorListData struct {
|
type PublishConnectorListData struct {
|
||||||
ConnectorList []*PublishConnectorInfo `thrift:"connector_list,1" form:"connector_list" json:"connector_list" query:"connector_list"`
|
ConnectorList []*PublishConnectorInfo `thrift:"connector_list,1" form:"connector_list" json:"connector_list" query:"connector_list"`
|
||||||
LastPublishInfo *LastPublishInfo `thrift:"last_publish_info,2" form:"last_publish_info" json:"last_publish_info" query:"last_publish_info"`
|
LastPublishInfo *LastPublishInfo `thrift:"last_publish_info,2" form:"last_publish_info" json:"last_publish_info" query:"last_publish_info"`
|
||||||
// 渠道集合信息,key是connector_union_id
|
// Channel collection information, the key is connector_union_id
|
||||||
ConnectorUnionInfoMap map[int64]*ConnectorUnionInfo `thrift:"connector_union_info_map,3" form:"connector_union_info_map" json:"connector_union_info_map" query:"connector_union_info_map"`
|
ConnectorUnionInfoMap map[int64]*ConnectorUnionInfo `thrift:"connector_union_info_map,3" form:"connector_union_info_map" json:"connector_union_info_map" query:"connector_union_info_map"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1729,47 +1729,47 @@ type PublishConnectorInfo struct {
|
||||||
ID int64 `thrift:"id,1,required" form:"id,required" json:"id,string,required" query:"id,required"`
|
ID int64 `thrift:"id,1,required" form:"id,required" json:"id,string,required" query:"id,required"`
|
||||||
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
Name string `thrift:"name,2,required" form:"name,required" json:"name,required" query:"name,required"`
|
||||||
IconURL string `thrift:"icon_url,3,required" form:"icon_url,required" json:"icon_url,required" query:"icon_url,required"`
|
IconURL string `thrift:"icon_url,3,required" form:"icon_url,required" json:"icon_url,required" query:"icon_url,required"`
|
||||||
// 描述
|
// describe
|
||||||
Description string `thrift:"description,4,required" form:"description,required" json:"description,required" query:"description,required"`
|
Description string `thrift:"description,4,required" form:"description,required" json:"description,required" query:"description,required"`
|
||||||
// 描述扩展
|
// description extension
|
||||||
DescriptionExtra string `thrift:"description_extra,5" form:"description_extra" json:"description_extra" query:"description_extra"`
|
DescriptionExtra string `thrift:"description_extra,5" form:"description_extra" json:"description_extra" query:"description_extra"`
|
||||||
// 渠道类型
|
// channel type
|
||||||
ConnectorClassification ConnectorClassification `thrift:"connector_classification,6,required" form:"connector_classification,required" json:"connector_classification,required" query:"connector_classification,required"`
|
ConnectorClassification ConnectorClassification `thrift:"connector_classification,6,required" form:"connector_classification,required" json:"connector_classification,required" query:"connector_classification,required"`
|
||||||
// 配置状态
|
// configuration status
|
||||||
ConfigStatus ConnectorConfigStatus `thrift:"config_status,7,required" form:"config_status,required" json:"config_status,required" query:"config_status,required"`
|
ConfigStatus ConnectorConfigStatus `thrift:"config_status,7,required" form:"config_status,required" json:"config_status,required" query:"config_status,required"`
|
||||||
// 渠道状态
|
// channel status
|
||||||
ConnectorStatus ConnectorStatus `thrift:"connector_status,8" form:"connector_status" json:"connector_status" query:"connector_status"`
|
ConnectorStatus ConnectorStatus `thrift:"connector_status,8" form:"connector_status" json:"connector_status" query:"connector_status"`
|
||||||
// 绑定类型
|
// binding type
|
||||||
BindType ConnectorBindType `thrift:"bind_type,9,required" form:"bind_type,required" json:"bind_type,required" query:"bind_type,required"`
|
BindType ConnectorBindType `thrift:"bind_type,9,required" form:"bind_type,required" json:"bind_type,required" query:"bind_type,required"`
|
||||||
// 绑定信息 key字段名 value是值
|
// Binding information key field name value is value
|
||||||
BindInfo map[string]string `thrift:"bind_info,10,required" form:"bind_info,required" json:"bind_info,required" query:"bind_info,required"`
|
BindInfo map[string]string `thrift:"bind_info,10,required" form:"bind_info,required" json:"bind_info,required" query:"bind_info,required"`
|
||||||
// 绑定id信息,用于解绑使用
|
// Bind id information for unbinding and use
|
||||||
BindID *string `thrift:"bind_id,11,optional" form:"bind_id" json:"bind_id,omitempty" query:"bind_id"`
|
BindID *string `thrift:"bind_id,11,optional" form:"bind_id" json:"bind_id,omitempty" query:"bind_id"`
|
||||||
// 用户授权登陆信息
|
// user authorization login information
|
||||||
AuthLoginInfo *AuthLoginInfo `thrift:"auth_login_info,12,optional" form:"auth_login_info" json:"auth_login_info,omitempty" query:"auth_login_info"`
|
AuthLoginInfo *AuthLoginInfo `thrift:"auth_login_info,12,optional" form:"auth_login_info" json:"auth_login_info,omitempty" query:"auth_login_info"`
|
||||||
// 隐私政策
|
// Privacy Policy
|
||||||
PrivacyPolicy string `thrift:"privacy_policy,13" form:"privacy_policy" json:"privacy_policy" query:"privacy_policy"`
|
PrivacyPolicy string `thrift:"privacy_policy,13" form:"privacy_policy" json:"privacy_policy" query:"privacy_policy"`
|
||||||
// 用户协议
|
// User Agreement
|
||||||
UserAgreement string `thrift:"user_agreement,14" form:"user_agreement" json:"user_agreement" query:"user_agreement"`
|
UserAgreement string `thrift:"user_agreement,14" form:"user_agreement" json:"user_agreement" query:"user_agreement"`
|
||||||
// 是否允许发布
|
// Whether to allow publishing
|
||||||
AllowPublish bool `thrift:"allow_publish,15" form:"allow_publish" json:"allow_publish" query:"allow_publish"`
|
AllowPublish bool `thrift:"allow_publish,15" form:"allow_publish" json:"allow_publish" query:"allow_publish"`
|
||||||
// 不允许发布的原因
|
// Reasons for not allowing publishing
|
||||||
NotAllowPublishReason *string `thrift:"not_allow_publish_reason,16,optional" form:"not_allow_publish_reason" json:"not_allow_publish_reason,omitempty" query:"not_allow_publish_reason"`
|
NotAllowPublishReason *string `thrift:"not_allow_publish_reason,16,optional" form:"not_allow_publish_reason" json:"not_allow_publish_reason,omitempty" query:"not_allow_publish_reason"`
|
||||||
// 渠道集合id,表示需要聚合展示的渠道
|
// Channel collection id, indicating the channel that needs to be aggregated and displayed.
|
||||||
ConnectorUnionID *int64 `thrift:"connector_union_id,17,optional" form:"connector_union_id" json:"connector_union_id,string,omitempty" query:"connector_union_id"`
|
ConnectorUnionID *int64 `thrift:"connector_union_id,17,optional" form:"connector_union_id" json:"connector_union_id,string,omitempty" query:"connector_union_id"`
|
||||||
// UI选项
|
// UI Options
|
||||||
UIOptions []*UIOption `thrift:"UIOptions,18,optional" form:"UIOptions" json:"UIOptions,omitempty" query:"UIOptions"`
|
UIOptions []*UIOption `thrift:"UIOptions,18,optional" form:"UIOptions" json:"UIOptions,omitempty" query:"UIOptions"`
|
||||||
// 支持商业化
|
// Support commercialization
|
||||||
SupportMonetization *bool `thrift:"support_monetization,19,optional" form:"support_monetization" json:"support_monetization,omitempty" query:"support_monetization"`
|
SupportMonetization *bool `thrift:"support_monetization,19,optional" form:"support_monetization" json:"support_monetization,omitempty" query:"support_monetization"`
|
||||||
// 安装指引
|
// Installation Guidelines
|
||||||
InstallationGuide *string `thrift:"installation_guide,20,optional" form:"installation_guide" json:"installation_guide,omitempty" query:"installation_guide"`
|
InstallationGuide *string `thrift:"installation_guide,20,optional" form:"installation_guide" json:"installation_guide,omitempty" query:"installation_guide"`
|
||||||
// 目前仅 bind_type == 8 时这个字段才有
|
// Currently this field is only available bind_type == 8
|
||||||
AuthStatus *UserAuthStatus `thrift:"auth_status,21,optional" form:"auth_status" json:"auth_status,omitempty" query:"auth_status"`
|
AuthStatus *UserAuthStatus `thrift:"auth_status,21,optional" form:"auth_status" json:"auth_status,omitempty" query:"auth_status"`
|
||||||
// 配置状态toast
|
// Configuration status toast
|
||||||
ConfigStatusToast *string `thrift:"config_status_toast,22,optional" form:"config_status_toast" json:"config_status_toast,omitempty" query:"config_status_toast"`
|
ConfigStatusToast *string `thrift:"config_status_toast,22,optional" form:"config_status_toast" json:"config_status_toast,omitempty" query:"config_status_toast"`
|
||||||
// connector_status为审核中时补全信息按钮的url
|
// connector_status the URL of the Complete Info button while under review
|
||||||
ToCompleteInfoURL *string `thrift:"to_complete_info_url,23,optional" form:"to_complete_info_url" json:"to_complete_info_url,omitempty" query:"to_complete_info_url"`
|
ToCompleteInfoURL *string `thrift:"to_complete_info_url,23,optional" form:"to_complete_info_url" json:"to_complete_info_url,omitempty" query:"to_complete_info_url"`
|
||||||
// 渠道发布提示
|
// Channel release tips
|
||||||
ConnectorTips *string `thrift:"connector_tips,24,optional" form:"connector_tips" json:"connector_tips,omitempty" query:"connector_tips"`
|
ConnectorTips *string `thrift:"connector_tips,24,optional" form:"connector_tips" json:"connector_tips,omitempty" query:"connector_tips"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3148,7 +3148,7 @@ func (p *PublishConnectorInfo) String() string {
|
||||||
type LastPublishInfo struct {
|
type LastPublishInfo struct {
|
||||||
VersionNumber string `thrift:"version_number,1" form:"version_number" json:"version_number" query:"version_number"`
|
VersionNumber string `thrift:"version_number,1" form:"version_number" json:"version_number" query:"version_number"`
|
||||||
ConnectorIds []int64 `thrift:"connector_ids,2" form:"connector_ids" json:"connector_ids,string" query:"connector_ids"`
|
ConnectorIds []int64 `thrift:"connector_ids,2" form:"connector_ids" json:"connector_ids,string" query:"connector_ids"`
|
||||||
// 渠道发布配置
|
// channel release configuration
|
||||||
ConnectorPublishConfig map[int64]*ConnectorPublishConfig `thrift:"connector_publish_config,3" form:"connector_publish_config" json:"connector_publish_config" query:"connector_publish_config"`
|
ConnectorPublishConfig map[int64]*ConnectorPublishConfig `thrift:"connector_publish_config,3" form:"connector_publish_config" json:"connector_publish_config" query:"connector_publish_config"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4254,11 +4254,11 @@ func (p *AuthLoginInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type UIOption struct {
|
type UIOption struct {
|
||||||
// UIChannel选项
|
// UIChannel Options
|
||||||
UIChannel int64 `thrift:"ui_channel,1" form:"ui_channel" json:"ui_channel,string" query:"ui_channel"`
|
UIChannel int64 `thrift:"ui_channel,1" form:"ui_channel" json:"ui_channel,string" query:"ui_channel"`
|
||||||
// 是否可选
|
// Is it optional
|
||||||
Available bool `thrift:"available,2" form:"available" json:"available" query:"available"`
|
Available bool `thrift:"available,2" form:"available" json:"available" query:"available"`
|
||||||
// 不可选原因
|
// unselectable reason
|
||||||
UnavailableReason string `thrift:"unavailable_reason,3" form:"unavailable_reason" json:"unavailable_reason" query:"unavailable_reason"`
|
UnavailableReason string `thrift:"unavailable_reason,3" form:"unavailable_reason" json:"unavailable_reason" query:"unavailable_reason"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4486,7 +4486,7 @@ func (p *UIOption) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ConnectorPublishConfig struct {
|
type ConnectorPublishConfig struct {
|
||||||
// 发布渠道选择的Workflow/ChatFlow
|
// Workflow/ChatFlow selected by publishing channel
|
||||||
SelectedWorkflows []*SelectedWorkflow `thrift:"selected_workflows,1" form:"selected_workflows" json:"selected_workflows" query:"selected_workflows"`
|
SelectedWorkflows []*SelectedWorkflow `thrift:"selected_workflows,1" form:"selected_workflows" json:"selected_workflows" query:"selected_workflows"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -4646,9 +4646,9 @@ func (p *ConnectorPublishConfig) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ConnectorUnionInfoOption struct {
|
type ConnectorUnionInfoOption struct {
|
||||||
// 渠道 ID
|
// Channel ID
|
||||||
ConnectorID int64 `thrift:"connector_id,1,required" form:"connector_id,required" json:"connector_id,string,required" query:"connector_id,required"`
|
ConnectorID int64 `thrift:"connector_id,1,required" form:"connector_id,required" json:"connector_id,string,required" query:"connector_id,required"`
|
||||||
// 展示名,如:托管发布、下载代码
|
// Display name, such as: hosted release, download code
|
||||||
ShowName string `thrift:"show_name,2,required" form:"show_name,required" json:"show_name,required" query:"show_name,required"`
|
ShowName string `thrift:"show_name,2,required" form:"show_name,required" json:"show_name,required" query:"show_name,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -5711,13 +5711,13 @@ func (p *CheckProjectVersionNumberData) String() string {
|
||||||
|
|
||||||
type PublishProjectRequest struct {
|
type PublishProjectRequest struct {
|
||||||
ProjectID int64 `thrift:"project_id,1,required" form:"project_id,required" json:"project_id,string,required" query:"project_id,required"`
|
ProjectID int64 `thrift:"project_id,1,required" form:"project_id,required" json:"project_id,string,required" query:"project_id,required"`
|
||||||
// 版本号
|
// version number
|
||||||
VersionNumber string `thrift:"version_number,2,required" form:"version_number,required" json:"version_number,required" query:"version_number,required"`
|
VersionNumber string `thrift:"version_number,2,required" form:"version_number,required" json:"version_number,required" query:"version_number,required"`
|
||||||
// 描述
|
// describe
|
||||||
Description *string `thrift:"description,3,optional" form:"description" json:"description,omitempty" query:"description"`
|
Description *string `thrift:"description,3,optional" form:"description" json:"description,omitempty" query:"description"`
|
||||||
// key代表connector_id,value是渠道发布的参数
|
// The key represents connector_id, and the value is the parameter published by the channel
|
||||||
Connectors map[int64]map[string]string `thrift:"connectors,4,optional" form:"connectors" json:"connectors,omitempty" query:"connectors"`
|
Connectors map[int64]map[string]string `thrift:"connectors,4,optional" form:"connectors" json:"connectors,omitempty" query:"connectors"`
|
||||||
// 渠道发布配置,key代表connector_id
|
// Channel release configuration, key represents connector_id
|
||||||
ConnectorPublishConfig map[int64]*ConnectorPublishConfig `thrift:"connector_publish_config,5,optional" form:"connector_publish_config" json:"connector_publish_config,omitempty" query:"connector_publish_config"`
|
ConnectorPublishConfig map[int64]*ConnectorPublishConfig `thrift:"connector_publish_config,5,optional" form:"connector_publish_config" json:"connector_publish_config,omitempty" query:"connector_publish_config"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
@ -6509,9 +6509,9 @@ func (p *PublishProjectResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishProjectData struct {
|
type PublishProjectData struct {
|
||||||
// 发布记录ID用于前端轮询
|
// Publish record ID for front-end polling
|
||||||
PublishRecordID int64 `thrift:"publish_record_id,1" form:"publish_record_id" json:"publish_record_id,string" query:"publish_record_id"`
|
PublishRecordID int64 `thrift:"publish_record_id,1" form:"publish_record_id" json:"publish_record_id,string" query:"publish_record_id"`
|
||||||
// 收费配置发布结果,海外环境才有
|
// The charging configuration is released, and the overseas environment is only available.
|
||||||
PublishMonetizationResult *bool `thrift:"publish_monetization_result,2,optional" form:"publish_monetization_result" json:"publish_monetization_result,omitempty" query:"publish_monetization_result"`
|
PublishMonetizationResult *bool `thrift:"publish_monetization_result,2,optional" form:"publish_monetization_result" json:"publish_monetization_result,omitempty" query:"publish_monetization_result"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7210,13 +7210,13 @@ func (p *GetPublishRecordListResponse) String() string {
|
||||||
type PublishRecordDetail struct {
|
type PublishRecordDetail struct {
|
||||||
PublishRecordID int64 `thrift:"publish_record_id,1" form:"publish_record_id" json:"publish_record_id,string" query:"publish_record_id"`
|
PublishRecordID int64 `thrift:"publish_record_id,1" form:"publish_record_id" json:"publish_record_id,string" query:"publish_record_id"`
|
||||||
VersionNumber string `thrift:"version_number,2" form:"version_number" json:"version_number" query:"version_number"`
|
VersionNumber string `thrift:"version_number,2" form:"version_number" json:"version_number" query:"version_number"`
|
||||||
// 发布状态
|
// release status
|
||||||
PublishStatus PublishRecordStatus `thrift:"publish_status,3" form:"publish_status" json:"publish_status" query:"publish_status"`
|
PublishStatus PublishRecordStatus `thrift:"publish_status,3" form:"publish_status" json:"publish_status" query:"publish_status"`
|
||||||
// 该字段废弃,请使用publish_status_detail
|
// This field is deprecated, please use publish_status_detail
|
||||||
PublishStatusMsg string `thrift:"publish_status_msg,4" form:"publish_status_msg" json:"publish_status_msg" query:"publish_status_msg"`
|
PublishStatusMsg string `thrift:"publish_status_msg,4" form:"publish_status_msg" json:"publish_status_msg" query:"publish_status_msg"`
|
||||||
// 渠道发布结果
|
// Channel release results
|
||||||
ConnectorPublishResult []*ConnectorPublishResult `thrift:"connector_publish_result,5,optional" form:"connector_publish_result" json:"connector_publish_result,omitempty" query:"connector_publish_result"`
|
ConnectorPublishResult []*ConnectorPublishResult `thrift:"connector_publish_result,5,optional" form:"connector_publish_result" json:"connector_publish_result,omitempty" query:"connector_publish_result"`
|
||||||
// 发布状态补充信息
|
// Release status Supplementary information
|
||||||
PublishStatusDetail *PublishRecordStatusDetail `thrift:"publish_status_detail,6,optional" form:"publish_status_detail" json:"publish_status_detail,omitempty" query:"publish_status_detail"`
|
PublishStatusDetail *PublishRecordStatusDetail `thrift:"publish_status_detail,6,optional" form:"publish_status_detail" json:"publish_status_detail,omitempty" query:"publish_status_detail"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -7618,17 +7618,17 @@ type ConnectorPublishResult struct {
|
||||||
ConnectorID int64 `thrift:"connector_id,1" form:"connector_id" json:"connector_id,string" query:"connector_id"`
|
ConnectorID int64 `thrift:"connector_id,1" form:"connector_id" json:"connector_id,string" query:"connector_id"`
|
||||||
ConnectorName string `thrift:"connector_name,2" form:"connector_name" json:"connector_name" query:"connector_name"`
|
ConnectorName string `thrift:"connector_name,2" form:"connector_name" json:"connector_name" query:"connector_name"`
|
||||||
ConnectorIconURL string `thrift:"connector_icon_url,3" form:"connector_icon_url" json:"connector_icon_url" query:"connector_icon_url"`
|
ConnectorIconURL string `thrift:"connector_icon_url,3" form:"connector_icon_url" json:"connector_icon_url" query:"connector_icon_url"`
|
||||||
// 渠道发布状态
|
// channel release status
|
||||||
ConnectorPublishStatus ConnectorPublishStatus `thrift:"connector_publish_status,4" form:"connector_publish_status" json:"connector_publish_status" query:"connector_publish_status"`
|
ConnectorPublishStatus ConnectorPublishStatus `thrift:"connector_publish_status,4" form:"connector_publish_status" json:"connector_publish_status" query:"connector_publish_status"`
|
||||||
// 渠道发布状态补充信息
|
// Channel Release Status Supplementary Information
|
||||||
ConnectorPublishStatusMsg string `thrift:"connector_publish_status_msg,5" form:"connector_publish_status_msg" json:"connector_publish_status_msg" query:"connector_publish_status_msg"`
|
ConnectorPublishStatusMsg string `thrift:"connector_publish_status_msg,5" form:"connector_publish_status_msg" json:"connector_publish_status_msg" query:"connector_publish_status_msg"`
|
||||||
// OpenIn链接
|
// OpenIn Link
|
||||||
ShareLink *string `thrift:"share_link,6,optional" form:"share_link" json:"share_link,omitempty" query:"share_link"`
|
ShareLink *string `thrift:"share_link,6,optional" form:"share_link" json:"share_link,omitempty" query:"share_link"`
|
||||||
// 小程序渠道下载链接
|
// Mini Program Channel Download Link
|
||||||
DownloadLink *string `thrift:"download_link,7,optional" form:"download_link" json:"download_link,omitempty" query:"download_link"`
|
DownloadLink *string `thrift:"download_link,7,optional" form:"download_link" json:"download_link,omitempty" query:"download_link"`
|
||||||
// 渠道发布配置
|
// channel release configuration
|
||||||
ConnectorPublishConfig *ConnectorPublishConfig `thrift:"connector_publish_config,8,optional" form:"connector_publish_config" json:"connector_publish_config,omitempty" query:"connector_publish_config"`
|
ConnectorPublishConfig *ConnectorPublishConfig `thrift:"connector_publish_config,8,optional" form:"connector_publish_config" json:"connector_publish_config,omitempty" query:"connector_publish_config"`
|
||||||
// 渠道绑定信息 key字段名 value是值
|
// Channel binding information key field name value is value
|
||||||
ConnectorBindInfo map[string]string `thrift:"connector_bind_info,9,optional" form:"connector_bind_info" json:"connector_bind_info,omitempty" query:"connector_bind_info"`
|
ConnectorBindInfo map[string]string `thrift:"connector_bind_info,9,optional" form:"connector_bind_info" json:"connector_bind_info,omitempty" query:"connector_bind_info"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8190,7 +8190,7 @@ func (p *ConnectorPublishResult) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type PublishRecordStatusDetail struct {
|
type PublishRecordStatusDetail struct {
|
||||||
// 打包失败详情
|
// Packaging failure details
|
||||||
PackFailedDetail []*PackFailedDetail `thrift:"pack_failed_detail,1,optional" form:"pack_failed_detail" json:"pack_failed_detail,omitempty" query:"pack_failed_detail"`
|
PackFailedDetail []*PackFailedDetail `thrift:"pack_failed_detail,1,optional" form:"pack_failed_detail" json:"pack_failed_detail,omitempty" query:"pack_failed_detail"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -8591,7 +8591,7 @@ func (p *PackFailedDetail) String() string {
|
||||||
|
|
||||||
type GetPublishRecordDetailRequest struct {
|
type GetPublishRecordDetailRequest struct {
|
||||||
ProjectID int64 `thrift:"project_id,1,required" form:"project_id,required" json:"project_id,string,required" query:"project_id,required"`
|
ProjectID int64 `thrift:"project_id,1,required" form:"project_id,required" json:"project_id,string,required" query:"project_id,required"`
|
||||||
// 不传则获取最近一次发布记录
|
// If you don't upload it, get the last release record.
|
||||||
PublishRecordID *int64 `thrift:"publish_record_id,2,optional" form:"publish_record_id" json:"publish_record_id,string,omitempty" query:"publish_record_id"`
|
PublishRecordID *int64 `thrift:"publish_record_id,2,optional" form:"publish_record_id" json:"publish_record_id,string,omitempty" query:"publish_record_id"`
|
||||||
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
Base *base.Base `thrift:"Base,255,optional" form:"-" json:"-" query:"-"`
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -89,9 +89,9 @@ func (p *ResType) Value() (driver.Value, error) {
|
||||||
type PublishStatus int64
|
type PublishStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 未发布
|
// unpublished
|
||||||
PublishStatus_UnPublished PublishStatus = 1
|
PublishStatus_UnPublished PublishStatus = 1
|
||||||
// 已发布
|
// Published
|
||||||
PublishStatus_Published PublishStatus = 2
|
PublishStatus_Published PublishStatus = 2
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -133,19 +133,19 @@ func (p *PublishStatus) Value() (driver.Value, error) {
|
||||||
type ActionKey int64
|
type ActionKey int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
// 复制
|
// copy
|
||||||
ActionKey_Copy ActionKey = 1
|
ActionKey_Copy ActionKey = 1
|
||||||
// 删除
|
// delete
|
||||||
ActionKey_Delete ActionKey = 2
|
ActionKey_Delete ActionKey = 2
|
||||||
// 启用/禁用
|
// enable/disable
|
||||||
ActionKey_EnableSwitch ActionKey = 3
|
ActionKey_EnableSwitch ActionKey = 3
|
||||||
// 编辑
|
// edit
|
||||||
ActionKey_Edit ActionKey = 4
|
ActionKey_Edit ActionKey = 4
|
||||||
// 切换成funcflow
|
// Switch to funcflow
|
||||||
ActionKey_SwitchToFuncflow ActionKey = 8
|
ActionKey_SwitchToFuncflow ActionKey = 8
|
||||||
// 切换成chatflow
|
// Switch to chatflow
|
||||||
ActionKey_SwitchToChatflow ActionKey = 9
|
ActionKey_SwitchToChatflow ActionKey = 9
|
||||||
// 跨空间复制
|
// Cross-space copy
|
||||||
ActionKey_CrossSpaceCopy ActionKey = 10
|
ActionKey_CrossSpaceCopy ActionKey = 10
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -207,25 +207,25 @@ func (p *ActionKey) Value() (driver.Value, error) {
|
||||||
type ProjectResourceActionKey int64
|
type ProjectResourceActionKey int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
//重命名
|
//rename
|
||||||
ProjectResourceActionKey_Rename ProjectResourceActionKey = 1
|
ProjectResourceActionKey_Rename ProjectResourceActionKey = 1
|
||||||
//创建副本/复制到当前项目
|
//Create a copy/copy to the current project
|
||||||
ProjectResourceActionKey_Copy ProjectResourceActionKey = 2
|
ProjectResourceActionKey_Copy ProjectResourceActionKey = 2
|
||||||
//复制到资源库
|
//Copy to Library
|
||||||
ProjectResourceActionKey_CopyToLibrary ProjectResourceActionKey = 3
|
ProjectResourceActionKey_CopyToLibrary ProjectResourceActionKey = 3
|
||||||
//移动到资源库
|
//Move to Library
|
||||||
ProjectResourceActionKey_MoveToLibrary ProjectResourceActionKey = 4
|
ProjectResourceActionKey_MoveToLibrary ProjectResourceActionKey = 4
|
||||||
//删除
|
//delete
|
||||||
ProjectResourceActionKey_Delete ProjectResourceActionKey = 5
|
ProjectResourceActionKey_Delete ProjectResourceActionKey = 5
|
||||||
//启用
|
//enable
|
||||||
ProjectResourceActionKey_Enable ProjectResourceActionKey = 6
|
ProjectResourceActionKey_Enable ProjectResourceActionKey = 6
|
||||||
//禁用
|
//disable
|
||||||
ProjectResourceActionKey_Disable ProjectResourceActionKey = 7
|
ProjectResourceActionKey_Disable ProjectResourceActionKey = 7
|
||||||
// 切换成funcflow
|
// Switch to funcflow
|
||||||
ProjectResourceActionKey_SwitchToFuncflow ProjectResourceActionKey = 8
|
ProjectResourceActionKey_SwitchToFuncflow ProjectResourceActionKey = 8
|
||||||
// 切换成chatflow
|
// Switch to chatflow
|
||||||
ProjectResourceActionKey_SwitchToChatflow ProjectResourceActionKey = 9
|
ProjectResourceActionKey_SwitchToChatflow ProjectResourceActionKey = 9
|
||||||
// 修改描述
|
// Modify description
|
||||||
ProjectResourceActionKey_UpdateDesc ProjectResourceActionKey = 10
|
ProjectResourceActionKey_UpdateDesc ProjectResourceActionKey = 10
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -346,31 +346,31 @@ func (p *ProjectResourceGroupType) Value() (driver.Value, error) {
|
||||||
type ResourceCopyScene int64
|
type ResourceCopyScene int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
//复制项目内的资源,浅拷贝
|
//Copy resources within the project, shallow copy
|
||||||
ResourceCopyScene_CopyProjectResource ResourceCopyScene = 1
|
ResourceCopyScene_CopyProjectResource ResourceCopyScene = 1
|
||||||
//复制项目资源到Library,复制后要发布
|
//Copy the project resources to the Library, and publish after copying
|
||||||
ResourceCopyScene_CopyResourceToLibrary ResourceCopyScene = 2
|
ResourceCopyScene_CopyResourceToLibrary ResourceCopyScene = 2
|
||||||
//移动项目资源到Library,复制后要发布,后置要删除项目资源
|
//Move project resources to Library, copy to publish, and delete project resources later
|
||||||
ResourceCopyScene_MoveResourceToLibrary ResourceCopyScene = 3
|
ResourceCopyScene_MoveResourceToLibrary ResourceCopyScene = 3
|
||||||
//复制Library资源到项目
|
//Copy Library Resources to Project
|
||||||
ResourceCopyScene_CopyResourceFromLibrary ResourceCopyScene = 4
|
ResourceCopyScene_CopyResourceFromLibrary ResourceCopyScene = 4
|
||||||
//复制项目,连带资源要复制。复制当前草稿。
|
//Copy the project, along with the resources. Copy the current draft.
|
||||||
ResourceCopyScene_CopyProject ResourceCopyScene = 5
|
ResourceCopyScene_CopyProject ResourceCopyScene = 5
|
||||||
//项目发布到渠道,连带资源需要发布(含商店)。以当前草稿发布。
|
//The project is published to the channel, and the associated resources need to be published (including the store). Publish with the current draft.
|
||||||
ResourceCopyScene_PublishProject ResourceCopyScene = 6
|
ResourceCopyScene_PublishProject ResourceCopyScene = 6
|
||||||
// 复制项目模板。
|
// Copy the project template.
|
||||||
ResourceCopyScene_CopyProjectTemplate ResourceCopyScene = 7
|
ResourceCopyScene_CopyProjectTemplate ResourceCopyScene = 7
|
||||||
// 项目发布到模板,以项目的指定版本发布成临时模板。
|
// The project is published to a template, and the specified version of the project is published as a temporary template.
|
||||||
ResourceCopyScene_PublishProjectTemplate ResourceCopyScene = 8
|
ResourceCopyScene_PublishProjectTemplate ResourceCopyScene = 8
|
||||||
// 模板审核通过,上架,根据临时模板复制正式模板。
|
// The template is approved, put on the shelves, and the official template is copied according to the temporary template.
|
||||||
ResourceCopyScene_LaunchTemplate ResourceCopyScene = 9
|
ResourceCopyScene_LaunchTemplate ResourceCopyScene = 9
|
||||||
// 草稿版本存档
|
// Draft version archive
|
||||||
ResourceCopyScene_ArchiveProject ResourceCopyScene = 10
|
ResourceCopyScene_ArchiveProject ResourceCopyScene = 10
|
||||||
// 线上版本加载到草稿,草稿版本加载到草稿
|
// Online version loaded into draft, draft version loaded into draft
|
||||||
ResourceCopyScene_RollbackProject ResourceCopyScene = 11
|
ResourceCopyScene_RollbackProject ResourceCopyScene = 11
|
||||||
// 单个资源跨空间复制
|
// Cross-space copy of a single resource
|
||||||
ResourceCopyScene_CrossSpaceCopy ResourceCopyScene = 12
|
ResourceCopyScene_CrossSpaceCopy ResourceCopyScene = 12
|
||||||
// 项目跨空间复制
|
// item cross-space copy
|
||||||
ResourceCopyScene_CrossSpaceCopyProject ResourceCopyScene = 13
|
ResourceCopyScene_CrossSpaceCopyProject ResourceCopyScene = 13
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
@ -505,11 +505,11 @@ func (p *TaskStatus) Value() (driver.Value, error) {
|
||||||
return int64(*p), nil
|
return int64(*p), nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// Library资源操作
|
// Library Resource Operations
|
||||||
type ResourceAction struct {
|
type ResourceAction struct {
|
||||||
// 一个操作对应一个唯一的key,key由资源侧约束
|
// An operation corresponds to a unique key, and the key is constrained by the resource side
|
||||||
Key ActionKey `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
Key ActionKey `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
||||||
//ture=可以操作该Action,false=置灰
|
//ture = can operate this Action, false = grey out
|
||||||
Enable bool `thrift:"Enable,2,required" json:"enable" form:"Enable,required" query:"Enable,required"`
|
Enable bool `thrift:"Enable,2,required" json:"enable" form:"Enable,required" query:"Enable,required"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -707,46 +707,46 @@ func (p *ResourceAction) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 前端用
|
// front end
|
||||||
type ResourceInfo struct {
|
type ResourceInfo struct {
|
||||||
// 资源id
|
// Resource ID
|
||||||
ResID *int64 `thrift:"ResID,1,optional" form:"res_id" json:"res_id,string,omitempty"`
|
ResID *int64 `thrift:"ResID,1,optional" form:"res_id" json:"res_id,string,omitempty"`
|
||||||
// 资源类型
|
// resource type
|
||||||
ResType *ResType `thrift:"ResType,2,optional" json:"res_type" form:"ResType" query:"ResType"`
|
ResType *ResType `thrift:"ResType,2,optional" json:"res_type" form:"ResType" query:"ResType"`
|
||||||
// 资源子类型,由资源实现方定义。
|
// Resource subtype, defined by the resource implementer.
|
||||||
// Plugin:1-Http; 2-App; 6-Local;Knowledge:0-text; 1-table; 2-image;UI:1-Card
|
// Plugin:1-Http; 2-App; 6-Local;Knowledge:0-text; 1-table; 2-image;UI:1-Card
|
||||||
ResSubType *int32 `thrift:"ResSubType,3,optional" json:"res_sub_type" form:"ResSubType" query:"ResSubType"`
|
ResSubType *int32 `thrift:"ResSubType,3,optional" json:"res_sub_type" form:"ResSubType" query:"ResSubType"`
|
||||||
// 资源名称
|
// resource name
|
||||||
Name *string `thrift:"Name,4,optional" json:"name" form:"Name" query:"Name"`
|
Name *string `thrift:"Name,4,optional" json:"name" form:"Name" query:"Name"`
|
||||||
// 资源描述
|
// resource description
|
||||||
Desc *string `thrift:"Desc,5,optional" json:"desc" form:"Desc" query:"Desc"`
|
Desc *string `thrift:"Desc,5,optional" json:"desc" form:"Desc" query:"Desc"`
|
||||||
// 资源Icon,完整url
|
// Resource Icon, full url
|
||||||
Icon *string `thrift:"Icon,6,optional" json:"icon" form:"Icon" query:"Icon"`
|
Icon *string `thrift:"Icon,6,optional" json:"icon" form:"Icon" query:"Icon"`
|
||||||
// 资源创建者
|
// Resource creator
|
||||||
CreatorID *int64 `thrift:"CreatorID,7,optional" form:"creator_id" json:"creator_id,string,omitempty"`
|
CreatorID *int64 `thrift:"CreatorID,7,optional" form:"creator_id" json:"creator_id,string,omitempty"`
|
||||||
// 资源创建者
|
// Resource creator
|
||||||
CreatorAvatar *string `thrift:"CreatorAvatar,8,optional" json:"creator_avatar" form:"CreatorAvatar" query:"CreatorAvatar"`
|
CreatorAvatar *string `thrift:"CreatorAvatar,8,optional" json:"creator_avatar" form:"CreatorAvatar" query:"CreatorAvatar"`
|
||||||
// 资源创建者
|
// Resource creator
|
||||||
CreatorName *string `thrift:"CreatorName,9,optional" json:"creator_name" form:"CreatorName" query:"CreatorName"`
|
CreatorName *string `thrift:"CreatorName,9,optional" json:"creator_name" form:"CreatorName" query:"CreatorName"`
|
||||||
// 资源创建者
|
// Resource creator
|
||||||
UserName *string `thrift:"UserName,10,optional" json:"user_name" form:"UserName" query:"UserName"`
|
UserName *string `thrift:"UserName,10,optional" json:"user_name" form:"UserName" query:"UserName"`
|
||||||
// 资源发布状态,1-未发布,2-已发布
|
// Resource release status, 1 - unpublished, 2 - published
|
||||||
PublishStatus *PublishStatus `thrift:"PublishStatus,11,optional" json:"publish_status" form:"PublishStatus" query:"PublishStatus"`
|
PublishStatus *PublishStatus `thrift:"PublishStatus,11,optional" json:"publish_status" form:"PublishStatus" query:"PublishStatus"`
|
||||||
// 资源状态,各类型资源自身定义
|
// Resource status, each type of resource defines itself
|
||||||
BizResStatus *int32 `thrift:"BizResStatus,12,optional" json:"biz_res_status" form:"BizResStatus" query:"BizResStatus"`
|
BizResStatus *int32 `thrift:"BizResStatus,12,optional" json:"biz_res_status" form:"BizResStatus" query:"BizResStatus"`
|
||||||
// 是否开启多人编辑
|
// Whether to enable multi-person editing
|
||||||
CollaborationEnable *bool `thrift:"CollaborationEnable,13,optional" json:"collaboration_enable" form:"CollaborationEnable" query:"CollaborationEnable"`
|
CollaborationEnable *bool `thrift:"CollaborationEnable,13,optional" json:"collaboration_enable" form:"CollaborationEnable" query:"CollaborationEnable"`
|
||||||
// 最近编辑时间, unix秒级时间戳
|
// Last edited, unix timestamp
|
||||||
EditTime *int64 `thrift:"EditTime,14,optional" form:"edit_time" json:"edit_time,string,omitempty"`
|
EditTime *int64 `thrift:"EditTime,14,optional" form:"edit_time" json:"edit_time,string,omitempty"`
|
||||||
// 资源所属空间ID
|
// Resource Ownership Space ID
|
||||||
SpaceID *int64 `thrift:"SpaceID,15,optional" form:"space_id" json:"space_id,string,omitempty"`
|
SpaceID *int64 `thrift:"SpaceID,15,optional" form:"space_id" json:"space_id,string,omitempty"`
|
||||||
// 业务携带的扩展信息,以res_type区分,每个res_type定义的schema和含义不一样,使用前需要判断res_type
|
// Business carry extended information to res_type distinguish, each res_type defined schema and meaning is not the same, need to judge before use res_type
|
||||||
BizExtend map[string]string `thrift:"BizExtend,16,optional" json:"biz_extend" form:"BizExtend" query:"BizExtend"`
|
BizExtend map[string]string `thrift:"BizExtend,16,optional" json:"biz_extend" form:"BizExtend" query:"BizExtend"`
|
||||||
// 不同类型的不同操作按钮,由资源实现方和前端约定。返回则展示,要隐藏某个按钮,则不要返回;
|
// Different types of different operation buttons are agreed upon by the resource implementer and the front end. Return is displayed, if you want to hide a button, do not return;
|
||||||
Actions []*ResourceAction `thrift:"Actions,17,optional" json:"actions" form:"Actions" query:"Actions"`
|
Actions []*ResourceAction `thrift:"Actions,17,optional" json:"actions" form:"Actions" query:"Actions"`
|
||||||
// 是否禁止进详情页
|
// Whether to ban entering the details page
|
||||||
DetailDisable *bool `thrift:"DetailDisable,18,optional" json:"detail_disable" form:"DetailDisable" query:"DetailDisable"`
|
DetailDisable *bool `thrift:"DetailDisable,18,optional" json:"detail_disable" form:"DetailDisable" query:"DetailDisable"`
|
||||||
// [数据延迟优化]删除标识符,true-已删除-前端隐藏该item,false-正常
|
// [Data delay optimization] Delete identifier, true-deleted-frontend hides the item, false-normal
|
||||||
DelFlag *bool `thrift:"DelFlag,19,optional" json:"del_flag" form:"DelFlag" query:"DelFlag"`
|
DelFlag *bool `thrift:"DelFlag,19,optional" json:"del_flag" form:"DelFlag" query:"DelFlag"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1938,11 +1938,11 @@ func (p *ResourceInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ProjectResourceAction struct {
|
type ProjectResourceAction struct {
|
||||||
// 一个操作对应一个唯一的key,key由资源侧约束
|
// An operation corresponds to a unique key, and the key is constrained by the resource side
|
||||||
Key ProjectResourceActionKey `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
Key ProjectResourceActionKey `thrift:"Key,1,required" json:"key" form:"Key,required" query:"Key,required"`
|
||||||
//ture=可以操作该Action,false=置灰
|
//ture = can operate this Action, false = grey out
|
||||||
Enable bool `thrift:"Enable,2,required" json:"enable" form:"Enable,required" query:"Enable,required"`
|
Enable bool `thrift:"Enable,2,required" json:"enable" form:"Enable,required" query:"Enable,required"`
|
||||||
// enable=false时,提示文案。后端返回Starling Key,注意放在同一个space下。
|
// When enable = false, prompt the copywriter. The backend returns the Starling Key, be careful to put it under the same space.
|
||||||
Hint *string `thrift:"Hint,3,optional" json:"hint" form:"Hint" query:"Hint"`
|
Hint *string `thrift:"Hint,3,optional" json:"hint" form:"Hint" query:"Hint"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2195,25 +2195,25 @@ func (p *ProjectResourceAction) String() string {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 实现方提供展示信息
|
// The implementer provides display information
|
||||||
type ProjectResourceInfo struct {
|
type ProjectResourceInfo struct {
|
||||||
// 资源id
|
// Resource ID
|
||||||
ResID int64 `thrift:"ResID,1" form:"res_id" json:"res_id,string"`
|
ResID int64 `thrift:"ResID,1" form:"res_id" json:"res_id,string"`
|
||||||
// 资源名称
|
// resource name
|
||||||
Name string `thrift:"Name,2" json:"name" form:"Name" query:"Name"`
|
Name string `thrift:"Name,2" json:"name" form:"Name" query:"Name"`
|
||||||
// 不同类型的不同操作按钮,由资源实现方和前端约定。返回则展示,要隐藏某个按钮,则不要返回;
|
// Different types of different operation buttons are agreed upon by the resource implementer and the front end. Return is displayed, if you want to hide a button, do not return;
|
||||||
Actions []*ProjectResourceAction `thrift:"Actions,3" json:"actions" form:"Actions" query:"Actions"`
|
Actions []*ProjectResourceAction `thrift:"Actions,3" json:"actions" form:"Actions" query:"Actions"`
|
||||||
// 该用户是否对资源只读
|
// Is the user read-only to the resource?
|
||||||
// 4: bool ReadOnly (go.tag = "json:\"read_only\"", agw.key = "read_only")
|
// 4: bool ReadOnly (go.tag = "json:\"read_only\"", agw.key = "read_only")
|
||||||
// 资源类型
|
// resource type
|
||||||
ResType ResType `thrift:"ResType,5" json:"res_type" form:"ResType" query:"ResType"`
|
ResType ResType `thrift:"ResType,5" json:"res_type" form:"ResType" query:"ResType"`
|
||||||
// 资源子类型,由资源实现方定义。Plugin:1-Http; 2-App; 6-Local;Knowledge:0-text; 1-table; 2-image;UI:1-Card
|
// Resource subtype, defined by the resource implementer. Plugin: 1-Http; 2-App; 6-Local; Knowledge: 0-text; 1-table; 2-image; UI: 1-Card
|
||||||
ResSubType *int32 `thrift:"ResSubType,6,optional" json:"res_sub_type" form:"ResSubType" query:"ResSubType"`
|
ResSubType *int32 `thrift:"ResSubType,6,optional" json:"res_sub_type" form:"ResSubType" query:"ResSubType"`
|
||||||
// 业务携带的扩展信息,以res_type区分,每个res_type定义的schema和含义不一样,使用前需要判断res_type
|
// Business carry extended information to res_type distinguish, each res_type defined schema and meaning is not the same, need to judge before use res_type
|
||||||
BizExtend map[string]string `thrift:"BizExtend,7,optional" json:"biz_extend" form:"BizExtend" query:"BizExtend"`
|
BizExtend map[string]string `thrift:"BizExtend,7,optional" json:"biz_extend" form:"BizExtend" query:"BizExtend"`
|
||||||
// 资源状态,各类型资源自身定义。前端与各资源方约定。
|
// Resource status, each type of resource defines itself. The front end agrees with each resource party.
|
||||||
BizResStatus *int32 `thrift:"BizResStatus,8,optional" json:"biz_res_status" form:"BizResStatus" query:"BizResStatus"`
|
BizResStatus *int32 `thrift:"BizResStatus,8,optional" json:"biz_res_status" form:"BizResStatus" query:"BizResStatus"`
|
||||||
// 当前资源的编辑态版本
|
// The edited version of the current resource
|
||||||
VersionStr *string `thrift:"VersionStr,9,optional" json:"version_str" form:"VersionStr" query:"VersionStr"`
|
VersionStr *string `thrift:"VersionStr,9,optional" json:"version_str" form:"VersionStr" query:"VersionStr"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -2754,7 +2754,7 @@ func (p *ProjectResourceInfo) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ProjectResourceGroup struct {
|
type ProjectResourceGroup struct {
|
||||||
// 资源分组
|
// resource grouping
|
||||||
GroupType ProjectResourceGroupType `thrift:"GroupType,1" json:"group_type" form:"GroupType" query:"GroupType"`
|
GroupType ProjectResourceGroupType `thrift:"GroupType,1" json:"group_type" form:"GroupType" query:"GroupType"`
|
||||||
ResourceList []*ProjectResourceInfo `thrift:"ResourceList,2,optional" json:"resource_list" form:"ResourceList" query:"ResourceList"`
|
ResourceList []*ProjectResourceInfo `thrift:"ResourceList,2,optional" json:"resource_list" form:"ResourceList" query:"ResourceList"`
|
||||||
}
|
}
|
||||||
|
|
@ -2974,9 +2974,9 @@ type ResourceCopyFailedReason struct {
|
||||||
ResType ResType `thrift:"ResType,2" json:"res_type" form:"ResType" query:"ResType"`
|
ResType ResType `thrift:"ResType,2" json:"res_type" form:"ResType" query:"ResType"`
|
||||||
ResName string `thrift:"ResName,3" json:"res_name" form:"ResName" query:"ResName"`
|
ResName string `thrift:"ResName,3" json:"res_name" form:"ResName" query:"ResName"`
|
||||||
Reason string `thrift:"Reason,4" json:"reason" form:"Reason" query:"Reason"`
|
Reason string `thrift:"Reason,4" json:"reason" form:"Reason" query:"Reason"`
|
||||||
// 废弃
|
// abandoned
|
||||||
PublishVersion *int64 `thrift:"PublishVersion,5,optional" json:"publish_version" form:"PublishVersion" query:"PublishVersion"`
|
PublishVersion *int64 `thrift:"PublishVersion,5,optional" json:"publish_version" form:"PublishVersion" query:"PublishVersion"`
|
||||||
// 资源的当前版本,为nil或空字符串都看作是最新版本。项目发布版本或Library发布版本。
|
// The current version of the resource, either nil or empty string, is considered the latest version. Project release or Library release.
|
||||||
PublishVersionStr *string `thrift:"PublishVersionStr,6,optional" json:"publish_version_str" form:"PublishVersionStr" query:"PublishVersionStr"`
|
PublishVersionStr *string `thrift:"PublishVersionStr,6,optional" json:"publish_version_str" form:"PublishVersionStr" query:"PublishVersionStr"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -3359,13 +3359,13 @@ func (p *ResourceCopyFailedReason) String() string {
|
||||||
|
|
||||||
type ResourceCopyTaskDetail struct {
|
type ResourceCopyTaskDetail struct {
|
||||||
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
||||||
// 任务状态
|
// task status
|
||||||
Status TaskStatus `thrift:"status,2" form:"status" json:"status" query:"status"`
|
Status TaskStatus `thrift:"status,2" form:"status" json:"status" query:"status"`
|
||||||
// 复制后的资源id
|
// Replicated resource id
|
||||||
ResID int64 `thrift:"res_id,3" form:"res_id" json:"res_id,string" query:"res_id"`
|
ResID int64 `thrift:"res_id,3" form:"res_id" json:"res_id,string" query:"res_id"`
|
||||||
ResType ResType `thrift:"res_type,4" form:"res_type" json:"res_type" query:"res_type"`
|
ResType ResType `thrift:"res_type,4" form:"res_type" json:"res_type" query:"res_type"`
|
||||||
Scene ResourceCopyScene `thrift:"scene,5" form:"scene" json:"scene" query:"scene"`
|
Scene ResourceCopyScene `thrift:"scene,5" form:"scene" json:"scene" query:"scene"`
|
||||||
// 复制前的资源名称
|
// Resource name before copy
|
||||||
ResName *string `thrift:"res_name,6,optional" form:"res_name" json:"res_name,omitempty" query:"res_name"`
|
ResName *string `thrift:"res_name,6,optional" form:"res_name" json:"res_name,omitempty" query:"res_name"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,31 +3,31 @@
|
||||||
package resource
|
package resource
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/resource/common"
|
|
||||||
"context"
|
"context"
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/resource/common"
|
||||||
)
|
)
|
||||||
|
|
||||||
type LibraryResourceListRequest struct {
|
type LibraryResourceListRequest struct {
|
||||||
// 是否由当前用户创建,0-不筛选,1-当前用户
|
// Whether created by the current user, 0 - unfiltered, 1 - current user
|
||||||
UserFilter *int32 `thrift:"user_filter,1,optional" form:"user_filter" json:"user_filter,omitempty" query:"user_filter"`
|
UserFilter *int32 `thrift:"user_filter,1,optional" form:"user_filter" json:"user_filter,omitempty" query:"user_filter"`
|
||||||
// [4,1] 0代表不筛选
|
// [4,1] 0 means do not filter
|
||||||
ResTypeFilter []common.ResType `thrift:"res_type_filter,2,optional" form:"res_type_filter" json:"res_type_filter,omitempty" query:"res_type_filter"`
|
ResTypeFilter []common.ResType `thrift:"res_type_filter,2,optional" form:"res_type_filter" json:"res_type_filter,omitempty" query:"res_type_filter"`
|
||||||
// 名称
|
// name
|
||||||
Name *string `thrift:"name,3,optional" form:"name" json:"name,omitempty" query:"name"`
|
Name *string `thrift:"name,3,optional" form:"name" json:"name,omitempty" query:"name"`
|
||||||
// 发布状态,0-不筛选,1-未发布,2-已发布
|
// Published status, 0 - unfiltered, 1 - unpublished, 2 - published
|
||||||
PublishStatusFilter *common.PublishStatus `thrift:"publish_status_filter,4,optional" form:"publish_status_filter" json:"publish_status_filter,omitempty" query:"publish_status_filter"`
|
PublishStatusFilter *common.PublishStatus `thrift:"publish_status_filter,4,optional" form:"publish_status_filter" json:"publish_status_filter,omitempty" query:"publish_status_filter"`
|
||||||
// 用户所在空间ID
|
// User's space ID
|
||||||
SpaceID int64 `thrift:"space_id,5,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
SpaceID int64 `thrift:"space_id,5,required" form:"space_id,required" json:"space_id,string,required" query:"space_id,required"`
|
||||||
// 一次读取的数据条数,默认10,最大100.
|
// The number of data bars read at one time, the default is 10, and the maximum is 100.
|
||||||
Size *int32 `thrift:"size,7,optional" form:"size" json:"size,omitempty" query:"size"`
|
Size *int32 `thrift:"size,7,optional" form:"size" json:"size,omitempty" query:"size"`
|
||||||
// 游标,用于分页,默认0,第一次请求可以不传,后续请求需要带上上次返回的cursor
|
// Cursor, used for paging, default 0, the first request can not be passed, subsequent requests need to bring the last returned cursor
|
||||||
Cursor *string `thrift:"cursor,9,optional" form:"cursor" json:"cursor,omitempty" query:"cursor"`
|
Cursor *string `thrift:"cursor,9,optional" form:"cursor" json:"cursor,omitempty" query:"cursor"`
|
||||||
// 用来指定自定义搜索的字段 不填默认只name匹配,eg []string{name,自定} 匹配name和自定义字段full_text
|
// The field used to specify the custom search, do not fill in the default only name matches, eg [] string {name, custom} matches the name and custom fields full_text
|
||||||
SearchKeys []string `thrift:"search_keys,10,optional" form:"search_keys" json:"search_keys,omitempty" query:"search_keys"`
|
SearchKeys []string `thrift:"search_keys,10,optional" form:"search_keys" json:"search_keys,omitempty" query:"search_keys"`
|
||||||
// 当res_type_filter为[2 workflow]时,是否需要返回图片流
|
// Do you need to return image review when the res_type_filter is [2 workflow]
|
||||||
IsGetImageflow *bool `thrift:"is_get_imageflow,11,optional" form:"is_get_imageflow" json:"is_get_imageflow,omitempty" query:"is_get_imageflow"`
|
IsGetImageflow *bool `thrift:"is_get_imageflow,11,optional" form:"is_get_imageflow" json:"is_get_imageflow,omitempty" query:"is_get_imageflow"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -710,9 +710,9 @@ type LibraryResourceListResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
ResourceList []*common.ResourceInfo `thrift:"resource_list,3" form:"resource_list" json:"resource_list" query:"resource_list"`
|
ResourceList []*common.ResourceInfo `thrift:"resource_list,3" form:"resource_list" json:"resource_list" query:"resource_list"`
|
||||||
// 游标,用于下次请求的cursor
|
// Cursor, the cursor for the next request
|
||||||
Cursor *string `thrift:"cursor,5,optional" form:"cursor" json:"cursor,omitempty" query:"cursor"`
|
Cursor *string `thrift:"cursor,5,optional" form:"cursor" json:"cursor,omitempty" query:"cursor"`
|
||||||
// 是否还有数据待拉取
|
// Is there still data to be pulled?
|
||||||
HasMore bool `thrift:"has_more,6" form:"has_more" json:"has_more" query:"has_more"`
|
HasMore bool `thrift:"has_more,6" form:"has_more" json:"has_more" query:"has_more"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
||||||
}
|
}
|
||||||
|
|
@ -1118,11 +1118,11 @@ func (p *LibraryResourceListResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ProjectResourceListRequest struct {
|
type ProjectResourceListRequest struct {
|
||||||
// 项目ID
|
// Project ID
|
||||||
ProjectID int64 `thrift:"project_id,1,required" form:"project_id,required" json:"project_id,string,required" query:"project_id,required"`
|
ProjectID int64 `thrift:"project_id,1,required" form:"project_id,required" json:"project_id,string,required" query:"project_id,required"`
|
||||||
// 用户所在space id
|
// User space id
|
||||||
SpaceID int64 `thrift:"space_id,2" form:"space_id" json:"space_id,string" query:"space_id"`
|
SpaceID int64 `thrift:"space_id,2" form:"space_id" json:"space_id,string" query:"space_id"`
|
||||||
// 指定获取某个版本的project的资源
|
// Specify the resources to obtain a version of the project
|
||||||
ProjectVersion *string `thrift:"project_version,3,optional" form:"project_version" json:"project_version,omitempty" query:"project_version"`
|
ProjectVersion *string `thrift:"project_version,3,optional" form:"project_version" json:"project_version,omitempty" query:"project_version"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -1728,15 +1728,15 @@ func (p *ProjectResourceListResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResourceCopyDispatchRequest struct {
|
type ResourceCopyDispatchRequest struct {
|
||||||
// 场景,只支持单资源的操作
|
// Scenario, only supports the operation of a single resource
|
||||||
Scene common.ResourceCopyScene `thrift:"scene,1" form:"scene" json:"scene" query:"scene"`
|
Scene common.ResourceCopyScene `thrift:"scene,1" form:"scene" json:"scene" query:"scene"`
|
||||||
// 被用户选择复制/移动的资源ID
|
// The resource ID selected by the user to copy/move
|
||||||
ResID int64 `thrift:"res_id,2" form:"res_id" json:"res_id,string"`
|
ResID int64 `thrift:"res_id,2" form:"res_id" json:"res_id,string"`
|
||||||
ResType common.ResType `thrift:"res_type,3" form:"res_type" json:"res_type" query:"res_type"`
|
ResType common.ResType `thrift:"res_type,3" form:"res_type" json:"res_type" query:"res_type"`
|
||||||
// 所在项目ID
|
// Project ID
|
||||||
ProjectID *int64 `thrift:"project_id,4,optional" form:"project_id" json:"project_id,string,omitempty"`
|
ProjectID *int64 `thrift:"project_id,4,optional" form:"project_id" json:"project_id,string,omitempty"`
|
||||||
ResName *string `thrift:"res_name,5,optional" form:"res_name" json:"res_name,omitempty" query:"res_name"`
|
ResName *string `thrift:"res_name,5,optional" form:"res_name" json:"res_name,omitempty" query:"res_name"`
|
||||||
// 跨空间复制的目标space id
|
// Target space id for cross-space copy
|
||||||
TargetSpaceID *int64 `thrift:"target_space_id,6,optional" form:"target_space_id" json:"target_space_id,string,omitempty"`
|
TargetSpaceID *int64 `thrift:"target_space_id,6,optional" form:"target_space_id" json:"target_space_id,string,omitempty"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -2182,9 +2182,9 @@ func (p *ResourceCopyDispatchRequest) String() string {
|
||||||
type ResourceCopyDispatchResponse struct {
|
type ResourceCopyDispatchResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
// 复制任务id, 用于查询任务状态或取消、重试任务
|
// Copy task ID, used to query task status or cancel or retry tasks
|
||||||
TaskID *string `thrift:"task_id,3,optional" form:"task_id" json:"task_id,omitempty" query:"task_id"`
|
TaskID *string `thrift:"task_id,3,optional" form:"task_id" json:"task_id,omitempty" query:"task_id"`
|
||||||
// 不可以进行操作的原因,返回多语言文本
|
// The reason why the operation cannot be performed is to return multilingual text
|
||||||
FailedReasons []*common.ResourceCopyFailedReason `thrift:"failed_reasons,4,optional" form:"failed_reasons" json:"failed_reasons,omitempty" query:"failed_reasons"`
|
FailedReasons []*common.ResourceCopyFailedReason `thrift:"failed_reasons,4,optional" form:"failed_reasons" json:"failed_reasons,omitempty" query:"failed_reasons"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
||||||
}
|
}
|
||||||
|
|
@ -2557,7 +2557,7 @@ func (p *ResourceCopyDispatchResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResourceCopyDetailRequest struct {
|
type ResourceCopyDetailRequest struct {
|
||||||
// 复制任务id, 用于查询任务状态或取消、重试任务
|
// Copy task ID, used to query task status or cancel or retry tasks
|
||||||
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3044,7 +3044,7 @@ func (p *ResourceCopyDetailResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResourceCopyRetryRequest struct {
|
type ResourceCopyRetryRequest struct {
|
||||||
// 复制任务id, 用于查询任务状态或取消、重试任务
|
// Copy task ID, used to query task status or cancel or retry tasks
|
||||||
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3237,7 +3237,7 @@ func (p *ResourceCopyRetryRequest) String() string {
|
||||||
type ResourceCopyRetryResponse struct {
|
type ResourceCopyRetryResponse struct {
|
||||||
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
Code int64 `thrift:"code,1" form:"code" json:"code" query:"code"`
|
||||||
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
Msg string `thrift:"msg,2" form:"msg" json:"msg" query:"msg"`
|
||||||
// 不可以进行操作的原因,返回多语言文本
|
// The reason why the operation cannot be performed is to return multilingual text
|
||||||
FailedReasons []*common.ResourceCopyFailedReason `thrift:"failed_reasons,4,optional" form:"failed_reasons" json:"failed_reasons,omitempty" query:"failed_reasons"`
|
FailedReasons []*common.ResourceCopyFailedReason `thrift:"failed_reasons,4,optional" form:"failed_reasons" json:"failed_reasons,omitempty" query:"failed_reasons"`
|
||||||
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
BaseResp *base.BaseResp `thrift:"BaseResp,255,required" form:"BaseResp,required" json:"BaseResp,required" query:"BaseResp,required"`
|
||||||
}
|
}
|
||||||
|
|
@ -3555,7 +3555,7 @@ func (p *ResourceCopyRetryResponse) String() string {
|
||||||
}
|
}
|
||||||
|
|
||||||
type ResourceCopyCancelRequest struct {
|
type ResourceCopyCancelRequest struct {
|
||||||
// 复制任务id, 用于查询任务状态或取消、重试任务
|
// Copy task ID, used to query task status or cancel or retry tasks
|
||||||
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
TaskID string `thrift:"task_id,1" form:"task_id" json:"task_id" query:"task_id"`
|
||||||
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
Base *base.Base `thrift:"Base,255" form:"Base" json:"Base" query:"Base"`
|
||||||
}
|
}
|
||||||
|
|
@ -3992,7 +3992,7 @@ type ResourceService interface {
|
||||||
LibraryResourceList(ctx context.Context, request *LibraryResourceListRequest) (r *LibraryResourceListResponse, err error)
|
LibraryResourceList(ctx context.Context, request *LibraryResourceListRequest) (r *LibraryResourceListResponse, err error)
|
||||||
|
|
||||||
ProjectResourceList(ctx context.Context, request *ProjectResourceListRequest) (r *ProjectResourceListResponse, err error)
|
ProjectResourceList(ctx context.Context, request *ProjectResourceListRequest) (r *ProjectResourceListResponse, err error)
|
||||||
// 复制Library资源到项目、复制项目资源到Library、移动项目资源到Library、项目内单复制资源
|
// Copy Library resources to projects, copy project resources to libraries, move project resources to libraries, and copy resources within projects
|
||||||
ResourceCopyDispatch(ctx context.Context, req *ResourceCopyDispatchRequest) (r *ResourceCopyDispatchResponse, err error)
|
ResourceCopyDispatch(ctx context.Context, req *ResourceCopyDispatchRequest) (r *ResourceCopyDispatchResponse, err error)
|
||||||
|
|
||||||
ResourceCopyDetail(ctx context.Context, req *ResourceCopyDetailRequest) (r *ResourceCopyDetailResponse, err error)
|
ResourceCopyDetail(ctx context.Context, req *ResourceCopyDetailRequest) (r *ResourceCopyDetailResponse, err error)
|
||||||
|
|
|
||||||
File diff suppressed because it is too large
Load Diff
|
|
@ -3,10 +3,10 @@
|
||||||
package task
|
package task
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
|
||||||
"github.com/coze-dev/coze-studio/backend/api/model/task_struct"
|
|
||||||
"fmt"
|
"fmt"
|
||||||
"github.com/apache/thrift/lib/go/thrift"
|
"github.com/apache/thrift/lib/go/thrift"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/base"
|
||||||
|
"github.com/coze-dev/coze-studio/backend/api/model/task_struct"
|
||||||
)
|
)
|
||||||
|
|
||||||
type DraftProjectInnerTaskListRequest struct {
|
type DraftProjectInnerTaskListRequest struct {
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@ import (
|
||||||
)
|
)
|
||||||
|
|
||||||
type ProjectInnerTaskInfo struct {
|
type ProjectInnerTaskInfo struct {
|
||||||
// 任务id
|
// Task ID
|
||||||
TaskID int64 `thrift:"task_id,1" form:"task_id" json:"task_id,string" query:"task_id"`
|
TaskID int64 `thrift:"task_id,1" form:"task_id" json:"task_id,string" query:"task_id"`
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1014,7 +1014,7 @@ func (a *APPApplicationService) ResourceCopyDetail(ctx context.Context, req *res
|
||||||
}
|
}
|
||||||
|
|
||||||
if !exist {
|
if !exist {
|
||||||
return resp, nil // 默认返回处理中
|
return resp, nil // Default return processing
|
||||||
}
|
}
|
||||||
|
|
||||||
detail.Status = resourceCommon.TaskStatus(result.CopyStatus)
|
detail.Status = resourceCommon.TaskStatus(result.CopyStatus)
|
||||||
|
|
|
||||||
|
|
@ -348,7 +348,7 @@ func (c *ConversationApplicationService) buildTools(ctx context.Context, tools [
|
||||||
}
|
}
|
||||||
|
|
||||||
arguments[key] = parametersStruct.Value
|
arguments[key] = parametersStruct.Value
|
||||||
// uri需要转换成url
|
// URI needs to be converted to url.
|
||||||
if parametersStruct.ResourceType == consts.ShortcutCommandResourceType {
|
if parametersStruct.ResourceType == consts.ShortcutCommandResourceType {
|
||||||
|
|
||||||
resourceInfo, err := c.appContext.ImageX.GetResourceURL(ctx, parametersStruct.Value)
|
resourceInfo, err := c.appContext.ImageX.GetResourceURL(ctx, parametersStruct.Value)
|
||||||
|
|
|
||||||
|
|
@ -64,7 +64,7 @@ func assertValAs(typ document.TableColumnType, val string) (*document.ColumnData
|
||||||
}, nil
|
}, nil
|
||||||
|
|
||||||
case document.TableColumnTypeTime:
|
case document.TableColumnTypeTime:
|
||||||
// 支持时间戳和时间字符串
|
// Supports timestamp and time string
|
||||||
i, err := strconv.ParseInt(val, 10, 64)
|
i, err := strconv.ParseInt(val, 10, 64)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
t := time.Unix(i, 0)
|
t := time.Unix(i, 0)
|
||||||
|
|
|
||||||
|
|
@ -658,7 +658,7 @@ func (d *DatabaseApplicationService) GetDatabaseTableSchema(ctx context.Context,
|
||||||
HeaderLineIdx: req.GetTableSheet().GetHeaderLineIdx(),
|
HeaderLineIdx: req.GetTableSheet().GetHeaderLineIdx(),
|
||||||
StartLineIdx: req.GetTableSheet().GetStartLineIdx(),
|
StartLineIdx: req.GetTableSheet().GetStartLineIdx(),
|
||||||
},
|
},
|
||||||
// 不传默认返回所有数据
|
// All data is returned by default without passing it on.
|
||||||
TableDataType: tableType,
|
TableDataType: tableType,
|
||||||
})
|
})
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
|
||||||
|
|
@ -39,7 +39,7 @@ var ModelmgrApplicationSVC = &ModelmgrApplicationService{}
|
||||||
func (m *ModelmgrApplicationService) GetModelList(ctx context.Context, _ *developer_api.GetTypeListRequest) (
|
func (m *ModelmgrApplicationService) GetModelList(ctx context.Context, _ *developer_api.GetTypeListRequest) (
|
||||||
resp *developer_api.GetTypeListResponse, err error,
|
resp *developer_api.GetTypeListResponse, err error,
|
||||||
) {
|
) {
|
||||||
// 一般不太可能同时配置这么多模型
|
// It is generally not possible to configure so many models simultaneously
|
||||||
const modelMaxLimit = 300
|
const modelMaxLimit = 300
|
||||||
|
|
||||||
modelResp, err := m.Mgr.ListModel(ctx, &modelmgr.ListModelRequest{
|
modelResp, err := m.Mgr.ListModel(ctx, &modelmgr.ListModelRequest{
|
||||||
|
|
@ -121,7 +121,7 @@ func modelDo2To(model *modelmgr.Model, locale i18n.Locale) (*developer_api.Model
|
||||||
ModelTagList: nil,
|
ModelTagList: nil,
|
||||||
IsUpRequired: nil,
|
IsUpRequired: nil,
|
||||||
ModelBriefDesc: model.Description.Read(locale),
|
ModelBriefDesc: model.Description.Read(locale),
|
||||||
ModelSeries: &developer_api.ModelSeriesInfo{ // TODO: 替换为真实配置
|
ModelSeries: &developer_api.ModelSeriesInfo{ // TODO: Replace with real configuration
|
||||||
SeriesName: "热门模型",
|
SeriesName: "热门模型",
|
||||||
},
|
},
|
||||||
ModelStatusDetails: nil,
|
ModelStatusDetails: nil,
|
||||||
|
|
|
||||||
|
|
@ -217,7 +217,7 @@ func (p *PluginApplicationService) toPluginInfoForPlayground(ctx context.Context
|
||||||
UpdateTime: strconv.FormatInt(pl.UpdatedAt/1000, 10),
|
UpdateTime: strconv.FormatInt(pl.UpdatedAt/1000, 10),
|
||||||
ProjectID: strconv.FormatInt(pl.GetAPPID(), 10),
|
ProjectID: strconv.FormatInt(pl.GetAPPID(), 10),
|
||||||
VersionName: pl.GetVersion(),
|
VersionName: pl.GetVersion(),
|
||||||
VersionTs: pl.GetVersion(), // 兼容前端逻辑,理论上应该使用 VersionName
|
VersionTs: pl.GetVersion(), // Compatible with front-end logic, in theory VersionName should be used
|
||||||
PluginApis: pluginAPIs,
|
PluginApis: pluginAPIs,
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -1237,7 +1237,7 @@ func (p *PluginApplicationService) PublicGetProductList(ctx context.Context, req
|
||||||
resp = &productAPI.GetProductListResponse{
|
resp = &productAPI.GetProductListResponse{
|
||||||
Data: &productAPI.GetProductListData{
|
Data: &productAPI.GetProductListData{
|
||||||
Products: products,
|
Products: products,
|
||||||
HasMore: false, // 一次性拉完
|
HasMore: false, // Finish at one time
|
||||||
Total: int32(res.Total),
|
Total: int32(res.Total),
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -73,7 +73,7 @@ func (s *SearchApplicationService) LibraryResourceList(ctx context.Context, req
|
||||||
Limit: req.GetSize(),
|
Limit: req.GetSize(),
|
||||||
}
|
}
|
||||||
|
|
||||||
// 设置用户过滤
|
// Set up user filtering
|
||||||
if req.IsSetUserFilter() && req.GetUserFilter() > 0 {
|
if req.IsSetUserFilter() && req.GetUserFilter() > 0 {
|
||||||
searchReq.OwnerID = ptr.From(userID)
|
searchReq.OwnerID = ptr.From(userID)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -444,7 +444,7 @@ func parametersDo2Vo(op *plugin.Openapi3Operation) []*playground.PluginParameter
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
break // 只取一种 MIME
|
break // Take only one MIME.
|
||||||
}
|
}
|
||||||
|
|
||||||
return params
|
return params
|
||||||
|
|
|
||||||
|
|
@ -156,7 +156,7 @@ func (s *SingleAgentApplicationService) UpdatePromptDisable(ctx context.Context,
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(draft.Database) == 0 {
|
if len(draft.Database) == 0 {
|
||||||
return nil, fmt.Errorf("agent %d has no database", agentID) // TODO(@fanlv): 错误码
|
return nil, fmt.Errorf("agent %d has no database", agentID) // TODO (@fanlv): error code
|
||||||
}
|
}
|
||||||
|
|
||||||
dbInfos := draft.Database
|
dbInfos := draft.Database
|
||||||
|
|
@ -170,7 +170,7 @@ func (s *SingleAgentApplicationService) UpdatePromptDisable(ctx context.Context,
|
||||||
}
|
}
|
||||||
|
|
||||||
if !found {
|
if !found {
|
||||||
return nil, fmt.Errorf("database %d not found in agent %d", req.GetDatabaseID(), agentID) // TODO(@fanlv): 错误码
|
return nil, fmt.Errorf("database %d not found in agent %d", req.GetDatabaseID(), agentID) // TODO (@fanlv): error code
|
||||||
}
|
}
|
||||||
|
|
||||||
draft.Database = dbInfos
|
draft.Database = dbInfos
|
||||||
|
|
@ -606,7 +606,7 @@ func (s *SingleAgentApplicationService) ListAgentPublishHistory(ctx context.Cont
|
||||||
Name: creator.Name,
|
Name: creator.Name,
|
||||||
AvatarURL: creator.IconURL,
|
AvatarURL: creator.IconURL,
|
||||||
Self: uid == v.CreatorID,
|
Self: uid == v.CreatorID,
|
||||||
// UserUniqueName: creator.UserUniqueName, // TODO(@fanlv) : user domain 补完以后再改
|
// UserUniqueName: creator. UserUniqueName,//TODO (@fanlv): Change the user domain after it is completed
|
||||||
// UserLabel TODO
|
// UserLabel TODO
|
||||||
},
|
},
|
||||||
PublishID: &v.PublishID,
|
PublishID: &v.PublishID,
|
||||||
|
|
|
||||||
|
|
@ -486,7 +486,7 @@ func isImageUri(uri string) bool {
|
||||||
"ico": true,
|
"ico": true,
|
||||||
}
|
}
|
||||||
|
|
||||||
// 检查扩展名是否在图片扩展名列表中
|
// Check if the extension is in the picture extension list
|
||||||
return imageExtensions[ext]
|
return imageExtensions[ext]
|
||||||
}
|
}
|
||||||
func (u *UploadService) GetObjInfoBySessionKey(ctx context.Context, sessionKey string) (*GetObjInfoBySessionKey, error) {
|
func (u *UploadService) GetObjInfoBySessionKey(ctx context.Context, sessionKey string) (*GetObjInfoBySessionKey, error) {
|
||||||
|
|
@ -534,7 +534,7 @@ type SVG struct {
|
||||||
ViewBox string `xml:"viewBox,attr"`
|
ViewBox string `xml:"viewBox,attr"`
|
||||||
}
|
}
|
||||||
|
|
||||||
// 获取 SVG 尺寸
|
// Get SVG size
|
||||||
func getSVGDimensions(content []byte) (width, height int32, err error) {
|
func getSVGDimensions(content []byte) (width, height int32, err error) {
|
||||||
decoder := xml.NewDecoder(bytes.NewReader(content))
|
decoder := xml.NewDecoder(bytes.NewReader(content))
|
||||||
|
|
||||||
|
|
@ -543,7 +543,7 @@ func getSVGDimensions(content []byte) (width, height int32, err error) {
|
||||||
return 100, 100, nil
|
return 100, 100, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// 尝试从width属性获取
|
// Try to get from the width property
|
||||||
if svg.Width != "" {
|
if svg.Width != "" {
|
||||||
w, err := parseDimension(svg.Width)
|
w, err := parseDimension(svg.Width)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
|
|
@ -551,7 +551,7 @@ func getSVGDimensions(content []byte) (width, height int32, err error) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 尝试从height属性获取
|
// Try to get from the height property
|
||||||
if svg.Height != "" {
|
if svg.Height != "" {
|
||||||
h, err := parseDimension(svg.Height)
|
h, err := parseDimension(svg.Height)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
|
|
@ -559,7 +559,7 @@ func getSVGDimensions(content []byte) (width, height int32, err error) {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 如果width或height未设置,尝试从viewBox获取
|
// If width or height is not set, try getting it from the viewBox
|
||||||
if width == 0 || height == 0 {
|
if width == 0 || height == 0 {
|
||||||
if svg.ViewBox != "" {
|
if svg.ViewBox != "" {
|
||||||
parts := strings.Fields(svg.ViewBox)
|
parts := strings.Fields(svg.ViewBox)
|
||||||
|
|
@ -587,19 +587,19 @@ func getSVGDimensions(content []byte) (width, height int32, err error) {
|
||||||
return width, height, nil
|
return width, height, nil
|
||||||
}
|
}
|
||||||
func parseDimension(dim string) (int32, error) {
|
func parseDimension(dim string) (int32, error) {
|
||||||
// 去除单位(px, pt, em, %等)和空格
|
// Remove units (px, pt, em,%, etc.) and spaces
|
||||||
dim = strings.TrimSpace(dim)
|
dim = strings.TrimSpace(dim)
|
||||||
dim = strings.TrimRightFunc(dim, func(r rune) bool {
|
dim = strings.TrimRightFunc(dim, func(r rune) bool {
|
||||||
return (r < '0' || r > '9') && r != '.' && r != '-' && r != '+'
|
return (r < '0' || r > '9') && r != '.' && r != '-' && r != '+'
|
||||||
})
|
})
|
||||||
|
|
||||||
// 解析为float64
|
// Resolve to float64
|
||||||
value, err := strconv.ParseFloat(dim, 64)
|
value, err := strconv.ParseFloat(dim, 64)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return 0, err
|
return 0, err
|
||||||
}
|
}
|
||||||
|
|
||||||
// 四舍五入转换为int32
|
// Rounding converts to int32
|
||||||
if value > math.MaxInt32 {
|
if value > math.MaxInt32 {
|
||||||
return math.MaxInt32, nil
|
return math.MaxInt32, nil
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -45,9 +45,9 @@ type UserApplicationService struct {
|
||||||
DomainSVC user.User
|
DomainSVC user.User
|
||||||
}
|
}
|
||||||
|
|
||||||
// 添加一个简单的 email 验证函数
|
// Add a simple email verification function
|
||||||
func isValidEmail(email string) bool {
|
func isValidEmail(email string) bool {
|
||||||
// 如果 email 字符串格式不正确,它会返回一个 error
|
// If the email string is not in the correct format, it will return an error.
|
||||||
_, err := mail.ParseAddress(email)
|
_, err := mail.ParseAddress(email)
|
||||||
return err == nil
|
return err == nil
|
||||||
}
|
}
|
||||||
|
|
@ -55,7 +55,7 @@ func isValidEmail(email string) bool {
|
||||||
func (u *UserApplicationService) PassportWebEmailRegisterV2(ctx context.Context, locale string, req *passport.PassportWebEmailRegisterV2PostRequest) (
|
func (u *UserApplicationService) PassportWebEmailRegisterV2(ctx context.Context, locale string, req *passport.PassportWebEmailRegisterV2PostRequest) (
|
||||||
resp *passport.PassportWebEmailRegisterV2PostResponse, sessionKey string, err error,
|
resp *passport.PassportWebEmailRegisterV2PostResponse, sessionKey string, err error,
|
||||||
) {
|
) {
|
||||||
// 验证 email 格式是否合法
|
// Verify that the email format is legitimate
|
||||||
if !isValidEmail(req.GetEmail()) {
|
if !isValidEmail(req.GetEmail()) {
|
||||||
return nil, "", errorx.New(errno.ErrUserInvalidParamCode, errorx.KV("msg", "Invalid email"))
|
return nil, "", errorx.New(errno.ErrUserInvalidParamCode, errorx.KV("msg", "Invalid email"))
|
||||||
}
|
}
|
||||||
|
|
@ -100,7 +100,7 @@ func (u *UserApplicationService) allowRegisterChecker(email string) bool {
|
||||||
return slices.Contains(strings.Split(allowedEmails, ","), strings.ToLower(email))
|
return slices.Contains(strings.Split(allowedEmails, ","), strings.ToLower(email))
|
||||||
}
|
}
|
||||||
|
|
||||||
// PassportWebLogoutGet 处理用户登出请求
|
// PassportWebLogoutGet handle user logout requests
|
||||||
func (u *UserApplicationService) PassportWebLogoutGet(ctx context.Context, req *passport.PassportWebLogoutGetRequest) (
|
func (u *UserApplicationService) PassportWebLogoutGet(ctx context.Context, req *passport.PassportWebLogoutGetRequest) (
|
||||||
resp *passport.PassportWebLogoutGetResponse, err error,
|
resp *passport.PassportWebLogoutGetResponse, err error,
|
||||||
) {
|
) {
|
||||||
|
|
@ -116,7 +116,7 @@ func (u *UserApplicationService) PassportWebLogoutGet(ctx context.Context, req *
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// PassportWebEmailLoginPost 处理用户邮箱登录请求
|
// PassportWebEmailLoginPost handle user email login requests
|
||||||
func (u *UserApplicationService) PassportWebEmailLoginPost(ctx context.Context, req *passport.PassportWebEmailLoginPostRequest) (
|
func (u *UserApplicationService) PassportWebEmailLoginPost(ctx context.Context, req *passport.PassportWebEmailLoginPostRequest) (
|
||||||
resp *passport.PassportWebEmailLoginPostResponse, sessionKey string, err error,
|
resp *passport.PassportWebEmailLoginPostResponse, sessionKey string, err error,
|
||||||
) {
|
) {
|
||||||
|
|
@ -160,11 +160,11 @@ func (u *UserApplicationService) PassportAccountInfoV2(ctx context.Context, req
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// UserUpdateAvatar 更新用户头像
|
// UserUpdateAvatar Update user avatar
|
||||||
func (u *UserApplicationService) UserUpdateAvatar(ctx context.Context, mimeType string, req *passport.UserUpdateAvatarRequest) (
|
func (u *UserApplicationService) UserUpdateAvatar(ctx context.Context, mimeType string, req *passport.UserUpdateAvatarRequest) (
|
||||||
resp *passport.UserUpdateAvatarResponse, err error,
|
resp *passport.UserUpdateAvatarResponse, err error,
|
||||||
) {
|
) {
|
||||||
// 根据 MIME type 获取文件后缀
|
// Get file suffix by MIME type
|
||||||
var ext string
|
var ext string
|
||||||
switch mimeType {
|
switch mimeType {
|
||||||
case "image/jpeg", "image/jpg":
|
case "image/jpeg", "image/jpg":
|
||||||
|
|
@ -195,7 +195,7 @@ func (u *UserApplicationService) UserUpdateAvatar(ctx context.Context, mimeType
|
||||||
}, nil
|
}, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
// UserUpdateProfile 更新用户资料
|
// UserUpdateProfile Update user profile
|
||||||
func (u *UserApplicationService) UserUpdateProfile(ctx context.Context, req *passport.UserUpdateProfileRequest) (
|
func (u *UserApplicationService) UserUpdateProfile(ctx context.Context, req *passport.UserUpdateProfileRequest) (
|
||||||
resp *passport.UserUpdateProfileResponse, err error,
|
resp *passport.UserUpdateProfileResponse, err error,
|
||||||
) {
|
) {
|
||||||
|
|
|
||||||
|
|
@ -432,7 +432,7 @@ paths:
|
||||||
type: object
|
type: object
|
||||||
type: array
|
type: array
|
||||||
resource_type:
|
resource_type:
|
||||||
description: 工作表类型,sheet:工作表,bitable:多维表格,#UNSUPPORTED_TYPE:不支持的类型
|
description: 工作表类型,sheet:工作表,bitable:多维表格,#UNSUPPORTED_TYPE: Unsupported types
|
||||||
type: string
|
type: string
|
||||||
sheet_id:
|
sheet_id:
|
||||||
description: 工作表 ID
|
description: 工作表 ID
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ import (
|
||||||
"github.com/coze-dev/coze-studio/backend/domain/workflow/entity/vo"
|
"github.com/coze-dev/coze-studio/backend/domain/workflow/entity/vo"
|
||||||
)
|
)
|
||||||
|
|
||||||
// TODO(@fanlv): 参数引用需要修改。
|
// TODO (@fanlv): Parameter references need to be modified.
|
||||||
type Workflow interface {
|
type Workflow interface {
|
||||||
WorkflowAsModelTool(ctx context.Context, policies []*vo.GetPolicy) ([]workflow.ToolFromWorkflow, error)
|
WorkflowAsModelTool(ctx context.Context, policies []*vo.GetPolicy) ([]workflow.ToolFromWorkflow, error)
|
||||||
DeleteWorkflow(ctx context.Context, id int64) error
|
DeleteWorkflow(ctx context.Context, id int64) error
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,7 @@ func TestBuildAgent(t *testing.T) {
|
||||||
// PluginID: 999,
|
// PluginID: 999,
|
||||||
// Operation: &pluginEntity.Openapi3Operation{
|
// Operation: &pluginEntity.Openapi3Operation{
|
||||||
// OperationID: "get_user_salary",
|
// OperationID: "get_user_salary",
|
||||||
// Summary: "了解用户的月收入情况",
|
// Summary: "Understand the monthly income of users",
|
||||||
// Parameters: openapi3.Parameters{
|
// Parameters: openapi3.Parameters{
|
||||||
// {
|
// {
|
||||||
// Value: &openapi3.Parameter{
|
// Value: &openapi3.Parameter{
|
||||||
|
|
@ -126,7 +126,7 @@ func TestBuildAgent(t *testing.T) {
|
||||||
// RawContent: []*knowledgeEntity.SliceContent{
|
// RawContent: []*knowledgeEntity.SliceContent{
|
||||||
// {
|
// {
|
||||||
// Type: knowledgeEntity.SliceContentTypeText,
|
// Type: knowledgeEntity.SliceContentTypeText,
|
||||||
// Text: ptr.Of("learn computer science, become software developer, 月薪 2W 左右"),
|
// Text: ptr. Of ("learn computer science, become software developer, monthly salary is about 2W"),
|
||||||
// },
|
// },
|
||||||
// },
|
// },
|
||||||
// },
|
// },
|
||||||
|
|
@ -168,7 +168,7 @@ func TestBuildAgent(t *testing.T) {
|
||||||
// KnowledgeInfo: []*bot_common.KnowledgeInfo{
|
// KnowledgeInfo: []*bot_common.KnowledgeInfo{
|
||||||
// {
|
// {
|
||||||
// Id: ptr.Of("777"),
|
// Id: ptr.Of("777"),
|
||||||
// Name: ptr.Of("赚钱指南:根据你的个人兴趣、个人条件规划职业发展路径,达成所需的赚钱目标"),
|
// Name: ptr. Of ("Making Money Guide: Plan a career development path according to your personal interests and personal conditions to achieve the desired earning goals"),
|
||||||
// },
|
// },
|
||||||
// },
|
// },
|
||||||
// },
|
// },
|
||||||
|
|
|
||||||
|
|
@ -46,9 +46,9 @@ func (p *promptVariables) AssemblePromptVariables(ctx context.Context, req *Agen
|
||||||
variables[placeholderOfUserInput] = []*schema.Message{req.Input}
|
variables[placeholderOfUserInput] = []*schema.Message{req.Input}
|
||||||
}
|
}
|
||||||
|
|
||||||
// 处理对话历史
|
// Handling conversation history
|
||||||
if len(req.History) > 0 {
|
if len(req.History) > 0 {
|
||||||
// 将历史消息添加到变量中
|
// Add chat history to variable
|
||||||
variables[placeholderOfChatHistory] = req.History
|
variables[placeholderOfChatHistory] = req.History
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -71,7 +71,7 @@ func newKnowledgeTool(ctx context.Context, conf *knowledgeConfig) (tool.Invokabl
|
||||||
Type: openapi3.TypeInteger,
|
Type: openapi3.TypeInteger,
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
// 设置字段描述和枚举值
|
// Set field descriptions and enumeration values
|
||||||
schema.Description = desc
|
schema.Description = desc
|
||||||
schema.Enum = make([]interface{}, 0, len(conf.knowledgeInfos))
|
schema.Enum = make([]interface{}, 0, len(conf.knowledgeInfos))
|
||||||
for _, k := range conf.knowledgeInfos {
|
for _, k := range conf.knowledgeInfos {
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ type SingleAgentDraft struct {
|
||||||
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
||||||
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
||||||
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;comment:delete time in millisecond" json:"deleted_at"` // delete time in millisecond
|
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;comment:delete time in millisecond" json:"deleted_at"` // delete time in millisecond
|
||||||
VariablesMetaID *int64 `gorm:"column:variables_meta_id;comment:variables meta 表 ID" json:"variables_meta_id"` // variables meta 表 ID
|
VariablesMetaID *int64 `gorm:"column:variables_meta_id;comment:variables meta table ID" json:"variables_meta_id"` // variables meta table ID
|
||||||
ModelInfo *bot_common.ModelInfo `gorm:"column:model_info;comment:Model Configuration Information;serializer:json" json:"model_info"` // Model Configuration Information
|
ModelInfo *bot_common.ModelInfo `gorm:"column:model_info;comment:Model Configuration Information;serializer:json" json:"model_info"` // Model Configuration Information
|
||||||
OnboardingInfo *bot_common.OnboardingInfo `gorm:"column:onboarding_info;comment:Onboarding Information;serializer:json" json:"onboarding_info"` // Onboarding Information
|
OnboardingInfo *bot_common.OnboardingInfo `gorm:"column:onboarding_info;comment:Onboarding Information;serializer:json" json:"onboarding_info"` // Onboarding Information
|
||||||
Prompt *bot_common.PromptInfo `gorm:"column:prompt;comment:Agent Prompt Configuration;serializer:json" json:"prompt"` // Agent Prompt Configuration
|
Prompt *bot_common.PromptInfo `gorm:"column:prompt;comment:Agent Prompt Configuration;serializer:json" json:"prompt"` // Agent Prompt Configuration
|
||||||
|
|
|
||||||
|
|
@ -6,20 +6,20 @@ package model
|
||||||
|
|
||||||
const TableNameSingleAgentPublish = "single_agent_publish"
|
const TableNameSingleAgentPublish = "single_agent_publish"
|
||||||
|
|
||||||
// SingleAgentPublish bot 渠道和发布版本流水表
|
// SingleAgentPublish Bot connector and release version info
|
||||||
type SingleAgentPublish struct {
|
type SingleAgentPublish struct {
|
||||||
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:主键id" json:"id"` // 主键id
|
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:id" json:"id"` // id
|
||||||
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
||||||
PublishID string `gorm:"column:publish_id;not null;comment:发布 id" json:"publish_id"` // 发布 id
|
PublishID string `gorm:"column:publish_id;not null;comment:publish id" json:"publish_id"` // publish id
|
||||||
ConnectorIds []int64 `gorm:"column:connector_ids;comment:发布的 connector_ids;serializer:json" json:"connector_ids"` // 发布的 connector_ids
|
ConnectorIds []int64 `gorm:"column:connector_ids;comment:connector_ids;serializer:json" json:"connector_ids"` // connector_ids
|
||||||
Version string `gorm:"column:version;not null;comment:Agent Version" json:"version"` // Agent Version
|
Version string `gorm:"column:version;not null;comment:Agent Version" json:"version"` // Agent Version
|
||||||
PublishInfo *string `gorm:"column:publish_info;comment:发布信息" json:"publish_info"` // 发布信息
|
PublishInfo *string `gorm:"column:publish_info;comment:publish info" json:"publish_info"` // publish info
|
||||||
PublishTime int64 `gorm:"column:publish_time;not null;comment:发布时间" json:"publish_time"` // 发布时间
|
PublishTime int64 `gorm:"column:publish_time;not null;comment:publish time" json:"publish_time"` // publish time
|
||||||
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
||||||
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
||||||
CreatorID int64 `gorm:"column:creator_id;not null;comment:发布人 user_id" json:"creator_id"` // 发布人 user_id
|
CreatorID int64 `gorm:"column:creator_id;not null;comment:creator id" json:"creator_id"` // creator id
|
||||||
Status int32 `gorm:"column:status;not null;comment:状态 0:使用中 1:删除 3:禁用" json:"status"` // 状态 0:使用中 1:删除 3:禁用
|
Status int32 `gorm:"column:status;not null;comment:Status 0: In use 1: Delete 3: Disabled" json:"status"` // Status 0: In use 1: Delete 3: Disabled
|
||||||
Extra *string `gorm:"column:extra;comment:扩展字段" json:"extra"` // 扩展字段
|
Extra *string `gorm:"column:extra;comment:extra" json:"extra"` // extra
|
||||||
}
|
}
|
||||||
|
|
||||||
// TableName SingleAgentPublish's table name
|
// TableName SingleAgentPublish's table name
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ type SingleAgentVersion struct {
|
||||||
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
||||||
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
||||||
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;comment:delete time in millisecond" json:"deleted_at"` // delete time in millisecond
|
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;comment:delete time in millisecond" json:"deleted_at"` // delete time in millisecond
|
||||||
VariablesMetaID *int64 `gorm:"column:variables_meta_id;comment:variables meta 表 ID" json:"variables_meta_id"` // variables meta 表 ID
|
VariablesMetaID *int64 `gorm:"column:variables_meta_id;comment:variables meta table ID" json:"variables_meta_id"` // variables meta table ID
|
||||||
ModelInfo *bot_common.ModelInfo `gorm:"column:model_info;comment:Model Configuration Information;serializer:json" json:"model_info"` // Model Configuration Information
|
ModelInfo *bot_common.ModelInfo `gorm:"column:model_info;comment:Model Configuration Information;serializer:json" json:"model_info"` // Model Configuration Information
|
||||||
OnboardingInfo *bot_common.OnboardingInfo `gorm:"column:onboarding_info;comment:Onboarding Information;serializer:json" json:"onboarding_info"` // Onboarding Information
|
OnboardingInfo *bot_common.OnboardingInfo `gorm:"column:onboarding_info;comment:Onboarding Information;serializer:json" json:"onboarding_info"` // Onboarding Information
|
||||||
Prompt *bot_common.PromptInfo `gorm:"column:prompt;comment:Agent Prompt Configuration;serializer:json" json:"prompt"` // Agent Prompt Configuration
|
Prompt *bot_common.PromptInfo `gorm:"column:prompt;comment:Agent Prompt Configuration;serializer:json" json:"prompt"` // Agent Prompt Configuration
|
||||||
|
|
|
||||||
|
|
@ -70,7 +70,7 @@ type singleAgentDraft struct {
|
||||||
CreatedAt field.Int64 // Create Time in Milliseconds
|
CreatedAt field.Int64 // Create Time in Milliseconds
|
||||||
UpdatedAt field.Int64 // Update Time in Milliseconds
|
UpdatedAt field.Int64 // Update Time in Milliseconds
|
||||||
DeletedAt field.Field // delete time in millisecond
|
DeletedAt field.Field // delete time in millisecond
|
||||||
VariablesMetaID field.Int64 // variables meta 表 ID
|
VariablesMetaID field.Int64 // variables meta table ID
|
||||||
ModelInfo field.Field // Model Configuration Information
|
ModelInfo field.Field // Model Configuration Information
|
||||||
OnboardingInfo field.Field // Onboarding Information
|
OnboardingInfo field.Field // Onboarding Information
|
||||||
Prompt field.Field // Agent Prompt Configuration
|
Prompt field.Field // Agent Prompt Configuration
|
||||||
|
|
|
||||||
|
|
@ -45,23 +45,23 @@ func newSingleAgentPublish(db *gorm.DB, opts ...gen.DOOption) singleAgentPublish
|
||||||
return _singleAgentPublish
|
return _singleAgentPublish
|
||||||
}
|
}
|
||||||
|
|
||||||
// singleAgentPublish bot 渠道和发布版本流水表
|
// singleAgentPublish Bot connector and release version info
|
||||||
type singleAgentPublish struct {
|
type singleAgentPublish struct {
|
||||||
singleAgentPublishDo
|
singleAgentPublishDo
|
||||||
|
|
||||||
ALL field.Asterisk
|
ALL field.Asterisk
|
||||||
ID field.Int64 // 主键id
|
ID field.Int64 // id
|
||||||
AgentID field.Int64 // agent_id
|
AgentID field.Int64 // agent_id
|
||||||
PublishID field.String // 发布 id
|
PublishID field.String // publish id
|
||||||
ConnectorIds field.Field // 发布的 connector_ids
|
ConnectorIds field.Field // connector_ids
|
||||||
Version field.String // Agent Version
|
Version field.String // Agent Version
|
||||||
PublishInfo field.String // 发布信息
|
PublishInfo field.String // publish info
|
||||||
PublishTime field.Int64 // 发布时间
|
PublishTime field.Int64 // publish time
|
||||||
CreatedAt field.Int64 // Create Time in Milliseconds
|
CreatedAt field.Int64 // Create Time in Milliseconds
|
||||||
UpdatedAt field.Int64 // Update Time in Milliseconds
|
UpdatedAt field.Int64 // Update Time in Milliseconds
|
||||||
CreatorID field.Int64 // 发布人 user_id
|
CreatorID field.Int64 // creator id
|
||||||
Status field.Int32 // 状态 0:使用中 1:删除 3:禁用
|
Status field.Int32 // Status 0: In use 1: Delete 3: Disabled
|
||||||
Extra field.String // 扩展字段
|
Extra field.String // extra
|
||||||
|
|
||||||
fieldMap map[string]field.Expr
|
fieldMap map[string]field.Expr
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -72,7 +72,7 @@ type singleAgentVersion struct {
|
||||||
CreatedAt field.Int64 // Create Time in Milliseconds
|
CreatedAt field.Int64 // Create Time in Milliseconds
|
||||||
UpdatedAt field.Int64 // Update Time in Milliseconds
|
UpdatedAt field.Int64 // Update Time in Milliseconds
|
||||||
DeletedAt field.Field // delete time in millisecond
|
DeletedAt field.Field // delete time in millisecond
|
||||||
VariablesMetaID field.Int64 // variables meta 表 ID
|
VariablesMetaID field.Int64 // variables meta table ID
|
||||||
ModelInfo field.Field // Model Configuration Information
|
ModelInfo field.Field // Model Configuration Information
|
||||||
OnboardingInfo field.Field // Onboarding Information
|
OnboardingInfo field.Field // Onboarding Information
|
||||||
Prompt field.Field // Agent Prompt Configuration
|
Prompt field.Field // Agent Prompt Configuration
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@ import (
|
||||||
"context"
|
"context"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
// 添加这个导入以解决 gen.Expr 未定义的问题
|
// Add this import to fix the undefined issue with gen. Expr
|
||||||
|
|
||||||
"github.com/coze-dev/coze-studio/backend/domain/agent/singleagent/entity"
|
"github.com/coze-dev/coze-studio/backend/domain/agent/singleagent/entity"
|
||||||
"github.com/coze-dev/coze-studio/backend/domain/agent/singleagent/internal/dal/model"
|
"github.com/coze-dev/coze-studio/backend/domain/agent/singleagent/internal/dal/model"
|
||||||
|
|
@ -29,7 +29,7 @@ import (
|
||||||
"github.com/coze-dev/coze-studio/backend/types/errno"
|
"github.com/coze-dev/coze-studio/backend/types/errno"
|
||||||
)
|
)
|
||||||
|
|
||||||
// List 方法:分页查询发布记录 pageIndex 从1开始
|
// List method: paging query publishing records pageIndex starts at 1
|
||||||
func (dao *SingleAgentVersionDAO) List(ctx context.Context, agentID int64, pageIndex, pageSize int32) ([]*entity.SingleAgentPublish, error) {
|
func (dao *SingleAgentVersionDAO) List(ctx context.Context, agentID int64, pageIndex, pageSize int32) ([]*entity.SingleAgentPublish, error) {
|
||||||
sap := dao.dbQuery.SingleAgentPublish
|
sap := dao.dbQuery.SingleAgentPublish
|
||||||
offset := (pageIndex - 1) * pageSize
|
offset := (pageIndex - 1) * pageSize
|
||||||
|
|
|
||||||
|
|
@ -126,7 +126,7 @@ func (s *singleAgentImpl) GetPublishConnectorList(ctx context.Context, agentID i
|
||||||
} else if v.ID == consts.APIConnectorID {
|
} else if v.ID == consts.APIConnectorID {
|
||||||
c.BindType = developer_api.BindType_ApiBind
|
c.BindType = developer_api.BindType_ApiBind
|
||||||
// c.BindInfo = map[string]string{
|
// c.BindInfo = map[string]string{
|
||||||
// "sdk_version": "1.2.0-beta.6", // TODO(@fanlv): 确认版本在哪读取?
|
// "sdk_version": "1.2.0 -beta.6",//TODO (@fanlv): Where to check the version?
|
||||||
// }
|
// }
|
||||||
c.AuthLoginInfo = &developer_api.AuthLoginInfo{}
|
c.AuthLoginInfo = &developer_api.AuthLoginInfo{}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -288,7 +288,7 @@ func (s *singleAgentImpl) ListAgentPublishHistory(ctx context.Context, agentID i
|
||||||
maxCount = pageSize * pageIndex
|
maxCount = pageSize * pageIndex
|
||||||
)
|
)
|
||||||
|
|
||||||
// 全量拉取符合条件的记录
|
// Pull all eligible records
|
||||||
for {
|
for {
|
||||||
pageData, err := s.AgentVersionRepo.List(ctx, agentID, currentPage, 50)
|
pageData, err := s.AgentVersionRepo.List(ctx, agentID, currentPage, 50)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
|
|
@ -298,7 +298,7 @@ func (s *singleAgentImpl) ListAgentPublishHistory(ctx context.Context, agentID i
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
|
||||||
// 过滤当前页数据
|
// Filter current page data
|
||||||
for _, item := range pageData {
|
for _, item := range pageData {
|
||||||
for _, cID := range item.ConnectorIds {
|
for _, cID := range item.ConnectorIds {
|
||||||
if cID == *connectorID {
|
if cID == *connectorID {
|
||||||
|
|
|
||||||
|
|
@ -8,23 +8,23 @@ import "github.com/coze-dev/coze-studio/backend/api/model/crossdomain/agentrun"
|
||||||
|
|
||||||
const TableNameRunRecord = "run_record"
|
const TableNameRunRecord = "run_record"
|
||||||
|
|
||||||
// RunRecord 执行记录表
|
// RunRecord run record
|
||||||
type RunRecord struct {
|
type RunRecord struct {
|
||||||
ID int64 `gorm:"column:id;primaryKey;comment:主键ID" json:"id"` // 主键ID
|
ID int64 `gorm:"column:id;primaryKey;comment:id" json:"id"` // id
|
||||||
ConversationID int64 `gorm:"column:conversation_id;not null;comment:会话 ID" json:"conversation_id"` // 会话 ID
|
ConversationID int64 `gorm:"column:conversation_id;not null;comment:conversation id" json:"conversation_id"` // conversation id
|
||||||
SectionID int64 `gorm:"column:section_id;not null;comment:section ID" json:"section_id"` // section ID
|
SectionID int64 `gorm:"column:section_id;not null;comment:section ID" json:"section_id"` // section ID
|
||||||
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
||||||
UserID string `gorm:"column:user_id;not null;comment:user id" json:"user_id"` // user id
|
UserID string `gorm:"column:user_id;not null;comment:user id" json:"user_id"` // user id
|
||||||
Source int32 `gorm:"column:source;not null;comment:执行来源 0 API," json:"source"` // 执行来源 0 API,
|
Source int32 `gorm:"column:source;not null;comment:Execute source 0 API" json:"source"` // Execute source 0 API
|
||||||
Status string `gorm:"column:status;not null;comment:状态,0 Unknown, 1-Created,2-InProgress,3-Completed,4-Failed,5-Expired,6-Cancelled,7-RequiresAction" json:"status"` // 状态,0 Unknown, 1-Created,2-InProgress,3-Completed,4-Failed,5-Expired,6-Cancelled,7-RequiresAction
|
Status string `gorm:"column:status;not null;comment:status,0 Unknown, 1-Created,2-InProgress,3-Completed,4-Failed,5-Expired,6-Cancelled,7-RequiresAction" json:"status"` // status,0 Unknown, 1-Created,2-InProgress,3-Completed,4-Failed,5-Expired,6-Cancelled,7-RequiresAction
|
||||||
CreatorID int64 `gorm:"column:creator_id;not null;comment:创建者标识" json:"creator_id"` // 创建者标识
|
CreatorID int64 `gorm:"column:creator_id;not null;comment:creator id" json:"creator_id"` // creator id
|
||||||
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:创建时间" json:"created_at"` // 创建时间
|
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
||||||
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:更新时间" json:"updated_at"` // 更新时间
|
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
||||||
FailedAt int64 `gorm:"column:failed_at;not null;comment:失败时间" json:"failed_at"` // 失败时间
|
FailedAt int64 `gorm:"column:failed_at;not null;comment:Fail Time in Milliseconds" json:"failed_at"` // Fail Time in Milliseconds
|
||||||
LastError string `gorm:"column:last_error;comment:error message" json:"last_error"` // error message
|
LastError string `gorm:"column:last_error;comment:error message" json:"last_error"` // error message
|
||||||
CompletedAt int64 `gorm:"column:completed_at;not null;comment:结束时间" json:"completed_at"` // 结束时间
|
CompletedAt int64 `gorm:"column:completed_at;not null;comment:Finish Time in Milliseconds" json:"completed_at"` // Finish Time in Milliseconds
|
||||||
ChatRequest string `gorm:"column:chat_request;comment:保存原始请求的部分字段" json:"chat_request"` // 保存原始请求的部分字段
|
ChatRequest string `gorm:"column:chat_request;comment:Original request field" json:"chat_request"` // Original request field
|
||||||
Ext string `gorm:"column:ext;comment:扩展字段" json:"ext"` // 扩展字段
|
Ext string `gorm:"column:ext;comment:ext" json:"ext"` // ext
|
||||||
Usage *agentrun.Usage `gorm:"column:usage;comment:usage;serializer:json" json:"usage"` // usage
|
Usage *agentrun.Usage `gorm:"column:usage;comment:usage;serializer:json" json:"usage"` // usage
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -49,26 +49,26 @@ func newRunRecord(db *gorm.DB, opts ...gen.DOOption) runRecord {
|
||||||
return _runRecord
|
return _runRecord
|
||||||
}
|
}
|
||||||
|
|
||||||
// runRecord 执行记录表
|
// runRecord run record
|
||||||
type runRecord struct {
|
type runRecord struct {
|
||||||
runRecordDo
|
runRecordDo
|
||||||
|
|
||||||
ALL field.Asterisk
|
ALL field.Asterisk
|
||||||
ID field.Int64 // 主键ID
|
ID field.Int64 // id
|
||||||
ConversationID field.Int64 // 会话 ID
|
ConversationID field.Int64 // conversation id
|
||||||
SectionID field.Int64 // section ID
|
SectionID field.Int64 // section ID
|
||||||
AgentID field.Int64 // agent_id
|
AgentID field.Int64 // agent_id
|
||||||
UserID field.String // user id
|
UserID field.String // user id
|
||||||
Source field.Int32 // 执行来源 0 API,
|
Source field.Int32 // Execute source 0 API
|
||||||
Status field.String // 状态,0 Unknown, 1-Created,2-InProgress,3-Completed,4-Failed,5-Expired,6-Cancelled,7-RequiresAction
|
Status field.String // status,0 Unknown, 1-Created,2-InProgress,3-Completed,4-Failed,5-Expired,6-Cancelled,7-RequiresAction
|
||||||
CreatorID field.Int64 // 创建者标识
|
CreatorID field.Int64 // creator id
|
||||||
CreatedAt field.Int64 // 创建时间
|
CreatedAt field.Int64 // Create Time in Milliseconds
|
||||||
UpdatedAt field.Int64 // 更新时间
|
UpdatedAt field.Int64 // Update Time in Milliseconds
|
||||||
FailedAt field.Int64 // 失败时间
|
FailedAt field.Int64 // Fail Time in Milliseconds
|
||||||
LastError field.String // error message
|
LastError field.String // error message
|
||||||
CompletedAt field.Int64 // 结束时间
|
CompletedAt field.Int64 // Finish Time in Milliseconds
|
||||||
ChatRequest field.String // 保存原始请求的部分字段
|
ChatRequest field.String // Original request field
|
||||||
Ext field.String // 扩展字段
|
Ext field.String // ext
|
||||||
Usage field.Field // usage
|
Usage field.Field // usage
|
||||||
|
|
||||||
fieldMap map[string]field.Expr
|
fieldMap map[string]field.Expr
|
||||||
|
|
|
||||||
|
|
@ -326,7 +326,7 @@ func (c *runImpl) buildAgentMessage2Create(ctx context.Context, chunk *entity.Ag
|
||||||
afcMarshal, _ := json.Marshal(afc)
|
afcMarshal, _ := json.Marshal(afc)
|
||||||
msg.Content = string(afcMarshal)
|
msg.Content = string(afcMarshal)
|
||||||
|
|
||||||
// 添加 ext 用于保存到 context_message
|
// Add ext to save to context_message
|
||||||
interruptByte, err := json.Marshal(chunk.Interrupt)
|
interruptByte, err := json.Marshal(chunk.Interrupt)
|
||||||
if err == nil {
|
if err == nil {
|
||||||
buildExt[string(msgEntity.ExtKeyResumeInfo)] = string(interruptByte)
|
buildExt[string(msgEntity.ExtKeyResumeInfo)] = string(interruptByte)
|
||||||
|
|
|
||||||
|
|
@ -54,7 +54,7 @@ func TestAgentRun(t *testing.T) {
|
||||||
// content := []*entity.InputMetaData{
|
// content := []*entity.InputMetaData{
|
||||||
// {
|
// {
|
||||||
// Type: entity.InputTypeText,
|
// Type: entity.InputTypeText,
|
||||||
// Text: "你是谁",
|
// Text: "Who are you",
|
||||||
// },
|
// },
|
||||||
// {
|
// {
|
||||||
// Type: entity.InputTypeImage,
|
// Type: entity.InputTypeImage,
|
||||||
|
|
|
||||||
|
|
@ -6,18 +6,18 @@ package model
|
||||||
|
|
||||||
const TableNameConversation = "conversation"
|
const TableNameConversation = "conversation"
|
||||||
|
|
||||||
// Conversation 会话信息表
|
// Conversation conversation info record
|
||||||
type Conversation struct {
|
type Conversation struct {
|
||||||
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:主键ID" json:"id"` // 主键ID
|
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:id" json:"id"` // id
|
||||||
ConnectorID int64 `gorm:"column:connector_id;not null;comment:业务线 ID" json:"connector_id"` // 业务线 ID
|
ConnectorID int64 `gorm:"column:connector_id;not null;comment:Publish Connector ID" json:"connector_id"` // Publish Connector ID
|
||||||
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
||||||
Scene int32 `gorm:"column:scene;not null;comment:会话场景" json:"scene"` // 会话场景
|
Scene int32 `gorm:"column:scene;not null;comment:conversation scene" json:"scene"` // conversation scene
|
||||||
SectionID int64 `gorm:"column:section_id;not null;comment:最新section_id" json:"section_id"` // 最新section_id
|
SectionID int64 `gorm:"column:section_id;not null;comment:section_id" json:"section_id"` // section_id
|
||||||
CreatorID int64 `gorm:"column:creator_id;comment:创建者id" json:"creator_id"` // 创建者id
|
CreatorID int64 `gorm:"column:creator_id;comment:creator_id" json:"creator_id"` // creator_id
|
||||||
Ext string `gorm:"column:ext;comment:扩展字段" json:"ext"` // 扩展字段
|
Ext string `gorm:"column:ext;comment:ext" json:"ext"` // ext
|
||||||
Status int32 `gorm:"column:status;not null;default:1;comment:status: 1-normal 2-deleted" json:"status"` // status: 1-normal 2-deleted
|
Status int32 `gorm:"column:status;not null;default:1;comment:status: 1-normal 2-deleted" json:"status"` // status: 1-normal 2-deleted
|
||||||
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:创建时间" json:"created_at"` // 创建时间
|
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
||||||
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:更新时间" json:"updated_at"` // 更新时间
|
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
||||||
}
|
}
|
||||||
|
|
||||||
// TableName Conversation's table name
|
// TableName Conversation's table name
|
||||||
|
|
|
||||||
|
|
@ -43,21 +43,21 @@ func newConversation(db *gorm.DB, opts ...gen.DOOption) conversation {
|
||||||
return _conversation
|
return _conversation
|
||||||
}
|
}
|
||||||
|
|
||||||
// conversation 会话信息表
|
// conversation conversation info record
|
||||||
type conversation struct {
|
type conversation struct {
|
||||||
conversationDo
|
conversationDo
|
||||||
|
|
||||||
ALL field.Asterisk
|
ALL field.Asterisk
|
||||||
ID field.Int64 // 主键ID
|
ID field.Int64 // id
|
||||||
ConnectorID field.Int64 // 业务线 ID
|
ConnectorID field.Int64 // Publish Connector ID
|
||||||
AgentID field.Int64 // agent_id
|
AgentID field.Int64 // agent_id
|
||||||
Scene field.Int32 // 会话场景
|
Scene field.Int32 // conversation scene
|
||||||
SectionID field.Int64 // 最新section_id
|
SectionID field.Int64 // section_id
|
||||||
CreatorID field.Int64 // 创建者id
|
CreatorID field.Int64 // creator_id
|
||||||
Ext field.String // 扩展字段
|
Ext field.String // ext
|
||||||
Status field.Int32 // status: 1-normal 2-deleted
|
Status field.Int32 // status: 1-normal 2-deleted
|
||||||
CreatedAt field.Int64 // 创建时间
|
CreatedAt field.Int64 // Create Time in Milliseconds
|
||||||
UpdatedAt field.Int64 // 更新时间
|
UpdatedAt field.Int64 // Update Time in Milliseconds
|
||||||
|
|
||||||
fieldMap map[string]field.Expr
|
fieldMap map[string]field.Expr
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -6,27 +6,27 @@ package model
|
||||||
|
|
||||||
const TableNameMessage = "message"
|
const TableNameMessage = "message"
|
||||||
|
|
||||||
// Message 消息表
|
// Message message record
|
||||||
type Message struct {
|
type Message struct {
|
||||||
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:主键ID" json:"id"` // 主键ID
|
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:id" json:"id"` // id
|
||||||
RunID int64 `gorm:"column:run_id;not null;comment:对应的run_id" json:"run_id"` // 对应的run_id
|
RunID int64 `gorm:"column:run_id;not null;comment:run_id" json:"run_id"` // run_id
|
||||||
ConversationID int64 `gorm:"column:conversation_id;not null;comment:conversation id" json:"conversation_id"` // conversation id
|
ConversationID int64 `gorm:"column:conversation_id;not null;comment:conversation id" json:"conversation_id"` // conversation id
|
||||||
UserID string `gorm:"column:user_id;not null;comment:user id" json:"user_id"` // user id
|
UserID string `gorm:"column:user_id;not null;comment:user id" json:"user_id"` // user id
|
||||||
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
AgentID int64 `gorm:"column:agent_id;not null;comment:agent_id" json:"agent_id"` // agent_id
|
||||||
Role string `gorm:"column:role;not null;comment:角色: user、assistant、system" json:"role"` // 角色: user、assistant、system
|
Role string `gorm:"column:role;not null;comment:role: user、assistant、system" json:"role"` // role: user、assistant、system
|
||||||
ContentType string `gorm:"column:content_type;not null;comment:内容类型 1 text" json:"content_type"` // 内容类型 1 text
|
ContentType string `gorm:"column:content_type;not null;comment:content type 1 text" json:"content_type"` // content type 1 text
|
||||||
Content string `gorm:"column:content;comment:内容" json:"content"` // 内容
|
Content string `gorm:"column:content;comment:content" json:"content"` // content
|
||||||
MessageType string `gorm:"column:message_type;not null;comment:消息类型:" json:"message_type"` // 消息类型:
|
MessageType string `gorm:"column:message_type;not null;comment:message_type" json:"message_type"` // message_type
|
||||||
DisplayContent string `gorm:"column:display_content;comment:展示内容" json:"display_content"` // 展示内容
|
DisplayContent string `gorm:"column:display_content;comment:display content" json:"display_content"` // display content
|
||||||
Ext string `gorm:"column:ext;comment:message 扩展字段" json:"ext"` // message 扩展字段
|
Ext string `gorm:"column:ext;comment:message ext" json:"ext"` // message ext
|
||||||
SectionID int64 `gorm:"column:section_id;comment:段落id" json:"section_id"` // 段落id
|
SectionID int64 `gorm:"column:section_id;comment:section_id" json:"section_id"` // section_id
|
||||||
BrokenPosition int32 `gorm:"column:broken_position;default:-1;comment:打断位置" json:"broken_position"` // 打断位置
|
BrokenPosition int32 `gorm:"column:broken_position;default:-1;comment:broken position" json:"broken_position"` // broken position
|
||||||
Status int32 `gorm:"column:status;not null;comment:消息状态 1 Available 2 Deleted 3 Replaced 4 Broken 5 Failed 6 Streaming 7 Pending" json:"status"` // 消息状态 1 Available 2 Deleted 3 Replaced 4 Broken 5 Failed 6 Streaming 7 Pending
|
Status int32 `gorm:"column:status;not null;comment:message status: 1 Available 2 Deleted 3 Replaced 4 Broken 5 Failed 6 Streaming 7 Pending" json:"status"` // message status: 1 Available 2 Deleted 3 Replaced 4 Broken 5 Failed 6 Streaming 7 Pending
|
||||||
ModelContent string `gorm:"column:model_content;comment:模型输入内容" json:"model_content"` // 模型输入内容
|
ModelContent string `gorm:"column:model_content;comment:model content" json:"model_content"` // model content
|
||||||
MetaInfo string `gorm:"column:meta_info;comment:引用、高亮等文本标记信息" json:"meta_info"` // 引用、高亮等文本标记信息
|
MetaInfo string `gorm:"column:meta_info;comment:text tagging information such as citation and highlighting" json:"meta_info"` // text tagging information such as citation and highlighting
|
||||||
ReasoningContent string `gorm:"column:reasoning_content;comment:思考内容" json:"reasoning_content"` // 思考内容
|
ReasoningContent string `gorm:"column:reasoning_content;comment:reasoning content" json:"reasoning_content"` // reasoning content
|
||||||
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:创建时间" json:"created_at"` // 创建时间
|
CreatedAt int64 `gorm:"column:created_at;not null;autoCreateTime:milli;comment:Create Time in Milliseconds" json:"created_at"` // Create Time in Milliseconds
|
||||||
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:更新时间" json:"updated_at"` // 更新时间
|
UpdatedAt int64 `gorm:"column:updated_at;not null;autoUpdateTime:milli;comment:Update Time in Milliseconds" json:"updated_at"` // Update Time in Milliseconds
|
||||||
}
|
}
|
||||||
|
|
||||||
// TableName Message's table name
|
// TableName Message's table name
|
||||||
|
|
|
||||||
|
|
@ -52,30 +52,30 @@ func newMessage(db *gorm.DB, opts ...gen.DOOption) message {
|
||||||
return _message
|
return _message
|
||||||
}
|
}
|
||||||
|
|
||||||
// message 消息表
|
// message message record
|
||||||
type message struct {
|
type message struct {
|
||||||
messageDo
|
messageDo
|
||||||
|
|
||||||
ALL field.Asterisk
|
ALL field.Asterisk
|
||||||
ID field.Int64 // 主键ID
|
ID field.Int64 // id
|
||||||
RunID field.Int64 // 对应的run_id
|
RunID field.Int64 // run_id
|
||||||
ConversationID field.Int64 // conversation id
|
ConversationID field.Int64 // conversation id
|
||||||
UserID field.String // user id
|
UserID field.String // user id
|
||||||
AgentID field.Int64 // agent_id
|
AgentID field.Int64 // agent_id
|
||||||
Role field.String // 角色: user、assistant、system
|
Role field.String // role: user、assistant、system
|
||||||
ContentType field.String // 内容类型 1 text
|
ContentType field.String // content type 1 text
|
||||||
Content field.String // 内容
|
Content field.String // content
|
||||||
MessageType field.String // 消息类型:
|
MessageType field.String // message_type
|
||||||
DisplayContent field.String // 展示内容
|
DisplayContent field.String // display content
|
||||||
Ext field.String // message 扩展字段
|
Ext field.String // message ext
|
||||||
SectionID field.Int64 // 段落id
|
SectionID field.Int64 // section_id
|
||||||
BrokenPosition field.Int32 // 打断位置
|
BrokenPosition field.Int32 // broken position
|
||||||
Status field.Int32 // 消息状态 1 Available 2 Deleted 3 Replaced 4 Broken 5 Failed 6 Streaming 7 Pending
|
Status field.Int32 // message status: 1 Available 2 Deleted 3 Replaced 4 Broken 5 Failed 6 Streaming 7 Pending
|
||||||
ModelContent field.String // 模型输入内容
|
ModelContent field.String // model content
|
||||||
MetaInfo field.String // 引用、高亮等文本标记信息
|
MetaInfo field.String // text tagging information such as citation and highlighting
|
||||||
ReasoningContent field.String // 思考内容
|
ReasoningContent field.String // reasoning content
|
||||||
CreatedAt field.Int64 // 创建时间
|
CreatedAt field.Int64 // Create Time in Milliseconds
|
||||||
UpdatedAt field.Int64 // 更新时间
|
UpdatedAt field.Int64 // Update Time in Milliseconds
|
||||||
|
|
||||||
fieldMap map[string]field.Expr
|
fieldMap map[string]field.Expr
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@
|
||||||
package entity
|
package entity
|
||||||
|
|
||||||
type CopyDataTask struct {
|
type CopyDataTask struct {
|
||||||
TaskUniqKey string // 复制任务的唯一标志
|
TaskUniqKey string // Unique sign of a replication task
|
||||||
OriginDataID int64
|
OriginDataID int64
|
||||||
TargetDataID int64
|
TargetDataID int64
|
||||||
OriginSpaceID int64
|
OriginSpaceID int64
|
||||||
|
|
@ -28,10 +28,10 @@ type CopyDataTask struct {
|
||||||
TargetAppID int64
|
TargetAppID int64
|
||||||
Status DataCopyTaskStatus
|
Status DataCopyTaskStatus
|
||||||
DataType DataType
|
DataType DataType
|
||||||
StartTime int64 // 任务开始时间ms
|
StartTime int64 // Task start time ms
|
||||||
FinishTime int64 // 任务结束时间ms
|
FinishTime int64 // Task end time ms
|
||||||
ExtInfo string
|
ExtInfo string
|
||||||
ErrorMsg string // 复制失败的错误信息
|
ErrorMsg string // Copy failed error message
|
||||||
}
|
}
|
||||||
type DataCopyTaskStatus int
|
type DataCopyTaskStatus int
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,23 +6,23 @@ package model
|
||||||
|
|
||||||
const TableNameDataCopyTask = "data_copy_task"
|
const TableNameDataCopyTask = "data_copy_task"
|
||||||
|
|
||||||
// DataCopyTask data方向复制任务记录表
|
// DataCopyTask data copy task record
|
||||||
type DataCopyTask struct {
|
type DataCopyTask struct {
|
||||||
MasterTaskID string `gorm:"column:master_task_id;not null;comment:复制任务ID" json:"master_task_id"` // 复制任务ID
|
MasterTaskID string `gorm:"column:master_task_id;comment:task id" json:"master_task_id"` // task id
|
||||||
OriginDataID int64 `gorm:"column:origin_data_id;not null;comment:源id" json:"origin_data_id"` // 源id
|
OriginDataID int64 `gorm:"column:origin_data_id;not null;comment:origin data id" json:"origin_data_id"` // origin data id
|
||||||
TargetDataID int64 `gorm:"column:target_data_id;not null;comment:目标id" json:"target_data_id"` // 目标id
|
TargetDataID int64 `gorm:"column:target_data_id;not null;comment:target data id" json:"target_data_id"` // target data id
|
||||||
OriginSpaceID int64 `gorm:"column:origin_space_id;not null;comment:源团队空间" json:"origin_space_id"` // 源团队空间
|
OriginSpaceID int64 `gorm:"column:origin_space_id;not null;comment:origin space id" json:"origin_space_id"` // origin space id
|
||||||
TargetSpaceID int64 `gorm:"column:target_space_id;not null;comment:目标团队空间" json:"target_space_id"` // 目标团队空间
|
TargetSpaceID int64 `gorm:"column:target_space_id;not null;comment:target space id" json:"target_space_id"` // target space id
|
||||||
OriginUserID int64 `gorm:"column:origin_user_id;not null;comment:源用户ID" json:"origin_user_id"` // 源用户ID
|
OriginUserID int64 `gorm:"column:origin_user_id;not null;comment:origin user id" json:"origin_user_id"` // origin user id
|
||||||
TargetUserID int64 `gorm:"column:target_user_id;not null;comment:目标用户ID" json:"target_user_id"` // 目标用户ID
|
TargetUserID int64 `gorm:"column:target_user_id;comment:target user id" json:"target_user_id"` // target user id
|
||||||
OriginAppID int64 `gorm:"column:origin_app_id;not null;comment:源AppID" json:"origin_app_id"` // 源AppID
|
OriginAppID int64 `gorm:"column:origin_app_id;not null;comment:origin app id" json:"origin_app_id"` // origin app id
|
||||||
TargetAppID int64 `gorm:"column:target_app_id;not null;comment:目标AppID" json:"target_app_id"` // 目标AppID
|
TargetAppID int64 `gorm:"column:target_app_id;not null;comment:target app id" json:"target_app_id"` // target app id
|
||||||
DataType int32 `gorm:"column:data_type;not null;comment:数据类型 1:knowledge, 2:database" json:"data_type"` // 数据类型 1:knowledge, 2:database
|
DataType int32 `gorm:"column:data_type;not null;comment:data type 1:knowledge, 2:database" json:"data_type"` // data type 1:knowledge, 2:database
|
||||||
ExtInfo string `gorm:"column:ext_info;not null;comment:存储额外信息" json:"ext_info"` // 存储额外信息
|
ExtInfo string `gorm:"column:ext_info;not null;comment:ext" json:"ext_info"` // ext
|
||||||
StartTime int64 `gorm:"column:start_time;not null;comment:任务开始时间" json:"start_time"` // 任务开始时间
|
StartTime int64 `gorm:"column:start_time;comment:task start time" json:"start_time"` // task start time
|
||||||
FinishTime int64 `gorm:"column:finish_time;comment:任务结束时间" json:"finish_time"` // 任务结束时间
|
FinishTime int64 `gorm:"column:finish_time;comment:task finish time" json:"finish_time"` // task finish time
|
||||||
Status int32 `gorm:"column:status;not null;default:1;comment:1:创建 2:执行中 3:成功 4:失败" json:"status"` // 1:创建 2:执行中 3:成功 4:失败
|
Status int32 `gorm:"column:status;not null;default:1;comment:1: Create 2: Running 3: Success 4: Failure" json:"status"` // 1: Create 2: Running 3: Success 4: Failure
|
||||||
ErrorMsg string `gorm:"column:error_msg;comment:错误信息" json:"error_msg"` // 错误信息
|
ErrorMsg string `gorm:"column:error_msg;comment:error msg" json:"error_msg"` // error msg
|
||||||
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:ID" json:"id"` // ID
|
ID int64 `gorm:"column:id;primaryKey;autoIncrement:true;comment:ID" json:"id"` // ID
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -49,26 +49,26 @@ func newDataCopyTask(db *gorm.DB, opts ...gen.DOOption) dataCopyTask {
|
||||||
return _dataCopyTask
|
return _dataCopyTask
|
||||||
}
|
}
|
||||||
|
|
||||||
// dataCopyTask data方向复制任务记录表
|
// dataCopyTask data copy task record
|
||||||
type dataCopyTask struct {
|
type dataCopyTask struct {
|
||||||
dataCopyTaskDo
|
dataCopyTaskDo
|
||||||
|
|
||||||
ALL field.Asterisk
|
ALL field.Asterisk
|
||||||
MasterTaskID field.String // 复制任务ID
|
MasterTaskID field.String // task id
|
||||||
OriginDataID field.Int64 // 源id
|
OriginDataID field.Int64 // origin data id
|
||||||
TargetDataID field.Int64 // 目标id
|
TargetDataID field.Int64 // target data id
|
||||||
OriginSpaceID field.Int64 // 源团队空间
|
OriginSpaceID field.Int64 // origin space id
|
||||||
TargetSpaceID field.Int64 // 目标团队空间
|
TargetSpaceID field.Int64 // target space id
|
||||||
OriginUserID field.Int64 // 源用户ID
|
OriginUserID field.Int64 // origin user id
|
||||||
TargetUserID field.Int64 // 目标用户ID
|
TargetUserID field.Int64 // target user id
|
||||||
OriginAppID field.Int64 // 源AppID
|
OriginAppID field.Int64 // origin app id
|
||||||
TargetAppID field.Int64 // 目标AppID
|
TargetAppID field.Int64 // target app id
|
||||||
DataType field.Int32 // 数据类型 1:knowledge, 2:database
|
DataType field.Int32 // data type 1:knowledge, 2:database
|
||||||
ExtInfo field.String // 存储额外信息
|
ExtInfo field.String // ext
|
||||||
StartTime field.Int64 // 任务开始时间
|
StartTime field.Int64 // task start time
|
||||||
FinishTime field.Int64 // 任务结束时间
|
FinishTime field.Int64 // task finish time
|
||||||
Status field.Int32 // 1:创建 2:执行中 3:成功 4:失败
|
Status field.Int32 // 1: Create 2: Running 3: Success 4: Failure
|
||||||
ErrorMsg field.String // 错误信息
|
ErrorMsg field.String // error msg
|
||||||
ID field.Int64 // ID
|
ID field.Int64 // ID
|
||||||
|
|
||||||
fieldMap map[string]field.Expr
|
fieldMap map[string]field.Expr
|
||||||
|
|
|
||||||
|
|
@ -59,7 +59,7 @@ func (svc *dataCopySVC) CheckAndGenCopyTask(ctx context.Context, req *datacopy.C
|
||||||
}
|
}
|
||||||
var err error
|
var err error
|
||||||
resp := datacopy.CheckAndGenCopyTaskResp{}
|
resp := datacopy.CheckAndGenCopyTaskResp{}
|
||||||
// 检查是否已经存在任务
|
// Check if a task already exists
|
||||||
task, err := svc.dataCopyTaskRepo.GetCopyTask(ctx, req.Task.TaskUniqKey, req.Task.OriginDataID, int32(req.Task.DataType))
|
task, err := svc.dataCopyTaskRepo.GetCopyTask(ctx, req.Task.TaskUniqKey, req.Task.OriginDataID, int32(req.Task.DataType))
|
||||||
if err != nil && !errors.Is(err, gorm.ErrRecordNotFound) {
|
if err != nil && !errors.Is(err, gorm.ErrRecordNotFound) {
|
||||||
return nil, err
|
return nil, err
|
||||||
|
|
|
||||||
|
|
@ -19,14 +19,14 @@ package entity
|
||||||
type DocumentStatus int64
|
type DocumentStatus int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
DocumentStatusInit DocumentStatus = -1 // 初始化
|
DocumentStatusInit DocumentStatus = -1 // initialization
|
||||||
DocumentStatusUploading DocumentStatus = 0 // 上传中
|
DocumentStatusUploading DocumentStatus = 0 // Uploading
|
||||||
DocumentStatusEnable DocumentStatus = 1 // 生效
|
DocumentStatusEnable DocumentStatus = 1 // take effect
|
||||||
DocumentStatusDisable DocumentStatus = 2 // 失效
|
DocumentStatusDisable DocumentStatus = 2 // failure
|
||||||
DocumentStatusDeleted DocumentStatus = 3 // 已删除
|
DocumentStatusDeleted DocumentStatus = 3 // deleted
|
||||||
DocumentStatusChunking DocumentStatus = 4 // 切片中
|
DocumentStatusChunking DocumentStatus = 4 // Slicing
|
||||||
// DocumentStatusRefreshing DocumentStatus = 5 // 刷新中
|
// DocumentStatusRefreshing DocumentStatus = 5//Refreshing
|
||||||
DocumentStatusFailed DocumentStatus = 9 // 失败
|
DocumentStatusFailed DocumentStatus = 9 // fail
|
||||||
)
|
)
|
||||||
|
|
||||||
func (s DocumentStatus) String() string {
|
func (s DocumentStatus) String() string {
|
||||||
|
|
@ -44,7 +44,7 @@ func (s DocumentStatus) String() string {
|
||||||
case DocumentStatusChunking:
|
case DocumentStatusChunking:
|
||||||
return "切片中"
|
return "切片中"
|
||||||
// case DocumentStatusRefreshing:
|
// case DocumentStatusRefreshing:
|
||||||
// return "刷新中"
|
// Returns "Refreshing"
|
||||||
case DocumentStatusFailed:
|
case DocumentStatusFailed:
|
||||||
return "失败"
|
return "失败"
|
||||||
default:
|
default:
|
||||||
|
|
@ -55,6 +55,6 @@ func (s DocumentStatus) String() string {
|
||||||
type DocumentSource int64
|
type DocumentSource int64
|
||||||
|
|
||||||
const (
|
const (
|
||||||
DocumentSourceLocal DocumentSource = 0 // 本地文件上传
|
DocumentSourceLocal DocumentSource = 0 // local file upload
|
||||||
DocumentSourceCustom DocumentSource = 2 // 自定义文本
|
DocumentSourceCustom DocumentSource = 2 // custom text
|
||||||
)
|
)
|
||||||
|
|
|
||||||
|
|
@ -27,25 +27,25 @@ type Document struct {
|
||||||
|
|
||||||
KnowledgeID int64
|
KnowledgeID int64
|
||||||
Type knowledge.DocumentType
|
Type knowledge.DocumentType
|
||||||
RawContent string // 用户自定义的原始内容
|
RawContent string // User-defined original content
|
||||||
URI string // 文档 uri
|
URI string // Document URI
|
||||||
URL string // 文档 url
|
URL string // Document URL
|
||||||
Size int64 // 文档 bytes
|
Size int64 // Document bytes
|
||||||
SliceCount int64 // slice 数量
|
SliceCount int64 // Number of slices
|
||||||
CharCount int64 // 文档字符数
|
CharCount int64 // Number of document characters
|
||||||
FileExtension parser.FileExtension // 文档后缀, csv/pdf...
|
FileExtension parser.FileExtension // Document suffix, csv/pdf...
|
||||||
Status DocumentStatus // 文档状态
|
Status DocumentStatus // Document Status
|
||||||
StatusMsg string // 文档状态详细信息
|
StatusMsg string // Document Status Details
|
||||||
Hits int64 // 命中次数
|
Hits int64 // hit count
|
||||||
Source DocumentSource // 文档来源
|
Source DocumentSource // document source
|
||||||
ParsingStrategy *ParsingStrategy // 解析策略
|
ParsingStrategy *ParsingStrategy // parsing strategy
|
||||||
ChunkingStrategy *ChunkingStrategy // 分段策略
|
ChunkingStrategy *ChunkingStrategy // segmentation strategy
|
||||||
|
|
||||||
TableInfo TableInfo
|
TableInfo TableInfo
|
||||||
IsAppend bool // 是否在表格中追加
|
IsAppend bool // Whether to append to the table
|
||||||
|
|
||||||
// LevelURI string // 层级分段预览 uri
|
// LevelURI string//Hierarchical segmentation preview uri
|
||||||
// PreviewURI string // 预览 uri
|
// PreviewURI string//preview uri
|
||||||
}
|
}
|
||||||
|
|
||||||
type TableInfo struct {
|
type TableInfo struct {
|
||||||
|
|
@ -56,18 +56,18 @@ type TableInfo struct {
|
||||||
}
|
}
|
||||||
type TableSheet struct {
|
type TableSheet struct {
|
||||||
SheetId int64 // sheet id
|
SheetId int64 // sheet id
|
||||||
HeaderLineIdx int64 // 表头行
|
HeaderLineIdx int64 // header row
|
||||||
StartLineIdx int64 // 数据起始行
|
StartLineIdx int64 // Data start row
|
||||||
SheetName string // sheet的名称
|
SheetName string // Name of sheet
|
||||||
TotalRows int64 // 总行数
|
TotalRows int64 // total number of rows
|
||||||
}
|
}
|
||||||
type TableColumn struct {
|
type TableColumn struct {
|
||||||
ID int64
|
ID int64
|
||||||
Name string
|
Name string
|
||||||
Type document.TableColumnType
|
Type document.TableColumnType
|
||||||
Description string
|
Description string
|
||||||
Indexing bool // 是否索引
|
Indexing bool // whether to index
|
||||||
Sequence int64 // 表格中的原始序号
|
Sequence int64 // The original serial number in the table
|
||||||
}
|
}
|
||||||
|
|
||||||
type WhereDocumentOpt struct {
|
type WhereDocumentOpt struct {
|
||||||
|
|
|
||||||
|
|
@ -29,20 +29,20 @@ type Event struct {
|
||||||
|
|
||||||
type EventType string
|
type EventType string
|
||||||
|
|
||||||
// 文档 event
|
// Document event
|
||||||
// 切分 + 写入向量库操作事务性由实现自行保证
|
// Split + write vector library operation transactionality is guaranteed by the implementation itself
|
||||||
const (
|
const (
|
||||||
EventTypeIndexDocuments EventType = "index_documents"
|
EventTypeIndexDocuments EventType = "index_documents"
|
||||||
|
|
||||||
// EventTypeIndexDocument 文档信息已写入 orm,逻辑中需要解析+切分+搜索数据入库
|
// EventTypeIndexDocument document information has been written to orm, the logic needs to parse + split + search data warehousing
|
||||||
// Event requires: Event.Document
|
// Event requires: Event.Document
|
||||||
EventTypeIndexDocument EventType = "index_document"
|
EventTypeIndexDocument EventType = "index_document"
|
||||||
|
|
||||||
// EventTypeIndexSlice 切片信息已写入 orm,逻辑中仅写入搜索数据
|
// EventTypeIndexSlice slice information has been written to orm, and only search data is written in the logic
|
||||||
// Event requires: Event.Slice
|
// Event requires: Event.Slice
|
||||||
EventTypeIndexSlice EventType = "index_slice"
|
EventTypeIndexSlice EventType = "index_slice"
|
||||||
|
|
||||||
// EventTypeDeleteKnowledgeData 删除 knowledge
|
// EventTypeDeleteKnowledgeData remove knowledge
|
||||||
// Event requires: Event.KnowledgeID, Event.SliceIDs
|
// Event requires: Event.KnowledgeID, Event.SliceIDs
|
||||||
EventTypeDeleteKnowledgeData EventType = "delete_knowledge_data"
|
EventTypeDeleteKnowledgeData EventType = "delete_knowledge_data"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -26,10 +26,10 @@ type WhereKnowledgeOption struct {
|
||||||
KnowledgeIDs []int64
|
KnowledgeIDs []int64
|
||||||
AppID *int64
|
AppID *int64
|
||||||
SpaceID *int64
|
SpaceID *int64
|
||||||
Name *string // 完全匹配
|
Name *string // Exact match
|
||||||
Status []int32
|
Status []int32
|
||||||
UserID *int64
|
UserID *int64
|
||||||
Query *string // 模糊匹配
|
Query *string // fuzzy match
|
||||||
Page *int
|
Page *int
|
||||||
PageSize *int
|
PageSize *int
|
||||||
Order *Order
|
Order *Order
|
||||||
|
|
|
||||||
|
|
@ -25,18 +25,18 @@ type RetrievalStrategy = knowledge.RetrievalStrategy
|
||||||
|
|
||||||
// ParsingStrategy for document parse before indexing
|
// ParsingStrategy for document parse before indexing
|
||||||
type ParsingStrategy struct {
|
type ParsingStrategy struct {
|
||||||
ParsingType ParsingType `json:"parsing_type"` // 解析类型
|
ParsingType ParsingType `json:"parsing_type"` // parse type
|
||||||
// Doc
|
// Doc
|
||||||
ExtractImage bool `json:"extract_image"` // 提取图片元素
|
ExtractImage bool `json:"extract_image"` // Extract image elements
|
||||||
ExtractTable bool `json:"extract_table"` // 提取表格元素
|
ExtractTable bool `json:"extract_table"` // Extract table elements
|
||||||
ImageOCR bool `json:"image_ocr"` // 图片 ocr
|
ImageOCR bool `json:"image_ocr"` // Image ocr
|
||||||
FilterPages []int `json:"filter_pages"` // 过滤页数
|
FilterPages []int `json:"filter_pages"` // filter pages
|
||||||
|
|
||||||
// Sheet
|
// Sheet
|
||||||
SheetID int64 `json:"sheet_id"` // xlsx sheet id
|
SheetID int64 `json:"sheet_id"` // xlsx sheet id
|
||||||
HeaderLine int `json:"header_line"` // 表头行
|
HeaderLine int `json:"header_line"` // header row
|
||||||
DataStartLine int `json:"data_start_line"` // 数据起始行
|
DataStartLine int `json:"data_start_line"` // Data start row
|
||||||
RowsCount int `json:"rows_count"` // 读取数据行数
|
RowsCount int `json:"rows_count"` // number of rows read
|
||||||
|
|
||||||
// Image
|
// Image
|
||||||
CaptionType *parser.ImageAnnotationType `json:"caption_type"`
|
CaptionType *parser.ImageAnnotationType `json:"caption_type"`
|
||||||
|
|
@ -52,13 +52,13 @@ const (
|
||||||
type ChunkingStrategy struct {
|
type ChunkingStrategy struct {
|
||||||
ChunkType parser.ChunkType `json:"chunk_type"`
|
ChunkType parser.ChunkType `json:"chunk_type"`
|
||||||
// custom chunk config
|
// custom chunk config
|
||||||
ChunkSize int64 `json:"chunk_size"` // 分段最大长度
|
ChunkSize int64 `json:"chunk_size"` // maximum segmentation length
|
||||||
Separator string `json:"separator"` // 分段标识符
|
Separator string `json:"separator"` // segmentation identifier
|
||||||
Overlap int64 `json:"overlap"` // 分段重叠
|
Overlap int64 `json:"overlap"` // segmented overlap
|
||||||
TrimSpace bool `json:"trim_space"`
|
TrimSpace bool `json:"trim_space"`
|
||||||
TrimURLAndEmail bool `json:"trim_url_and_email"`
|
TrimURLAndEmail bool `json:"trim_url_and_email"`
|
||||||
|
|
||||||
// 按层级分段
|
// segmentation by hierarchy
|
||||||
MaxDepth int64 `json:"max_depth"` // 按层级分段时的最大层级
|
MaxDepth int64 `json:"max_depth"` // Maximum level when segmented by level
|
||||||
SaveTitle bool `json:"save_title"` // 保留层级标题
|
SaveTitle bool `json:"save_title"` // Preserve Hierarchical Titles
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -132,12 +132,12 @@ func (dao *KnowledgeDocumentDAO) DeleteDocuments(ctx context.Context, ids []int6
|
||||||
tx.Commit()
|
tx.Commit()
|
||||||
}
|
}
|
||||||
}()
|
}()
|
||||||
// 删除document
|
// Delete document
|
||||||
err = tx.WithContext(ctx).Model(&model.KnowledgeDocument{}).Where("id in ?", ids).Delete(&model.KnowledgeDocument{}).Error
|
err = tx.WithContext(ctx).Model(&model.KnowledgeDocument{}).Where("id in ?", ids).Delete(&model.KnowledgeDocument{}).Error
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
}
|
}
|
||||||
// 删除document_slice
|
// Delete document_slice
|
||||||
err = tx.WithContext(ctx).Model(&model.KnowledgeDocumentSlice{}).Where("document_id in?", ids).Delete(&model.KnowledgeDocumentSlice{}).Error
|
err = tx.WithContext(ctx).Model(&model.KnowledgeDocumentSlice{}).Where("document_id in?", ids).Delete(&model.KnowledgeDocumentSlice{}).Error
|
||||||
if err != nil {
|
if err != nil {
|
||||||
return err
|
return err
|
||||||
|
|
|
||||||
|
|
@ -120,7 +120,7 @@ func (dao *KnowledgeDocumentSliceDAO) listBatch(ctx context.Context, knowledgeID
|
||||||
pos []*model.KnowledgeDocumentSlice, hasMore bool, err error) {
|
pos []*model.KnowledgeDocumentSlice, hasMore bool, err error) {
|
||||||
|
|
||||||
if batchSize <= 0 {
|
if batchSize <= 0 {
|
||||||
batchSize = 100 // 默认批量大小
|
batchSize = 100 // Default batch size
|
||||||
}
|
}
|
||||||
|
|
||||||
do, err := dao.listDo(ctx, knowledgeID, documentID)
|
do, err := dao.listDo(ctx, knowledgeID, documentID)
|
||||||
|
|
@ -161,7 +161,7 @@ func (dao *KnowledgeDocumentSliceDAO) GetDocumentSliceIDs(ctx context.Context, d
|
||||||
if len(docIDs) == 0 {
|
if len(docIDs) == 0 {
|
||||||
return nil, errors.New("empty document ids")
|
return nil, errors.New("empty document ids")
|
||||||
}
|
}
|
||||||
// doc可能会有很多slice,所以批量处理
|
// Doc may have many slices, so batch processing
|
||||||
sliceIDs = make([]int64, 0)
|
sliceIDs = make([]int64, 0)
|
||||||
var mu sync.Mutex
|
var mu sync.Mutex
|
||||||
errGroup, ctx := errgroup.WithContext(ctx)
|
errGroup, ctx := errgroup.WithContext(ctx)
|
||||||
|
|
|
||||||
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue