public static final class DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig extends GeneratedMessageV3 implements DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfigOrBuilder
Filter on the confidence score. Only adds to index if the confidence
score is higher than the threshold.
Example data schema:
key: "name-confidence-pair"
type: CUSTOMIZED_STRUCT
granularity: GRANULARITY_PARTITION_LEVEL
customized_struct_config {
field_schemas {
key: "name"
type: STRING
granularity: GRANULARITY_PARTITION_LEVEL
search_strategy {
search_strategy_type: SMART_SEARCH
confidence_score_index_config {
field_path: "name-confidence-pair.score"
threshold: 0.6
}
}
}
field_schemas {
key: "score"
type: FLOAT
granularity: GRANULARITY_PARTITION_LEVEL
}
}
This means only "name" with score > 0.6 will be indexed.
Protobuf type
google.cloud.visionai.v1.DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig
Inherited Members
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT)
com.google.protobuf.GeneratedMessageV3.<ListT>makeMutableCopy(ListT,int)
com.google.protobuf.GeneratedMessageV3.<T>emptyList(java.lang.Class<T>)
com.google.protobuf.GeneratedMessageV3.internalGetMapFieldReflection(int)
Static Fields
FIELD_PATH_FIELD_NUMBER
public static final int FIELD_PATH_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
THRESHOLD_FIELD_NUMBER
public static final int THRESHOLD_FIELD_NUMBER
Field Value |
Type |
Description |
int |
|
Static Methods
getDefaultInstance()
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig getDefaultInstance()
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
newBuilder()
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig.Builder newBuilder()
newBuilder(DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig prototype)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig.Builder newBuilder(DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig prototype)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseDelimitedFrom(InputStream input)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(byte[] data)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(byte[] data)
Parameter |
Name |
Description |
data |
byte[]
|
parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteString data)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(ByteString data)
parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(CodedInputStream input)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(InputStream input)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
parseFrom(ByteBuffer data)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(ByteBuffer data)
parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
public static DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
parser()
public static Parser<DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig> parser()
Methods
equals(Object obj)
public boolean equals(Object obj)
Parameter |
Name |
Description |
obj |
Object
|
Overrides
getDefaultInstanceForType()
public DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig getDefaultInstanceForType()
getFieldPath()
public String getFieldPath()
Required. The path to the confidence score field. It is a string that
concatenates all the data schema keys along the path. See the example
above. If the data schema contains LIST, use '_ENTRIES' to concatenate.
Example data schema contains a list:
"key": "list-name-score",
"schemaDetails": {
"type": "LIST",
"granularity": "GRANULARITY_PARTITION_LEVEL",
"listConfig": {
"valueSchema": {
"type": "CUSTOMIZED_STRUCT",
"granularity": "GRANULARITY_PARTITION_LEVEL",
"customizedStructConfig": {
"fieldSchemas": {
"name": {
"type": "STRING",
"granularity": "GRANULARITY_PARTITION_LEVEL",
"searchStrategy": {
"searchStrategyType": "SMART_SEARCH"
"confidence_score_index_config": {
"field_path": "list-name-score._ENTRIES.score",
"threshold": "0.9",
}
}
},
"score": {
"type": "FLOAT",
"granularity": "GRANULARITY_PARTITION_LEVEL",
}
}
}
}
}
}
string field_path = 1 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
String |
The fieldPath.
|
getFieldPathBytes()
public ByteString getFieldPathBytes()
Required. The path to the confidence score field. It is a string that
concatenates all the data schema keys along the path. See the example
above. If the data schema contains LIST, use '_ENTRIES' to concatenate.
Example data schema contains a list:
"key": "list-name-score",
"schemaDetails": {
"type": "LIST",
"granularity": "GRANULARITY_PARTITION_LEVEL",
"listConfig": {
"valueSchema": {
"type": "CUSTOMIZED_STRUCT",
"granularity": "GRANULARITY_PARTITION_LEVEL",
"customizedStructConfig": {
"fieldSchemas": {
"name": {
"type": "STRING",
"granularity": "GRANULARITY_PARTITION_LEVEL",
"searchStrategy": {
"searchStrategyType": "SMART_SEARCH"
"confidence_score_index_config": {
"field_path": "list-name-score._ENTRIES.score",
"threshold": "0.9",
}
}
},
"score": {
"type": "FLOAT",
"granularity": "GRANULARITY_PARTITION_LEVEL",
}
}
}
}
}
}
string field_path = 1 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
ByteString |
The bytes for fieldPath.
|
getParserForType()
public Parser<DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig> getParserForType()
Overrides
getSerializedSize()
public int getSerializedSize()
Returns |
Type |
Description |
int |
|
Overrides
getThreshold()
public float getThreshold()
Required. The threshold.
float threshold = 2 [(.google.api.field_behavior) = REQUIRED];
Returns |
Type |
Description |
float |
The threshold.
|
hashCode()
Returns |
Type |
Description |
int |
|
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
newBuilderForType()
public DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig.Builder newBuilderForType()
newBuilderForType(GeneratedMessageV3.BuilderParent parent)
protected DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Overrides
newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Returns |
Type |
Description |
Object |
|
Overrides
toBuilder()
public DataSchemaDetails.SearchStrategy.ConfidenceScoreIndexConfig.Builder toBuilder()
writeTo(CodedOutputStream output)
public void writeTo(CodedOutputStream output)
Overrides