This commit is contained in:
董宏凯 committed 2026-06-16 22:01:18 +08:00
commit 7afdf5b363
13 files changed
+176 -28

No files matched your search

+12 -1
View File
@@ -176,10 +176,21 @@ function BatchImportDialog({
skip_existing: skipExisting,
status: "approved",
include_sources: true,
// Run in the background so the request returns immediately — a large
// batch otherwise blocks past the gateway timeout and shows "request
// failed". Threads stream into the list as they finish.
background: true,
model_name: model,
template_id: template,
folder,
});
if (result.queued) {
toast.success(
`已转入后台导入 ${result.processed} 个线程,完成后会陆续出现在左侧列表(可稍后刷新查看)`,
);
onOpenChange(false);
return;
}
const base = `批量导入完成:新增 ${result.created},跳过 ${result.skipped},失败 ${result.failed}`;
if (result.llm_fallback && result.llm_fallback > 0) {
// The model failed on some threads — they were saved via rule-based
@@ -549,7 +560,7 @@ export default function KnowledgeBasePage() {
keyword: debouncedKeyword || undefined,
source_type: sourceType === "all" ? undefined : sourceType,
status: status === "all" ? undefined : status,
limit: 500,
limit: 1000,
}),
[debouncedKeyword, sourceType, status],
);