feat(web): AI 文档查询卡片重构与单号判定统一

- documentClassification 抽出 isApplicationDocumentNo,统一兼容 AP-/APP- 旧格式与 A+8 新格式,aiDocumentQueryModel 复用
- aiDocumentQueryModel 文档卡片改为结构化字段布局(单据类型/金额/申请人/编号/操作),新增查询范围摘要区,渲染走 HTML 信任块
- AppShellRouteView/useAppShell/useRequests/detailAlerts/riskVisibility 等差旅详情模型适配单号判定
- 同步更新 ai-document-query-model/workbench-ai-mode-switch 测试,新增 document-classification 测试
This commit is contained in:
caoxiaozhu
2026-06-20 22:04:37 +08:00
parent 8158716e23
commit 3b74a330a3
17 changed files with 348 additions and 209 deletions

View File

@@ -10,6 +10,7 @@ import { fetchOntologyParse } from '../services/ontology.js'
import { fetchLatestConversation } from '../services/orchestrator.js'
import { markAiWorkbenchConversationDraftDeleted } from '../utils/aiWorkbenchConversationStore.js'
import { clearAssistantSessionSnapshotForDraftClaim } from '../utils/assistantSessionSnapshot.js'
import { isApplicationDocumentNo } from '../utils/documentClassification.js'
import {
ASSISTANT_SCOPE_SESSION_STEWARD,
buildUnsupportedBusinessScopeConversation,
@@ -428,8 +429,7 @@ export function useAppShell() {
return (
documentType === 'application'
|| documentType === 'expense_application'
|| normalizedClaimNo.startsWith('AP-')
|| normalizedClaimNo.startsWith('APP-')
|| isApplicationDocumentNo(normalizedClaimNo)
)
}