* perf: some log, chatTest histories slice; http request failed tip

* fix: ssr render

* perf: if else node ui and fix value type select
This commit is contained in:
Archer
2024-05-07 15:27:05 +08:00
committed by GitHub
parent 2053bbdb1b
commit 8f9203c053
21 changed files with 164 additions and 137 deletions

View File

@@ -1,3 +1,4 @@
import { addLog } from '../../../common/system/log';
import { POST } from '../../../common/api/serverRequest';
type PostReRankResponse = {
@@ -38,7 +39,7 @@ export function reRankRecall({
}
)
.then((data) => {
console.log('rerank time:', Date.now() - start);
addLog.info('ReRank finish:', { time: Date.now() - start });
return data?.results?.map((item) => ({
id: documents[item.index].id,
@@ -46,7 +47,7 @@ export function reRankRecall({
}));
})
.catch((err) => {
console.log('rerank error:', err);
addLog.error('rerank error', err);
return [];
});