diff --git a/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/ocr/controller/OcrSimulatorController.java b/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/ocr/controller/OcrSimulatorController.java index 727a0f4..ea1c52b 100644 --- a/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/ocr/controller/OcrSimulatorController.java +++ b/jeecg-module-system/jeecg-system-biz/src/main/java/org/jeecg/modules/ocr/controller/OcrSimulatorController.java @@ -24,6 +24,7 @@ import javax.annotation.Resource; import java.math.BigDecimal; import java.math.RoundingMode; import java.util.ArrayList; +import java.util.Arrays; import java.util.Date; import java.util.List; @@ -77,6 +78,15 @@ public class OcrSimulatorController{ ocrIdentifyDetail.setImageUrl(uploadFilePath + "/" + image);//图片地址 semanticRequestBody.put("img_path", uploadFilePath + "/" + image); } + if(ocrIdentify.getTaskType()!=null&&ocrIdentify.equals("1699246961812586497")){ + semanticRequestBody.put("scenes",1); + List schema=new ArrayList<>(); + schema.add("姓名");schema.add("年龄");schema.add("主要症状");schema.add("体征");schema.add("入院时主要症状和体征"); + semanticRequestBody.put("schema",schema); + }else{ + semanticRequestBody.put("scenes",0); + } + JSONObject semanticResponseJson = RestUtil.post(OcrConstant.api_test2_identify_url, semanticRequestBody); //执行时间 调整小数点 Double nluTime = semanticResponseJson.getDouble("nlu_time");