feat: 知识库匹配模式选择
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
import { Schema, model, models, Model as MongoModel } from 'mongoose';
|
||||
import { ModelSchema as ModelType } from '@/types/mongoSchema';
|
||||
import { ModelVectorSearchModeMap, ModelVectorSearchModeEnum } from '@/constants/model';
|
||||
|
||||
const ModelSchema = new Schema({
|
||||
userId: {
|
||||
type: Schema.Types.ObjectId,
|
||||
@@ -43,6 +45,13 @@ const ModelSchema = new Schema({
|
||||
max: 10,
|
||||
default: 4
|
||||
},
|
||||
search: {
|
||||
mode: {
|
||||
type: String,
|
||||
enum: Object.keys(ModelVectorSearchModeMap),
|
||||
default: ModelVectorSearchModeEnum.hightSimilarity
|
||||
}
|
||||
},
|
||||
service: {
|
||||
company: {
|
||||
type: String,
|
||||
|
||||
Reference in New Issue
Block a user