优化检索引用连接展示,避免url解析错误

This commit is contained in:
Vinlic 2024-04-17 12:18:17 +08:00
parent e1b7e55e70
commit ae8e8316e4

View File

@ -610,7 +610,7 @@ async function receiveStream(model: string, convId: string, stream: any) {
}
// 处理联网搜索
else if (!silentSearch && result.event == 'search_plus' && result.msg && result.msg.type == 'get_res')
refContent += `${result.msg.title}(${result.msg.url})\n`;
refContent += `${result.msg.title} - ${result.msg.url}\n`;
// else
// logger.warn(result.event, result);
}
@ -707,7 +707,7 @@ function createTransStream(model: string, convId: string, stream: any, endCallba
choices: [
{
index: 0, delta: {
content: `检索 ${result.msg.title}(${result.msg.url}) ...\n`
content: `检索 ${result.msg.title} - ${result.msg.url} ...\n`
}, finish_reason: null
}
],