fix: load member list (#2536)

* fix: load member list

* fix: extract field type error

* fix: workflow runtime error

* fix: ts
This commit is contained in:
Archer
2024-08-27 12:07:57 +08:00
committed by GitHub
parent 77e6cf4157
commit f6e2d13e21
13 changed files with 50 additions and 36 deletions

View File

@@ -27,6 +27,7 @@ export function addStatisticalDataToHistoryItem(historyItem: ChatItemType) {
return item;
})
.flat() || [];
return {
...historyItem,
llmModuleAccount: flatResData.filter(isLLMNode).length,
@@ -36,7 +37,7 @@ export function addStatisticalDataToHistoryItem(historyItem: ChatItemType) {
.flat()
.filter(Boolean) as SearchDataResponseItemType[],
totalRunningTime: Number(
flatResData.reduce((sum, item) => sum + (item.runningTime || 0), 0).toFixed(2)
historyItem.responseData?.reduce((sum, item) => sum + (item.runningTime || 0), 0).toFixed(2)
),
historyPreviewLength: flatResData.find(isLLMNode)?.historyPreview?.length
};