Browse Source

add: 修正所有控制命令都为图文识别类型bug

zhongwei
haungxing 2 months ago
parent
commit
b7f4a49a8c
  1. 2
      hzims-service/gglm-big-model/src/main/java/com/hnac/gglm/bigmodel/database/service/WeaviateService.java
  2. 1
      hzims-service/gglm-big-model/src/main/java/com/hnac/gglm/bigmodel/interactive/constants/FunctionConstants.java
  3. 4
      hzims-service/gglm-big-model/src/main/java/com/hnac/gglm/bigmodel/interactive/service/impl/ControlAnswerResolveServiceImpl.java

2
hzims-service/gglm-big-model/src/main/java/com/hnac/gglm/bigmodel/database/service/WeaviateService.java

@ -219,7 +219,7 @@ public class WeaviateService {
if(Func.isNotEmpty(className)) { if(Func.isNotEmpty(className)) {
objectsGetter.withClassName(className); objectsGetter.withClassName(className);
} }
Result<List<WeaviateObject>> result = objectsGetter.withVector().withLimit(pageSize).withOffset((current-1) * pageSize).run(); Result<List<WeaviateObject>> result = objectsGetter.withLimit(pageSize).withOffset((current-1) * pageSize).run();
if(result.hasErrors()) { if(result.hasErrors()) {
throw new HzServiceException("查询失败!"); throw new HzServiceException("查询失败!");
} }

1
hzims-service/gglm-big-model/src/main/java/com/hnac/gglm/bigmodel/interactive/constants/FunctionConstants.java

@ -27,7 +27,6 @@ public interface FunctionConstants {
CHART("6"), CHART("6"),
IMAGE_TEXT("7") IMAGE_TEXT("7")
; ;
;
@Getter @Getter
private String type; private String type;

4
hzims-service/gglm-big-model/src/main/java/com/hnac/gglm/bigmodel/interactive/service/impl/ControlAnswerResolveServiceImpl.java

@ -47,10 +47,12 @@ public class ControlAnswerResolveServiceImpl implements IAnswerResolveService {
String body = HttpRequest.post(url).body(JSON.toJSONString(param)).execute().body(); String body = HttpRequest.post(url).body(JSON.toJSONString(param)).execute().body();
params.put("data",body); params.put("data",body);
log.info("识别结果为:{}", body); log.info("识别结果为:{}", body);
ExtraVO result = originExtra.toJavaObject(ExtraVO.class);
result.setType(FunctionConstants.TypeEnum.IMAGE_TEXT.getType());
return result;
} }
} }
ExtraVO result = originExtra.toJavaObject(ExtraVO.class); ExtraVO result = originExtra.toJavaObject(ExtraVO.class);
result.setType(FunctionConstants.TypeEnum.IMAGE_TEXT.getType());
return result; return result;
} }
} }

Loading…
Cancel
Save