Переглянути джерело

宁波手麻分支合入北仑dev分支

rengb 4 роки тому
батько
коміт
5cfa285fc2

+ 1 - 9
kernel/src/main/java/com/lantone/qc/kernel/analysis/QCAnalysis.java

@@ -35,22 +35,17 @@ public class QCAnalysis {
     @Autowired
     SimilarityServiceClient similarityServiceClient;
 
-    //质控分析接口
     public OutputInfo anlysis(QueryVo queryVo) throws AIException, CatalogueException, Exception {
-        //1.创建两个ThreadLocal存储数据
+        log.error("json:"+ FastJsonUtils.getBeanToJson(queryVo));
         specialStorageUtil.getHospitalIdThreadLocal().set(queryVo.getHospitalId());
         specialStorageUtil.getBehospitalInfoThreadLocal().set(queryVo.getBehospitalInfo());
-        //2.创建输出结果集
         OutputInfo outputInfo = new OutputInfo();
         long t1 = System.currentTimeMillis();
-        //3.得到质控病历录入对象
         InputInfo inputInfo = TransDispatch.trans(queryVo);
         long t2 = System.currentTimeMillis();
-        //4.设置质控病历录入对象缓存、
         inputInfo.setUseCrfCache(queryVo.isUseCrfCache());
         inputInfo.setInputCatalogueMap(queryVo.getInputCatalogueMap());
         AIAnalyze aiAnalyze = new AIAnalyze(crfServiceClient, similarityServiceClient);
-        //5.质控录入数据过CRF ai模型(完善InputInfo用户相关信息)
         try {
             aiAnalyze.aiProcess(inputInfo);
         } catch (Exception e) {
@@ -59,8 +54,6 @@ public class QCAnalysis {
             throw new AIException("AI模型执行错误:" + e.getMessage());
         }
         long t3 = System.currentTimeMillis();
-        //6.遍历所有质控条目集合id,获取指定质控条目执行
-        log.error("json"+FastJsonUtils.getBeanToJson(inputInfo));
         for (Map.Entry<String, Map<String, String>> entry : inputInfo.getInputCatalogueMap().entrySet()) {
             if (CatalogueUtil.qcCatalogueMap.get(queryVo.getCid() + "." + entry.getKey()) == null) {
                 continue;
@@ -101,5 +94,4 @@ public class QCAnalysis {
         return outputInfo;
     }
 
-
 }

+ 0 - 6
kernel/src/main/java/com/lantone/qc/kernel/structure/ai/AIAnalyze.java

@@ -23,17 +23,11 @@ public class AIAnalyze {
     }
 
     public void aiProcess(InputInfo inputInfo) {
-        //入院记录
         beHospitalizedAI.medrec(inputInfo, crfServiceClient);
-        //首次病程录
         firstCourseRecordAI.medrec(inputInfo, crfServiceClient, similarityServiceClient);
-        //出院小结
         leaveHospitalAI.medrec(inputInfo, crfServiceClient);
-        //查房记录
         threeLevelWardAI.medrec(inputInfo, crfServiceClient);
-        //手术记录,术后首次病程及谈话记录
         operationAI.medrec(inputInfo, crfServiceClient);
-        //会诊记录
         consultationAI.medrec(inputInfo, crfServiceClient);
     }
 

+ 11 - 12
kernel/src/main/java/com/lantone/qc/kernel/structure/ai/model/Lemma.java

@@ -16,18 +16,17 @@ import java.util.List;
 @Getter
 @Setter
 public class Lemma {
-    private int id;		                                    //实体id
-    private String text;		                            //实体内容文本
-    private String position;	                            //实体位置
-    private int from;		                                //实体起始位置
-    private int to;		                                    //实体终止位置
-    private int len;		                                //实体文本长度
-    private String property;	                            //实体类别,如疾病名称、身体部位
-    private String relationName;                            //关系名称
-    private Lemma parent;		                            //父类实体信息,如头痛三天,头痛为临床表现实体,是三天(时间)实体的父实体
-    private boolean haveChildren = false;                   //是否包含子实体信息,与上述逻辑一致
-    private List<Lemma> relationLemmas = new ArrayList<>(); //与该实体有关系的所有实体列表
-
+    private int id;
+    private String text;
+    private String position;
+    private int from;
+    private int to;
+    private int len;
+    private String property;
+    private String relationName;
+    private Lemma parent;
+    private boolean haveChildren = false;
+    private List<Lemma> relationLemmas = new ArrayList<>();
 
     public void addRelationLemmas(Lemma lemma) {
         this.relationLemmas.add(lemma);

+ 1 - 1
kernel/src/main/java/com/lantone/qc/kernel/structure/ai/process/EntityProcess.java

@@ -284,7 +284,7 @@ public class EntityProcess {
             if (lemma.getProperty().equals(EntityEnum.TIME.toString())) {
                 PD pd = new PD();
                 value = lemma.getText();
-                String[] valUnit = new String[2];
+                String[] valUnit = new String[2];;
                 if (value.trim().length() > 0) {
                     valUnit = CatalogueUtil.extractDigit(value);
                 }

+ 0 - 6
kernel/src/main/java/com/lantone/qc/kernel/util/CatalogueUtil.java

@@ -629,10 +629,4 @@ public class CatalogueUtil {
         return "";
     }
 
-
-    public static void main(String args[])
-    {
-
-    }
-
 }

+ 4 - 4
public/src/main/java/com/lantone/qc/pub/model/entity/Diag.java

@@ -14,8 +14,8 @@ import lombok.Setter;
 @Setter
 public class Diag extends General {
     private String hospitalDiagName;    //医院疾病名称
-    private Possible possible;          //可能性
-    private Negative negative;          //阴性
-    private PD pd;                      //疾病进展
-    private String ICD;                 //疾病编码
+    private Possible possible;
+    private Negative negative;
+    private PD pd;
+    private String ICD;
 }

+ 2 - 2
public/src/main/java/com/lantone/qc/pub/model/entity/PD.java

@@ -6,6 +6,6 @@ import lombok.Setter;
 @Setter
 @Getter
 public class PD extends General {
-    private String value; //值
-    private String unit;  //单位
+    private String value;
+    private String unit;
 }

+ 2 - 2
public/src/main/java/com/lantone/qc/pub/model/label/ChiefLabel.java

@@ -18,8 +18,8 @@ import java.util.List;
 @Setter
 @Getter
 public class ChiefLabel extends GeneralLabel {
-    private List<Clinical> clinicals; //临床表现
-    private List<Diag> diags;         //诊断
+    private List<Clinical> clinicals;
+    private List<Diag> diags;
     //现病史中所有时间实体存入
     private List<PD> pds = new ArrayList<>();
 }

+ 1 - 1
public/src/main/java/com/lantone/qc/pub/model/label/PastLabel.java

@@ -22,7 +22,7 @@ public class PastLabel extends GeneralLabel{
     private List<Allergy> allergies = new ArrayList<>();//过敏史
     private List<AllergyFood> allergyFoods = new ArrayList<>();//食物过敏史
     private List<AllergyMedicine> allergyMedicines = new ArrayList<>();//药物过敏史
-    private List<AllergyDesc> allergyDescs = new ArrayList<>();//过敏表现
+    private List<AllergyDesc> allergyDescs = new ArrayList<>();
     private List<BloodTransfusion> bloodTransfusions = new ArrayList<>();//输血史
     private List<Operation> operations = new ArrayList<>();//手术史
     private List<Vaccinate> vaccinates = new ArrayList<>();//预防接种史

+ 0 - 2
trans/src/main/java/com/lantone/qc/trans/TransDispatch.java

@@ -19,7 +19,6 @@ public class TransDispatch {
 
     public static InputInfo trans(QueryVo queryVo) {
         try {
-//            com.lantone.qc.trans.beilun.BeilunDocTrans
             String classPath = "com.lantone.qc.trans."
                     + queryVo.getCid()
                     + "."
@@ -27,7 +26,6 @@ public class TransDispatch {
                     + queryVo.getCid().substring(1)
                     + "DocTrans";
             DocTrans docTrans = (DocTrans) Class.forName(classPath).newInstance();
-            //将大标题里面的内容取出封装成小标题:MedrecVo装进MedrecVo
             queryDeal(queryVo, "会诊", "会诊申请单", "会诊结果单", "会诊记录");
             queryDeal(queryVo, "手术", "术前讨论、术前小结", "手术记录", "术后首次病程及谈话记录");
             queryDeal(queryVo, "转科", "转入记录", "转出记录", "转科记录");

+ 0 - 4
trans/src/main/java/com/lantone/qc/trans/beilun/util/BeiLunBeHospitalizedHtmlAnalysis.java

@@ -8,11 +8,7 @@ import lombok.extern.slf4j.Slf4j;
 import org.jsoup.Jsoup;
 import org.jsoup.nodes.Document;
 import org.jsoup.nodes.Element;
-import org.jsoup.select.Elements;
 
-import java.awt.*;
-import java.io.File;
-import java.io.IOException;
 import java.util.List;
 import java.util.Map;
 

+ 0 - 1
trans/src/main/java/com/lantone/qc/trans/comsis/ModelDocGenerate.java

@@ -489,5 +489,4 @@ public class ModelDocGenerate {
         return textJoin;
     }
 
-
 }