fix 舆情自动化图片分析代码

This commit is contained in:
lxu75
2025-03-10 20:15:10 +08:00
parent e27c66da84
commit 6f35bab7cc
2 changed files with 3 additions and 2 deletions

View File

@@ -1,5 +1,6 @@
package com.volvo.ai.analytic.center.service.impl;
import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;
import com.volvo.ai.analytic.center.dto.req.DiFyReq;
import com.volvo.ai.analytic.center.feign.DiFyFeign;
@@ -24,7 +25,7 @@ public class DiFyServiceImpl implements DiFyService{
map.put("inputs",diFyReq.getInputs());
map.put("response_mode","blocking");
map.put("user",diFyReq.getUser());
log.info("请求DiFy入参:{}",JSON.toJSONString(map));
log.info("请求DiFy入参:{}", JSON.toJSONString(map));
JSONObject difyResult = diFyFeign.runWorkflows("Bearer "+diFyReq.getFlowId(),map);
log.info("请求DiFy响应结果:{}",difyResult.toJSONString());
JSONObject data = difyResult.getJSONObject("data");

View File

@@ -111,7 +111,7 @@ public class MqMessageRecordServiceImpl extends ServiceImpl<MqMessageRecordMappe
diFyImageReq.setFlowId(imageFlowId);
JSONObject imageInputs = new JSONObject();
imageInputs.put("image", JSON.toJSONString(diFyImageWorkFlow));
diFyImageReq.setInputs(imageInputs.toJSONString());
diFyImageReq.setInputs(imageInputs);
//调用dify图片分析workflow
JSONObject difImageResult = (JSONObject) diFyService.getDiFyObject(diFyImageReq);