azure.ai.language.conversations.aio package

class azure.ai.language.conversations.aio.ConversationAnalysisClient(endpoint: str, credential: azure.core.credentials.AzureKeyCredential, **kwargs: Any)[source]

This API accepts a request and mediates among multiple language projects, such as LUIS Generally Available, Question Answering, Conversation, and then calls the best candidate service to handle the request. At last, it returns a response with the candidate service’s response as a payload.

In some cases, this API needs to forward requests and responses between the caller and an upstream service.

param endpoint

Supported Cognitive Services endpoint (e.g., https://<resource-name>.api.cognitiveservices.azure.com).

type endpoint

str

param credential

Credential needed for the client to connect to Azure.

type credential

~azure.core.credentials.AzureKeyCredential

async analyze_conversations(conversation_analysis_options: _models.ConversationAnalysisOptions, *, project_name: str, deployment_name: str, **kwargs: Any)_models.AnalyzeConversationResult

Analyzes the input conversation utterance.

Parameters

conversation_analysis_options (ConversationAnalysisOptions) – Post body of the request.

Keyword Arguments
  • project_name (str) – The name of the project to use.

  • deployment_name (str) – The name of the specific deployment of the project to use.

Returns

AnalyzeConversationResult

Return type

AnalyzeConversationResult

Raises

~azure.core.exceptions.HttpResponseError

async close()None[source]
send_request(request: azure.core.rest._rest_py3.HttpRequest, **kwargs: Any)Awaitable[azure.core.rest._rest_py3.AsyncHttpResponse][source]

Runs the network request through the client’s chained policies.

>>> from azure.core.rest import HttpRequest
>>> request = HttpRequest("GET", "https://www.example.org/")
<HttpRequest [GET], url: 'https://www.example.org/'>
>>> response = await client.send_request(request)
<AsyncHttpResponse: 200 OK>

For more information on this code flow, see https://aka.ms/azsdk/python/protocol/quickstart

Parameters

request (HttpRequest) – The network request you want to make. Required.

Keyword Arguments

stream (bool) – Whether the response payload will be streamed. Defaults to False.

Returns

The response of your network call. Does not do error handling on your response.

Return type

AsyncHttpResponse