feat(escort): 病历与诉求支持多材料解析为四段摘要
新增独立病历整理 Agent 与异步解析任务,支持 PDF 文本、图片 OCR、 语音 ASR 与文字输入,统一整理为基础健康、检查治疗、用药和问诊诉求。 Agent 只产出草稿,订单本人在编辑页核对确认后才写入当前订单; 原件在任务结束、失败或取消时立即清除。 inquiry 增加三段规范字段,medicalHistory 保留为旧版兼容摘要, 并兼容旧客户端只写 medicalHistory 的更新方式。
This commit is contained in:
@@ -11,6 +11,7 @@ import { TrainingApplicationSchema } from "./schema/training_application.js"
|
||||
import { AttendantApplicationSchema } from "./schema/attendant_application.js"
|
||||
import { PaymentRecordSchema } from "./schema/payment_record.js"
|
||||
import { RefundRecordSchema } from "./schema/refund_record.js"
|
||||
import { InquiryParseJobSchema } from "./schema/inquiry_parse_job.js"
|
||||
import config from '../config.js';
|
||||
import logger from '../utils/logger.js';
|
||||
|
||||
@@ -27,6 +28,7 @@ class MongoDBSchema {
|
||||
this.AttendantApplication = null;
|
||||
this.PaymentRecord = null;
|
||||
this.RefundRecord = null;
|
||||
this.InquiryParseJob = null;
|
||||
}
|
||||
|
||||
init() {
|
||||
@@ -62,6 +64,7 @@ class MongoDBSchema {
|
||||
this.AttendantApplication = this.dbConnection.model('attendant_application', AttendantApplicationSchema)
|
||||
this.PaymentRecord = this.dbConnection.model('payment_record', PaymentRecordSchema)
|
||||
this.RefundRecord = this.dbConnection.model('refund_record', RefundRecordSchema)
|
||||
this.InquiryParseJob = this.dbConnection.model('inquiry_parse_job', InquiryParseJobSchema)
|
||||
|
||||
// 索引创建失败(如唯一索引遇到存量重复)时 mongoose 会 emit('error'),
|
||||
// 而 EventEmitter 对没有监听器的 'error' 事件会直接抛未捕获异常,
|
||||
|
||||
Reference in New Issue
Block a user