tccli 3.0.1098.1__py2.py3-none-any.whl → 3.0.1099.1__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.
- tccli/__init__.py +1 -1
- tccli/examples/cfw/v20190904/DescribeIPStatusList.md +4 -4
- tccli/examples/cls/v20201016/OpenKafkaConsumer.md +1 -1
- tccli/examples/cynosdb/v20190107/DescribeChangedParamsAfterUpgrade.md +31 -0
- tccli/examples/faceid/v20180301/GetFaceIdResult.md +3 -1
- tccli/examples/hunyuan/v20230901/ChatCompletions.md +43 -0
- tccli/examples/ims/v20200713/ImageModeration.md +4 -1
- tccli/examples/teo/v20220901/DescribeRealtimeLogDeliveryTasks.md +42 -21
- tccli/services/aiart/v20221229/api.json +1 -1
- tccli/services/ccc/v20200210/api.json +1 -1
- tccli/services/cfs/v20190719/api.json +27 -27
- tccli/services/cfw/v20190904/api.json +5 -5
- tccli/services/cfw/v20190904/examples.json +1 -1
- tccli/services/cloudstudio/v20230508/api.json +13 -4
- tccli/services/cls/v20201016/api.json +68 -44
- tccli/services/cls/v20201016/examples.json +1 -1
- tccli/services/cynosdb/cynosdb_client.py +53 -0
- tccli/services/cynosdb/v20190107/api.json +120 -2
- tccli/services/cynosdb/v20190107/examples.json +8 -0
- tccli/services/dcdb/v20180411/api.json +2 -2
- tccli/services/ess/v20201111/api.json +1 -1
- tccli/services/faceid/v20180301/api.json +21 -1
- tccli/services/faceid/v20180301/examples.json +1 -1
- tccli/services/hunyuan/hunyuan_client.py +53 -0
- tccli/services/hunyuan/v20230901/api.json +161 -22
- tccli/services/hunyuan/v20230901/examples.json +8 -0
- tccli/services/ims/v20200713/api.json +13 -0
- tccli/services/ims/v20200713/examples.json +1 -1
- tccli/services/lcic/v20220817/api.json +1 -1
- tccli/services/mariadb/v20170312/api.json +2 -2
- tccli/services/monitor/v20180724/api.json +1 -1
- tccli/services/mps/v20190612/api.json +46 -1
- tccli/services/rum/v20210622/api.json +2 -2
- tccli/services/teo/v20220901/api.json +128 -17
- tccli/services/teo/v20220901/examples.json +2 -2
- tccli/services/tmt/v20180321/api.json +1 -1
- tccli/services/waf/v20180125/api.json +2 -2
- {tccli-3.0.1098.1.dist-info → tccli-3.0.1099.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1098.1.dist-info → tccli-3.0.1099.1.dist-info}/RECORD +42 -40
- {tccli-3.0.1098.1.dist-info → tccli-3.0.1099.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1098.1.dist-info → tccli-3.0.1099.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1098.1.dist-info → tccli-3.0.1099.1.dist-info}/license_files/LICENSE +0 -0
@@ -15,7 +15,7 @@
|
|
15
15
|
"status": "online"
|
16
16
|
},
|
17
17
|
"CancelDcnJob": {
|
18
|
-
"document": "
|
18
|
+
"document": "本接口(CancelDcnJob)用于取消DCN同步",
|
19
19
|
"input": "CancelDcnJobRequest",
|
20
20
|
"name": "取消DCN同步",
|
21
21
|
"output": "CancelDcnJobResponse",
|
@@ -731,7 +731,7 @@
|
|
731
731
|
"example": "11211",
|
732
732
|
"member": "int64",
|
733
733
|
"name": "FlowId",
|
734
|
-
"
|
734
|
+
"output_required": true,
|
735
735
|
"type": "int",
|
736
736
|
"value_allowed_null": false
|
737
737
|
},
|
@@ -2768,7 +2768,7 @@
|
|
2768
2768
|
},
|
2769
2769
|
{
|
2770
2770
|
"disabled": false,
|
2771
|
-
"document": "
|
2771
|
+
"document": "plus版:描述当前请求所在设备的风险标签,详情如下:\n01-设备疑似被Root/设备疑似越狱\n02-设备疑似被注入\n03-设备疑似为模拟器\n04-设备疑似存在风险操作\n05-摄像头疑似被劫持\n06-疑似黑产设备\nnull-无设备风险\n增强版:此字段不生效,默认为null\n注意:此字段可能返回 null,表示取不到有效值。",
|
2772
2772
|
"example": "01",
|
2773
2773
|
"member": "string",
|
2774
2774
|
"name": "DeviceInfoTag",
|
@@ -2786,6 +2786,26 @@
|
|
2786
2786
|
"type": "string",
|
2787
2787
|
"value_allowed_null": true
|
2788
2788
|
},
|
2789
|
+
{
|
2790
|
+
"disabled": false,
|
2791
|
+
"document": "plus版:描述当前请求活体阶段被拒绝的详细原因,详情如下:\n01-用户全程闭眼\n02-用户未完成指定动作\n03-疑似翻拍攻击\n04-疑似合成图片\n05-疑似合成视频\n06-疑似合成动作\n07-疑似黑产模版\n08-疑似存在水印\n09-反光校验未通过\n10-最佳帧校验未通过\n11-人脸质量过差\n12-人脸距离不匹配\n13-疑似对抗样本攻击\nnull-无\n增强版:此字段不生效,默认为null\n注意:此字段可能返回 null,表示取不到有效值。",
|
2792
|
+
"example": "01",
|
2793
|
+
"member": "string",
|
2794
|
+
"name": "LivenessInfoTag",
|
2795
|
+
"output_required": true,
|
2796
|
+
"type": "string",
|
2797
|
+
"value_allowed_null": true
|
2798
|
+
},
|
2799
|
+
{
|
2800
|
+
"disabled": false,
|
2801
|
+
"document": "plus版:描述当前请求所在设备的风险等级,共4级,详情如下:\n1 - 安全\n2 - 低风险\n3 - 中风险\n4 - 高危\nnull - 未获取到风险等级\n增强版:此字段不生效,默认为null\n注意:此字段可能返回 null,表示取不到有效值。",
|
2802
|
+
"example": "1",
|
2803
|
+
"member": "string",
|
2804
|
+
"name": "DeviceInfoLevel",
|
2805
|
+
"output_required": true,
|
2806
|
+
"type": "string",
|
2807
|
+
"value_allowed_null": true
|
2808
|
+
},
|
2789
2809
|
{
|
2790
2810
|
"document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
|
2791
2811
|
"member": "string",
|
@@ -162,7 +162,7 @@
|
|
162
162
|
{
|
163
163
|
"document": "",
|
164
164
|
"input": "https://faceid.tencentcloudapi.com/?Action=GetFaceIdResult\n&FaceIdToken=CE661F1A-0F1E-45BD-BE13-34C05CEA7681\n&<公共请求参数>",
|
165
|
-
"output": "{\n \"Response\": {\n \"Result\": \"0\",\n \"Description\": \"成功\",\n \"IdCard\": \"23232323232\",\n \"Name\": \"王五\",\n \"Similarity\": 97.7,\n \"RequestId\": \"0f96cf39-a183-485c-ab29-8427ab81f9ae\",\n \"Extra\": \"\",\n \"VideoBase64\": \"\",\n \"BestFrameBase64\": \"\",\n \"DeviceInfoTag\": \"01\",\n \"RiskInfoTag\": \"02\"\n }\n}",
|
165
|
+
"output": "{\n \"Response\": {\n \"Result\": \"0\",\n \"Description\": \"成功\",\n \"IdCard\": \"23232323232\",\n \"Name\": \"王五\",\n \"Similarity\": 97.7,\n \"RequestId\": \"0f96cf39-a183-485c-ab29-8427ab81f9ae\",\n \"Extra\": \"\",\n \"VideoBase64\": \"\",\n \"BestFrameBase64\": \"\",\n \"DeviceInfoTag\": \"01\",\n \"RiskInfoTag\": \"02\",\n \"LivenessInfoTag\": \"01\",\n \"DeviceInfoLevel\": \"1\"\n }\n}",
|
166
166
|
"title": "获取结果成功时"
|
167
167
|
}
|
168
168
|
],
|
@@ -17,6 +17,58 @@ from tencentcloud.hunyuan.v20230901 import models as models_v20230901
|
|
17
17
|
from jmespath import search
|
18
18
|
import time
|
19
19
|
|
20
|
+
def doChatCompletions(args, parsed_globals):
|
21
|
+
g_param = parse_global_arg(parsed_globals)
|
22
|
+
|
23
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
24
|
+
cred = credential.CVMRoleCredential()
|
25
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
26
|
+
cred = credential.STSAssumeRoleCredential(
|
27
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
28
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
29
|
+
)
|
30
|
+
elif os.getenv(OptionsDefine.ENV_TKE_REGION) and os.getenv(OptionsDefine.ENV_TKE_PROVIDER_ID) and os.getenv(OptionsDefine.ENV_TKE_WEB_IDENTITY_TOKEN_FILE) and os.getenv(OptionsDefine.ENV_TKE_ROLE_ARN):
|
31
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
32
|
+
else:
|
33
|
+
cred = credential.Credential(
|
34
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
35
|
+
)
|
36
|
+
http_profile = HttpProfile(
|
37
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
38
|
+
reqMethod="POST",
|
39
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
40
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
41
|
+
)
|
42
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
43
|
+
if g_param[OptionsDefine.Language]:
|
44
|
+
profile.language = g_param[OptionsDefine.Language]
|
45
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
46
|
+
client = mod.HunyuanClient(cred, g_param[OptionsDefine.Region], profile)
|
47
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
48
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
49
|
+
model = models.ChatCompletionsRequest()
|
50
|
+
model.from_json_string(json.dumps(args))
|
51
|
+
start_time = time.time()
|
52
|
+
while True:
|
53
|
+
rsp = client.ChatCompletions(model)
|
54
|
+
result = rsp.to_json_string()
|
55
|
+
try:
|
56
|
+
json_obj = json.loads(result)
|
57
|
+
except TypeError as e:
|
58
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
59
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
60
|
+
break
|
61
|
+
cur_time = time.time()
|
62
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
63
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
64
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
65
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
66
|
+
else:
|
67
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
68
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
69
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
70
|
+
|
71
|
+
|
20
72
|
def doChatPro(args, parsed_globals):
|
21
73
|
g_param = parse_global_arg(parsed_globals)
|
22
74
|
|
@@ -236,6 +288,7 @@ MODELS_MAP = {
|
|
236
288
|
}
|
237
289
|
|
238
290
|
ACTION_MAP = {
|
291
|
+
"ChatCompletions": doChatCompletions,
|
239
292
|
"ChatPro": doChatPro,
|
240
293
|
"ChatStd": doChatStd,
|
241
294
|
"GetTokenCount": doGetTokenCount,
|
@@ -1,30 +1,37 @@
|
|
1
1
|
{
|
2
2
|
"actions": {
|
3
|
+
"ChatCompletions": {
|
4
|
+
"document": "腾讯混元大模型是由腾讯研发的大语言模型,具备强大的中文创作能力,复杂语境下的逻辑推理能力,以及可靠的任务执行能力。本接口支持流式或非流式调用,当使用流式调用时为 SSE 协议。\n\n 1. 本接口暂不支持返回图片内容。\n 2. 默认每种模型单账号限制并发数为 5 路,如您有提高并发限制的需求请 [联系我们](https://cloud.tencent.com/act/event/Online_service) 。\n 3. 请使用 SDK 调用本接口,每种开发语言的 SDK Git 仓库 examples/hunyuan/v20230901/ 目录下有提供示例供参考。SDK 链接在文档下方 “**开发者资源 - SDK**” 部分提供。",
|
5
|
+
"input": "ChatCompletionsRequest",
|
6
|
+
"name": "hunyuan",
|
7
|
+
"output": "ChatCompletionsResponse",
|
8
|
+
"status": "online"
|
9
|
+
},
|
3
10
|
"ChatPro": {
|
4
|
-
"document": "
|
11
|
+
"document": "腾讯混元大模型(hunyuan-pro)是由腾讯研发的大语言模型,具备强大的中文创作能力,复杂语境下的逻辑推理能力,以及可靠的任务执行能力。本接口支持流式或非流式调用,当使用流式调用时为 SSE 协议。\n\n 1. 本接口暂不支持返回图片内容。\n 2. 默认单账号限制并发数为 5 路,如您有提高并发限制的需求请 [联系我们](https://cloud.tencent.com/act/event/Online_service) 。\n 3. 请使用 SDK 调用本接口,每种开发语言的 SDK Git 仓库 examples/hunyuan/v20230901/ 目录下有提供示例供参考。SDK 链接在文档下方 “**开发者资源 - SDK**” 部分提供。",
|
5
12
|
"input": "ChatProRequest",
|
6
|
-
"name": "
|
13
|
+
"name": "hunyuan-pro",
|
7
14
|
"output": "ChatProResponse",
|
8
15
|
"status": "online"
|
9
16
|
},
|
10
17
|
"ChatStd": {
|
11
|
-
"document": "腾讯混元大模型标准版是由腾讯研发的大语言模型,具备强大的中文创作能力,复杂语境下的逻辑推理能力,以及可靠的任务执行能力。本接口支持流式或非流式调用,当使用流式调用时为 SSE 协议。\n\n 1. 本接口暂不支持返回图片内容。\n 2. 默认单账号限制并发数为 5 路,如您有提高并发限制的需求请 [联系我们](https://cloud.tencent.com/act/event/Online_service) 。\n 3. 请使用 SDK 调用本接口,每种开发语言的 SDK Git 仓库 examples/hunyuan/v20230901/ 目录下有提供示例供参考。",
|
18
|
+
"document": "腾讯混元大模型标准版是由腾讯研发的大语言模型,具备强大的中文创作能力,复杂语境下的逻辑推理能力,以及可靠的任务执行能力。本接口支持流式或非流式调用,当使用流式调用时为 SSE 协议。\n\n 1. 本接口暂不支持返回图片内容。\n 2. 默认单账号限制并发数为 5 路,如您有提高并发限制的需求请 [联系我们](https://cloud.tencent.com/act/event/Online_service) 。\n 3. 请使用 SDK 调用本接口,每种开发语言的 SDK Git 仓库 examples/hunyuan/v20230901/ 目录下有提供示例供参考。SDK 链接在文档下方 “**开发者资源 - SDK**” 部分提供。",
|
12
19
|
"input": "ChatStdRequest",
|
13
|
-
"name": "
|
20
|
+
"name": "hunyuan-standard",
|
14
21
|
"output": "ChatStdResponse",
|
15
22
|
"status": "online"
|
16
23
|
},
|
17
24
|
"GetEmbedding": {
|
18
|
-
"document": "
|
25
|
+
"document": "腾讯混元 Embedding 接口,可以将文本转化为高质量的向量数据。",
|
19
26
|
"input": "GetEmbeddingRequest",
|
20
|
-
"name": "
|
27
|
+
"name": "hunyuan-embedding",
|
21
28
|
"output": "GetEmbeddingResponse",
|
22
29
|
"status": "online"
|
23
30
|
},
|
24
31
|
"GetTokenCount": {
|
25
32
|
"document": "该接口用于计算文本对应Token数、字符数。",
|
26
33
|
"input": "GetTokenCountRequest",
|
27
|
-
"name": "Token计数",
|
34
|
+
"name": "Token 计数",
|
28
35
|
"output": "GetTokenCountResponse",
|
29
36
|
"status": "online"
|
30
37
|
}
|
@@ -36,6 +43,138 @@
|
|
36
43
|
"serviceShortName": "hunyuan"
|
37
44
|
},
|
38
45
|
"objects": {
|
46
|
+
"ChatCompletionsRequest": {
|
47
|
+
"document": "ChatCompletions请求参数结构体",
|
48
|
+
"members": [
|
49
|
+
{
|
50
|
+
"disabled": false,
|
51
|
+
"document": "模型名称,可选值包括 hunyuan-lite、hunyuan-standard、hunyuan-pro。\n各模型介绍请阅读 [产品概述](https://cloud.tencent.com/document/product/1729/104753) 中的说明。\n\n注意:\n不同的模型计费不同,请根据 [购买指南](https://cloud.tencent.com/document/product/1729/97731) 按需调用。",
|
52
|
+
"example": "无",
|
53
|
+
"member": "string",
|
54
|
+
"name": "Model",
|
55
|
+
"required": true,
|
56
|
+
"type": "string"
|
57
|
+
},
|
58
|
+
{
|
59
|
+
"disabled": false,
|
60
|
+
"document": "聊天上下文信息。\n说明:\n1. 长度最多为 40,按对话时间从旧到新在数组中排列。\n2. Message.Role 可选值:system、user、assistant。\n其中,system 角色可选,如存在则必须位于列表的最开始。user 和 assistant 需交替出现(一问一答),以 user 提问开始和结束,且 Content 不能为空。Role 的顺序示例:[system(可选) user assistant user assistant user ...]。\n3. Messages 中 Content 总长度不超过 16000 Token,超过则会截断最前面的内容,只保留尾部内容。建议不超过 4000 Token。",
|
61
|
+
"example": "无",
|
62
|
+
"member": "Message",
|
63
|
+
"name": "Messages",
|
64
|
+
"required": true,
|
65
|
+
"type": "list"
|
66
|
+
},
|
67
|
+
{
|
68
|
+
"disabled": false,
|
69
|
+
"document": "流式调用开关。\n说明:\n1. 未传值时默认为非流式调用(false)。\n2. 流式调用时以 SSE 协议增量返回结果(返回值取 Choices[n].Delta 中的值,需要拼接增量数据才能获得完整结果)。\n3. 非流式调用时:\n调用方式与普通 HTTP 请求无异。\n接口响应耗时较长,**如需更低时延建议设置为 true**。\n只返回一次最终结果(返回值取 Choices[n].Message 中的值)。\n\n注意:\n通过 SDK 调用时,流式和非流式调用需用**不同的方式**获取返回值,具体参考 SDK 中的注释或示例(在各语言 SDK 代码仓库的 examples/hunyuan/v20230901/ 目录中)。",
|
70
|
+
"example": "false",
|
71
|
+
"member": "bool",
|
72
|
+
"name": "Stream",
|
73
|
+
"required": false,
|
74
|
+
"type": "bool"
|
75
|
+
},
|
76
|
+
{
|
77
|
+
"disabled": false,
|
78
|
+
"document": "流式输出审核开关。\n说明:\n1. 输出审核有流式和同步两种模式,**流式模式首包响应更快**。\n2. 当使用流式输出(Stream 字段值为 true)时,该字段生效。\n3. 如果值为 true,将对输出内容进行分段审核,审核通过的内容流式输出返回。如果出现审核不过,响应中的 FinishReason 值为 sensitive。\n4. 如果未传值或值为 false,则不使用流式输出审核,需要审核完所有输出内容后再返回结果。\n\n注意:\n当选择流式输出审核时,可能会出现部分内容已输出,但中间某一段响应中的 FinishReason 值为 sensitive,此时说明安全审核未通过。如果业务场景有实时文字上屏的需求,需要自行撤回已上屏的内容,并建议自定义替换为一条提示语,如 “这个问题我不方便回答,不如我们换个话题试试”,以保障终端体验。",
|
79
|
+
"example": "false",
|
80
|
+
"member": "bool",
|
81
|
+
"name": "StreamModeration",
|
82
|
+
"required": false,
|
83
|
+
"type": "bool"
|
84
|
+
},
|
85
|
+
{
|
86
|
+
"disabled": false,
|
87
|
+
"document": "说明:\n1. 影响输出文本的多样性,取值越大,生成文本的多样性越强。\n2. 默认 1.0,取值区间为 [0.0, 1.0]。\n3. 非必要不建议使用,不合理的取值会影响效果。",
|
88
|
+
"example": "无",
|
89
|
+
"member": "float",
|
90
|
+
"name": "TopP",
|
91
|
+
"required": false,
|
92
|
+
"type": "float"
|
93
|
+
},
|
94
|
+
{
|
95
|
+
"disabled": false,
|
96
|
+
"document": "说明:\n1. 较高的数值会使输出更加随机,而较低的数值会使其更加集中和确定。\n2. 默认 1.0,取值区间为 [0.0, 2.0]。\n3. 非必要不建议使用,不合理的取值会影响效果。",
|
97
|
+
"example": "无",
|
98
|
+
"member": "float",
|
99
|
+
"name": "Temperature",
|
100
|
+
"required": false,
|
101
|
+
"type": "float"
|
102
|
+
}
|
103
|
+
],
|
104
|
+
"type": "object"
|
105
|
+
},
|
106
|
+
"ChatCompletionsResponse": {
|
107
|
+
"document": "ChatCompletions返回参数结构体",
|
108
|
+
"members": [
|
109
|
+
{
|
110
|
+
"disabled": false,
|
111
|
+
"document": "Unix 时间戳,单位为秒。",
|
112
|
+
"example": "无",
|
113
|
+
"member": "int64",
|
114
|
+
"name": "Created",
|
115
|
+
"output_required": false,
|
116
|
+
"type": "int",
|
117
|
+
"value_allowed_null": false
|
118
|
+
},
|
119
|
+
{
|
120
|
+
"disabled": false,
|
121
|
+
"document": "Token 统计信息。\n按照总 Token 数量计费。",
|
122
|
+
"example": "无",
|
123
|
+
"member": "Usage",
|
124
|
+
"name": "Usage",
|
125
|
+
"output_required": false,
|
126
|
+
"type": "object",
|
127
|
+
"value_allowed_null": false
|
128
|
+
},
|
129
|
+
{
|
130
|
+
"disabled": false,
|
131
|
+
"document": "免责声明。",
|
132
|
+
"example": "无",
|
133
|
+
"member": "string",
|
134
|
+
"name": "Note",
|
135
|
+
"output_required": false,
|
136
|
+
"type": "string",
|
137
|
+
"value_allowed_null": false
|
138
|
+
},
|
139
|
+
{
|
140
|
+
"disabled": false,
|
141
|
+
"document": "本轮对话的 ID。",
|
142
|
+
"example": "无",
|
143
|
+
"member": "string",
|
144
|
+
"name": "Id",
|
145
|
+
"output_required": false,
|
146
|
+
"type": "string",
|
147
|
+
"value_allowed_null": false
|
148
|
+
},
|
149
|
+
{
|
150
|
+
"disabled": false,
|
151
|
+
"document": "回复内容。",
|
152
|
+
"example": "无",
|
153
|
+
"member": "Choice",
|
154
|
+
"name": "Choices",
|
155
|
+
"output_required": false,
|
156
|
+
"type": "list",
|
157
|
+
"value_allowed_null": false
|
158
|
+
},
|
159
|
+
{
|
160
|
+
"disabled": false,
|
161
|
+
"document": "错误信息。\n如果流式返回中服务处理异常,返回该错误信息。\n注意:此字段可能返回 null,表示取不到有效值。",
|
162
|
+
"example": "无",
|
163
|
+
"member": "ErrorMsg",
|
164
|
+
"name": "ErrorMsg",
|
165
|
+
"output_required": false,
|
166
|
+
"type": "object",
|
167
|
+
"value_allowed_null": true
|
168
|
+
},
|
169
|
+
{
|
170
|
+
"document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。本接口为流式响应接口,当请求成功时,RequestId 会被放在 HTTP 响应的 Header \"X-TC-RequestId\" 中。",
|
171
|
+
"member": "string",
|
172
|
+
"name": "RequestId",
|
173
|
+
"type": "string"
|
174
|
+
}
|
175
|
+
],
|
176
|
+
"type": "object"
|
177
|
+
},
|
39
178
|
"ChatProRequest": {
|
40
179
|
"document": "ChatPro请求参数结构体",
|
41
180
|
"members": [
|
@@ -51,7 +190,7 @@
|
|
51
190
|
{
|
52
191
|
"disabled": false,
|
53
192
|
"document": "说明:\n1. 影响输出文本的多样性,取值越大,生成文本的多样性越强。\n2. 默认 1.0,取值区间为 [0.0, 1.0]。\n3. 非必要不建议使用,不合理的取值会影响效果。",
|
54
|
-
"example": "
|
193
|
+
"example": "1.0",
|
55
194
|
"member": "float",
|
56
195
|
"name": "TopP",
|
57
196
|
"required": false,
|
@@ -59,8 +198,8 @@
|
|
59
198
|
},
|
60
199
|
{
|
61
200
|
"disabled": false,
|
62
|
-
"document": "说明:\n1. 较高的数值会使输出更加随机,而较低的数值会使其更加集中和确定。\n2. 默认 1.0,取值区间为 [0.0
|
63
|
-
"example": "
|
201
|
+
"document": "说明:\n1. 较高的数值会使输出更加随机,而较低的数值会使其更加集中和确定。\n2. 默认 1.0,取值区间为 [0.0, 2.0]。\n3. 非必要不建议使用,不合理的取值会影响效果。",
|
202
|
+
"example": "1.0",
|
64
203
|
"member": "float",
|
65
204
|
"name": "Temperature",
|
66
205
|
"required": false,
|
@@ -68,7 +207,7 @@
|
|
68
207
|
},
|
69
208
|
{
|
70
209
|
"disabled": false,
|
71
|
-
"document": "流式调用开关。\n说明:\n1. 未传值时默认为流式调用。\n2. 流式调用时以 SSE 协议增量返回结果。\n3. 非流式调用时接口响应耗时较长,非必要不建议使用。\n4. 非流式调用时只返回一次最终结果,调用方式与普通 HTTP
|
210
|
+
"document": "流式调用开关。\n说明:\n1. 未传值时默认为流式调用。\n2. 流式调用时以 SSE 协议增量返回结果。\n3. 非流式调用时接口响应耗时较长,非必要不建议使用。\n4. 非流式调用时只返回一次最终结果,调用方式与普通 HTTP 请求无异。\n\n注意:\n通过 SDK 调用时,流式和非流式调用需要用**不同的方式**获取返回值,具体参考 SDK 中的注释或示例(在各语言 SDK 代码仓库的 examples/hunyuan/v20230901/ 目录中)。",
|
72
211
|
"example": "true",
|
73
212
|
"member": "bool",
|
74
213
|
"name": "Stream",
|
@@ -77,7 +216,7 @@
|
|
77
216
|
},
|
78
217
|
{
|
79
218
|
"disabled": false,
|
80
|
-
"document": "流式输出审核开关。\n说明:\n1.
|
219
|
+
"document": "流式输出审核开关。\n说明:\n1. 输出审核有流式和同步两种模式,**流式模式首包响应更快**。\n2. 当使用流式输出(Stream 字段值为 true)时,该字段生效。\n3. 如果值为 true,将对输出内容进行分段审核,审核通过的内容流式输出返回。如果出现审核不过,响应中的 FinishReason 值为 sensitive。\n4. 如果未传值或值为 false,则不使用流式输出审核,需要审核完所有输出内容后再返回结果。\n\n注意:\n当选择流式输出审核时,可能会出现部分内容已输出,但中间某一段响应中的 FinishReason 值为 sensitive,此时说明安全审核未通过。如果业务场景有实时文字上屏的需求,需要自行撤回已上屏的内容,并建议自定义替换为一条提示语,如 “这个问题我不方便回答,不如我们换个话题试试”,以保障终端体验。",
|
81
220
|
"example": "false",
|
82
221
|
"member": "bool",
|
83
222
|
"name": "StreamModeration",
|
@@ -174,7 +313,7 @@
|
|
174
313
|
{
|
175
314
|
"disabled": false,
|
176
315
|
"document": "说明:\n1. 影响输出文本的多样性,取值越大,生成文本的多样性越强。\n2. 默认 1.0,取值区间为 [0.0, 1.0]。\n3. 非必要不建议使用,不合理的取值会影响效果。",
|
177
|
-
"example": "
|
316
|
+
"example": "1.0",
|
178
317
|
"member": "float",
|
179
318
|
"name": "TopP",
|
180
319
|
"required": false,
|
@@ -182,8 +321,8 @@
|
|
182
321
|
},
|
183
322
|
{
|
184
323
|
"disabled": false,
|
185
|
-
"document": "说明:\n1. 较高的数值会使输出更加随机,而较低的数值会使其更加集中和确定。\n2. 默认 1.0,取值区间为 [0.0
|
186
|
-
"example": "
|
324
|
+
"document": "说明:\n1. 较高的数值会使输出更加随机,而较低的数值会使其更加集中和确定。\n2. 默认 1.0,取值区间为 [0.0, 2.0]。\n3. 非必要不建议使用,不合理的取值会影响效果。",
|
325
|
+
"example": "1.0",
|
187
326
|
"member": "float",
|
188
327
|
"name": "Temperature",
|
189
328
|
"required": false,
|
@@ -191,7 +330,7 @@
|
|
191
330
|
},
|
192
331
|
{
|
193
332
|
"disabled": false,
|
194
|
-
"document": "流式调用开关。\n说明:\n1. 未传值时默认为流式调用。\n2. 流式调用时以 SSE 协议增量返回结果。\n3. 非流式调用时接口响应耗时较长,非必要不建议使用。\n4. 非流式调用时只返回一次最终结果,调用方式与普通 HTTP
|
333
|
+
"document": "流式调用开关。\n说明:\n1. 未传值时默认为流式调用。\n2. 流式调用时以 SSE 协议增量返回结果。\n3. 非流式调用时接口响应耗时较长,非必要不建议使用。\n4. 非流式调用时只返回一次最终结果,调用方式与普通 HTTP 请求无异。\n\n注意:\n通过 SDK 调用时,流式和非流式调用需要用**不同的方式**获取返回值,具体参考 SDK 中的注释或示例(在各语言 SDK 代码仓库的 examples/hunyuan/v20230901/ 目录中)。",
|
195
334
|
"example": "true",
|
196
335
|
"member": "bool",
|
197
336
|
"name": "Stream",
|
@@ -200,7 +339,7 @@
|
|
200
339
|
},
|
201
340
|
{
|
202
341
|
"disabled": false,
|
203
|
-
"document": "流式输出审核开关。\n说明:\n1.
|
342
|
+
"document": "流式输出审核开关。\n说明:\n1. 输出审核有流式和同步两种模式,**流式模式首包响应更快**。\n2. 当使用流式输出(Stream 字段值为 true)时,该字段生效。\n3. 如果值为 true,将对输出内容进行分段审核,审核通过的内容流式输出返回。如果出现审核不过,响应中的 FinishReason 值为 sensitive。\n4. 如果未传值或值为 false,则不使用流式输出审核,需要审核完所有输出内容后再返回结果。\n\n注意:\n当选择流式输出审核时,可能会出现部分内容已输出,但中间某一段响应中的 FinishReason 值为 sensitive,此时说明安全审核未通过。如果业务场景有实时文字上屏的需求,需要自行撤回已上屏的内容,并建议自定义替换为一条提示语,如 “这个问题我不方便回答,不如我们换个话题试试”,以保障终端体验。",
|
204
343
|
"example": "false",
|
205
344
|
"member": "bool",
|
206
345
|
"name": "StreamModeration",
|
@@ -345,7 +484,7 @@
|
|
345
484
|
"usage": "out"
|
346
485
|
},
|
347
486
|
"EmbeddingData": {
|
348
|
-
"document": "
|
487
|
+
"document": "Embedding 信息。",
|
349
488
|
"members": [
|
350
489
|
{
|
351
490
|
"disabled": false,
|
@@ -437,7 +576,7 @@
|
|
437
576
|
"members": [
|
438
577
|
{
|
439
578
|
"disabled": false,
|
440
|
-
"document": "输入文本。总长度不超过1024 个
|
579
|
+
"document": "输入文本。总长度不超过 1024 个 Token,超过则会截断最后面的内容。",
|
441
580
|
"example": "无",
|
442
581
|
"member": "string",
|
443
582
|
"name": "Input",
|
@@ -452,7 +591,7 @@
|
|
452
591
|
"members": [
|
453
592
|
{
|
454
593
|
"disabled": false,
|
455
|
-
"document": "返回的
|
594
|
+
"document": "返回的 Embedding 信息。当前不支持批量,所以数组元素数目为 1。",
|
456
595
|
"example": "无",
|
457
596
|
"member": "EmbeddingData",
|
458
597
|
"name": "Data",
|
@@ -462,7 +601,7 @@
|
|
462
601
|
},
|
463
602
|
{
|
464
603
|
"disabled": false,
|
465
|
-
"document": "
|
604
|
+
"document": "Token 使用计数,按照总 Token 数量收费。",
|
466
605
|
"example": "无",
|
467
606
|
"member": "EmbeddingUsage",
|
468
607
|
"name": "Usage",
|
@@ -552,7 +691,7 @@
|
|
552
691
|
},
|
553
692
|
{
|
554
693
|
"disabled": false,
|
555
|
-
"document": "
|
694
|
+
"document": "文本内容",
|
556
695
|
"example": "你好!",
|
557
696
|
"member": "string",
|
558
697
|
"name": "Content",
|
@@ -1,5 +1,13 @@
|
|
1
1
|
{
|
2
2
|
"actions": {
|
3
|
+
"ChatCompletions": [
|
4
|
+
{
|
5
|
+
"document": "system提示词",
|
6
|
+
"input": "POST / HTTP/1.1\nHost: hunyuan.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: ChatCompletions\n<公共请求参数>\n\n{\n \"TopP\": 1,\n \"Temperature\": 1,\n \"Model\": \"hunyuan-lite\",\n \"Messages\": [\n {\n \"Role\": \"system\",\n \"Content\": \"将英文单词转换为包括中文翻译、英文释义和一个例句的完整解释。请检查所有信息是否准确,并在回答时保持简洁,不需要任何其他反馈。\"\n },\n {\n \"Role\": \"user\",\n \"Content\": \"nice\"\n }\n ]\n}",
|
7
|
+
"output": "{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"很好\"}}],\"Created\":1705634813,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":1,\"TotalTokens\":37}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\":\"}}],\"Created\":1705634813,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":2,\"TotalTokens\":38}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"nice\"}}],\"Created\":1705634813,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":3,\"TotalTokens\":39}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"\\n\"}}],\"Created\":1705634813,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":4,\"TotalTokens\":40}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"英文\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":5,\"TotalTokens\":41}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"释义\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":6,\"TotalTokens\":42}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\":\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":7,\"TotalTokens\":43}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"ple\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":8,\"TotalTokens\":44}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"asing\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":9,\"TotalTokens\":45}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\" or\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":10,\"TotalTokens\":46}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\" acceptable\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":11,\"TotalTokens\":47}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"\\n\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":12,\"TotalTokens\":48}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"例\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":13,\"TotalTokens\":49}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"句\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":14,\"TotalTokens\":50}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\":\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":15,\"TotalTokens\":51}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"She\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":16,\"TotalTokens\":52}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\" had\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":17,\"TotalTokens\":53}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\" a\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":18,\"TotalTokens\":54}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\" nice\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":19,\"TotalTokens\":55}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\" smile\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":20,\"TotalTokens\":56}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\".\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":21,\"TotalTokens\":57}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"stop\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":21,\"TotalTokens\":57}}",
|
8
|
+
"title": "system参数示例"
|
9
|
+
}
|
10
|
+
],
|
3
11
|
"ChatPro": [
|
4
12
|
{
|
5
13
|
"document": "system提示词",
|
@@ -188,6 +188,7 @@
|
|
188
188
|
"example": "1",
|
189
189
|
"member": "int64",
|
190
190
|
"name": "HitFlag",
|
191
|
+
"output_required": true,
|
191
192
|
"type": "int",
|
192
193
|
"value_allowed_null": false
|
193
194
|
},
|
@@ -197,6 +198,7 @@
|
|
197
198
|
"example": "Block",
|
198
199
|
"member": "string",
|
199
200
|
"name": "Suggestion",
|
201
|
+
"output_required": true,
|
200
202
|
"type": "string",
|
201
203
|
"value_allowed_null": false
|
202
204
|
},
|
@@ -206,6 +208,7 @@
|
|
206
208
|
"example": "Porn",
|
207
209
|
"member": "string",
|
208
210
|
"name": "Label",
|
211
|
+
"output_required": true,
|
209
212
|
"type": "string",
|
210
213
|
"value_allowed_null": false
|
211
214
|
},
|
@@ -215,6 +218,7 @@
|
|
215
218
|
"example": "SexBehavior",
|
216
219
|
"member": "string",
|
217
220
|
"name": "SubLabel",
|
221
|
+
"output_required": true,
|
218
222
|
"type": "string",
|
219
223
|
"value_allowed_null": false
|
220
224
|
},
|
@@ -224,6 +228,7 @@
|
|
224
228
|
"example": "90",
|
225
229
|
"member": "int64",
|
226
230
|
"name": "Score",
|
231
|
+
"output_required": true,
|
227
232
|
"type": "int",
|
228
233
|
"value_allowed_null": false
|
229
234
|
},
|
@@ -233,6 +238,7 @@
|
|
233
238
|
"example": "无",
|
234
239
|
"member": "LabelResult",
|
235
240
|
"name": "LabelResults",
|
241
|
+
"output_required": true,
|
236
242
|
"type": "list",
|
237
243
|
"value_allowed_null": true
|
238
244
|
},
|
@@ -242,6 +248,7 @@
|
|
242
248
|
"example": "无",
|
243
249
|
"member": "ObjectResult",
|
244
250
|
"name": "ObjectResults",
|
251
|
+
"output_required": true,
|
245
252
|
"type": "list",
|
246
253
|
"value_allowed_null": true
|
247
254
|
},
|
@@ -251,6 +258,7 @@
|
|
251
258
|
"example": "无",
|
252
259
|
"member": "OcrResult",
|
253
260
|
"name": "OcrResults",
|
261
|
+
"output_required": true,
|
254
262
|
"type": "list",
|
255
263
|
"value_allowed_null": true
|
256
264
|
},
|
@@ -260,6 +268,7 @@
|
|
260
268
|
"example": "无",
|
261
269
|
"member": "LibResult",
|
262
270
|
"name": "LibResults",
|
271
|
+
"output_required": true,
|
263
272
|
"type": "list",
|
264
273
|
"value_allowed_null": true
|
265
274
|
},
|
@@ -269,6 +278,7 @@
|
|
269
278
|
"example": "a61237dd-c2a0-43e7-a3da-d27022d39ba7",
|
270
279
|
"member": "string",
|
271
280
|
"name": "DataId",
|
281
|
+
"output_required": true,
|
272
282
|
"type": "string",
|
273
283
|
"value_allowed_null": false
|
274
284
|
},
|
@@ -278,6 +288,7 @@
|
|
278
288
|
"example": "test_1001",
|
279
289
|
"member": "string",
|
280
290
|
"name": "BizType",
|
291
|
+
"output_required": true,
|
281
292
|
"type": "string",
|
282
293
|
"value_allowed_null": false
|
283
294
|
},
|
@@ -287,6 +298,7 @@
|
|
287
298
|
"example": "无",
|
288
299
|
"member": "string",
|
289
300
|
"name": "Extra",
|
301
|
+
"output_required": true,
|
290
302
|
"type": "string",
|
291
303
|
"value_allowed_null": true
|
292
304
|
},
|
@@ -296,6 +308,7 @@
|
|
296
308
|
"example": "无",
|
297
309
|
"member": "RecognitionResult",
|
298
310
|
"name": "RecognitionResults",
|
311
|
+
"output_required": true,
|
299
312
|
"type": "list",
|
300
313
|
"value_allowed_null": true
|
301
314
|
},
|
@@ -4,7 +4,7 @@
|
|
4
4
|
{
|
5
5
|
"document": "图片同步检测",
|
6
6
|
"input": "POST / HTTP/1.1\nHost: ims.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: ImageModeration\n<公共请求参数>\n\n{\n \"BizType\": \"test_1001\",\n \"DataId\": \"1213\",\n \"FileUrl\": \"https://xxx.jpg\"\n}",
|
7
|
-
"output": "{\n \"Response\": {\n \"RequestId\": \"a61237dd-c2a0-43e7-a3da-d27022d39ba7\",\n \"DataId\": \"a61237dd-c2a0-43e7-a3da-d27022d39ba7\",\n \"BizType\": \"test_1001\",\n \"Suggestion\": \"Block\",\n \"Label\": \"Porn\",\n \"SubLabel\": \"SexBehavior\",\n \"Score\": 90,\n \"HitFlag\": 1,\n \"LabelResults\": [\n {\n \"Scene\": \"Porn\",\n \"Suggestion\": \"Block\",\n \"Label\": \"Porn\",\n \"SubLabel\": \"SexBehavior\",\n \"Score\": 90,\n \"Details\": [\n {\n \"Id\": 0,\n \"Name\": \"SexBehavior\",\n \"Score\": 90\n }\n ]\n }\n ],\n \"ObjectResults\": [\n {\n \"Scene\": \"QrCode\",\n \"Suggestion\": \"Block\",\n \"Label\": \"Ad\",\n \"SubLabel\": \"\",\n \"Score\": 100,\n \"Names\": [\n \"QRCODE\"\n ],\n \"Details\": [\n {\n \"Id\": 0,\n \"Name\": \"QRCODE\",\n \"Value\": \"https://test.com/test\",\n \"Score\": 100,\n \"Location\": {\n \"X\": 155.01746,\n \"Y\": 396.01746,\n \"Width\": 769.9824,\n \"Height\": 769.98254,\n \"Rotate\": 0\n }\n }\n ]\n }\n ],\n \"OcrResults\": [\n {\n \"HitFlag\": 0,\n \"Scene\": \"OCR\",\n \"Suggestion\": \"Pass\",\n \"Label\": \"Normal\",\n \"SubLabel\": \"\",\n \"Score\": 0,\n \"Text\": \"hello world\",\n \"Details\": [\n {\n \"Text\": \"hello world\",\n \"Label\": \"\",\n \"LibId\": \"\",\n \"LibName\": \"\",\n \"Keywords\": [],\n \"Rate\": 0,\n \"Score\": 0,\n \"Location\": {\n \"X\": 8,\n \"Y\": 0,\n \"Width\": 111,\n \"Height\": 19,\n \"Rotate\": 0\n }\n }\n ]\n }\n ],\n \"LibResults\": [\n {\n \"Scene\": \"Similar\",\n \"Label\": \"Porn\",\n \"SubLabel\": \"\",\n \"Score\": 99,\n \"Details\": [\n {\n \"LibName\": \"123\",\n \"Score\": 99,\n \"Label\": \"Porn\",\n \"Tag\": \"\",\n \"ImageId\": \"111\",\n \"Id\": 0,\n \"LibId\": \"\"\n }\n ],\n \"Suggestion\": \"Block\"\n }\n ],\n \"RecognitionResults\": [\n {\n \"Label\": \"Scene\",\n \"Tags\": [\n {\n \"Name\": \"MedicalImage\",\n \"Score\": 30,\n \"Location\": {\n \"X\": 0,\n \"Y\": 0,\n \"Width\": 0,\n \"Height\": 0,\n \"Rotate\": 0\n }\n }\n ]\n }\n ],\n \"Extra\": \"\"\n }\n}",
|
7
|
+
"output": "{\n \"Response\": {\n \"RequestId\": \"a61237dd-c2a0-43e7-a3da-d27022d39ba7\",\n \"DataId\": \"a61237dd-c2a0-43e7-a3da-d27022d39ba7\",\n \"BizType\": \"test_1001\",\n \"Suggestion\": \"Block\",\n \"Label\": \"Porn\",\n \"SubLabel\": \"SexBehavior\",\n \"Score\": 90,\n \"HitFlag\": 1,\n \"LabelResults\": [\n {\n \"Scene\": \"Porn\",\n \"Suggestion\": \"Block\",\n \"Label\": \"Porn\",\n \"SubLabel\": \"SexBehavior\",\n \"Score\": 90,\n \"Details\": [\n {\n \"Id\": 0,\n \"Name\": \"SexBehavior\",\n \"Score\": 90\n }\n ]\n }\n ],\n \"ObjectResults\": [\n {\n \"Scene\": \"QrCode\",\n \"Suggestion\": \"Block\",\n \"Label\": \"Ad\",\n \"SubLabel\": \"\",\n \"Score\": 100,\n \"Names\": [\n \"QRCODE\"\n ],\n \"Details\": [\n {\n \"Id\": 0,\n \"Name\": \"QRCODE\",\n \"Value\": \"https://test.com/test\",\n \"Score\": 100,\n \"Location\": {\n \"X\": 155.01746,\n \"Y\": 396.01746,\n \"Width\": 769.9824,\n \"Height\": 769.98254,\n \"Rotate\": 0\n },\n \"SubLabel\": \"abc\",\n \"GroupId\": \"abc\",\n \"ObjectId\": \"abc\"\n }\n ]\n }\n ],\n \"OcrResults\": [\n {\n \"HitFlag\": 0,\n \"Scene\": \"OCR\",\n \"Suggestion\": \"Pass\",\n \"Label\": \"Normal\",\n \"SubLabel\": \"\",\n \"Score\": 0,\n \"Text\": \"hello world\",\n \"Details\": [\n {\n \"Text\": \"hello world\",\n \"Label\": \"\",\n \"LibId\": \"\",\n \"LibName\": \"\",\n \"Keywords\": [],\n \"Rate\": 0,\n \"Score\": 0,\n \"Location\": {\n \"X\": 8,\n \"Y\": 0,\n \"Width\": 111,\n \"Height\": 19,\n \"Rotate\": 0\n }\n }\n ]\n }\n ],\n \"LibResults\": [\n {\n \"Scene\": \"Similar\",\n \"Label\": \"Porn\",\n \"SubLabel\": \"\",\n \"Score\": 99,\n \"Details\": [\n {\n \"LibName\": \"123\",\n \"Score\": 99,\n \"Label\": \"Porn\",\n \"Tag\": \"\",\n \"ImageId\": \"111\",\n \"Id\": 0,\n \"LibId\": \"\"\n }\n ],\n \"Suggestion\": \"Block\"\n }\n ],\n \"RecognitionResults\": [\n {\n \"Label\": \"Scene\",\n \"Tags\": [\n {\n \"Name\": \"MedicalImage\",\n \"Score\": 30,\n \"Location\": {\n \"X\": 0,\n \"Y\": 0,\n \"Width\": 0,\n \"Height\": 0,\n \"Rotate\": 0\n }\n }\n ]\n }\n ],\n \"Extra\": \"\"\n }\n}",
|
8
8
|
"title": "图片同步检测"
|
9
9
|
}
|
10
10
|
]
|
@@ -5552,7 +5552,7 @@
|
|
5552
5552
|
},
|
5553
5553
|
{
|
5554
5554
|
"disabled": false,
|
5555
|
-
"document": "直播方式:0 常规模式(默认)1
|
5555
|
+
"document": "直播方式:0 常规模式(默认)1 回放直播模式(伪直播)。 目前支持从回放直播模式(伪直播)改为常规模式,不支持从常规模式改为回放直播模式(伪直播)",
|
5556
5556
|
"example": "0",
|
5557
5557
|
"member": "uint64",
|
5558
5558
|
"name": "LiveType",
|