mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-11 12:07:42 +00:00
add constructTagQueryReq for dict (#807)
This commit is contained in:
@@ -1,6 +1,7 @@
|
||||
package com.tencent.supersonic.headless.api.pojo.request;
|
||||
|
||||
import com.google.common.collect.Lists;
|
||||
import com.tencent.supersonic.common.pojo.enums.QueryType;
|
||||
import com.tencent.supersonic.headless.api.pojo.Cache;
|
||||
import com.tencent.supersonic.headless.api.pojo.Param;
|
||||
import lombok.Data;
|
||||
@@ -23,6 +24,8 @@ public abstract class SemanticQueryReq {
|
||||
|
||||
protected String dataSetName;
|
||||
|
||||
protected QueryType queryType;
|
||||
|
||||
protected Set<Long> modelIds = new HashSet<>();
|
||||
|
||||
protected List<Param> params = new ArrayList<>();
|
||||
|
||||
@@ -32,7 +32,7 @@ public class DictItemResp {
|
||||
@NotNull
|
||||
private StatusEnum status;
|
||||
|
||||
public String getNature() {
|
||||
public String generateNature() {
|
||||
return UNDERLINE + modelId + UNDERLINE + itemId + UNDERLINE + type.name().toLowerCase().substring(0, 1)
|
||||
+ DICT_VALUE;
|
||||
|
||||
@@ -41,4 +41,5 @@ public class DictItemResp {
|
||||
public String fetchDictFileName() {
|
||||
return String.format("dic_value_%d_%s_%s", modelId, type.name(), itemId);
|
||||
}
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user