new(all): Auto import for logo, colors and website content.
This commit is contained in:
parent
e18094fd5e
commit
039805de05
1 changed files with 11 additions and 8 deletions
|
@ -264,15 +264,18 @@ export class ChatServices {
|
|||
|
||||
const docsContext = min['vectorStore'];
|
||||
|
||||
const memory = new BufferWindowMemory({
|
||||
returnMessages: true,
|
||||
memoryKey: 'chat_history',
|
||||
inputKey: 'input',
|
||||
k: 2
|
||||
});
|
||||
|
||||
let memory;
|
||||
if (user && !this.memoryMap[user.userSystemId]) {
|
||||
this.memoryMap[user.userSystemId] = memory;
|
||||
this.memoryMap[user.userSystemId] = new BufferWindowMemory({
|
||||
returnMessages: true,
|
||||
memoryKey: 'chat_history',
|
||||
inputKey: 'input',
|
||||
k: 2
|
||||
});
|
||||
}
|
||||
else
|
||||
{
|
||||
memory = this.memoryMap[user.userSystemId]
|
||||
}
|
||||
|
||||
const systemPrompt = user ? this.userSystemPrompt[user.userSystemId] : '';
|
||||
|
|
Loading…
Add table
Reference in a new issue