chore: align ai stack with openhub weknora
This commit is contained in:
@@ -1473,7 +1473,7 @@ export const createResourceTabRuntime = (dependencies = {}) => {
|
||||
};
|
||||
|
||||
const knowledgeRagProvider = () => {
|
||||
return 'lightrag';
|
||||
return 'weknora';
|
||||
};
|
||||
|
||||
const setKnowledgeRagStatus = (entry, status, message, job) => {
|
||||
@@ -1521,7 +1521,7 @@ export const createResourceTabRuntime = (dependencies = {}) => {
|
||||
sourceRootRelativePath,
|
||||
rootUri: String(registryEntry.rootUri || rootUri || '').trim(),
|
||||
artifactRootRelativePath: '',
|
||||
provider: 'lightrag',
|
||||
provider: knowledgeRagProvider(),
|
||||
status,
|
||||
stageLabel: status === 'done' ? '资料库已索引' : status === 'failed' ? '资料库需重建' : '资料库索引中',
|
||||
stale: registryEntry.stale === true,
|
||||
@@ -1901,7 +1901,7 @@ export const createResourceTabRuntime = (dependencies = {}) => {
|
||||
};
|
||||
|
||||
const insertRetiredOcrLink = async (entry, job) => {
|
||||
throw new Error('OCR sidecar 已退役,请使用 LightRAG 资料库引用与问答。');
|
||||
throw new Error('OCR sidecar 已退役,请使用知识库引用与问答。');
|
||||
};
|
||||
|
||||
const createKnowledgeRagIngestTask = async (entry) => {
|
||||
@@ -1909,7 +1909,7 @@ export const createResourceTabRuntime = (dependencies = {}) => {
|
||||
const entryRootUri = String(entry.rootUri || '').trim();
|
||||
if (entryRootUri) knowledgeRagTaskState.rootUri = entryRootUri;
|
||||
const startedAt = Date.now();
|
||||
const pendingJob = knowledgeRagTaskSnapshotFromEntry(entry, 'running', 'lightrag', '资料库索引中', startedAt);
|
||||
const pendingJob = knowledgeRagTaskSnapshotFromEntry(entry, 'running', knowledgeRagProvider(), '资料库索引中', startedAt);
|
||||
pendingJob.taskKind = 'knowledge_rag';
|
||||
setKnowledgeRagStatus(entry, 'running', '资料库索引中', pendingJob);
|
||||
updateKnowledgeRagTaskState(pendingJob);
|
||||
@@ -1945,7 +1945,7 @@ export const createResourceTabRuntime = (dependencies = {}) => {
|
||||
const job = knowledgeRagJobFromRegistryEntry(registryEntry, entryRootUri) || {
|
||||
...pendingJob,
|
||||
status: payload.retryRequired ? 'running' : 'done',
|
||||
stageLabel: payload.retryRequired ? 'LightRAG 忙碌,等待重试' : '资料库已提交索引',
|
||||
stageLabel: payload.retryRequired ? '知识库忙碌,等待重试' : '资料库已提交索引',
|
||||
updatedAtMs: Date.now(),
|
||||
finishedAtMs: payload.retryRequired ? null : Date.now(),
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user