AnswerRecord

Answer records are records to manage answer history and feedbacks for Dialogflow.

Currently, answer record includes:

  • human agent assistant article suggestion
  • human agent assistant faq article

It doesn't include:

  • DetectIntent intent matching
  • DetectIntent knowledge

Answer records are not related to the conversation history in the Dialogflow Console. A Record is generated even when the end-user disables conversation history in the console. Records are created when there's a human agent assistant suggestion generated.

A typical workflow for customers provide feedback to an answer is:

  1. For human agent assistant, customers get suggestion via suggestions.list API. Together with the answers, AnswerRecord.name are returned to the customers.
  2. The customer uses the AnswerRecord.name to call the [UpdateAnswerRecord][] method to send feedback about a specific answer that they believe is wrong.
JSON representation
{
  "name": string,
  "answerFeedback": {
    object (AnswerFeedback)
  },

  // Union field record can be only one of the following:
  "agentAssistantRecord": {
    object (AgentAssistantRecord)
  }
  // End of list of possible types for union field record.
}
Fields
name

string

The unique identifier of this answer record. Format: projects/<Project ID>/locations/<Location ID>/answerRecords/<Answer Record ID>.

answerFeedback

object (AnswerFeedback)

Required. The AnswerFeedback for this record. You can set this with AnswerRecords.UpdateAnswerRecord in order to give us feedback about this answer.

Union field record. The record for this answer. record can be only one of the following:
agentAssistantRecord

object (AgentAssistantRecord)

Output only. The record for human agent assistant.

AnswerFeedback

Represents feedback the customer has about the quality & correctness of a certain answer in a conversation.

JSON representation
{
  "correctnessLevel": enum (CorrectnessLevel),
  "clicked": boolean,
  "clickTime": string,
  "displayed": boolean,
  "displayTime": string,

  // Union field detail_feedback can be only one of the following:
  "agentAssistantDetailFeedback": {
    object (AgentAssistantFeedback)
  }
  // End of list of possible types for union field detail_feedback.
}
Fields
correctnessLevel

enum (CorrectnessLevel)

The correctness level of the specific answer.

clicked

boolean

Indicates whether the answer/item was clicked by the human agent or not. Default to false. For knowledge search and knowledge assist, the answer record is considered to be clicked if the answer was copied or any URI was clicked.

clickTime

string (Timestamp format)

Time when the answer/item was clicked.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

displayed

boolean

Indicates whether the answer/item was displayed to the human agent in the agent desktop UI. Default to false.

displayTime

string (Timestamp format)

Time when the answer/item was displayed.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

Union field detail_feedback. Normally, detail feedback is provided when answer is not fully correct. detail_feedback can be only one of the following:
agentAssistantDetailFeedback

object (AgentAssistantFeedback)

Detail feedback of agent assist suggestions.

CorrectnessLevel

The correctness level of an answer.

Enums
CORRECTNESS_LEVEL_UNSPECIFIED Correctness level unspecified.
NOT_CORRECT Answer is totally wrong.
PARTIALLY_CORRECT Answer is partially correct.
FULLY_CORRECT Answer is fully correct.

AgentAssistantFeedback

Detail feedback of Agent Assist result.

JSON representation
{
  "answerRelevance": enum (AnswerRelevance),
  "documentCorrectness": enum (DocumentCorrectness),
  "documentEfficiency": enum (DocumentEfficiency),
  "summarizationFeedback": {
    object (SummarizationFeedback)
  },
  "knowledgeSearchFeedback": {
    object (KnowledgeSearchFeedback)
  },
  "knowledgeAssistFeedback": {
    object (KnowledgeAssistFeedback)
  }
}
Fields
answerRelevance

enum (AnswerRelevance)

Optional. Whether or not the suggested answer is relevant.

For example:

documentCorrectness

enum (DocumentCorrectness)

Optional. Whether or not the information in the document is correct.

For example:

  • Query: "Can I return the package in 2 days once received?"
  • Suggested document says: "Items must be returned/exchanged within 60 days of the purchase date."
  • Ground truth: "No return or exchange is allowed."
documentEfficiency

enum (DocumentEfficiency)

Optional. Whether or not the suggested document is efficient. For example, if the document is poorly written, hard to understand, hard to use or too long to find useful information, documentEfficiency is DocumentEfficiency.INEFFICIENT.

summarizationFeedback

object (SummarizationFeedback)

Optional. Feedback for conversation summarization.

knowledgeSearchFeedback

object (KnowledgeSearchFeedback)

Optional. Feedback for knowledge search.

knowledgeAssistFeedback

object (KnowledgeAssistFeedback)

Optional. Feedback for knowledge assist.

AnswerRelevance

Relevance of an answer.

Enums
ANSWER_RELEVANCE_UNSPECIFIED Answer relevance unspecified.
IRRELEVANT Answer is irrelevant to query.
RELEVANT Answer is relevant to query.

DocumentCorrectness

Correctness of document.

Enums
DOCUMENT_CORRECTNESS_UNSPECIFIED Document correctness unspecified.
INCORRECT Information in document is incorrect.
CORRECT Information in document is correct.

DocumentEfficiency

Efficiency of document.

Enums
DOCUMENT_EFFICIENCY_UNSPECIFIED Document efficiency unspecified.
INEFFICIENT Document is inefficient.
EFFICIENT Document is efficient.

SummarizationFeedback

Feedback for conversation summarization.

JSON representation
{
  "startTime": string,
  "submitTime": string,
  "summaryText": string,
  "textSections": {
    string: string,
    ...
  }
}
Fields
startTime

string (Timestamp format)

Timestamp when composing of the summary starts.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

submitTime

string (Timestamp format)

Timestamp when the summary was submitted.

A timestamp in RFC3339 UTC "Zulu" format, with nanosecond resolution and up to nine fractional digits. Examples: "2014-10-02T15:01:23Z" and "2014-10-02T15:01:23.045123456Z".

summaryText

string

Text of actual submitted summary.

textSections

map (key: string, value: string)

Optional. Actual text sections of submitted summary.

An object containing a list of "key": value pairs. Example: { "name": "wrench", "mass": "1.3kg", "count": "3" }.

KnowledgeSearchFeedback

Feedback for knowledge search.

JSON representation
{
  "answerCopied": boolean,
  "clickedUris": [
    string
  ]
}
Fields
answerCopied

boolean

Whether the answer was copied by the human agent or not. If the value is set to be true, AnswerFeedback.clicked will be updated to be true.

clickedUris[]

string

The URIs clicked by the human agent. The value is appended for each UpdateAnswerRecordRequest. If the value is not empty, AnswerFeedback.clicked will be updated to be true.

KnowledgeAssistFeedback

Feedback for knowledge assist.

JSON representation
{
  "answerCopied": boolean,
  "clickedUris": [
    string
  ]
}
Fields
answerCopied

boolean

Whether the suggested answer was copied by the human agent. If the value is set to be true, AnswerFeedback.clicked will be updated to be true.

clickedUris[]

string

The URIs clicked by the human agent. The value is appended for each UpdateAnswerRecordRequest. If the value is not empty, AnswerFeedback.clicked will be updated to be true.

AgentAssistantRecord

Represents a record of a human agent assist answer.

JSON representation
{

  // Union field answer can be only one of the following:
  "articleSuggestionAnswer": {
    object (ArticleAnswer)
  },
  "faqAnswer": {
    object (FaqAnswer)
  },
  "dialogflowAssistAnswer": {
    object (DialogflowAssistAnswer)
  }
  // End of list of possible types for union field answer.
}
Fields
Union field answer. Output only. The agent assist answer. answer can be only one of the following:
articleSuggestionAnswer

object (ArticleAnswer)

Output only. The article suggestion answer.

faqAnswer

object (FaqAnswer)

Output only. The FAQ answer.

dialogflowAssistAnswer

object (DialogflowAssistAnswer)

Output only. Dialogflow assist answer.

DialogflowAssistAnswer

Represents a Dialogflow assist answer.

JSON representation
{
  "answerRecord": string,

  // Union field result can be only one of the following:
  "queryResult": {
    object (QueryResult)
  },
  "intentSuggestion": {
    object (IntentSuggestion)
  }
  // End of list of possible types for union field result.
}
Fields
answerRecord

string

The name of answer record, in the format of "projects//locations//answerRecords/"

Union field result. Result from DetectIntent for one matched intent. result can be only one of the following:
queryResult

object (QueryResult)

Result from v2 agent.

intentSuggestion

object (IntentSuggestion)

An intent suggestion generated from conversation.

IntentSuggestion

Represents an intent suggestion.

JSON representation
{
  "displayName": string,
  "description": string,

  // Union field intent can be only one of the following:
  "intentV2": string
  // End of list of possible types for union field intent.
}
Fields
displayName

string

The display name of the intent.

description

string

Human readable description for better understanding an intent like its scope, content, result etc. Maximum character limit: 140 characters.

Union field intent. The name of the intent. intent can be only one of the following:
intentV2

string

The unique identifier of this intent. Format: projects/<Project ID>/locations/<Location ID>/agent/intents/<Intent ID>.