你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

PredictionOperations 类

PredictionOperations 操作。

不应直接实例化此类,而应创建一个客户端实例,该实例将为你创建它并将其附加为属性。

继承
builtins.object
PredictionOperations

构造函数

PredictionOperations(client, config, serializer, deserializer)

参数

名称 说明
client
必需

服务请求的客户端。

config
必需

服务客户端的配置。

serializer
必需

对象模型序列化程序。

deserializer
必需

对象模型反序列化程序。

方法

get_slot_prediction

获取应用程序槽的预测。

get_version_prediction

获取应用程序版本的预测。

get_slot_prediction

获取应用程序槽的预测。

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

参数

名称 说明
app_id
必需
str

应用程序 ID。

slot_name
必需
str

应用程序槽名称。

prediction_request
必需

预测请求参数。

verbose

指示是否获取实体预测的额外元数据。

默认值: None
show_all_intents

指示是返回响应中的所有意向,还是仅返回顶部意向。

默认值: None
log

指示是否记录终结点查询。

默认值: None
custom_headers

将添加到请求的标头

默认值: None
raw

返回直接响应以及反序列化的响应

默认值: False
operation_config
必需

操作配置替代

返回

类型 说明
<xref:msrest.pipeline.ClientRawResponse>

如果 raw=true,则 PredictionResponse 或 ClientRawResponse

例外

类型 说明

get_version_prediction

获取应用程序版本的预测。

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

参数

名称 说明
app_id
必需
str

应用程序 ID。

version_id
必需
str

应用程序版本 ID。

prediction_request
必需

预测请求参数。

verbose

指示是否获取实体预测的额外元数据。

默认值: None
show_all_intents

指示是返回响应中的所有意向,还是仅返回顶部意向。

默认值: None
log

指示是否记录终结点查询。

默认值: None
custom_headers

将添加到请求的标头

默认值: None
raw

返回直接响应以及反序列化的响应

默认值: False
operation_config
必需

操作配置替代

返回

类型 说明
<xref:msrest.pipeline.ClientRawResponse>

如果 raw=true,则 PredictionResponse 或 ClientRawResponse

例外

类型 说明

属性

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'>