Class CheckGroundingResponse.Builder (0.47.0)

public static final class CheckGroundingResponse.Builder extends GeneratedMessageV3.Builder<CheckGroundingResponse.Builder> implements CheckGroundingResponseOrBuilder

Response message for the GroundedGenerationService.CheckGrounding method.

Protobuf type google.cloud.discoveryengine.v1.CheckGroundingResponse

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addAllCitedChunks(Iterable<? extends FactChunk> values)

public CheckGroundingResponse.Builder addAllCitedChunks(Iterable<? extends FactChunk> values)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
values Iterable<? extends com.google.cloud.discoveryengine.v1.FactChunk>
Returns
Type Description
CheckGroundingResponse.Builder

addAllClaims(Iterable<? extends CheckGroundingResponse.Claim> values)

public CheckGroundingResponse.Builder addAllClaims(Iterable<? extends CheckGroundingResponse.Claim> values)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
values Iterable<? extends com.google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim>
Returns
Type Description
CheckGroundingResponse.Builder

addCitedChunks(FactChunk value)

public CheckGroundingResponse.Builder addCitedChunks(FactChunk value)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
value FactChunk
Returns
Type Description
CheckGroundingResponse.Builder

addCitedChunks(FactChunk.Builder builderForValue)

public CheckGroundingResponse.Builder addCitedChunks(FactChunk.Builder builderForValue)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
builderForValue FactChunk.Builder
Returns
Type Description
CheckGroundingResponse.Builder

addCitedChunks(int index, FactChunk value)

public CheckGroundingResponse.Builder addCitedChunks(int index, FactChunk value)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameters
Name Description
index int
value FactChunk
Returns
Type Description
CheckGroundingResponse.Builder

addCitedChunks(int index, FactChunk.Builder builderForValue)

public CheckGroundingResponse.Builder addCitedChunks(int index, FactChunk.Builder builderForValue)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameters
Name Description
index int
builderForValue FactChunk.Builder
Returns
Type Description
CheckGroundingResponse.Builder

addCitedChunksBuilder()

public FactChunk.Builder addCitedChunksBuilder()

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Returns
Type Description
FactChunk.Builder

addCitedChunksBuilder(int index)

public FactChunk.Builder addCitedChunksBuilder(int index)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
index int
Returns
Type Description
FactChunk.Builder

addClaims(CheckGroundingResponse.Claim value)

public CheckGroundingResponse.Builder addClaims(CheckGroundingResponse.Claim value)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
value CheckGroundingResponse.Claim
Returns
Type Description
CheckGroundingResponse.Builder

addClaims(CheckGroundingResponse.Claim.Builder builderForValue)

public CheckGroundingResponse.Builder addClaims(CheckGroundingResponse.Claim.Builder builderForValue)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
builderForValue CheckGroundingResponse.Claim.Builder
Returns
Type Description
CheckGroundingResponse.Builder

addClaims(int index, CheckGroundingResponse.Claim value)

public CheckGroundingResponse.Builder addClaims(int index, CheckGroundingResponse.Claim value)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameters
Name Description
index int
value CheckGroundingResponse.Claim
Returns
Type Description
CheckGroundingResponse.Builder

addClaims(int index, CheckGroundingResponse.Claim.Builder builderForValue)

public CheckGroundingResponse.Builder addClaims(int index, CheckGroundingResponse.Claim.Builder builderForValue)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameters
Name Description
index int
builderForValue CheckGroundingResponse.Claim.Builder
Returns
Type Description
CheckGroundingResponse.Builder

addClaimsBuilder()

public CheckGroundingResponse.Claim.Builder addClaimsBuilder()

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Returns
Type Description
CheckGroundingResponse.Claim.Builder

addClaimsBuilder(int index)

public CheckGroundingResponse.Claim.Builder addClaimsBuilder(int index)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
index int
Returns
Type Description
CheckGroundingResponse.Claim.Builder

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public CheckGroundingResponse.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

build()

public CheckGroundingResponse build()
Returns
Type Description
CheckGroundingResponse

buildPartial()

public CheckGroundingResponse buildPartial()
Returns
Type Description
CheckGroundingResponse

clear()

public CheckGroundingResponse.Builder clear()
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

clearCitedChunks()

public CheckGroundingResponse.Builder clearCitedChunks()

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Returns
Type Description
CheckGroundingResponse.Builder

clearClaims()

public CheckGroundingResponse.Builder clearClaims()

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Returns
Type Description
CheckGroundingResponse.Builder

clearField(Descriptors.FieldDescriptor field)

public CheckGroundingResponse.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public CheckGroundingResponse.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

clearSupportScore()

public CheckGroundingResponse.Builder clearSupportScore()

The support score for the input answer candidate. Higher the score, higher is the fraction of claims that are supported by the provided facts. This is always set when a response is returned.

optional float support_score = 1;

Returns
Type Description
CheckGroundingResponse.Builder

This builder for chaining.

clone()

public CheckGroundingResponse.Builder clone()
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

getCitedChunks(int index)

public FactChunk getCitedChunks(int index)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
index int
Returns
Type Description
FactChunk

getCitedChunksBuilder(int index)

public FactChunk.Builder getCitedChunksBuilder(int index)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
index int
Returns
Type Description
FactChunk.Builder

getCitedChunksBuilderList()

public List<FactChunk.Builder> getCitedChunksBuilderList()

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Returns
Type Description
List<Builder>

getCitedChunksCount()

public int getCitedChunksCount()

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Returns
Type Description
int

getCitedChunksList()

public List<FactChunk> getCitedChunksList()

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Returns
Type Description
List<FactChunk>

getCitedChunksOrBuilder(int index)

public FactChunkOrBuilder getCitedChunksOrBuilder(int index)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
index int
Returns
Type Description
FactChunkOrBuilder

getCitedChunksOrBuilderList()

public List<? extends FactChunkOrBuilder> getCitedChunksOrBuilderList()

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Returns
Type Description
List<? extends com.google.cloud.discoveryengine.v1.FactChunkOrBuilder>

getClaims(int index)

public CheckGroundingResponse.Claim getClaims(int index)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
index int
Returns
Type Description
CheckGroundingResponse.Claim

getClaimsBuilder(int index)

public CheckGroundingResponse.Claim.Builder getClaimsBuilder(int index)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
index int
Returns
Type Description
CheckGroundingResponse.Claim.Builder

getClaimsBuilderList()

public List<CheckGroundingResponse.Claim.Builder> getClaimsBuilderList()

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Returns
Type Description
List<Builder>

getClaimsCount()

public int getClaimsCount()

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Returns
Type Description
int

getClaimsList()

public List<CheckGroundingResponse.Claim> getClaimsList()

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Returns
Type Description
List<Claim>

getClaimsOrBuilder(int index)

public CheckGroundingResponse.ClaimOrBuilder getClaimsOrBuilder(int index)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
index int
Returns
Type Description
CheckGroundingResponse.ClaimOrBuilder

getClaimsOrBuilderList()

public List<? extends CheckGroundingResponse.ClaimOrBuilder> getClaimsOrBuilderList()

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Returns
Type Description
List<? extends com.google.cloud.discoveryengine.v1.CheckGroundingResponse.ClaimOrBuilder>

getDefaultInstanceForType()

public CheckGroundingResponse getDefaultInstanceForType()
Returns
Type Description
CheckGroundingResponse

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getSupportScore()

public float getSupportScore()

The support score for the input answer candidate. Higher the score, higher is the fraction of claims that are supported by the provided facts. This is always set when a response is returned.

optional float support_score = 1;

Returns
Type Description
float

The supportScore.

hasSupportScore()

public boolean hasSupportScore()

The support score for the input answer candidate. Higher the score, higher is the fraction of claims that are supported by the provided facts. This is always set when a response is returned.

optional float support_score = 1;

Returns
Type Description
boolean

Whether the supportScore field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(CheckGroundingResponse other)

public CheckGroundingResponse.Builder mergeFrom(CheckGroundingResponse other)
Parameter
Name Description
other CheckGroundingResponse
Returns
Type Description
CheckGroundingResponse.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public CheckGroundingResponse.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
CheckGroundingResponse.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public CheckGroundingResponse.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final CheckGroundingResponse.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

removeCitedChunks(int index)

public CheckGroundingResponse.Builder removeCitedChunks(int index)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameter
Name Description
index int
Returns
Type Description
CheckGroundingResponse.Builder

removeClaims(int index)

public CheckGroundingResponse.Builder removeClaims(int index)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameter
Name Description
index int
Returns
Type Description
CheckGroundingResponse.Builder

setCitedChunks(int index, FactChunk value)

public CheckGroundingResponse.Builder setCitedChunks(int index, FactChunk value)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameters
Name Description
index int
value FactChunk
Returns
Type Description
CheckGroundingResponse.Builder

setCitedChunks(int index, FactChunk.Builder builderForValue)

public CheckGroundingResponse.Builder setCitedChunks(int index, FactChunk.Builder builderForValue)

List of facts cited across all claims in the answer candidate. These are derived from the facts supplied in the request.

repeated .google.cloud.discoveryengine.v1.FactChunk cited_chunks = 3;

Parameters
Name Description
index int
builderForValue FactChunk.Builder
Returns
Type Description
CheckGroundingResponse.Builder

setClaims(int index, CheckGroundingResponse.Claim value)

public CheckGroundingResponse.Builder setClaims(int index, CheckGroundingResponse.Claim value)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameters
Name Description
index int
value CheckGroundingResponse.Claim
Returns
Type Description
CheckGroundingResponse.Builder

setClaims(int index, CheckGroundingResponse.Claim.Builder builderForValue)

public CheckGroundingResponse.Builder setClaims(int index, CheckGroundingResponse.Claim.Builder builderForValue)

Claim texts and citation info across all claims in the answer candidate.

repeated .google.cloud.discoveryengine.v1.CheckGroundingResponse.Claim claims = 4;

Parameters
Name Description
index int
builderForValue CheckGroundingResponse.Claim.Builder
Returns
Type Description
CheckGroundingResponse.Builder

setField(Descriptors.FieldDescriptor field, Object value)

public CheckGroundingResponse.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public CheckGroundingResponse.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
CheckGroundingResponse.Builder
Overrides

setSupportScore(float value)

public CheckGroundingResponse.Builder setSupportScore(float value)

The support score for the input answer candidate. Higher the score, higher is the fraction of claims that are supported by the provided facts. This is always set when a response is returned.

optional float support_score = 1;

Parameter
Name Description
value float

The supportScore to set.

Returns
Type Description
CheckGroundingResponse.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final CheckGroundingResponse.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
CheckGroundingResponse.Builder
Overrides