Delen via


PredictionOperations Class

PredictionOperations operations.

You should not instantiate directly this class, but create a Client instance that will create it for you and attach it as attribute.

Inheritance
builtins.object
PredictionOperations

Constructor

PredictionOperations(client, config, serializer, deserializer)

Parameters

Name Description
client
Required

Client for service requests.

config
Required

Configuration of service client.

serializer
Required

An object model serializer.

deserializer
Required

An object model deserializer.

Methods

get_slot_prediction

Gets the predictions for an application slot.

get_version_prediction

Gets the predictions for an application version.

get_slot_prediction

Gets the predictions for an application slot.

get_slot_prediction(app_id, slot_name, prediction_request, verbose=None, show_all_intents=None, log=None, custom_headers=None, raw=False, **operation_config)

Parameters

Name Description
app_id
Required
str

The application ID.

slot_name
Required
str

The application slot name.

prediction_request
Required

The prediction request parameters.

verbose

Indicates whether to get extra metadata for the entities predictions or not.

Default value: None
show_all_intents

Indicates whether to return all the intents in the response or just the top intent.

Default value: None
log

Indicates whether to log the endpoint query or not.

Default value: None
custom_headers

headers that will be added to the request

Default value: None
raw

returns the direct response alongside the deserialized response

Default value: False
operation_config
Required

Operation configuration overrides.

Returns

Type Description
<xref:msrest.pipeline.ClientRawResponse>

PredictionResponse or ClientRawResponse if raw=true

Exceptions

Type Description

get_version_prediction

Gets the predictions for an application version.

get_version_prediction(app_id, version_id, prediction_request, verbose=None, show_all_intents=None, log=None, custom_headers=None, raw=False, **operation_config)

Parameters

Name Description
app_id
Required
str

The application ID.

version_id
Required
str

The application version ID.

prediction_request
Required

The prediction request parameters.

verbose

Indicates whether to get extra metadata for the entities predictions or not.

Default value: None
show_all_intents

Indicates whether to return all the intents in the response or just the top intent.

Default value: None
log

Indicates whether to log the endpoint query or not.

Default value: None
custom_headers

headers that will be added to the request

Default value: None
raw

returns the direct response alongside the deserialized response

Default value: False
operation_config
Required

Operation configuration overrides.

Returns

Type Description
<xref:msrest.pipeline.ClientRawResponse>

PredictionResponse or ClientRawResponse if raw=true

Exceptions

Type Description

Attributes

models

models = <module 'azure.cognitiveservices.language.luis.runtime.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\cognitiveservices\\language\\luis\\runtime\\models\\__init__.py'>