mirror of
https://github.com/danny-avila/LibreChat.git
synced 2025-09-22 08:12:00 +02:00
handle bing message refusal
This commit is contained in:
parent
ea4180f22a
commit
5568a60174
3 changed files with 5 additions and 4 deletions
1
.gitignore
vendored
1
.gitignore
vendored
|
@ -33,6 +33,7 @@ client/public/main.js.LICENSE.txt
|
||||||
# Deployed apps should consider commenting these lines out:
|
# Deployed apps should consider commenting these lines out:
|
||||||
# see https://npmjs.org/doc/faq.html#Should-I-check-my-node_modules-folder-into-git
|
# see https://npmjs.org/doc/faq.html#Should-I-check-my-node_modules-folder-into-git
|
||||||
node_modules/
|
node_modules/
|
||||||
|
meili_data/
|
||||||
api/node_modules/
|
api/node_modules/
|
||||||
client/node_modules/
|
client/node_modules/
|
||||||
bower_components/
|
bower_components/
|
||||||
|
|
|
@ -117,8 +117,8 @@ const ask = async ({
|
||||||
);
|
);
|
||||||
conversationId = userMessage.conversationId;
|
conversationId = userMessage.conversationId;
|
||||||
|
|
||||||
response.text = response.response;
|
response.text = response.response || response.details.spokenText || '**Bing refused to answer.**';
|
||||||
delete response.response;
|
// delete response.response;
|
||||||
// response.id = response.details.messageId;
|
// response.id = response.details.messageId;
|
||||||
response.suggestions =
|
response.suggestions =
|
||||||
response.details.suggestedResponses &&
|
response.details.suggestedResponses &&
|
||||||
|
|
|
@ -111,8 +111,8 @@ const ask = async ({
|
||||||
response.conversationSignature = convo.conversationSignature
|
response.conversationSignature = convo.conversationSignature
|
||||||
? convo.conversationSignature
|
? convo.conversationSignature
|
||||||
: crypto.randomUUID();
|
: crypto.randomUUID();
|
||||||
response.text = response.response;
|
response.text = response.response || response.details.spokenText || '**Bing refused to answer.**';
|
||||||
delete response.response;
|
// delete response.response;
|
||||||
response.suggestions =
|
response.suggestions =
|
||||||
response.details.suggestedResponses &&
|
response.details.suggestedResponses &&
|
||||||
response.details.suggestedResponses.map((s) => s.text);
|
response.details.suggestedResponses.map((s) => s.text);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue