diff --git a/server/src/utils/store.ts b/server/src/utils/store.ts index c104fd43..32161808 100644 --- a/server/src/utils/store.ts +++ b/server/src/utils/store.ts @@ -94,8 +94,10 @@ export class DialoqbaseVectorStore extends VectorStore { k: number, filter?: this["FilterType"] | undefined ): Promise<[Document>, number][]> { - console.log(this.botId); - const vector = `[${query.join(",")}]`; + if (!query) { + return []; + } + const vector = `[${query?.join(",")}]`; const bot_id = this.botId; const botInfo = await prisma.bot.findFirst({