feat: cites text with links

This commit is contained in:
Daniel Avila 2023-03-09 20:29:44 -05:00
parent a286f027c8
commit d0ecaabfd8
5 changed files with 13 additions and 6 deletions

View file

@ -42,7 +42,7 @@ router.post('/', async (req, res) => {
console.log('BING RESPONSE');
// console.dir(response, { depth: null });
const hasCitations = citationRegex.test(response.response);
const hasCitations = response.response.match(citationRegex)?.length > 0;
userMessage.conversationSignature =
convo.conversationSignature || response.conversationSignature;

View file

@ -43,7 +43,7 @@ router.post('/', async (req, res) => {
console.log('SYDNEY RESPONSE');
console.log(response.response);
// console.dir(response, { depth: null });
const hasCitations = citationRegex.test(response.response);
const hasCitations = response.response.match(citationRegex)?.length > 0;
// Save sydney response
response.id = response.messageId;