Package types (2.0.0)

API documentation for dialogflow_v2beta1.types package.

Classes

Agent

A Dialogflow agent is a virtual agent that handles conversations with your end-users. It is a natural language understanding module that understands the nuances of human language. Dialogflow translates end-user text or audio during a conversation to structured data that your apps and services can understand. You design and build a Dialogflow agent to handle the types of conversations required for your system.

For more information about agents, see the Agent guide <https://cloud.google.com/dialogflow/docs/agents-overview>__.

BatchCreateEntitiesRequest

The request message for EntityTypes.BatchCreateEntities.

BatchDeleteEntitiesRequest

The request message for EntityTypes.BatchDeleteEntities.

BatchDeleteEntityTypesRequest

The request message for EntityTypes.BatchDeleteEntityTypes.

BatchDeleteIntentsRequest

The request message for Intents.BatchDeleteIntents.

BatchUpdateEntitiesRequest

The request message for EntityTypes.BatchUpdateEntities.

BatchUpdateEntityTypesRequest

The request message for EntityTypes.BatchUpdateEntityTypes.

BatchUpdateEntityTypesResponse

The response message for EntityTypes.BatchUpdateEntityTypes.

BatchUpdateIntentsRequest

The request message for Intents.BatchUpdateIntents.

BatchUpdateIntentsResponse

The response message for Intents.BatchUpdateIntents.

Context

Dialogflow contexts are similar to natural language context. If a person says to you "they are orange", you need context in order to understand what "they" is referring to. Similarly, for Dialogflow to handle an end-user expression like that, it needs to be provided with context in order to correctly match an intent.

Using contexts, you can control the flow of a conversation. You can configure contexts for an intent by setting input and output contexts, which are identified by string names. When an intent is matched, any configured output contexts for that intent become active. While any contexts are active, Dialogflow is more likely to match intents that are configured with input contexts that correspond to the currently active contexts.

For more information about context, see the Contexts guide <https://cloud.google.com/dialogflow/docs/contexts-overview>__.

CreateContextRequest

The request message for Contexts.CreateContext.

CreateDocumentRequest

Request message for Documents.CreateDocument.

CreateEntityTypeRequest

The request message for EntityTypes.CreateEntityType.

CreateIntentRequest

The request message for Intents.CreateIntent.

CreateKnowledgeBaseRequest

Request message for KnowledgeBases.CreateKnowledgeBase.

CreateSessionEntityTypeRequest

The request message for SessionEntityTypes.CreateSessionEntityType.

DeleteAgentRequest

The request message for Agents.DeleteAgent.

DeleteAllContextsRequest

The request message for Contexts.DeleteAllContexts.

DeleteContextRequest

The request message for Contexts.DeleteContext.

DeleteDocumentRequest

Request message for Documents.DeleteDocument.

DeleteEntityTypeRequest

The request message for EntityTypes.DeleteEntityType.

DeleteIntentRequest

The request message for Intents.DeleteIntent.

DeleteKnowledgeBaseRequest

Request message for KnowledgeBases.DeleteKnowledgeBase.

DeleteSessionEntityTypeRequest

The request message for SessionEntityTypes.DeleteSessionEntityType.

DetectIntentRequest

The request to detect user's intent.

DetectIntentResponse

The message returned from the DetectIntent method.

Document

A knowledge document to be used by a KnowledgeBase.

For more information, see the knowledge base guide <https://cloud.google.com/dialogflow/docs/how/knowledge-bases>__.

Note: The projects.agent.knowledgeBases.documents resource is deprecated; only use projects.knowledgeBases.documents.

EntityType

Each intent parameter has a type, called the entity type, which dictates exactly how data from an end-user expression is extracted.

Dialogflow provides predefined system entities that can match many common types of data. For example, there are system entities for matching dates, times, colors, email addresses, and so on. You can also create your own custom entities for matching custom data. For example, you could define a vegetable entity that can match the types of vegetables available for purchase with a grocery store agent.

For more information, see the Entity guide <https://cloud.google.com/dialogflow/docs/entities-overview>__.

EntityTypeBatch

This message is a wrapper around a collection of entity types.

Environment

You can create multiple versions of your agent and publish them to separate environments.

When you edit an agent, you are editing the draft agent. At any point, you can save the draft agent as an agent version, which is an immutable snapshot of your agent.

When you save the draft agent, it is published to the default environment. When you create agent versions, you can publish them to custom environments. You can create a variety of custom environments for:

  • testing
  • development
  • production
  • etc.

For more information, see the versions and environments guide <https://cloud.google.com/dialogflow/docs/agents-versions>__.

EventInput

Events allow for matching intents by event name instead of the natural language input. For instance, input <event: { name: "welcome_event", parameters: { name: "Sam" } }> can trigger a personalized welcome response. The parameter name may be used by the agent in the response: "Hello #welcome_event.name! What can I do for you today?".

ExportAgentRequest

The request message for Agents.ExportAgent.

ExportAgentResponse

The response message for Agents.ExportAgent.

GcsSource

Google Cloud Storage location for single input.

GetAgentRequest

The request message for Agents.GetAgent.

GetContextRequest

The request message for Contexts.GetContext.

GetDocumentRequest

Request message for Documents.GetDocument.

GetEntityTypeRequest

The request message for EntityTypes.GetEntityType.

GetIntentRequest

The request message for Intents.GetIntent.

GetKnowledgeBaseRequest

Request message for KnowledgeBases.GetKnowledgeBase.

GetSessionEntityTypeRequest

The request message for SessionEntityTypes.GetSessionEntityType.

GetValidationResultRequest

The request message for Agents.GetValidationResult.

ImportAgentRequest

The request message for Agents.ImportAgent.

InputAudioConfig

Instructs the speech recognizer on how to process the audio content.

Intent

An intent categorizes an end-user's intention for one conversation turn. For each agent, you define many intents, where your combined intents can handle a complete conversation. When an end-user writes or says something, referred to as an end-user expression or end-user input, Dialogflow matches the end-user input to the best intent in your agent. Matching an intent is also known as intent classification.

For more information, see the intent guide <https://cloud.google.com/dialogflow/docs/intents-overview>__.

IntentBatch

This message is a wrapper around a collection of intents.

KnowledgeAnswers

Represents the result of querying a Knowledge base.

KnowledgeBase

A knowledge base represents a collection of knowledge documents that you provide to Dialogflow. Your knowledge documents contain information that may be useful during conversations with end-users. Some Dialogflow features use knowledge bases when looking for a response to an end-user input.

For more information, see the knowledge base guide <https://cloud.google.com/dialogflow/docs/how/knowledge-bases>__.

Note: The projects.agent.knowledgeBases resource is deprecated; only use projects.knowledgeBases.

KnowledgeOperationMetadata

Metadata in google::longrunning::Operation for Knowledge operations.

ListContextsRequest

The request message for Contexts.ListContexts.

ListContextsResponse

The response message for Contexts.ListContexts.

ListDocumentsRequest

Request message for Documents.ListDocuments.

ListDocumentsResponse

Response message for Documents.ListDocuments.

ListEntityTypesRequest

The request message for EntityTypes.ListEntityTypes.

ListEntityTypesResponse

The response message for EntityTypes.ListEntityTypes.

ListEnvironmentsRequest

The request message for Environments.ListEnvironments.

ListEnvironmentsResponse

The response message for Environments.ListEnvironments.

ListIntentsRequest

The request message for Intents.ListIntents.

ListIntentsResponse

The response message for Intents.ListIntents.

ListKnowledgeBasesRequest

Request message for KnowledgeBases.ListKnowledgeBases.

ListKnowledgeBasesResponse

Response message for KnowledgeBases.ListKnowledgeBases.

ListSessionEntityTypesRequest

The request message for SessionEntityTypes.ListSessionEntityTypes.

ListSessionEntityTypesResponse

The response message for SessionEntityTypes.ListSessionEntityTypes.

OriginalDetectIntentRequest

Represents the contents of the original request that was passed to the [Streaming]DetectIntent call.

OutputAudioConfig

Instructs the speech synthesizer how to generate the output audio content. If this audio config is supplied in a request, it overrides all existing text-to-speech settings applied to the agent.

QueryInput

Represents the query input. It can contain either:

  1. An audio config which instructs the speech recognizer how to process the speech audio.
  2. A conversational query in the form of text.

  3. An event that specifies which intent to trigger.

QueryParameters

Represents the parameters of the conversational query.

QueryResult

Represents the result of conversational query or event processing.

ReloadDocumentRequest

Request message for Documents.ReloadDocument.

RestoreAgentRequest

The request message for Agents.RestoreAgent.

SearchAgentsRequest

The request message for Agents.SearchAgents.

SearchAgentsResponse

The response message for Agents.SearchAgents.

Sentiment

The sentiment, such as positive/negative feeling or association, for a unit of analysis, such as the query text.

SentimentAnalysisRequestConfig

Configures the types of sentiment analysis to perform.

SentimentAnalysisResult

The result of sentiment analysis. Sentiment analysis inspects user input and identifies the prevailing subjective opinion, especially to determine a user's attitude as positive, negative, or neutral. For [Participants.DetectIntent][], it needs to be configured in DetectIntentRequest.query_params. For [Participants.StreamingDetectIntent][], it needs to be configured in StreamingDetectIntentRequest.query_params. And for Participants.AnalyzeContent and Participants.StreamingAnalyzeContent, it needs to be configured in ConversationProfile.human_agent_assistant_config

SessionEntityType

A session represents a conversation between a Dialogflow agent and an end-user. You can create special entities, called session entities, during a session. Session entities can extend or replace custom entity types and only exist during the session that they were created for. All session data, including session entities, is stored by Dialogflow for 20 minutes.

For more information, see the session entity guide <https://cloud.google.com/dialogflow/docs/entities-session>__.

SetAgentRequest

The request message for Agents.SetAgent.

SpeechContext

Hints for the speech recognizer to help with recognition in a specific conversation state.

SpeechWordInfo

Information for a word recognized by the speech recognizer.

StreamingDetectIntentRequest

The top-level message sent by the client to the Sessions.StreamingDetectIntent method.

Multiple request messages should be sent in order:

  1. The first message must contain session, query_input plus optionally query_params. If the client wants to receive an audio response, it should also contain output_audio_config. The message must not contain input_audio.

  2. If query_input was set to query_input.audio_config, all subsequent messages must contain input_audio to continue with Speech recognition. If you decide to rather detect an intent from text input after you already started Speech recognition, please send a message with query_input.text.

    However, note that:

    • Dialogflow will bill you for the audio duration so far.
    • Dialogflow discards all Speech recognition results in favor of the input text.
    • Dialogflow will use the language code from the first message.

After you sent all input, you must half-close or abort the request stream.

StreamingDetectIntentResponse

The top-level message returned from the StreamingDetectIntent method.

Multiple response messages can be returned in order:

  1. If the input was set to streaming audio, the first one or more messages contain recognition_result. Each recognition_result represents a more complete transcript of what the user said. The last recognition_result has is_final set to true.

  2. The next message contains response_id, query_result, alternative_query_results and optionally webhook_status if a WebHook was called.

  3. If output_audio_config was specified in the request or agent-level speech synthesizer is configured, all subsequent messages contain output_audio and output_audio_config.

StreamingRecognitionResult

Contains a speech recognition result corresponding to a portion of the audio that is currently being processed or an indication that this is the end of the single requested utterance.

Example:

  1. transcript: "tube"

  2. transcript: "to be a"

  3. transcript: "to be"

  4. transcript: "to be or not to be" is_final: true

  5. transcript: " that's"

  6. transcript: " that is"

  7. message_type: END_OF_SINGLE_UTTERANCE

  8. transcript: " that is the question" is_final: true

Only two of the responses contain final results (#4 and #8 indicated by is_final: true). Concatenating these generates the full transcript: "to be or not to be that is the question".

In each response we populate:

  • for TRANSCRIPT: transcript and possibly is_final.

  • for END_OF_SINGLE_UTTERANCE: only message_type.

SubAgent

Contains basic configuration for a sub-agent.

SynthesizeSpeechConfig

Configuration of how speech should be synthesized.

TelephonyDtmfEvents

A wrapper of repeated TelephonyDtmf digits.

TextInput

Represents the natural language text to be processed.

TrainAgentRequest

The request message for Agents.TrainAgent.

UpdateContextRequest

The request message for Contexts.UpdateContext.

UpdateDocumentRequest

Request message for Documents.UpdateDocument.

UpdateEntityTypeRequest

The request message for EntityTypes.UpdateEntityType.

UpdateIntentRequest

The request message for Intents.UpdateIntent.

UpdateKnowledgeBaseRequest

Request message for KnowledgeBases.UpdateKnowledgeBase.

UpdateSessionEntityTypeRequest

The request message for SessionEntityTypes.UpdateSessionEntityType.

ValidationError

Represents a single validation error.

ValidationResult

Represents the output of agent validation.

VoiceSelectionParams

Description of which voice to use for speech synthesis.

WebhookRequest

The request message for a webhook call.

WebhookResponse

The response message for a webhook call.

This response is validated by the Dialogflow server. If validation fails, an error will be returned in the QueryResult.diagnostic_info field. Setting JSON fields to an empty value with the wrong type is a common error. To avoid this error:

  • Use "" for empty strings
  • Use {} or null for empty objects
  • Use [] or null for empty arrays

For more information, see the Protocol Buffers Language Guide <https://developers.google.com/protocol-buffers/docs/proto3#json>__.