提交
This commit is contained in:
@@ -8,9 +8,11 @@ import (
|
|||||||
|
|
||||||
// CreateChatReq 创建对话配置请求
|
// CreateChatReq 创建对话配置请求
|
||||||
type CreateChatReq struct {
|
type CreateChatReq struct {
|
||||||
Name string `json:"name"` // 对话配置名称
|
Name string `json:"name"` // 对话配置名称(助理姓名)
|
||||||
DatasetIds []string `json:"dataset_ids"` // 关联的知识库ID列表
|
Description string `json:"description,omitempty"` // 助理描述
|
||||||
Prompt *PromptConfig `json:"prompt"` // 提示词配置
|
DatasetIds []string `json:"dataset_ids"` // 关联的知识库ID列表
|
||||||
|
Prompt *PromptConfig `json:"prompt"` // 提示词配置
|
||||||
|
Llm *Llm `json:"llm,omitempty"` // LLM配置
|
||||||
}
|
}
|
||||||
|
|
||||||
// PromptConfig 提示词配置
|
// PromptConfig 提示词配置
|
||||||
@@ -19,10 +21,10 @@ type PromptConfig struct {
|
|||||||
SimilarityThreshold float64 `json:"similarity_threshold"` // 相似度阈值
|
SimilarityThreshold float64 `json:"similarity_threshold"` // 相似度阈值
|
||||||
KeywordsSimilarityWeight float64 `json:"keywords_similarity_weight"` // 关键词相似度权重
|
KeywordsSimilarityWeight float64 `json:"keywords_similarity_weight"` // 关键词相似度权重
|
||||||
TopN int `json:"top_n"` // 返回顶部N个chunk
|
TopN int `json:"top_n"` // 返回顶部N个chunk
|
||||||
EmptyResponse string `json:"empty_response"` // 无匹配时回复
|
EmptyResponse string `json:"empty_response"` // 无匹配时回复(必须显式传入空字符串才能让LLM自由发挥,不传入会使用RAGFlow默认提示词)
|
||||||
Opener string `json:"opener"` // 开场白
|
Opener string `json:"opener,omitempty"` // 开场白
|
||||||
ShowQuote bool `json:"show_quote"` // 是否显示引用
|
ShowQuote bool `json:"show_quote,omitempty"` // 是否显示引用
|
||||||
Variables []map[string]interface{} `json:"variables"` // 变量列表
|
Variables []map[string]interface{} `json:"variables,omitempty"` // 变量列表
|
||||||
}
|
}
|
||||||
|
|
||||||
// CreateChatRes 创建对话配置响应
|
// CreateChatRes 创建对话配置响应
|
||||||
|
|||||||
Reference in New Issue
Block a user