metadata returned to client when grounding is enabled.
webSearchQueries[]
string
Optional. Web search queries for the following-up web search.
retrievalQueries[]
string
Optional. Queries executed by the retrieval tools.
List of supporting references retrieved from specified grounding source.
Optional. List of grounding support.
Optional. Google search entry for the following-up web searches.
Optional. Output only. Retrieval metadata.
JSON representation |
---|
{ "webSearchQueries": [ string ], "retrievalQueries": [ string ], "groundingChunks": [ { object ( |
SearchEntryPoint
Google search entry point.
renderedContent
string
Optional. Web content snippet that can be embedded in a web page or an app webview.
Optional. Base64 encoded JSON representing array of <search term, search url> tuple.
A base64-encoded string.
JSON representation |
---|
{ "renderedContent": string, "sdkBlob": string } |
GroundingChunk
Grounding chunk.
chunk_type
Union type
chunk_type
can be only one of the following:Grounding chunk from the web.
Grounding chunk from context retrieved by the retrieval tools.
JSON representation |
---|
{ // chunk_type "web": { object ( |
Web
Chunk from the web.
uri
string
URI reference of the chunk.
title
string
title of the chunk.
domain
string
domain of the (original) URI.
JSON representation |
---|
{ "uri": string, "title": string, "domain": string } |
RetrievedContext
Chunk from context retrieved by the retrieval tools.
context_details
Union type
context_details
can be only one of the following:Additional context for the RAG retrieval result. This is only populated when using the RAG retrieval tool.
uri
string
URI reference of the attribution.
title
string
title of the attribution.
text
string
Text of the attribution.
JSON representation |
---|
{
// context_details
"ragChunk": {
object ( |
GroundingSupport
Grounding support.
groundingChunkIndices[]
integer
A list of indices (into 'grounding_chunk') specifying the citations associated with the claim. For instance [1,3,4] means that grounding_chunk[1], grounding_chunk[3], grounding_chunk[4] are the retrieved content attributed to the claim.
confidenceScores[]
number
confidence score of the support references. Ranges from 0 to 1. 1 is the most confident. This list must have the same size as the groundingChunkIndices.
Segment of the content this support belongs to.
JSON representation |
---|
{
"groundingChunkIndices": [
integer
],
"confidenceScores": [
number
],
"segment": {
object ( |
Segment
Segment of the content.
partIndex
integer
Output only. The index of a Part object within its parent Content object.
startIndex
integer
Output only. Start index in the given Part, measured in bytes. offset from the start of the Part, inclusive, starting at zero.
endIndex
integer
Output only. End index in the given Part, measured in bytes. offset from the start of the Part, exclusive, starting at zero.
text
string
Output only. The text corresponding to the segment from the response.
JSON representation |
---|
{ "partIndex": integer, "startIndex": integer, "endIndex": integer, "text": string } |
RetrievalMetadata
metadata related to retrieval in the grounding flow.
googleSearchDynamicRetrievalScore
number
Optional. Score indicating how likely information from Google Search could help answer the prompt. The score is in the range [0, 1]
, where 0 is the least likely and 1 is the most likely. This score is only populated when Google Search grounding and dynamic retrieval is enabled. It will be compared to the threshold to determine whether to trigger Google Search.
JSON representation |
---|
{ "googleSearchDynamicRetrievalScore": number } |