|
@@ -401,12 +401,16 @@ public class CrmCustomerAnalyzeServiceImpl extends ServiceImpl<CrmCustomerAnalyz
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
@Override
|
|
@Override
|
|
|
- public String aiIntentionDegree(String content, Long chatId) throws JsonProcessingException {
|
|
|
|
|
|
|
+ public String aiIntentionDegree(String content, Long chatId) {
|
|
|
Map<String, Object> requestParam = new HashMap<>();
|
|
Map<String, Object> requestParam = new HashMap<>();
|
|
|
-
|
|
|
|
|
- List<Map<String, Object>> maps = mapper.readValue(content,
|
|
|
|
|
- new com.fasterxml.jackson.core.type.TypeReference<List<Map<String, Object>>>() {
|
|
|
|
|
- });
|
|
|
|
|
|
|
+ List<Map<String, Object>> maps = new ArrayList<>();
|
|
|
|
|
+ try {
|
|
|
|
|
+ maps = mapper.readValue(content,
|
|
|
|
|
+ new com.fasterxml.jackson.core.type.TypeReference<List<Map<String, Object>>>() {
|
|
|
|
|
+ });
|
|
|
|
|
+ }catch (JsonProcessingException e){
|
|
|
|
|
+ log.error("聊天对话图数据格式错误");
|
|
|
|
|
+ }
|
|
|
maps.remove(0);//去除提示词
|
|
maps.remove(0);//去除提示词
|
|
|
StringBuilder history = new StringBuilder();
|
|
StringBuilder history = new StringBuilder();
|
|
|
history.append("{");
|
|
history.append("{");
|