SuggestKnowledgeAssistResponse

The response message for Participants.SuggestKnowledgeAssist.

JSON representation
{
  "knowledgeAssistAnswer": {
    object (KnowledgeAssistAnswer)
  },
  "latestMessage": string,
  "contextSize": integer
}
Fields
knowledgeAssistAnswer

object (KnowledgeAssistAnswer)

Output only. Knowledge Assist suggestion.

latestMessage

string

The name of the latest conversation message used to compile suggestion for. Format: projects/<Project ID>/locations/<Location ID>/conversations/<Conversation ID>/messages/<Message ID>.

contextSize

integer

Number of messages prior to and including latestMessage to compile the suggestion. It may be smaller than the SuggestKnowledgeAssistRequest.context_size field in the request if there are fewer messages in the conversation.

KnowledgeAssistAnswer

Represents a Knowledge Assist answer.

JSON representation
{
  "suggestedQuery": {
    object (SuggestedQuery)
  },
  "suggestedQueryAnswer": {
    object (KnowledgeAnswer)
  },
  "answerRecord": string,
  "knowledgeAssistDebugInfo": {
    object (KnowledgeAssistDebugInfo)
  }
}
Fields
suggestedQuery

object (SuggestedQuery)

The query suggested based on the context. Suggestion is made only if it is different from the previous suggestion.

suggestedQueryAnswer

object (KnowledgeAnswer)

The answer generated for the suggested query. Whether or not an answer is generated depends on how confident we are about the generated query.

answerRecord

string

The name of the answer record. Format: projects/<Project ID>/locations/<location ID>/answer Records/<Answer Record ID>.

knowledgeAssistDebugInfo

object (KnowledgeAssistDebugInfo)

Debug information related to Knowledge Assist feature.

SuggestedQuery

Represents a suggested query.

JSON representation
{
  "queryText": string
}
Fields
queryText

string

Suggested query text.

KnowledgeAnswer

Represents an answer from Knowledge. Currently supports FAQ and Generative answers.

JSON representation
{
  "answerText": string,

  // Union field source can be only one of the following:
  "faqSource": {
    object (FaqSource)
  },
  "generativeSource": {
    object (GenerativeSource)
  }
  // End of list of possible types for union field source.
}
Fields
answerText

string

The piece of text from the source that answers this suggested query.

Union field source. Source of result. source can be only one of the following:
faqSource

object (FaqSource)

Populated if the prediction came from FAQ.

generativeSource

object (GenerativeSource)

Populated if the prediction was Generative.

FaqSource

Details about source of FAQ answer.

JSON representation
{
  "question": string
}
Fields
question

string

The corresponding FAQ question.

GenerativeSource

Details about source of Generative answer.

JSON representation
{
  "snippets": [
    {
      object (Snippet)
    }
  ]
}
Fields
snippets[]

object (Snippet)

All snippets used for this Generative Prediction, with their source URI and data.

Snippet

Snippet Source for a Generative Prediction.

JSON representation
{
  "uri": string,
  "text": string,
  "title": string,
  "metadata": {
    object
  }
}
Fields
uri

string

URI the data is sourced from.

text

string

Text taken from that URI.

title

string

Title of the document.

metadata

object (Struct format)

Metadata of the document.

KnowledgeAssistDebugInfo

Debug information related to Knowledge Assist feature.

JSON representation
{
  "queryGenerationFailureReason": enum (QueryGenerationFailureReason),
  "queryCategorizationFailureReason": enum (QueryCategorizationFailureReason),
  "datastoreResponseReason": enum (DatastoreResponseReason),
  "knowledgeAssistBehavior": {
    object (KnowledgeAssistBehavior)
  },
  "ingestedContextReferenceDebugInfo": {
    object (IngestedContextReferenceDebugInfo)
  },
  "serviceLatency": {
    object (ServiceLatency)
  }
}
Fields
queryGenerationFailureReason

enum (QueryGenerationFailureReason)

Reason for query generation.

queryCategorizationFailureReason

enum (QueryCategorizationFailureReason)

Reason for query categorization.

datastoreResponseReason

enum (DatastoreResponseReason)

Response reason from datastore which indicates data serving status or answer quality degradation.

knowledgeAssistBehavior

object (KnowledgeAssistBehavior)

Configured behaviors for Knowedge Assist.

ingestedContextReferenceDebugInfo

object (IngestedContextReferenceDebugInfo)

Information about parameters ingested for search knowledge.

serviceLatency

object (ServiceLatency)

The latency of the service.

QueryGenerationFailureReason

Reason for query generation failure.

Enums
QUERY_GENERATION_FAILURE_REASON_UNSPECIFIED Default value.
QUERY_GENERATION_OUT_OF_QUOTA Query generation is blocked due to out of quota.
QUERY_GENERATION_FAILED Call to Knowedge Assist query generation model fails.
QUERY_GENERATION_NO_QUERY_GENERATED Query generation model decides that there is no new topic change or there has been similar queries generated in the previous turns.
QUERY_GENERATION_RAI_FAILED Knowedge Assist generated query is blocked by RAI (Responsible AI).
NOT_IN_ALLOWLIST Query generation is blocked by Knowledge Assist conversation profile level / agent id level filtering.
QUERY_GENERATION_QUERY_REDACTED The generated query is blocked due to redaction.
QUERY_GENERATION_LLM_RESPONSE_PARSE_FAILED Query generation failed due to LLM response parse failure.
QUERY_GENERATION_EMPTY_CONVERSATION The conversation has no messages.
QUERY_GENERATION_EMPTY_LAST_MESSAGE The last message in the conversation is empty.
QUERY_GENERATION_TRIGGERING_EVENT_CONDITION_NOT_MET The trigger event condition is not met. This occurs in the following scenarios: 1. The triggerEvent is CUSTOMER_MESSAGE or UNSPECIFIED, but the last message is not from the customer. 2. The triggerEvent is AGENT_MESSAGE, but the last message is not from the agent.

QueryCategorizationFailureReason

Reason for query categorization failure.

Enums
QUERY_CATEGORIZATION_FAILURE_REASON_UNSPECIFIED Default value.
QUERY_CATEGORIZATION_INVALID_CONFIG Vertex AI Search config supplied for query categorization is invalid.
QUERY_CATEGORIZATION_RESULT_NOT_FOUND Vertex AI Search result does not contain a query categorization result.
QUERY_CATEGORIZATION_FAILED Vertex AI Search call fails.

KnowledgeAssistBehavior

Configured behaviors for Knowedge Assist.

JSON representation
{
  "answerGenerationRewriterOn": boolean,
  "endUserMetadataIncluded": boolean,
  "returnQueryOnly": boolean,
  "usePubsubDelivery": boolean,
  "disableSyncDelivery": boolean,
  "previousQueriesIncluded": boolean,
  "useTranslatedMessage": boolean,
  "useCustomSafetyFilterLevel": boolean,
  "conversationTranscriptHasMixedLanguages": boolean,
  "queryGenerationAgentLanguageMismatch": boolean,
  "queryGenerationEndUserLanguageMismatch": boolean,
  "thirdPartyConnectorAllowed": boolean,
  "multipleQueriesGenerated": boolean,
  "queryContainedSearchContext": boolean,
  "invalidItemsQuerySuggestionSkipped": boolean,
  "primaryQueryRedactedAndReplaced": boolean,
  "appendedSearchContextCount": integer
}
Fields
answerGenerationRewriterOn

boolean

Whether data store agent rewriter was turned off for the request.

endUserMetadataIncluded

boolean

Whether endUserMetadata is included in the data store agent call.

returnQueryOnly

boolean

Whether customers configured to return query only in the conversation profile.

usePubsubDelivery

boolean

Whether customers configured to use pubsub to deliver.

disableSyncDelivery

boolean

Whether customers configured to disable the synchronous delivery of Knowedge Assist response.

previousQueriesIncluded

boolean

Whether previously suggested queries are included in the query generation process.

useTranslatedMessage

boolean

Translated message is included in query generation process.

useCustomSafetyFilterLevel

boolean

Safety filter is adjusted by user.

conversationTranscriptHasMixedLanguages

boolean

Conversation transcript has mixed languages.

queryGenerationAgentLanguageMismatch

boolean

Whether the agent language from the translation generator mismatches the end-user language.

queryGenerationEndUserLanguageMismatch

boolean

Whether the end-user language from the translation generator mismatches the end-user language.

thirdPartyConnectorAllowed

boolean

This field indicates whether third party connectors are enabled for the project.

multipleQueriesGenerated

boolean

Indicates that the query generation model generated multiple queries.

queryContainedSearchContext

boolean

Indicates that the generated query contains search context.

invalidItemsQuerySuggestionSkipped

boolean

Indicates that invalid items were skipped when parsing the LLM response.

primaryQueryRedactedAndReplaced

boolean

True if the primary suggested query was redacted and replaced by an additional query.

appendedSearchContextCount

integer

The number of search contexts appended to the query.