tencentcloud-sdk-python 3.0.1420__py2.py3-none-any.whl → 3.0.1422__py2.py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- tencentcloud/__init__.py +1 -1
- tencentcloud/autoscaling/v20180419/models.py +15 -0
- tencentcloud/batch/v20170312/models.py +4 -4
- tencentcloud/cdb/v20170320/cdb_client.py +1 -1
- tencentcloud/cdb/v20170320/models.py +8 -8
- tencentcloud/cdn/v20180606/models.py +4 -4
- tencentcloud/cdwch/v20200915/models.py +17 -2
- tencentcloud/cdwdoris/v20211228/errorcodes.py +6 -0
- tencentcloud/cdwdoris/v20211228/models.py +244 -4
- tencentcloud/cfg/v20210820/models.py +40 -0
- tencentcloud/ckafka/v20190819/ckafka_client.py +0 -23
- tencentcloud/ckafka/v20190819/models.py +0 -371
- tencentcloud/ctem/v20231128/models.py +30 -0
- tencentcloud/cvm/v20170312/models.py +4 -4
- tencentcloud/dts/v20211206/models.py +32 -2
- tencentcloud/emr/v20190103/models.py +74 -24
- tencentcloud/faceid/v20180301/models.py +22 -16
- tencentcloud/gs/v20191118/models.py +71 -0
- tencentcloud/igtm/v20231024/igtm_client.py +69 -0
- tencentcloud/igtm/v20231024/models.py +1202 -198
- tencentcloud/iotexplorer/v20190423/iotexplorer_client.py +3 -1
- tencentcloud/live/v20180801/live_client.py +69 -0
- tencentcloud/live/v20180801/models.py +102 -0
- tencentcloud/ocr/v20181119/models.py +4 -18
- tencentcloud/ocr/v20181119/ocr_client.py +3 -1
- tencentcloud/omics/v20221128/models.py +62 -2
- tencentcloud/ses/v20201002/models.py +171 -0
- tencentcloud/tcb/v20180608/models.py +64 -10
- tencentcloud/tdmq/v20200217/models.py +15 -0
- tencentcloud/teo/v20220901/models.py +664 -2
- tencentcloud/teo/v20220901/teo_client.py +115 -0
- tencentcloud/vrs/v20200824/vrs_client.py +1 -1
- {tencentcloud_sdk_python-3.0.1420.dist-info → tencentcloud_sdk_python-3.0.1422.dist-info}/METADATA +1 -1
- {tencentcloud_sdk_python-3.0.1420.dist-info → tencentcloud_sdk_python-3.0.1422.dist-info}/RECORD +37 -166
- tencentcloud/cis/__init__.py +0 -0
- tencentcloud/cis/v20180408/__init__.py +0 -0
- tencentcloud/cis/v20180408/cis_client.py +0 -187
- tencentcloud/cis/v20180408/errorcodes.py +0 -21
- tencentcloud/cis/v20180408/models.py +0 -1688
- tencentcloud/dataintegration/__init__.py +0 -0
- tencentcloud/dataintegration/v20220613/__init__.py +0 -0
- tencentcloud/dataintegration/v20220613/dataintegration_client.py +0 -49
- tencentcloud/dataintegration/v20220613/errorcodes.py +0 -15
- tencentcloud/dataintegration/v20220613/models.py +0 -168
- tencentcloud/dtf/__init__.py +0 -0
- tencentcloud/dtf/v20200506/__init__.py +0 -0
- tencentcloud/dtf/v20200506/dtf_client.py +0 -49
- tencentcloud/dtf/v20200506/errorcodes.py +0 -21
- tencentcloud/dtf/v20200506/models.py +0 -538
- tencentcloud/gpm/__init__.py +0 -0
- tencentcloud/gpm/v20200820/__init__.py +0 -0
- tencentcloud/gpm/v20200820/errorcodes.py +0 -168
- tencentcloud/gpm/v20200820/gpm_client.py +0 -476
- tencentcloud/gpm/v20200820/models.py +0 -4255
- tencentcloud/gse/__init__.py +0 -0
- tencentcloud/gse/v20191112/__init__.py +0 -0
- tencentcloud/gse/v20191112/errorcodes.py +0 -90
- tencentcloud/gse/v20191112/gse_client.py +0 -1993
- tencentcloud/gse/v20191112/models.py +0 -15093
- tencentcloud/iecp/__init__.py +0 -0
- tencentcloud/iecp/v20210914/__init__.py +0 -0
- tencentcloud/iecp/v20210914/errorcodes.py +0 -75
- tencentcloud/iecp/v20210914/iecp_client.py +0 -1912
- tencentcloud/iecp/v20210914/models.py +0 -17466
- tencentcloud/iir/__init__.py +0 -0
- tencentcloud/iir/v20200417/__init__.py +0 -0
- tencentcloud/iir/v20200417/errorcodes.py +0 -48
- tencentcloud/iir/v20200417/iir_client.py +0 -53
- tencentcloud/iir/v20200417/models.py +0 -451
- tencentcloud/iottid/__init__.py +0 -0
- tencentcloud/iottid/v20190411/__init__.py +0 -0
- tencentcloud/iottid/v20190411/errorcodes.py +0 -54
- tencentcloud/iottid/v20190411/iottid_client.py +0 -233
- tencentcloud/iottid/v20190411/models.py +0 -1053
- tencentcloud/mgobe/__init__.py +0 -0
- tencentcloud/mgobe/v20190929/__init__.py +0 -0
- tencentcloud/mgobe/v20190929/errorcodes.py +0 -945
- tencentcloud/mgobe/v20190929/mgobe_client.py +0 -49
- tencentcloud/mgobe/v20190929/models.py +0 -97
- tencentcloud/mgobe/v20201014/__init__.py +0 -0
- tencentcloud/mgobe/v20201014/errorcodes.py +0 -948
- tencentcloud/mgobe/v20201014/mgobe_client.py +0 -201
- tencentcloud/mgobe/v20201014/models.py +0 -1361
- tencentcloud/mvj/__init__.py +0 -0
- tencentcloud/mvj/v20190926/__init__.py +0 -0
- tencentcloud/mvj/v20190926/errorcodes.py +0 -30
- tencentcloud/mvj/v20190926/models.py +0 -263
- tencentcloud/mvj/v20190926/mvj_client.py +0 -51
- tencentcloud/pds/__init__.py +0 -0
- tencentcloud/pds/v20210701/__init__.py +0 -0
- tencentcloud/pds/v20210701/errorcodes.py +0 -48
- tencentcloud/pds/v20210701/models.py +0 -346
- tencentcloud/pds/v20210701/pds_client.py +0 -72
- tencentcloud/smpn/__init__.py +0 -0
- tencentcloud/smpn/v20190822/__init__.py +0 -0
- tencentcloud/smpn/v20190822/errorcodes.py +0 -27
- tencentcloud/smpn/v20190822/models.py +0 -389
- tencentcloud/smpn/v20190822/smpn_client.py +0 -76
- tencentcloud/solar/__init__.py +0 -0
- tencentcloud/solar/v20181011/__init__.py +0 -0
- tencentcloud/solar/v20181011/errorcodes.py +0 -42
- tencentcloud/solar/v20181011/models.py +0 -3848
- tencentcloud/solar/v20181011/solar_client.py +0 -417
- tencentcloud/tan/__init__.py +0 -0
- tencentcloud/tan/v20220420/__init__.py +0 -0
- tencentcloud/tan/v20220420/errorcodes.py +0 -81
- tencentcloud/tan/v20220420/models.py +0 -112
- tencentcloud/tan/v20220420/tan_client.py +0 -51
- tencentcloud/tav/__init__.py +0 -0
- tencentcloud/tav/v20190118/__init__.py +0 -0
- tencentcloud/tav/v20190118/errorcodes.py +0 -15
- tencentcloud/tav/v20190118/models.py +0 -550
- tencentcloud/tav/v20190118/tav_client.py +0 -118
- tencentcloud/tbm/__init__.py +0 -0
- tencentcloud/tbm/v20180129/__init__.py +0 -0
- tencentcloud/tbm/v20180129/errorcodes.py +0 -39
- tencentcloud/tbm/v20180129/models.py +0 -2354
- tencentcloud/tbm/v20180129/tbm_client.py +0 -233
- tencentcloud/tcex/__init__.py +0 -0
- tencentcloud/tcex/v20200727/__init__.py +0 -0
- tencentcloud/tcex/v20200727/errorcodes.py +0 -51
- tencentcloud/tcex/v20200727/models.py +0 -374
- tencentcloud/tcex/v20200727/tcex_client.py +0 -76
- tencentcloud/tci/__init__.py +0 -0
- tencentcloud/tci/v20190318/__init__.py +0 -0
- tencentcloud/tci/v20190318/errorcodes.py +0 -237
- tencentcloud/tci/v20190318/models.py +0 -11569
- tencentcloud/tci/v20190318/tci_client.py +0 -1017
- tencentcloud/tic/__init__.py +0 -0
- tencentcloud/tic/v20201117/__init__.py +0 -0
- tencentcloud/tic/v20201117/errorcodes.py +0 -48
- tencentcloud/tic/v20201117/models.py +0 -1952
- tencentcloud/tic/v20201117/tic_client.py +0 -342
- tencentcloud/ticm/__init__.py +0 -0
- tencentcloud/ticm/v20181127/__init__.py +0 -0
- tencentcloud/ticm/v20181127/errorcodes.py +0 -36
- tencentcloud/ticm/v20181127/models.py +0 -3385
- tencentcloud/ticm/v20181127/ticm_client.py +0 -95
- tencentcloud/tics/__init__.py +0 -0
- tencentcloud/tics/v20181115/__init__.py +0 -0
- tencentcloud/tics/v20181115/errorcodes.py +0 -30
- tencentcloud/tics/v20181115/models.py +0 -1324
- tencentcloud/tics/v20181115/tics_client.py +0 -118
- tencentcloud/tiems/__init__.py +0 -0
- tencentcloud/tiems/v20190416/__init__.py +0 -0
- tencentcloud/tiems/v20190416/errorcodes.py +0 -36
- tencentcloud/tiems/v20190416/models.py +0 -6644
- tencentcloud/tiems/v20190416/tiems_client.py +0 -651
- tencentcloud/trdp/__init__.py +0 -0
- tencentcloud/trdp/v20220726/__init__.py +0 -0
- tencentcloud/trdp/v20220726/errorcodes.py +0 -30
- tencentcloud/trdp/v20220726/models.py +0 -1609
- tencentcloud/trdp/v20220726/trdp_client.py +0 -49
- tencentcloud/ump/__init__.py +0 -0
- tencentcloud/ump/v20200918/__init__.py +0 -0
- tencentcloud/ump/v20200918/errorcodes.py +0 -57
- tencentcloud/ump/v20200918/models.py +0 -4089
- tencentcloud/ump/v20200918/ump_client.py +0 -454
- tencentcloud/youmall/__init__.py +0 -0
- tencentcloud/youmall/v20180228/__init__.py +0 -0
- tencentcloud/youmall/v20180228/errorcodes.py +0 -93
- tencentcloud/youmall/v20180228/models.py +0 -8181
- tencentcloud/youmall/v20180228/youmall_client.py +0 -740
- {tencentcloud_sdk_python-3.0.1420.dist-info → tencentcloud_sdk_python-3.0.1422.dist-info}/LICENSE +0 -0
- {tencentcloud_sdk_python-3.0.1420.dist-info → tencentcloud_sdk_python-3.0.1422.dist-info}/WHEEL +0 -0
- {tencentcloud_sdk_python-3.0.1420.dist-info → tencentcloud_sdk_python-3.0.1422.dist-info}/top_level.txt +0 -0
@@ -1,233 +0,0 @@
|
|
1
|
-
# -*- coding: utf8 -*-
|
2
|
-
# Copyright (c) 2017-2025 Tencent. All Rights Reserved.
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
|
16
|
-
import json
|
17
|
-
|
18
|
-
from tencentcloud.common.exception.tencent_cloud_sdk_exception import TencentCloudSDKException
|
19
|
-
from tencentcloud.common.abstract_client import AbstractClient
|
20
|
-
from tencentcloud.tbm.v20180129 import models
|
21
|
-
|
22
|
-
|
23
|
-
class TbmClient(AbstractClient):
|
24
|
-
_apiVersion = '2018-01-29'
|
25
|
-
_endpoint = 'tbm.tencentcloudapi.com'
|
26
|
-
_service = 'tbm'
|
27
|
-
|
28
|
-
|
29
|
-
def DescribeBrandCommentCount(self, request):
|
30
|
-
"""通过分析用户在评价品牌时用词的正负面情绪评分,返回品牌好评与差评评价条数,按天输出结果。
|
31
|
-
|
32
|
-
:param request: Request instance for DescribeBrandCommentCount.
|
33
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandCommentCountRequest`
|
34
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandCommentCountResponse`
|
35
|
-
|
36
|
-
"""
|
37
|
-
try:
|
38
|
-
params = request._serialize()
|
39
|
-
headers = request.headers
|
40
|
-
body = self.call("DescribeBrandCommentCount", params, headers=headers)
|
41
|
-
response = json.loads(body)
|
42
|
-
model = models.DescribeBrandCommentCountResponse()
|
43
|
-
model._deserialize(response["Response"])
|
44
|
-
return model
|
45
|
-
except Exception as e:
|
46
|
-
if isinstance(e, TencentCloudSDKException):
|
47
|
-
raise
|
48
|
-
else:
|
49
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
50
|
-
|
51
|
-
|
52
|
-
def DescribeBrandExposure(self, request):
|
53
|
-
"""监测品牌关键词命中文章标题或全文的文章篇数,按天输出数据。
|
54
|
-
|
55
|
-
:param request: Request instance for DescribeBrandExposure.
|
56
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandExposureRequest`
|
57
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandExposureResponse`
|
58
|
-
|
59
|
-
"""
|
60
|
-
try:
|
61
|
-
params = request._serialize()
|
62
|
-
headers = request.headers
|
63
|
-
body = self.call("DescribeBrandExposure", params, headers=headers)
|
64
|
-
response = json.loads(body)
|
65
|
-
model = models.DescribeBrandExposureResponse()
|
66
|
-
model._deserialize(response["Response"])
|
67
|
-
return model
|
68
|
-
except Exception as e:
|
69
|
-
if isinstance(e, TencentCloudSDKException):
|
70
|
-
raise
|
71
|
-
else:
|
72
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
73
|
-
|
74
|
-
|
75
|
-
def DescribeBrandMediaReport(self, request):
|
76
|
-
"""监测品牌关键词出现在媒体网站(新闻媒体、网络门户、政府网站、微信公众号、天天快报等)发布资讯标题和正文中的报道数。按天输出结果。
|
77
|
-
|
78
|
-
:param request: Request instance for DescribeBrandMediaReport.
|
79
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandMediaReportRequest`
|
80
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandMediaReportResponse`
|
81
|
-
|
82
|
-
"""
|
83
|
-
try:
|
84
|
-
params = request._serialize()
|
85
|
-
headers = request.headers
|
86
|
-
body = self.call("DescribeBrandMediaReport", params, headers=headers)
|
87
|
-
response = json.loads(body)
|
88
|
-
model = models.DescribeBrandMediaReportResponse()
|
89
|
-
model._deserialize(response["Response"])
|
90
|
-
return model
|
91
|
-
except Exception as e:
|
92
|
-
if isinstance(e, TencentCloudSDKException):
|
93
|
-
raise
|
94
|
-
else:
|
95
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
96
|
-
|
97
|
-
|
98
|
-
def DescribeBrandNegComments(self, request):
|
99
|
-
"""通过分析用户在评价品牌时用词的正负面情绪评分,返回品牌热门差评观点列表。
|
100
|
-
|
101
|
-
:param request: Request instance for DescribeBrandNegComments.
|
102
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandNegCommentsRequest`
|
103
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandNegCommentsResponse`
|
104
|
-
|
105
|
-
"""
|
106
|
-
try:
|
107
|
-
params = request._serialize()
|
108
|
-
headers = request.headers
|
109
|
-
body = self.call("DescribeBrandNegComments", params, headers=headers)
|
110
|
-
response = json.loads(body)
|
111
|
-
model = models.DescribeBrandNegCommentsResponse()
|
112
|
-
model._deserialize(response["Response"])
|
113
|
-
return model
|
114
|
-
except Exception as e:
|
115
|
-
if isinstance(e, TencentCloudSDKException):
|
116
|
-
raise
|
117
|
-
else:
|
118
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
119
|
-
|
120
|
-
|
121
|
-
def DescribeBrandPosComments(self, request):
|
122
|
-
"""通过分析用户在评价品牌时用词的正负面情绪评分,返回品牌热门好评观点列表。
|
123
|
-
|
124
|
-
:param request: Request instance for DescribeBrandPosComments.
|
125
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandPosCommentsRequest`
|
126
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandPosCommentsResponse`
|
127
|
-
|
128
|
-
"""
|
129
|
-
try:
|
130
|
-
params = request._serialize()
|
131
|
-
headers = request.headers
|
132
|
-
body = self.call("DescribeBrandPosComments", params, headers=headers)
|
133
|
-
response = json.loads(body)
|
134
|
-
model = models.DescribeBrandPosCommentsResponse()
|
135
|
-
model._deserialize(response["Response"])
|
136
|
-
return model
|
137
|
-
except Exception as e:
|
138
|
-
if isinstance(e, TencentCloudSDKException):
|
139
|
-
raise
|
140
|
-
else:
|
141
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
142
|
-
|
143
|
-
|
144
|
-
def DescribeBrandSocialOpinion(self, request):
|
145
|
-
"""检测品牌关键词出现在微博、QQ兴趣部落、论坛、博客等个人公开贡献资讯中的内容,每天聚合近30天热度最高的观点列表。
|
146
|
-
|
147
|
-
:param request: Request instance for DescribeBrandSocialOpinion.
|
148
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandSocialOpinionRequest`
|
149
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandSocialOpinionResponse`
|
150
|
-
|
151
|
-
"""
|
152
|
-
try:
|
153
|
-
params = request._serialize()
|
154
|
-
headers = request.headers
|
155
|
-
body = self.call("DescribeBrandSocialOpinion", params, headers=headers)
|
156
|
-
response = json.loads(body)
|
157
|
-
model = models.DescribeBrandSocialOpinionResponse()
|
158
|
-
model._deserialize(response["Response"])
|
159
|
-
return model
|
160
|
-
except Exception as e:
|
161
|
-
if isinstance(e, TencentCloudSDKException):
|
162
|
-
raise
|
163
|
-
else:
|
164
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
165
|
-
|
166
|
-
|
167
|
-
def DescribeBrandSocialReport(self, request):
|
168
|
-
"""监测品牌关键词出现在微博、QQ兴趣部落、论坛、博客等个人公开贡献资讯中的条数。按天输出数据结果。
|
169
|
-
|
170
|
-
:param request: Request instance for DescribeBrandSocialReport.
|
171
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandSocialReportRequest`
|
172
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeBrandSocialReportResponse`
|
173
|
-
|
174
|
-
"""
|
175
|
-
try:
|
176
|
-
params = request._serialize()
|
177
|
-
headers = request.headers
|
178
|
-
body = self.call("DescribeBrandSocialReport", params, headers=headers)
|
179
|
-
response = json.loads(body)
|
180
|
-
model = models.DescribeBrandSocialReportResponse()
|
181
|
-
model._deserialize(response["Response"])
|
182
|
-
return model
|
183
|
-
except Exception as e:
|
184
|
-
if isinstance(e, TencentCloudSDKException):
|
185
|
-
raise
|
186
|
-
else:
|
187
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
188
|
-
|
189
|
-
|
190
|
-
def DescribeIndustryNews(self, request):
|
191
|
-
"""根据客户定制的行业关键词,监测关键词出现在媒体网站(新闻媒体、网络门户、政府网站、微信公众号、天天快报等)发布资讯标题和正文中的报道数,以及文章列表、来源渠道、作者、发布时间等。
|
192
|
-
|
193
|
-
:param request: Request instance for DescribeIndustryNews.
|
194
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeIndustryNewsRequest`
|
195
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeIndustryNewsResponse`
|
196
|
-
|
197
|
-
"""
|
198
|
-
try:
|
199
|
-
params = request._serialize()
|
200
|
-
headers = request.headers
|
201
|
-
body = self.call("DescribeIndustryNews", params, headers=headers)
|
202
|
-
response = json.loads(body)
|
203
|
-
model = models.DescribeIndustryNewsResponse()
|
204
|
-
model._deserialize(response["Response"])
|
205
|
-
return model
|
206
|
-
except Exception as e:
|
207
|
-
if isinstance(e, TencentCloudSDKException):
|
208
|
-
raise
|
209
|
-
else:
|
210
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
211
|
-
|
212
|
-
|
213
|
-
def DescribeUserPortrait(self, request):
|
214
|
-
"""通过分析洞察参与过品牌媒体互动的用户,比如公开发表品牌的新闻评论、在公开社交渠道发表过对品牌的评价观点等用户,返回用户的画像属性分布,例如性别、年龄、地域、喜爱的明星、喜爱的影视。
|
215
|
-
|
216
|
-
:param request: Request instance for DescribeUserPortrait.
|
217
|
-
:type request: :class:`tencentcloud.tbm.v20180129.models.DescribeUserPortraitRequest`
|
218
|
-
:rtype: :class:`tencentcloud.tbm.v20180129.models.DescribeUserPortraitResponse`
|
219
|
-
|
220
|
-
"""
|
221
|
-
try:
|
222
|
-
params = request._serialize()
|
223
|
-
headers = request.headers
|
224
|
-
body = self.call("DescribeUserPortrait", params, headers=headers)
|
225
|
-
response = json.loads(body)
|
226
|
-
model = models.DescribeUserPortraitResponse()
|
227
|
-
model._deserialize(response["Response"])
|
228
|
-
return model
|
229
|
-
except Exception as e:
|
230
|
-
if isinstance(e, TencentCloudSDKException):
|
231
|
-
raise
|
232
|
-
else:
|
233
|
-
raise TencentCloudSDKException(type(e).__name__, str(e))
|
tencentcloud/tcex/__init__.py
DELETED
File without changes
|
File without changes
|
@@ -1,51 +0,0 @@
|
|
1
|
-
# -*- coding: utf8 -*-
|
2
|
-
# Copyright (c) 2017-2025 Tencent. All Rights Reserved.
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
|
16
|
-
|
17
|
-
# 操作失败。
|
18
|
-
FAILEDOPERATION = 'FailedOperation'
|
19
|
-
|
20
|
-
# 数据库查询错误。
|
21
|
-
FAILEDOPERATION_DATABASEFINDERROR = 'FailedOperation.DatabaseFindError'
|
22
|
-
|
23
|
-
# 文件不存在。
|
24
|
-
FAILEDOPERATION_FILENOTEXISTS = 'FailedOperation.FileNotExists'
|
25
|
-
|
26
|
-
# 权限不足。
|
27
|
-
FAILEDOPERATION_INSUFFICIENTPRIVILEGE = 'FailedOperation.InsufficientPrivilege'
|
28
|
-
|
29
|
-
# 指定的服务不存在。
|
30
|
-
FAILEDOPERATION_SERVICENOTFOUND = 'FailedOperation.ServiceNotFound'
|
31
|
-
|
32
|
-
# 内部错误。
|
33
|
-
INTERNALERROR = 'InternalError'
|
34
|
-
|
35
|
-
# 参数错误。
|
36
|
-
INVALIDPARAMETER = 'InvalidParameter'
|
37
|
-
|
38
|
-
# 参数值不能为空。
|
39
|
-
INVALIDPARAMETER_EMPTYPARAMETERS = 'InvalidParameter.EmptyParameters'
|
40
|
-
|
41
|
-
# 文件格式解析失败。
|
42
|
-
INVALIDPARAMETER_INVALIDFILEFORMAT = 'InvalidParameter.InvalidFileFormat'
|
43
|
-
|
44
|
-
# 文件大小不符合要求。
|
45
|
-
INVALIDPARAMETER_INVALIDFILESIZE = 'InvalidParameter.InvalidFileSize'
|
46
|
-
|
47
|
-
# 参数取值错误。
|
48
|
-
INVALIDPARAMETER_INVALIDPARAMETERVALUE = 'InvalidParameter.InvalidParameterValue'
|
49
|
-
|
50
|
-
# 参数解析失败。
|
51
|
-
INVALIDPARAMETER_REQUESTPARSEERROR = 'InvalidParameter.RequestParseError'
|
@@ -1,374 +0,0 @@
|
|
1
|
-
# -*- coding: utf8 -*-
|
2
|
-
# Copyright (c) 2017-2025 Tencent. All Rights Reserved.
|
3
|
-
#
|
4
|
-
# Licensed under the Apache License, Version 2.0 (the "License");
|
5
|
-
# you may not use this file except in compliance with the License.
|
6
|
-
# You may obtain a copy of the License at
|
7
|
-
#
|
8
|
-
# http://www.apache.org/licenses/LICENSE-2.0
|
9
|
-
#
|
10
|
-
# Unless required by applicable law or agreed to in writing, software
|
11
|
-
# distributed under the License is distributed on an "AS IS" BASIS,
|
12
|
-
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
13
|
-
# See the License for the specific language governing permissions and
|
14
|
-
# limitations under the License.
|
15
|
-
|
16
|
-
import warnings
|
17
|
-
|
18
|
-
from tencentcloud.common.abstract_model import AbstractModel
|
19
|
-
|
20
|
-
|
21
|
-
class AlgorithmResult(AbstractModel):
|
22
|
-
"""每个算法的返回结果
|
23
|
-
|
24
|
-
"""
|
25
|
-
|
26
|
-
def __init__(self):
|
27
|
-
r"""
|
28
|
-
:param _AlgoId: 算法ID
|
29
|
-
:type AlgoId: str
|
30
|
-
:param _AlgoName: 算法名称
|
31
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
32
|
-
:type AlgoName: str
|
33
|
-
:param _Result: 算法返回的结果。
|
34
|
-
- 当算法类型为“OCR(1)”时,结果为文本字符串
|
35
|
-
- 当算法类型为“文本分类(2)”时,结果字符串为json对象数组:
|
36
|
-
Class:分类结果
|
37
|
-
Confidence:置信度
|
38
|
-
- 算法类型为“情感分析(3)”时,结果字符串为json对象:
|
39
|
-
Positive:正面情感概率
|
40
|
-
Negative:负面情感概率
|
41
|
-
Neutral:中性情感概率
|
42
|
-
- 当算法类型为“合同要素抽取(4)”时,结果字符串为json对象数组:
|
43
|
-
NodeName:一级要素名称
|
44
|
-
ItemName:二级要素名称
|
45
|
-
Content:要素文本内容
|
46
|
-
- 当算法类型为“实体识别(5)”时,结果字符串为json对象数组:
|
47
|
-
- Entity:实体类型
|
48
|
-
- Content:实体文本内容
|
49
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
50
|
-
:type Result: str
|
51
|
-
:param _Error: 算法调用错误信息
|
52
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
53
|
-
:type Error: str
|
54
|
-
:param _AlgoType: 算法类型:
|
55
|
-
1:OCR算法
|
56
|
-
2:文本分类算法
|
57
|
-
3:情感分析算法
|
58
|
-
4:合同要素抽取算法
|
59
|
-
5、实体识别算法
|
60
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
61
|
-
:type AlgoType: int
|
62
|
-
"""
|
63
|
-
self._AlgoId = None
|
64
|
-
self._AlgoName = None
|
65
|
-
self._Result = None
|
66
|
-
self._Error = None
|
67
|
-
self._AlgoType = None
|
68
|
-
|
69
|
-
@property
|
70
|
-
def AlgoId(self):
|
71
|
-
"""算法ID
|
72
|
-
:rtype: str
|
73
|
-
"""
|
74
|
-
return self._AlgoId
|
75
|
-
|
76
|
-
@AlgoId.setter
|
77
|
-
def AlgoId(self, AlgoId):
|
78
|
-
self._AlgoId = AlgoId
|
79
|
-
|
80
|
-
@property
|
81
|
-
def AlgoName(self):
|
82
|
-
"""算法名称
|
83
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
84
|
-
:rtype: str
|
85
|
-
"""
|
86
|
-
return self._AlgoName
|
87
|
-
|
88
|
-
@AlgoName.setter
|
89
|
-
def AlgoName(self, AlgoName):
|
90
|
-
self._AlgoName = AlgoName
|
91
|
-
|
92
|
-
@property
|
93
|
-
def Result(self):
|
94
|
-
"""算法返回的结果。
|
95
|
-
- 当算法类型为“OCR(1)”时,结果为文本字符串
|
96
|
-
- 当算法类型为“文本分类(2)”时,结果字符串为json对象数组:
|
97
|
-
Class:分类结果
|
98
|
-
Confidence:置信度
|
99
|
-
- 算法类型为“情感分析(3)”时,结果字符串为json对象:
|
100
|
-
Positive:正面情感概率
|
101
|
-
Negative:负面情感概率
|
102
|
-
Neutral:中性情感概率
|
103
|
-
- 当算法类型为“合同要素抽取(4)”时,结果字符串为json对象数组:
|
104
|
-
NodeName:一级要素名称
|
105
|
-
ItemName:二级要素名称
|
106
|
-
Content:要素文本内容
|
107
|
-
- 当算法类型为“实体识别(5)”时,结果字符串为json对象数组:
|
108
|
-
- Entity:实体类型
|
109
|
-
- Content:实体文本内容
|
110
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
111
|
-
:rtype: str
|
112
|
-
"""
|
113
|
-
return self._Result
|
114
|
-
|
115
|
-
@Result.setter
|
116
|
-
def Result(self, Result):
|
117
|
-
self._Result = Result
|
118
|
-
|
119
|
-
@property
|
120
|
-
def Error(self):
|
121
|
-
"""算法调用错误信息
|
122
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
123
|
-
:rtype: str
|
124
|
-
"""
|
125
|
-
return self._Error
|
126
|
-
|
127
|
-
@Error.setter
|
128
|
-
def Error(self, Error):
|
129
|
-
self._Error = Error
|
130
|
-
|
131
|
-
@property
|
132
|
-
def AlgoType(self):
|
133
|
-
"""算法类型:
|
134
|
-
1:OCR算法
|
135
|
-
2:文本分类算法
|
136
|
-
3:情感分析算法
|
137
|
-
4:合同要素抽取算法
|
138
|
-
5、实体识别算法
|
139
|
-
注意:此字段可能返回 null,表示取不到有效值。
|
140
|
-
:rtype: int
|
141
|
-
"""
|
142
|
-
return self._AlgoType
|
143
|
-
|
144
|
-
@AlgoType.setter
|
145
|
-
def AlgoType(self, AlgoType):
|
146
|
-
self._AlgoType = AlgoType
|
147
|
-
|
148
|
-
|
149
|
-
def _deserialize(self, params):
|
150
|
-
self._AlgoId = params.get("AlgoId")
|
151
|
-
self._AlgoName = params.get("AlgoName")
|
152
|
-
self._Result = params.get("Result")
|
153
|
-
self._Error = params.get("Error")
|
154
|
-
self._AlgoType = params.get("AlgoType")
|
155
|
-
memeber_set = set(params.keys())
|
156
|
-
for name, value in vars(self).items():
|
157
|
-
property_name = name[1:]
|
158
|
-
if property_name in memeber_set:
|
159
|
-
memeber_set.remove(property_name)
|
160
|
-
if len(memeber_set) > 0:
|
161
|
-
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
162
|
-
|
163
|
-
|
164
|
-
|
165
|
-
class DescribeInvocationResultRequest(AbstractModel):
|
166
|
-
"""DescribeInvocationResult请求参数结构体
|
167
|
-
|
168
|
-
"""
|
169
|
-
|
170
|
-
def __init__(self):
|
171
|
-
r"""
|
172
|
-
:param _InvokeId: 调用id,为调用InvokeService接口返回的RequestId
|
173
|
-
:type InvokeId: str
|
174
|
-
"""
|
175
|
-
self._InvokeId = None
|
176
|
-
|
177
|
-
@property
|
178
|
-
def InvokeId(self):
|
179
|
-
"""调用id,为调用InvokeService接口返回的RequestId
|
180
|
-
:rtype: str
|
181
|
-
"""
|
182
|
-
return self._InvokeId
|
183
|
-
|
184
|
-
@InvokeId.setter
|
185
|
-
def InvokeId(self, InvokeId):
|
186
|
-
self._InvokeId = InvokeId
|
187
|
-
|
188
|
-
|
189
|
-
def _deserialize(self, params):
|
190
|
-
self._InvokeId = params.get("InvokeId")
|
191
|
-
memeber_set = set(params.keys())
|
192
|
-
for name, value in vars(self).items():
|
193
|
-
property_name = name[1:]
|
194
|
-
if property_name in memeber_set:
|
195
|
-
memeber_set.remove(property_name)
|
196
|
-
if len(memeber_set) > 0:
|
197
|
-
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
198
|
-
|
199
|
-
|
200
|
-
|
201
|
-
class DescribeInvocationResultResponse(AbstractModel):
|
202
|
-
"""DescribeInvocationResult返回参数结构体
|
203
|
-
|
204
|
-
"""
|
205
|
-
|
206
|
-
def __init__(self):
|
207
|
-
r"""
|
208
|
-
:param _Results: 服务的调用结果
|
209
|
-
:type Results: list of AlgorithmResult
|
210
|
-
:param _Status: 0:获取结果失败
|
211
|
-
1:结果还没有生成,继续轮询
|
212
|
-
2:获取结果成功
|
213
|
-
:type Status: int
|
214
|
-
:param _RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
215
|
-
:type RequestId: str
|
216
|
-
"""
|
217
|
-
self._Results = None
|
218
|
-
self._Status = None
|
219
|
-
self._RequestId = None
|
220
|
-
|
221
|
-
@property
|
222
|
-
def Results(self):
|
223
|
-
"""服务的调用结果
|
224
|
-
:rtype: list of AlgorithmResult
|
225
|
-
"""
|
226
|
-
return self._Results
|
227
|
-
|
228
|
-
@Results.setter
|
229
|
-
def Results(self, Results):
|
230
|
-
self._Results = Results
|
231
|
-
|
232
|
-
@property
|
233
|
-
def Status(self):
|
234
|
-
"""0:获取结果失败
|
235
|
-
1:结果还没有生成,继续轮询
|
236
|
-
2:获取结果成功
|
237
|
-
:rtype: int
|
238
|
-
"""
|
239
|
-
return self._Status
|
240
|
-
|
241
|
-
@Status.setter
|
242
|
-
def Status(self, Status):
|
243
|
-
self._Status = Status
|
244
|
-
|
245
|
-
@property
|
246
|
-
def RequestId(self):
|
247
|
-
"""唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
248
|
-
:rtype: str
|
249
|
-
"""
|
250
|
-
return self._RequestId
|
251
|
-
|
252
|
-
@RequestId.setter
|
253
|
-
def RequestId(self, RequestId):
|
254
|
-
self._RequestId = RequestId
|
255
|
-
|
256
|
-
|
257
|
-
def _deserialize(self, params):
|
258
|
-
if params.get("Results") is not None:
|
259
|
-
self._Results = []
|
260
|
-
for item in params.get("Results"):
|
261
|
-
obj = AlgorithmResult()
|
262
|
-
obj._deserialize(item)
|
263
|
-
self._Results.append(obj)
|
264
|
-
self._Status = params.get("Status")
|
265
|
-
self._RequestId = params.get("RequestId")
|
266
|
-
|
267
|
-
|
268
|
-
class InvokeServiceRequest(AbstractModel):
|
269
|
-
"""InvokeService请求参数结构体
|
270
|
-
|
271
|
-
"""
|
272
|
-
|
273
|
-
def __init__(self):
|
274
|
-
r"""
|
275
|
-
:param _ServiceId: 待调用的服务ID。
|
276
|
-
:type ServiceId: str
|
277
|
-
:param _ServiceStatus: 要调用服务的状态:0表示调试版本,1表示上线版本
|
278
|
-
:type ServiceStatus: int
|
279
|
-
:param _FileUrl: 用于测试的文档的URL。
|
280
|
-
:type FileUrl: str
|
281
|
-
:param _Input: 用于测试的文本,当此值不为空时,调用内容以此参数的值为准。
|
282
|
-
:type Input: str
|
283
|
-
"""
|
284
|
-
self._ServiceId = None
|
285
|
-
self._ServiceStatus = None
|
286
|
-
self._FileUrl = None
|
287
|
-
self._Input = None
|
288
|
-
|
289
|
-
@property
|
290
|
-
def ServiceId(self):
|
291
|
-
"""待调用的服务ID。
|
292
|
-
:rtype: str
|
293
|
-
"""
|
294
|
-
return self._ServiceId
|
295
|
-
|
296
|
-
@ServiceId.setter
|
297
|
-
def ServiceId(self, ServiceId):
|
298
|
-
self._ServiceId = ServiceId
|
299
|
-
|
300
|
-
@property
|
301
|
-
def ServiceStatus(self):
|
302
|
-
"""要调用服务的状态:0表示调试版本,1表示上线版本
|
303
|
-
:rtype: int
|
304
|
-
"""
|
305
|
-
return self._ServiceStatus
|
306
|
-
|
307
|
-
@ServiceStatus.setter
|
308
|
-
def ServiceStatus(self, ServiceStatus):
|
309
|
-
self._ServiceStatus = ServiceStatus
|
310
|
-
|
311
|
-
@property
|
312
|
-
def FileUrl(self):
|
313
|
-
"""用于测试的文档的URL。
|
314
|
-
:rtype: str
|
315
|
-
"""
|
316
|
-
return self._FileUrl
|
317
|
-
|
318
|
-
@FileUrl.setter
|
319
|
-
def FileUrl(self, FileUrl):
|
320
|
-
self._FileUrl = FileUrl
|
321
|
-
|
322
|
-
@property
|
323
|
-
def Input(self):
|
324
|
-
"""用于测试的文本,当此值不为空时,调用内容以此参数的值为准。
|
325
|
-
:rtype: str
|
326
|
-
"""
|
327
|
-
return self._Input
|
328
|
-
|
329
|
-
@Input.setter
|
330
|
-
def Input(self, Input):
|
331
|
-
self._Input = Input
|
332
|
-
|
333
|
-
|
334
|
-
def _deserialize(self, params):
|
335
|
-
self._ServiceId = params.get("ServiceId")
|
336
|
-
self._ServiceStatus = params.get("ServiceStatus")
|
337
|
-
self._FileUrl = params.get("FileUrl")
|
338
|
-
self._Input = params.get("Input")
|
339
|
-
memeber_set = set(params.keys())
|
340
|
-
for name, value in vars(self).items():
|
341
|
-
property_name = name[1:]
|
342
|
-
if property_name in memeber_set:
|
343
|
-
memeber_set.remove(property_name)
|
344
|
-
if len(memeber_set) > 0:
|
345
|
-
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
346
|
-
|
347
|
-
|
348
|
-
|
349
|
-
class InvokeServiceResponse(AbstractModel):
|
350
|
-
"""InvokeService返回参数结构体
|
351
|
-
|
352
|
-
"""
|
353
|
-
|
354
|
-
def __init__(self):
|
355
|
-
r"""
|
356
|
-
:param _RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
357
|
-
:type RequestId: str
|
358
|
-
"""
|
359
|
-
self._RequestId = None
|
360
|
-
|
361
|
-
@property
|
362
|
-
def RequestId(self):
|
363
|
-
"""唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
|
364
|
-
:rtype: str
|
365
|
-
"""
|
366
|
-
return self._RequestId
|
367
|
-
|
368
|
-
@RequestId.setter
|
369
|
-
def RequestId(self, RequestId):
|
370
|
-
self._RequestId = RequestId
|
371
|
-
|
372
|
-
|
373
|
-
def _deserialize(self, params):
|
374
|
-
self._RequestId = params.get("RequestId")
|