feat: inject search result doc in the response, not the query
this is to handle when we have multiple models selected or regenerate a response, it'll only add it to the model's response and not add dupes on the user message
This commit is contained in:
@@ -327,11 +327,10 @@
|
||||
messages = messages;
|
||||
return;
|
||||
}
|
||||
const parentMessage = history.messages[parentId];
|
||||
if (!parentMessage.files) {
|
||||
parentMessage.files = [];
|
||||
if (!responseMessage.files) {
|
||||
responseMessage.files = [];
|
||||
}
|
||||
parentMessage.files.push({
|
||||
responseMessage.files.push({
|
||||
collection_name: searchDocument!.collection_name,
|
||||
name: searchQuery,
|
||||
type: 'websearch',
|
||||
|
||||
Reference in New Issue
Block a user