@@ -1,10 +1,12 @@
import type { IUser, Ref, HasObjectId } from '@growi/core';
+import type { AiAssistant } from './ai-assistant';
import type { IVectorStore } from './vector-store';
export interface IThreadRelation {
userId: Ref<IUser>
vectorStore: Ref<IVectorStore>
+ aiAssistant: Ref<AiAssistant>
threadId: string;
title?: string;
expiredAt: Date;
@@ -25,6 +25,11 @@ const schema = new Schema<ThreadRelationDocument, ThreadRelationModel>({
ref: 'User',
required: true,
},
+ aiAssistant: {
+ type: Schema.Types.ObjectId,
+ ref: 'AiAssistant',
+ required: true,
+ },
vectorStore: {
type: Schema.Types.ObjectId,
ref: 'VectorStore',