tencentcloud-sdk-python 3.0.1479__py2.py3-none-any.whl → 3.0.1481__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.
Potentially problematic release.
This version of tencentcloud-sdk-python might be problematic. Click here for more details.
- tencentcloud/__init__.py +1 -1
- tencentcloud/autoscaling/v20180419/autoscaling_client.py +2 -2
- tencentcloud/autoscaling/v20180419/models.py +42 -0
- tencentcloud/billing/v20180709/models.py +8 -8
- tencentcloud/cam/v20190116/errorcodes.py +3 -0
- tencentcloud/cam/v20190116/models.py +0 -2
- tencentcloud/cdn/v20180606/errorcodes.py +3 -0
- tencentcloud/cdwdoris/v20211228/models.py +20 -0
- tencentcloud/ckafka/v20190819/models.py +2 -0
- tencentcloud/cloudaudit/v20190319/models.py +17 -0
- tencentcloud/cls/v20201016/errorcodes.py +9 -0
- tencentcloud/cvm/v20170312/models.py +2 -32
- tencentcloud/dbbrain/v20210527/models.py +18 -3
- tencentcloud/dlc/v20210125/models.py +45 -0
- tencentcloud/ess/v20201111/models.py +101 -2
- tencentcloud/essbasic/v20210526/models.py +139 -10
- tencentcloud/iotexplorer/v20190423/iotexplorer_client.py +46 -0
- tencentcloud/iotexplorer/v20190423/models.py +162 -0
- tencentcloud/lcic/v20220817/models.py +22 -2
- tencentcloud/live/v20180801/models.py +2 -0
- tencentcloud/lke/v20231130/models.py +4 -2
- tencentcloud/lkeap/v20240522/errorcodes.py +1 -1
- tencentcloud/monitor/v20180724/models.py +30 -0
- tencentcloud/mps/v20190612/errorcodes.py +6 -0
- tencentcloud/mps/v20190612/models.py +231 -4
- tencentcloud/oceanus/v20190422/models.py +4 -4
- tencentcloud/ocr/v20181119/models.py +159 -0
- tencentcloud/ocr/v20181119/ocr_client.py +25 -0
- tencentcloud/organization/v20210331/models.py +15 -0
- tencentcloud/postgres/v20170312/errorcodes.py +9 -0
- tencentcloud/postgres/v20170312/models.py +488 -79
- tencentcloud/redis/v20180412/models.py +213 -24
- tencentcloud/region/v20220627/models.py +0 -2
- tencentcloud/sqlserver/v20180328/models.py +49 -4
- tencentcloud/svp/v20240125/models.py +21 -4
- tencentcloud/tag/v20180813/models.py +5 -5
- tencentcloud/tcss/v20201101/models.py +157 -0
- tencentcloud/teo/v20220901/models.py +1963 -220
- tencentcloud/tione/v20211111/models.py +162 -0
- tencentcloud/tione/v20211111/tione_client.py +69 -0
- tencentcloud/tke/v20180525/models.py +136 -22
- tencentcloud/tke/v20220501/models.py +21 -6
- tencentcloud/tms/v20201229/errorcodes.py +30 -0
- tencentcloud/tms/v20201229/models.py +461 -0
- tencentcloud/tms/v20201229/tms_client.py +48 -1
- tencentcloud/trro/v20220325/errorcodes.py +3 -0
- tencentcloud/trro/v20220325/models.py +739 -0
- tencentcloud/trro/v20220325/trro_client.py +46 -0
- tencentcloud/trtc/v20190722/models.py +32 -36
- tencentcloud/tsf/v20180326/errorcodes.py +3 -0
- tencentcloud/tsf/v20180326/models.py +96 -0
- tencentcloud/vclm/v20240523/models.py +260 -0
- tencentcloud/vclm/v20240523/vclm_client.py +46 -0
- tencentcloud/vpc/v20170312/models.py +175 -10
- tencentcloud/vpc/v20170312/vpc_client.py +23 -0
- {tencentcloud_sdk_python-3.0.1479.dist-info → tencentcloud_sdk_python-3.0.1481.dist-info}/METADATA +1 -1
- {tencentcloud_sdk_python-3.0.1479.dist-info → tencentcloud_sdk_python-3.0.1481.dist-info}/RECORD +60 -60
- {tencentcloud_sdk_python-3.0.1479.dist-info → tencentcloud_sdk_python-3.0.1481.dist-info}/LICENSE +0 -0
- {tencentcloud_sdk_python-3.0.1479.dist-info → tencentcloud_sdk_python-3.0.1481.dist-info}/WHEEL +0 -0
- {tencentcloud_sdk_python-3.0.1479.dist-info → tencentcloud_sdk_python-3.0.1481.dist-info}/top_level.txt +0 -0
|
@@ -44,6 +44,36 @@ INVALIDPARAMETERVALUE_ERRTEXTCONTENTTYPE = 'InvalidParameterValue.ErrTextContent
|
|
|
44
44
|
# Type参数值不支持
|
|
45
45
|
INVALIDPARAMETERVALUE_ERRTYPE = 'InvalidParameterValue.ErrType'
|
|
46
46
|
|
|
47
|
+
# BizType参数错误
|
|
48
|
+
INVALIDPARAMETERVALUE_INVALIDBIZTYPE = 'InvalidParameterValue.InvalidBizType'
|
|
49
|
+
|
|
50
|
+
# InvalidParameterValue.InvalidContent
|
|
51
|
+
INVALIDPARAMETERVALUE_INVALIDCONTENT = 'InvalidParameterValue.InvalidContent'
|
|
52
|
+
|
|
53
|
+
# ContentType参数错误
|
|
54
|
+
INVALIDPARAMETERVALUE_INVALIDCONTENTTYPE = 'InvalidParameterValue.InvalidContentType'
|
|
55
|
+
|
|
56
|
+
# FileName参数错误
|
|
57
|
+
INVALIDPARAMETERVALUE_INVALIDFILENAME = 'InvalidParameterValue.InvalidFileName'
|
|
58
|
+
|
|
59
|
+
# FileType参数错误
|
|
60
|
+
INVALIDPARAMETERVALUE_INVALIDFILETYPE = 'InvalidParameterValue.InvalidFileType'
|
|
61
|
+
|
|
62
|
+
# FileUrl参数错误
|
|
63
|
+
INVALIDPARAMETERVALUE_INVALIDFILEURL = 'InvalidParameterValue.InvalidFileUrl'
|
|
64
|
+
|
|
65
|
+
# Requirement参数错误
|
|
66
|
+
INVALIDPARAMETERVALUE_INVALIDREQUIREMENT = 'InvalidParameterValue.InvalidRequirement'
|
|
67
|
+
|
|
68
|
+
# TaskId参数错误
|
|
69
|
+
INVALIDPARAMETERVALUE_INVALIDTASKID = 'InvalidParameterValue.InvalidTaskId'
|
|
70
|
+
|
|
71
|
+
# Verbose参数错误
|
|
72
|
+
INVALIDPARAMETERVALUE_INVALIDVERBOSE = 'InvalidParameterValue.InvalidVerbose'
|
|
73
|
+
|
|
74
|
+
# 任务ID不存在
|
|
75
|
+
INVALIDPARAMETERVALUE_TASKIDNOTFOUND = 'InvalidParameterValue.TaskIdNotFound'
|
|
76
|
+
|
|
47
77
|
# 请求的次数超过了频率限制。
|
|
48
78
|
REQUESTLIMITEXCEEDED = 'RequestLimitExceeded'
|
|
49
79
|
|
|
@@ -18,6 +18,148 @@ import warnings
|
|
|
18
18
|
from tencentcloud.common.abstract_model import AbstractModel
|
|
19
19
|
|
|
20
20
|
|
|
21
|
+
class CreateFinancialLLMTaskRequest(AbstractModel):
|
|
22
|
+
r"""CreateFinancialLLMTask请求参数结构体
|
|
23
|
+
|
|
24
|
+
"""
|
|
25
|
+
|
|
26
|
+
def __init__(self):
|
|
27
|
+
r"""
|
|
28
|
+
:param _BizType: 审核策略BizType
|
|
29
|
+
:type BizType: str
|
|
30
|
+
:param _FileType: 待审文件类型,目前支持:PDF, DOC, DOCX
|
|
31
|
+
:type FileType: str
|
|
32
|
+
:param _ContentType: 送审内容类型:1-文档,2-文本
|
|
33
|
+
:type ContentType: int
|
|
34
|
+
:param _Content: 送审内容,根据ContentType字段的取值,传入送审文档的Url链接,或送审文本的Base64编码
|
|
35
|
+
|
|
36
|
+
文档限制:
|
|
37
|
+
|
|
38
|
+
- 文件下载时间不超过15秒(文件存储于腾讯云的Url可保障更高的下载速度和稳定性,建议文件存储于腾讯云。非腾讯云存储的 Url 速度和稳定性可能受一定影响。)
|
|
39
|
+
- 所下载文件经 Base64 编码后不超过支持的文件大小:PDF/DOC/DOCX - 200M
|
|
40
|
+
- 文档解析后的纯文本长度不超过 10000字
|
|
41
|
+
|
|
42
|
+
文本限制:Base64解码后的文本长度不超过10000字
|
|
43
|
+
|
|
44
|
+
:type Content: str
|
|
45
|
+
"""
|
|
46
|
+
self._BizType = None
|
|
47
|
+
self._FileType = None
|
|
48
|
+
self._ContentType = None
|
|
49
|
+
self._Content = None
|
|
50
|
+
|
|
51
|
+
@property
|
|
52
|
+
def BizType(self):
|
|
53
|
+
r"""审核策略BizType
|
|
54
|
+
:rtype: str
|
|
55
|
+
"""
|
|
56
|
+
return self._BizType
|
|
57
|
+
|
|
58
|
+
@BizType.setter
|
|
59
|
+
def BizType(self, BizType):
|
|
60
|
+
self._BizType = BizType
|
|
61
|
+
|
|
62
|
+
@property
|
|
63
|
+
def FileType(self):
|
|
64
|
+
r"""待审文件类型,目前支持:PDF, DOC, DOCX
|
|
65
|
+
:rtype: str
|
|
66
|
+
"""
|
|
67
|
+
return self._FileType
|
|
68
|
+
|
|
69
|
+
@FileType.setter
|
|
70
|
+
def FileType(self, FileType):
|
|
71
|
+
self._FileType = FileType
|
|
72
|
+
|
|
73
|
+
@property
|
|
74
|
+
def ContentType(self):
|
|
75
|
+
r"""送审内容类型:1-文档,2-文本
|
|
76
|
+
:rtype: int
|
|
77
|
+
"""
|
|
78
|
+
return self._ContentType
|
|
79
|
+
|
|
80
|
+
@ContentType.setter
|
|
81
|
+
def ContentType(self, ContentType):
|
|
82
|
+
self._ContentType = ContentType
|
|
83
|
+
|
|
84
|
+
@property
|
|
85
|
+
def Content(self):
|
|
86
|
+
r"""送审内容,根据ContentType字段的取值,传入送审文档的Url链接,或送审文本的Base64编码
|
|
87
|
+
|
|
88
|
+
文档限制:
|
|
89
|
+
|
|
90
|
+
- 文件下载时间不超过15秒(文件存储于腾讯云的Url可保障更高的下载速度和稳定性,建议文件存储于腾讯云。非腾讯云存储的 Url 速度和稳定性可能受一定影响。)
|
|
91
|
+
- 所下载文件经 Base64 编码后不超过支持的文件大小:PDF/DOC/DOCX - 200M
|
|
92
|
+
- 文档解析后的纯文本长度不超过 10000字
|
|
93
|
+
|
|
94
|
+
文本限制:Base64解码后的文本长度不超过10000字
|
|
95
|
+
|
|
96
|
+
:rtype: str
|
|
97
|
+
"""
|
|
98
|
+
return self._Content
|
|
99
|
+
|
|
100
|
+
@Content.setter
|
|
101
|
+
def Content(self, Content):
|
|
102
|
+
self._Content = Content
|
|
103
|
+
|
|
104
|
+
|
|
105
|
+
def _deserialize(self, params):
|
|
106
|
+
self._BizType = params.get("BizType")
|
|
107
|
+
self._FileType = params.get("FileType")
|
|
108
|
+
self._ContentType = params.get("ContentType")
|
|
109
|
+
self._Content = params.get("Content")
|
|
110
|
+
memeber_set = set(params.keys())
|
|
111
|
+
for name, value in vars(self).items():
|
|
112
|
+
property_name = name[1:]
|
|
113
|
+
if property_name in memeber_set:
|
|
114
|
+
memeber_set.remove(property_name)
|
|
115
|
+
if len(memeber_set) > 0:
|
|
116
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
117
|
+
|
|
118
|
+
|
|
119
|
+
|
|
120
|
+
class CreateFinancialLLMTaskResponse(AbstractModel):
|
|
121
|
+
r"""CreateFinancialLLMTask返回参数结构体
|
|
122
|
+
|
|
123
|
+
"""
|
|
124
|
+
|
|
125
|
+
def __init__(self):
|
|
126
|
+
r"""
|
|
127
|
+
:param _TaskId: 金融大模型审校任务ID
|
|
128
|
+
:type TaskId: str
|
|
129
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
130
|
+
:type RequestId: str
|
|
131
|
+
"""
|
|
132
|
+
self._TaskId = None
|
|
133
|
+
self._RequestId = None
|
|
134
|
+
|
|
135
|
+
@property
|
|
136
|
+
def TaskId(self):
|
|
137
|
+
r"""金融大模型审校任务ID
|
|
138
|
+
:rtype: str
|
|
139
|
+
"""
|
|
140
|
+
return self._TaskId
|
|
141
|
+
|
|
142
|
+
@TaskId.setter
|
|
143
|
+
def TaskId(self, TaskId):
|
|
144
|
+
self._TaskId = TaskId
|
|
145
|
+
|
|
146
|
+
@property
|
|
147
|
+
def RequestId(self):
|
|
148
|
+
r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
149
|
+
:rtype: str
|
|
150
|
+
"""
|
|
151
|
+
return self._RequestId
|
|
152
|
+
|
|
153
|
+
@RequestId.setter
|
|
154
|
+
def RequestId(self, RequestId):
|
|
155
|
+
self._RequestId = RequestId
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
def _deserialize(self, params):
|
|
159
|
+
self._TaskId = params.get("TaskId")
|
|
160
|
+
self._RequestId = params.get("RequestId")
|
|
161
|
+
|
|
162
|
+
|
|
21
163
|
class DetailResults(AbstractModel):
|
|
22
164
|
r"""文本审核返回的详细结果
|
|
23
165
|
|
|
@@ -331,6 +473,295 @@ class Device(AbstractModel):
|
|
|
331
473
|
|
|
332
474
|
|
|
333
475
|
|
|
476
|
+
class FinancialLLMViolationDetail(AbstractModel):
|
|
477
|
+
r"""金融大模型审校 违规明细
|
|
478
|
+
|
|
479
|
+
"""
|
|
480
|
+
|
|
481
|
+
def __init__(self):
|
|
482
|
+
r"""
|
|
483
|
+
:param _Label: 违规点
|
|
484
|
+
:type Label: str
|
|
485
|
+
:param _Suggestion: 处置建议
|
|
486
|
+
:type Suggestion: str
|
|
487
|
+
:param _Reasons: 违规原因列表
|
|
488
|
+
:type Reasons: list of FinancialLLMViolationReason
|
|
489
|
+
"""
|
|
490
|
+
self._Label = None
|
|
491
|
+
self._Suggestion = None
|
|
492
|
+
self._Reasons = None
|
|
493
|
+
|
|
494
|
+
@property
|
|
495
|
+
def Label(self):
|
|
496
|
+
r"""违规点
|
|
497
|
+
:rtype: str
|
|
498
|
+
"""
|
|
499
|
+
return self._Label
|
|
500
|
+
|
|
501
|
+
@Label.setter
|
|
502
|
+
def Label(self, Label):
|
|
503
|
+
self._Label = Label
|
|
504
|
+
|
|
505
|
+
@property
|
|
506
|
+
def Suggestion(self):
|
|
507
|
+
r"""处置建议
|
|
508
|
+
:rtype: str
|
|
509
|
+
"""
|
|
510
|
+
return self._Suggestion
|
|
511
|
+
|
|
512
|
+
@Suggestion.setter
|
|
513
|
+
def Suggestion(self, Suggestion):
|
|
514
|
+
self._Suggestion = Suggestion
|
|
515
|
+
|
|
516
|
+
@property
|
|
517
|
+
def Reasons(self):
|
|
518
|
+
r"""违规原因列表
|
|
519
|
+
:rtype: list of FinancialLLMViolationReason
|
|
520
|
+
"""
|
|
521
|
+
return self._Reasons
|
|
522
|
+
|
|
523
|
+
@Reasons.setter
|
|
524
|
+
def Reasons(self, Reasons):
|
|
525
|
+
self._Reasons = Reasons
|
|
526
|
+
|
|
527
|
+
|
|
528
|
+
def _deserialize(self, params):
|
|
529
|
+
self._Label = params.get("Label")
|
|
530
|
+
self._Suggestion = params.get("Suggestion")
|
|
531
|
+
if params.get("Reasons") is not None:
|
|
532
|
+
self._Reasons = []
|
|
533
|
+
for item in params.get("Reasons"):
|
|
534
|
+
obj = FinancialLLMViolationReason()
|
|
535
|
+
obj._deserialize(item)
|
|
536
|
+
self._Reasons.append(obj)
|
|
537
|
+
memeber_set = set(params.keys())
|
|
538
|
+
for name, value in vars(self).items():
|
|
539
|
+
property_name = name[1:]
|
|
540
|
+
if property_name in memeber_set:
|
|
541
|
+
memeber_set.remove(property_name)
|
|
542
|
+
if len(memeber_set) > 0:
|
|
543
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
544
|
+
|
|
545
|
+
|
|
546
|
+
|
|
547
|
+
class FinancialLLMViolationReason(AbstractModel):
|
|
548
|
+
r"""金融大模型审校-违规原因
|
|
549
|
+
|
|
550
|
+
"""
|
|
551
|
+
|
|
552
|
+
def __init__(self):
|
|
553
|
+
r"""
|
|
554
|
+
:param _TargetText: 违规原文片段
|
|
555
|
+
:type TargetText: str
|
|
556
|
+
:param _Reason: 违规原因
|
|
557
|
+
:type Reason: str
|
|
558
|
+
"""
|
|
559
|
+
self._TargetText = None
|
|
560
|
+
self._Reason = None
|
|
561
|
+
|
|
562
|
+
@property
|
|
563
|
+
def TargetText(self):
|
|
564
|
+
r"""违规原文片段
|
|
565
|
+
:rtype: str
|
|
566
|
+
"""
|
|
567
|
+
return self._TargetText
|
|
568
|
+
|
|
569
|
+
@TargetText.setter
|
|
570
|
+
def TargetText(self, TargetText):
|
|
571
|
+
self._TargetText = TargetText
|
|
572
|
+
|
|
573
|
+
@property
|
|
574
|
+
def Reason(self):
|
|
575
|
+
r"""违规原因
|
|
576
|
+
:rtype: str
|
|
577
|
+
"""
|
|
578
|
+
return self._Reason
|
|
579
|
+
|
|
580
|
+
@Reason.setter
|
|
581
|
+
def Reason(self, Reason):
|
|
582
|
+
self._Reason = Reason
|
|
583
|
+
|
|
584
|
+
|
|
585
|
+
def _deserialize(self, params):
|
|
586
|
+
self._TargetText = params.get("TargetText")
|
|
587
|
+
self._Reason = params.get("Reason")
|
|
588
|
+
memeber_set = set(params.keys())
|
|
589
|
+
for name, value in vars(self).items():
|
|
590
|
+
property_name = name[1:]
|
|
591
|
+
if property_name in memeber_set:
|
|
592
|
+
memeber_set.remove(property_name)
|
|
593
|
+
if len(memeber_set) > 0:
|
|
594
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
595
|
+
|
|
596
|
+
|
|
597
|
+
|
|
598
|
+
class GetFinancialLLMTaskResultRequest(AbstractModel):
|
|
599
|
+
r"""GetFinancialLLMTaskResult请求参数结构体
|
|
600
|
+
|
|
601
|
+
"""
|
|
602
|
+
|
|
603
|
+
def __init__(self):
|
|
604
|
+
r"""
|
|
605
|
+
:param _TaskId: 金融大模型审校任务ID
|
|
606
|
+
:type TaskId: str
|
|
607
|
+
"""
|
|
608
|
+
self._TaskId = None
|
|
609
|
+
|
|
610
|
+
@property
|
|
611
|
+
def TaskId(self):
|
|
612
|
+
r"""金融大模型审校任务ID
|
|
613
|
+
:rtype: str
|
|
614
|
+
"""
|
|
615
|
+
return self._TaskId
|
|
616
|
+
|
|
617
|
+
@TaskId.setter
|
|
618
|
+
def TaskId(self, TaskId):
|
|
619
|
+
self._TaskId = TaskId
|
|
620
|
+
|
|
621
|
+
|
|
622
|
+
def _deserialize(self, params):
|
|
623
|
+
self._TaskId = params.get("TaskId")
|
|
624
|
+
memeber_set = set(params.keys())
|
|
625
|
+
for name, value in vars(self).items():
|
|
626
|
+
property_name = name[1:]
|
|
627
|
+
if property_name in memeber_set:
|
|
628
|
+
memeber_set.remove(property_name)
|
|
629
|
+
if len(memeber_set) > 0:
|
|
630
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
631
|
+
|
|
632
|
+
|
|
633
|
+
|
|
634
|
+
class GetFinancialLLMTaskResultResponse(AbstractModel):
|
|
635
|
+
r"""GetFinancialLLMTaskResult返回参数结构体
|
|
636
|
+
|
|
637
|
+
"""
|
|
638
|
+
|
|
639
|
+
def __init__(self):
|
|
640
|
+
r"""
|
|
641
|
+
:param _Status: 审校任务状态:
|
|
642
|
+
|
|
643
|
+
- Success: 成功
|
|
644
|
+
- Processing: 处理中,请等待
|
|
645
|
+
- Failed: 失败
|
|
646
|
+
:type Status: str
|
|
647
|
+
:param _ModerationResult: 大模型审校结果
|
|
648
|
+
:type ModerationResult: str
|
|
649
|
+
:param _FailureReason: 审校任务失败原因,仅当任务失败时有值
|
|
650
|
+
:type FailureReason: str
|
|
651
|
+
:param _StartTime: 审校任务开始时间
|
|
652
|
+
:type StartTime: str
|
|
653
|
+
:param _ReviewedLabels: 本次检测的违规点列表
|
|
654
|
+
:type ReviewedLabels: list of str
|
|
655
|
+
:param _Details: 违规明细
|
|
656
|
+
:type Details: list of FinancialLLMViolationDetail
|
|
657
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
658
|
+
:type RequestId: str
|
|
659
|
+
"""
|
|
660
|
+
self._Status = None
|
|
661
|
+
self._ModerationResult = None
|
|
662
|
+
self._FailureReason = None
|
|
663
|
+
self._StartTime = None
|
|
664
|
+
self._ReviewedLabels = None
|
|
665
|
+
self._Details = None
|
|
666
|
+
self._RequestId = None
|
|
667
|
+
|
|
668
|
+
@property
|
|
669
|
+
def Status(self):
|
|
670
|
+
r"""审校任务状态:
|
|
671
|
+
|
|
672
|
+
- Success: 成功
|
|
673
|
+
- Processing: 处理中,请等待
|
|
674
|
+
- Failed: 失败
|
|
675
|
+
:rtype: str
|
|
676
|
+
"""
|
|
677
|
+
return self._Status
|
|
678
|
+
|
|
679
|
+
@Status.setter
|
|
680
|
+
def Status(self, Status):
|
|
681
|
+
self._Status = Status
|
|
682
|
+
|
|
683
|
+
@property
|
|
684
|
+
def ModerationResult(self):
|
|
685
|
+
r"""大模型审校结果
|
|
686
|
+
:rtype: str
|
|
687
|
+
"""
|
|
688
|
+
return self._ModerationResult
|
|
689
|
+
|
|
690
|
+
@ModerationResult.setter
|
|
691
|
+
def ModerationResult(self, ModerationResult):
|
|
692
|
+
self._ModerationResult = ModerationResult
|
|
693
|
+
|
|
694
|
+
@property
|
|
695
|
+
def FailureReason(self):
|
|
696
|
+
r"""审校任务失败原因,仅当任务失败时有值
|
|
697
|
+
:rtype: str
|
|
698
|
+
"""
|
|
699
|
+
return self._FailureReason
|
|
700
|
+
|
|
701
|
+
@FailureReason.setter
|
|
702
|
+
def FailureReason(self, FailureReason):
|
|
703
|
+
self._FailureReason = FailureReason
|
|
704
|
+
|
|
705
|
+
@property
|
|
706
|
+
def StartTime(self):
|
|
707
|
+
r"""审校任务开始时间
|
|
708
|
+
:rtype: str
|
|
709
|
+
"""
|
|
710
|
+
return self._StartTime
|
|
711
|
+
|
|
712
|
+
@StartTime.setter
|
|
713
|
+
def StartTime(self, StartTime):
|
|
714
|
+
self._StartTime = StartTime
|
|
715
|
+
|
|
716
|
+
@property
|
|
717
|
+
def ReviewedLabels(self):
|
|
718
|
+
r"""本次检测的违规点列表
|
|
719
|
+
:rtype: list of str
|
|
720
|
+
"""
|
|
721
|
+
return self._ReviewedLabels
|
|
722
|
+
|
|
723
|
+
@ReviewedLabels.setter
|
|
724
|
+
def ReviewedLabels(self, ReviewedLabels):
|
|
725
|
+
self._ReviewedLabels = ReviewedLabels
|
|
726
|
+
|
|
727
|
+
@property
|
|
728
|
+
def Details(self):
|
|
729
|
+
r"""违规明细
|
|
730
|
+
:rtype: list of FinancialLLMViolationDetail
|
|
731
|
+
"""
|
|
732
|
+
return self._Details
|
|
733
|
+
|
|
734
|
+
@Details.setter
|
|
735
|
+
def Details(self, Details):
|
|
736
|
+
self._Details = Details
|
|
737
|
+
|
|
738
|
+
@property
|
|
739
|
+
def RequestId(self):
|
|
740
|
+
r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
741
|
+
:rtype: str
|
|
742
|
+
"""
|
|
743
|
+
return self._RequestId
|
|
744
|
+
|
|
745
|
+
@RequestId.setter
|
|
746
|
+
def RequestId(self, RequestId):
|
|
747
|
+
self._RequestId = RequestId
|
|
748
|
+
|
|
749
|
+
|
|
750
|
+
def _deserialize(self, params):
|
|
751
|
+
self._Status = params.get("Status")
|
|
752
|
+
self._ModerationResult = params.get("ModerationResult")
|
|
753
|
+
self._FailureReason = params.get("FailureReason")
|
|
754
|
+
self._StartTime = params.get("StartTime")
|
|
755
|
+
self._ReviewedLabels = params.get("ReviewedLabels")
|
|
756
|
+
if params.get("Details") is not None:
|
|
757
|
+
self._Details = []
|
|
758
|
+
for item in params.get("Details"):
|
|
759
|
+
obj = FinancialLLMViolationDetail()
|
|
760
|
+
obj._deserialize(item)
|
|
761
|
+
self._Details.append(obj)
|
|
762
|
+
self._RequestId = params.get("RequestId")
|
|
763
|
+
|
|
764
|
+
|
|
334
765
|
class HitInfo(AbstractModel):
|
|
335
766
|
r"""关键词命中位置信息
|
|
336
767
|
|
|
@@ -756,6 +1187,8 @@ class TextModerationRequest(AbstractModel):
|
|
|
756
1187
|
:type SourceLanguage: str
|
|
757
1188
|
:param _Type: 审核的业务类型,枚举值包括"TEXT"和"TEXT_AIGC"。其中"TEXT"表示传统文本审核,"TEXT_AIGC"表示AI生成检测(生成检测能力具体能力了解可[参见文档](https://cloud.tencent.com/document/product/1124/118694))。
|
|
758
1189
|
:type Type: str
|
|
1190
|
+
:param _SessionId: 流式审核策略维度下的唯一会话ID
|
|
1191
|
+
:type SessionId: str
|
|
759
1192
|
"""
|
|
760
1193
|
self._Content = None
|
|
761
1194
|
self._BizType = None
|
|
@@ -764,6 +1197,7 @@ class TextModerationRequest(AbstractModel):
|
|
|
764
1197
|
self._Device = None
|
|
765
1198
|
self._SourceLanguage = None
|
|
766
1199
|
self._Type = None
|
|
1200
|
+
self._SessionId = None
|
|
767
1201
|
|
|
768
1202
|
@property
|
|
769
1203
|
def Content(self):
|
|
@@ -843,6 +1277,17 @@ class TextModerationRequest(AbstractModel):
|
|
|
843
1277
|
def Type(self, Type):
|
|
844
1278
|
self._Type = Type
|
|
845
1279
|
|
|
1280
|
+
@property
|
|
1281
|
+
def SessionId(self):
|
|
1282
|
+
r"""流式审核策略维度下的唯一会话ID
|
|
1283
|
+
:rtype: str
|
|
1284
|
+
"""
|
|
1285
|
+
return self._SessionId
|
|
1286
|
+
|
|
1287
|
+
@SessionId.setter
|
|
1288
|
+
def SessionId(self, SessionId):
|
|
1289
|
+
self._SessionId = SessionId
|
|
1290
|
+
|
|
846
1291
|
|
|
847
1292
|
def _deserialize(self, params):
|
|
848
1293
|
self._Content = params.get("Content")
|
|
@@ -856,6 +1301,7 @@ class TextModerationRequest(AbstractModel):
|
|
|
856
1301
|
self._Device._deserialize(params.get("Device"))
|
|
857
1302
|
self._SourceLanguage = params.get("SourceLanguage")
|
|
858
1303
|
self._Type = params.get("Type")
|
|
1304
|
+
self._SessionId = params.get("SessionId")
|
|
859
1305
|
memeber_set = set(params.keys())
|
|
860
1306
|
for name, value in vars(self).items():
|
|
861
1307
|
property_name = name[1:]
|
|
@@ -903,6 +1349,8 @@ class TextModerationResponse(AbstractModel):
|
|
|
903
1349
|
:type SentimentAnalysis: :class:`tencentcloud.tms.v20201229.models.SentimentAnalysis`
|
|
904
1350
|
:param _HitType: 该字段用于标识本次审核决策归因,比如text_nlp_tianji标识是由nlp tianji模型给出的审核决策,text_keyword_public标识命中了业务的关键词库
|
|
905
1351
|
:type HitType: str
|
|
1352
|
+
:param _SessionId: 流式审核策略维度下的唯一会话ID
|
|
1353
|
+
:type SessionId: str
|
|
906
1354
|
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
907
1355
|
:type RequestId: str
|
|
908
1356
|
"""
|
|
@@ -919,6 +1367,7 @@ class TextModerationResponse(AbstractModel):
|
|
|
919
1367
|
self._ContextText = None
|
|
920
1368
|
self._SentimentAnalysis = None
|
|
921
1369
|
self._HitType = None
|
|
1370
|
+
self._SessionId = None
|
|
922
1371
|
self._RequestId = None
|
|
923
1372
|
|
|
924
1373
|
@property
|
|
@@ -1068,6 +1517,17 @@ class TextModerationResponse(AbstractModel):
|
|
|
1068
1517
|
def HitType(self, HitType):
|
|
1069
1518
|
self._HitType = HitType
|
|
1070
1519
|
|
|
1520
|
+
@property
|
|
1521
|
+
def SessionId(self):
|
|
1522
|
+
r"""流式审核策略维度下的唯一会话ID
|
|
1523
|
+
:rtype: str
|
|
1524
|
+
"""
|
|
1525
|
+
return self._SessionId
|
|
1526
|
+
|
|
1527
|
+
@SessionId.setter
|
|
1528
|
+
def SessionId(self, SessionId):
|
|
1529
|
+
self._SessionId = SessionId
|
|
1530
|
+
|
|
1071
1531
|
@property
|
|
1072
1532
|
def RequestId(self):
|
|
1073
1533
|
r"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
@@ -1106,6 +1566,7 @@ class TextModerationResponse(AbstractModel):
|
|
|
1106
1566
|
self._SentimentAnalysis = SentimentAnalysis()
|
|
1107
1567
|
self._SentimentAnalysis._deserialize(params.get("SentimentAnalysis"))
|
|
1108
1568
|
self._HitType = params.get("HitType")
|
|
1569
|
+
self._SessionId = params.get("SessionId")
|
|
1109
1570
|
self._RequestId = params.get("RequestId")
|
|
1110
1571
|
|
|
1111
1572
|
|
|
@@ -26,6 +26,52 @@ class TmsClient(AbstractClient):
|
|
|
26
26
|
_service = 'tms'
|
|
27
27
|
|
|
28
28
|
|
|
29
|
+
def CreateFinancialLLMTask(self, request):
|
|
30
|
+
r"""创建金融大模型审校任务
|
|
31
|
+
|
|
32
|
+
:param request: Request instance for CreateFinancialLLMTask.
|
|
33
|
+
:type request: :class:`tencentcloud.tms.v20201229.models.CreateFinancialLLMTaskRequest`
|
|
34
|
+
:rtype: :class:`tencentcloud.tms.v20201229.models.CreateFinancialLLMTaskResponse`
|
|
35
|
+
|
|
36
|
+
"""
|
|
37
|
+
try:
|
|
38
|
+
params = request._serialize()
|
|
39
|
+
headers = request.headers
|
|
40
|
+
body = self.call("CreateFinancialLLMTask", params, headers=headers)
|
|
41
|
+
response = json.loads(body)
|
|
42
|
+
model = models.CreateFinancialLLMTaskResponse()
|
|
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 GetFinancialLLMTaskResult(self, request):
|
|
53
|
+
r"""获取金融大模型审校任务结果
|
|
54
|
+
|
|
55
|
+
:param request: Request instance for GetFinancialLLMTaskResult.
|
|
56
|
+
:type request: :class:`tencentcloud.tms.v20201229.models.GetFinancialLLMTaskResultRequest`
|
|
57
|
+
:rtype: :class:`tencentcloud.tms.v20201229.models.GetFinancialLLMTaskResultResponse`
|
|
58
|
+
|
|
59
|
+
"""
|
|
60
|
+
try:
|
|
61
|
+
params = request._serialize()
|
|
62
|
+
headers = request.headers
|
|
63
|
+
body = self.call("GetFinancialLLMTaskResult", params, headers=headers)
|
|
64
|
+
response = json.loads(body)
|
|
65
|
+
model = models.GetFinancialLLMTaskResultResponse()
|
|
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
|
+
|
|
29
75
|
def TextModeration(self, request):
|
|
30
76
|
r"""本接口(Text Moderation)用于提交文本内容进行智能审核任务。使用前请您使用腾讯云主账号登录控制台 [开通文本内容安全服务](https://console.cloud.tencent.com/cms) 并调整好对应的业务配置。
|
|
31
77
|
|
|
@@ -38,7 +84,8 @@ class TmsClient(AbstractClient):
|
|
|
38
84
|
- 支持识别多种违规场景,包括:低俗、谩骂、色情、广告等场景;
|
|
39
85
|
- 支持根据不同的业务场景配置自定义的审核策略,可在控制台文本内容安全-策略管理中配置;
|
|
40
86
|
- 支持用户自定义配置词库黑白名单,打击自定义识别类型的违规文本(目前仅支持黑名单配置);
|
|
41
|
-
-
|
|
87
|
+
- 支持在审核文本内容时同时关联账号或设备信息,可识别违规风险账号或设备;
|
|
88
|
+
- 支持大模型、聊天室等场景下的流式上下文审核。
|
|
42
89
|
|
|
43
90
|
### 接口调用说明:
|
|
44
91
|
- 文本内容大小支持:文本原文长度不能超过unicode编码长度10000个字符;
|