Package com.google.cloud.automl.v1beta1
Class PredictResponse.Builder
- java.lang.Object
-
- com.google.protobuf.AbstractMessageLite.Builder
-
- com.google.protobuf.AbstractMessage.Builder<BuilderT>
-
- com.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
- com.google.cloud.automl.v1beta1.PredictResponse.Builder
-
- All Implemented Interfaces:
PredictResponseOrBuilder
,com.google.protobuf.Message.Builder
,com.google.protobuf.MessageLite.Builder
,com.google.protobuf.MessageLiteOrBuilder
,com.google.protobuf.MessageOrBuilder
,Cloneable
- Enclosing class:
- PredictResponse
public static final class PredictResponse.Builder extends com.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder> implements PredictResponseOrBuilder
Response message for [PredictionService.Predict][google.cloud.automl.v1beta1.PredictionService.Predict].
Protobuf typegoogle.cloud.automl.v1beta1.PredictResponse
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description PredictResponse.Builder
addAllPayload(Iterable<? extends AnnotationPayload> values)
Prediction result.PredictResponse.Builder
addPayload(int index, AnnotationPayload value)
Prediction result.PredictResponse.Builder
addPayload(int index, AnnotationPayload.Builder builderForValue)
Prediction result.PredictResponse.Builder
addPayload(AnnotationPayload value)
Prediction result.PredictResponse.Builder
addPayload(AnnotationPayload.Builder builderForValue)
Prediction result.AnnotationPayload.Builder
addPayloadBuilder()
Prediction result.AnnotationPayload.Builder
addPayloadBuilder(int index)
Prediction result.PredictResponse.Builder
addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
PredictResponse
build()
PredictResponse
buildPartial()
PredictResponse.Builder
clear()
PredictResponse.Builder
clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
PredictResponse.Builder
clearMetadata()
PredictResponse.Builder
clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
PredictResponse.Builder
clearPayload()
Prediction result.PredictResponse.Builder
clearPreprocessedInput()
The preprocessed example that AutoML actually makes prediction on.PredictResponse.Builder
clone()
boolean
containsMetadata(String key)
Additional domain-specific prediction response metadata.PredictResponse
getDefaultInstanceForType()
static com.google.protobuf.Descriptors.Descriptor
getDescriptor()
com.google.protobuf.Descriptors.Descriptor
getDescriptorForType()
Map<String,String>
getMetadata()
Deprecated.int
getMetadataCount()
Additional domain-specific prediction response metadata.Map<String,String>
getMetadataMap()
Additional domain-specific prediction response metadata.String
getMetadataOrDefault(String key, String defaultValue)
Additional domain-specific prediction response metadata.String
getMetadataOrThrow(String key)
Additional domain-specific prediction response metadata.Map<String,String>
getMutableMetadata()
Deprecated.AnnotationPayload
getPayload(int index)
Prediction result.AnnotationPayload.Builder
getPayloadBuilder(int index)
Prediction result.List<AnnotationPayload.Builder>
getPayloadBuilderList()
Prediction result.int
getPayloadCount()
Prediction result.List<AnnotationPayload>
getPayloadList()
Prediction result.AnnotationPayloadOrBuilder
getPayloadOrBuilder(int index)
Prediction result.List<? extends AnnotationPayloadOrBuilder>
getPayloadOrBuilderList()
Prediction result.ExamplePayload
getPreprocessedInput()
The preprocessed example that AutoML actually makes prediction on.ExamplePayload.Builder
getPreprocessedInputBuilder()
The preprocessed example that AutoML actually makes prediction on.ExamplePayloadOrBuilder
getPreprocessedInputOrBuilder()
The preprocessed example that AutoML actually makes prediction on.boolean
hasPreprocessedInput()
The preprocessed example that AutoML actually makes prediction on.protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable()
protected com.google.protobuf.MapField
internalGetMapField(int number)
protected com.google.protobuf.MapField
internalGetMutableMapField(int number)
boolean
isInitialized()
PredictResponse.Builder
mergeFrom(PredictResponse other)
PredictResponse.Builder
mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)
PredictResponse.Builder
mergeFrom(com.google.protobuf.Message other)
PredictResponse.Builder
mergePreprocessedInput(ExamplePayload value)
The preprocessed example that AutoML actually makes prediction on.PredictResponse.Builder
mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
PredictResponse.Builder
putAllMetadata(Map<String,String> values)
Additional domain-specific prediction response metadata.PredictResponse.Builder
putMetadata(String key, String value)
Additional domain-specific prediction response metadata.PredictResponse.Builder
removeMetadata(String key)
Additional domain-specific prediction response metadata.PredictResponse.Builder
removePayload(int index)
Prediction result.PredictResponse.Builder
setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
PredictResponse.Builder
setPayload(int index, AnnotationPayload value)
Prediction result.PredictResponse.Builder
setPayload(int index, AnnotationPayload.Builder builderForValue)
Prediction result.PredictResponse.Builder
setPreprocessedInput(ExamplePayload value)
The preprocessed example that AutoML actually makes prediction on.PredictResponse.Builder
setPreprocessedInput(ExamplePayload.Builder builderForValue)
The preprocessed example that AutoML actually makes prediction on.PredictResponse.Builder
setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
PredictResponse.Builder
setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
-
Methods inherited from class com.google.protobuf.GeneratedMessageV3.Builder
getAllFields, getField, getFieldBuilder, getOneofFieldDescriptor, getParentForChildren, getRepeatedField, getRepeatedFieldBuilder, getRepeatedFieldCount, getUnknownFields, getUnknownFieldSetBuilder, hasField, hasOneof, isClean, markClean, mergeUnknownLengthDelimitedField, mergeUnknownVarintField, newBuilderForField, onBuilt, onChanged, parseUnknownField, setUnknownFieldSetBuilder, setUnknownFieldsProto3
-
Methods inherited from class com.google.protobuf.AbstractMessage.Builder
findInitializationErrors, getInitializationErrorString, internalMergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, mergeFrom, newUninitializedMessageException, toString
-
Methods inherited from class com.google.protobuf.AbstractMessageLite.Builder
addAll, addAll, mergeDelimitedFrom, mergeDelimitedFrom, mergeFrom, newUninitializedMessageException
-
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
-
-
-
Method Detail
-
getDescriptor
public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
-
internalGetMapField
protected com.google.protobuf.MapField internalGetMapField(int number)
- Overrides:
internalGetMapField
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
internalGetMutableMapField
protected com.google.protobuf.MapField internalGetMutableMapField(int number)
- Overrides:
internalGetMutableMapField
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
internalGetFieldAccessorTable
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
- Specified by:
internalGetFieldAccessorTable
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
clear
public PredictResponse.Builder clear()
- Specified by:
clear
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clear
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clear
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
getDescriptorForType
public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.Message.Builder
- Specified by:
getDescriptorForType
in interfacecom.google.protobuf.MessageOrBuilder
- Overrides:
getDescriptorForType
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
getDefaultInstanceForType
public PredictResponse getDefaultInstanceForType()
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Specified by:
getDefaultInstanceForType
in interfacecom.google.protobuf.MessageOrBuilder
-
build
public PredictResponse build()
- Specified by:
build
in interfacecom.google.protobuf.Message.Builder
- Specified by:
build
in interfacecom.google.protobuf.MessageLite.Builder
-
buildPartial
public PredictResponse buildPartial()
- Specified by:
buildPartial
in interfacecom.google.protobuf.Message.Builder
- Specified by:
buildPartial
in interfacecom.google.protobuf.MessageLite.Builder
-
clone
public PredictResponse.Builder clone()
- Specified by:
clone
in interfacecom.google.protobuf.Message.Builder
- Specified by:
clone
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
clone
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
setField
public PredictResponse.Builder setField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
setField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setField
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
clearField
public PredictResponse.Builder clearField(com.google.protobuf.Descriptors.FieldDescriptor field)
- Specified by:
clearField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearField
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
clearOneof
public PredictResponse.Builder clearOneof(com.google.protobuf.Descriptors.OneofDescriptor oneof)
- Specified by:
clearOneof
in interfacecom.google.protobuf.Message.Builder
- Overrides:
clearOneof
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
setRepeatedField
public PredictResponse.Builder setRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, int index, Object value)
- Specified by:
setRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
addRepeatedField
public PredictResponse.Builder addRepeatedField(com.google.protobuf.Descriptors.FieldDescriptor field, Object value)
- Specified by:
addRepeatedField
in interfacecom.google.protobuf.Message.Builder
- Overrides:
addRepeatedField
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
mergeFrom
public PredictResponse.Builder mergeFrom(com.google.protobuf.Message other)
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<PredictResponse.Builder>
-
mergeFrom
public PredictResponse.Builder mergeFrom(PredictResponse other)
-
isInitialized
public final boolean isInitialized()
- Specified by:
isInitialized
in interfacecom.google.protobuf.MessageLiteOrBuilder
- Overrides:
isInitialized
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
mergeFrom
public PredictResponse.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
- Specified by:
mergeFrom
in interfacecom.google.protobuf.Message.Builder
- Specified by:
mergeFrom
in interfacecom.google.protobuf.MessageLite.Builder
- Overrides:
mergeFrom
in classcom.google.protobuf.AbstractMessage.Builder<PredictResponse.Builder>
- Throws:
IOException
-
getPayloadList
public List<AnnotationPayload> getPayloadList()
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
- Specified by:
getPayloadList
in interfacePredictResponseOrBuilder
-
getPayloadCount
public int getPayloadCount()
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
- Specified by:
getPayloadCount
in interfacePredictResponseOrBuilder
-
getPayload
public AnnotationPayload getPayload(int index)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
- Specified by:
getPayload
in interfacePredictResponseOrBuilder
-
setPayload
public PredictResponse.Builder setPayload(int index, AnnotationPayload value)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
setPayload
public PredictResponse.Builder setPayload(int index, AnnotationPayload.Builder builderForValue)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
addPayload
public PredictResponse.Builder addPayload(AnnotationPayload value)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
addPayload
public PredictResponse.Builder addPayload(int index, AnnotationPayload value)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
addPayload
public PredictResponse.Builder addPayload(AnnotationPayload.Builder builderForValue)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
addPayload
public PredictResponse.Builder addPayload(int index, AnnotationPayload.Builder builderForValue)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
addAllPayload
public PredictResponse.Builder addAllPayload(Iterable<? extends AnnotationPayload> values)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
clearPayload
public PredictResponse.Builder clearPayload()
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
removePayload
public PredictResponse.Builder removePayload(int index)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
getPayloadBuilder
public AnnotationPayload.Builder getPayloadBuilder(int index)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
getPayloadOrBuilder
public AnnotationPayloadOrBuilder getPayloadOrBuilder(int index)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
- Specified by:
getPayloadOrBuilder
in interfacePredictResponseOrBuilder
-
getPayloadOrBuilderList
public List<? extends AnnotationPayloadOrBuilder> getPayloadOrBuilderList()
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
- Specified by:
getPayloadOrBuilderList
in interfacePredictResponseOrBuilder
-
addPayloadBuilder
public AnnotationPayload.Builder addPayloadBuilder()
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
addPayloadBuilder
public AnnotationPayload.Builder addPayloadBuilder(int index)
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
getPayloadBuilderList
public List<AnnotationPayload.Builder> getPayloadBuilderList()
Prediction result. Translation and Text Sentiment will return precisely one payload.
repeated .google.cloud.automl.v1beta1.AnnotationPayload payload = 1;
-
hasPreprocessedInput
public boolean hasPreprocessedInput()
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
- Specified by:
hasPreprocessedInput
in interfacePredictResponseOrBuilder
- Returns:
- Whether the preprocessedInput field is set.
-
getPreprocessedInput
public ExamplePayload getPreprocessedInput()
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
- Specified by:
getPreprocessedInput
in interfacePredictResponseOrBuilder
- Returns:
- The preprocessedInput.
-
setPreprocessedInput
public PredictResponse.Builder setPreprocessedInput(ExamplePayload value)
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
-
setPreprocessedInput
public PredictResponse.Builder setPreprocessedInput(ExamplePayload.Builder builderForValue)
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
-
mergePreprocessedInput
public PredictResponse.Builder mergePreprocessedInput(ExamplePayload value)
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
-
clearPreprocessedInput
public PredictResponse.Builder clearPreprocessedInput()
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
-
getPreprocessedInputBuilder
public ExamplePayload.Builder getPreprocessedInputBuilder()
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
-
getPreprocessedInputOrBuilder
public ExamplePayloadOrBuilder getPreprocessedInputOrBuilder()
The preprocessed example that AutoML actually makes prediction on. Empty if AutoML does not preprocess the input example. * For Text Extraction: If the input is a .pdf file, the OCR'ed text will be provided in [document_text][google.cloud.automl.v1beta1.Document.document_text].
.google.cloud.automl.v1beta1.ExamplePayload preprocessed_input = 3;
- Specified by:
getPreprocessedInputOrBuilder
in interfacePredictResponseOrBuilder
-
getMetadataCount
public int getMetadataCount()
Description copied from interface:PredictResponseOrBuilder
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
- Specified by:
getMetadataCount
in interfacePredictResponseOrBuilder
-
containsMetadata
public boolean containsMetadata(String key)
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
- Specified by:
containsMetadata
in interfacePredictResponseOrBuilder
-
getMetadata
@Deprecated public Map<String,String> getMetadata()
Deprecated.UsegetMetadataMap()
instead.- Specified by:
getMetadata
in interfacePredictResponseOrBuilder
-
getMetadataMap
public Map<String,String> getMetadataMap()
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
- Specified by:
getMetadataMap
in interfacePredictResponseOrBuilder
-
getMetadataOrDefault
public String getMetadataOrDefault(String key, String defaultValue)
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
- Specified by:
getMetadataOrDefault
in interfacePredictResponseOrBuilder
-
getMetadataOrThrow
public String getMetadataOrThrow(String key)
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
- Specified by:
getMetadataOrThrow
in interfacePredictResponseOrBuilder
-
clearMetadata
public PredictResponse.Builder clearMetadata()
-
removeMetadata
public PredictResponse.Builder removeMetadata(String key)
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
-
getMutableMetadata
@Deprecated public Map<String,String> getMutableMetadata()
Deprecated.Use alternate mutation accessors instead.
-
putMetadata
public PredictResponse.Builder putMetadata(String key, String value)
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
-
putAllMetadata
public PredictResponse.Builder putAllMetadata(Map<String,String> values)
Additional domain-specific prediction response metadata. * For Image Object Detection: `max_bounding_box_count` - (int64) At most that many bounding boxes per image could have been returned. * For Text Sentiment: `sentiment_score` - (float, deprecated) A value between -1 and 1, -1 maps to least positive sentiment, while 1 maps to the most positive one and the higher the score, the more positive the sentiment in the document is. Yet these values are relative to the training data, so e.g. if all data was positive then -1 will be also positive (though the least). The sentiment_score shouldn't be confused with "score" or "magnitude" from the previous Natural Language Sentiment Analysis API.
map<string, string> metadata = 2;
-
setUnknownFields
public final PredictResponse.Builder setUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
setUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
setUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
mergeUnknownFields
public final PredictResponse.Builder mergeUnknownFields(com.google.protobuf.UnknownFieldSet unknownFields)
- Specified by:
mergeUnknownFields
in interfacecom.google.protobuf.Message.Builder
- Overrides:
mergeUnknownFields
in classcom.google.protobuf.GeneratedMessageV3.Builder<PredictResponse.Builder>
-
-