tccli 3.0.1122.1__py2.py3-none-any.whl → 3.0.1124.1__py2.py3-none-any.whl
Sign up to get free protection for your applications and to get access to all the features.
- tccli/__init__.py +1 -1
- tccli/services/aiart/v20221229/api.json +2 -2
- tccli/services/asr/v20190614/api.json +1 -1
- tccli/services/ccc/ccc_client.py +53 -0
- tccli/services/ccc/v20200210/api.json +89 -0
- tccli/services/ccc/v20200210/examples.json +8 -0
- tccli/services/cdb/v20170320/api.json +2 -2
- tccli/services/cfw/v20190904/api.json +6 -5
- tccli/services/cfw/v20190904/examples.json +1 -1
- tccli/services/csip/v20221121/api.json +1 -0
- tccli/services/cynosdb/v20190107/api.json +43 -16
- tccli/services/cynosdb/v20190107/examples.json +2 -2
- tccli/services/domain/v20180808/api.json +102 -102
- tccli/services/dts/v20211206/api.json +9 -0
- tccli/services/facefusion/facefusion_client.py +53 -0
- tccli/services/facefusion/v20220927/api.json +168 -0
- tccli/services/facefusion/v20220927/examples.json +14 -0
- tccli/services/hunyuan/v20230901/api.json +15 -15
- tccli/services/hunyuan/v20230901/examples.json +5 -5
- tccli/services/iotcloud/v20210408/api.json +37 -17
- tccli/services/iotexplorer/iotexplorer_client.py +53 -0
- tccli/services/iotexplorer/v20190423/api.json +156 -10
- tccli/services/iotexplorer/v20190423/examples.json +8 -0
- tccli/services/lighthouse/v20200324/api.json +6 -6
- tccli/services/mps/v20190612/api.json +22 -22
- tccli/services/ms/v20180408/api.json +6 -3
- tccli/services/ms/v20180408/examples.json +1 -1
- tccli/services/oceanus/v20190422/api.json +10 -0
- tccli/services/pts/v20210728/api.json +1 -1
- tccli/services/pts/v20210728/examples.json +1 -1
- tccli/services/redis/v20180412/api.json +4 -4
- tccli/services/rum/v20210622/api.json +9 -8
- tccli/services/rum/v20210622/examples.json +15 -15
- tccli/services/sqlserver/v20180328/api.json +41 -29
- tccli/services/tcss/v20201101/api.json +3 -2
- tccli/services/tcss/v20201101/examples.json +1 -1
- tccli/services/trp/trp_client.py +53 -0
- tccli/services/trp/v20210515/api.json +110 -0
- tccli/services/trp/v20210515/examples.json +8 -0
- tccli/services/vcg/v20240404/api.json +8 -8
- tccli/services/vdb/v20230616/api.json +1 -1
- tccli/services/waf/v20180125/api.json +11 -1
- tccli/services/waf/v20180125/examples.json +2 -2
- tccli/services/wedata/v20210820/api.json +40 -7
- tccli/services/yinsuda/v20220527/api.json +285 -268
- tccli/services/yinsuda/v20220527/examples.json +5 -5
- {tccli-3.0.1122.1.dist-info → tccli-3.0.1124.1.dist-info}/METADATA +2 -2
- {tccli-3.0.1122.1.dist-info → tccli-3.0.1124.1.dist-info}/RECORD +51 -51
- {tccli-3.0.1122.1.dist-info → tccli-3.0.1124.1.dist-info}/WHEEL +0 -0
- {tccli-3.0.1122.1.dist-info → tccli-3.0.1124.1.dist-info}/entry_points.txt +0 -0
- {tccli-3.0.1122.1.dist-info → tccli-3.0.1124.1.dist-info}/license_files/LICENSE +0 -0
@@ -4730,6 +4730,15 @@
|
|
4730
4730
|
"required": false,
|
4731
4731
|
"type": "string"
|
4732
4732
|
},
|
4733
|
+
{
|
4734
|
+
"disabled": false,
|
4735
|
+
"document": "订阅的topicName",
|
4736
|
+
"example": "topic-subs-g9k9ct7gmc--6itdltb8",
|
4737
|
+
"member": "string",
|
4738
|
+
"name": "Topic",
|
4739
|
+
"required": false,
|
4740
|
+
"type": "string"
|
4741
|
+
},
|
4733
4742
|
{
|
4734
4743
|
"disabled": false,
|
4735
4744
|
"document": "计费模式筛选,可能的值:0-包年包月,1-按量计费",
|
@@ -175,6 +175,58 @@ def doFuseFace(args, parsed_globals):
|
|
175
175
|
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
176
176
|
|
177
177
|
|
178
|
+
def doFuseFaceUltra(args, parsed_globals):
|
179
|
+
g_param = parse_global_arg(parsed_globals)
|
180
|
+
|
181
|
+
if g_param[OptionsDefine.UseCVMRole.replace('-', '_')]:
|
182
|
+
cred = credential.CVMRoleCredential()
|
183
|
+
elif g_param[OptionsDefine.RoleArn.replace('-', '_')] and g_param[OptionsDefine.RoleSessionName.replace('-', '_')]:
|
184
|
+
cred = credential.STSAssumeRoleCredential(
|
185
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.RoleArn.replace('-', '_')],
|
186
|
+
g_param[OptionsDefine.RoleSessionName.replace('-', '_')], endpoint=g_param["sts_cred_endpoint"]
|
187
|
+
)
|
188
|
+
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):
|
189
|
+
cred = credential.DefaultTkeOIDCRoleArnProvider().get_credentials()
|
190
|
+
else:
|
191
|
+
cred = credential.Credential(
|
192
|
+
g_param[OptionsDefine.SecretId], g_param[OptionsDefine.SecretKey], g_param[OptionsDefine.Token]
|
193
|
+
)
|
194
|
+
http_profile = HttpProfile(
|
195
|
+
reqTimeout=60 if g_param[OptionsDefine.Timeout] is None else int(g_param[OptionsDefine.Timeout]),
|
196
|
+
reqMethod="POST",
|
197
|
+
endpoint=g_param[OptionsDefine.Endpoint],
|
198
|
+
proxy=g_param[OptionsDefine.HttpsProxy.replace('-', '_')]
|
199
|
+
)
|
200
|
+
profile = ClientProfile(httpProfile=http_profile, signMethod="HmacSHA256")
|
201
|
+
if g_param[OptionsDefine.Language]:
|
202
|
+
profile.language = g_param[OptionsDefine.Language]
|
203
|
+
mod = CLIENT_MAP[g_param[OptionsDefine.Version]]
|
204
|
+
client = mod.FacefusionClient(cred, g_param[OptionsDefine.Region], profile)
|
205
|
+
client._sdkVersion += ("_CLI_" + __version__)
|
206
|
+
models = MODELS_MAP[g_param[OptionsDefine.Version]]
|
207
|
+
model = models.FuseFaceUltraRequest()
|
208
|
+
model.from_json_string(json.dumps(args))
|
209
|
+
start_time = time.time()
|
210
|
+
while True:
|
211
|
+
rsp = client.FuseFaceUltra(model)
|
212
|
+
result = rsp.to_json_string()
|
213
|
+
try:
|
214
|
+
json_obj = json.loads(result)
|
215
|
+
except TypeError as e:
|
216
|
+
json_obj = json.loads(result.decode('utf-8')) # python3.3
|
217
|
+
if not g_param[OptionsDefine.Waiter] or search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj) == g_param['OptionsDefine.WaiterInfo']['to']:
|
218
|
+
break
|
219
|
+
cur_time = time.time()
|
220
|
+
if cur_time - start_time >= g_param['OptionsDefine.WaiterInfo']['timeout']:
|
221
|
+
raise ClientError('Request timeout, wait `%s` to `%s` timeout, last request is %s' %
|
222
|
+
(g_param['OptionsDefine.WaiterInfo']['expr'], g_param['OptionsDefine.WaiterInfo']['to'],
|
223
|
+
search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj)))
|
224
|
+
else:
|
225
|
+
print('Inquiry result is %s.' % search(g_param['OptionsDefine.WaiterInfo']['expr'], json_obj))
|
226
|
+
time.sleep(g_param['OptionsDefine.WaiterInfo']['interval'])
|
227
|
+
FormatOutput.output("action", json_obj, g_param[OptionsDefine.Output], g_param[OptionsDefine.Filter])
|
228
|
+
|
229
|
+
|
178
230
|
CLIENT_MAP = {
|
179
231
|
"v20220927": facefusion_client_v20220927,
|
180
232
|
"v20181201": facefusion_client_v20181201,
|
@@ -191,6 +243,7 @@ ACTION_MAP = {
|
|
191
243
|
"DescribeMaterialList": doDescribeMaterialList,
|
192
244
|
"FaceFusion": doFaceFusion,
|
193
245
|
"FuseFace": doFuseFace,
|
246
|
+
"FuseFaceUltra": doFuseFaceUltra,
|
194
247
|
|
195
248
|
}
|
196
249
|
|
@@ -13,6 +13,13 @@
|
|
13
13
|
"name": "图片人脸融合",
|
14
14
|
"output": "FuseFaceResponse",
|
15
15
|
"status": "online"
|
16
|
+
},
|
17
|
+
"FuseFaceUltra": {
|
18
|
+
"document": "图片人脸融合(专业版)为同步接口,支持自定义美颜、人脸增强、牙齿增强、拉脸等参数,最高支持8K分辨率,有多个模型类型供选择。查看 <a href=\"https://cloud.tencent.com/document/product/670/38247\" target=\"_blank\">融合接入指引</a>。\n请求频率限制为2次/秒。",
|
19
|
+
"input": "FuseFaceUltraRequest",
|
20
|
+
"name": "图片人脸融合专业版",
|
21
|
+
"output": "FuseFaceUltraResponse",
|
22
|
+
"status": "online"
|
16
23
|
}
|
17
24
|
},
|
18
25
|
"metadata": {
|
@@ -295,6 +302,106 @@
|
|
295
302
|
],
|
296
303
|
"type": "object"
|
297
304
|
},
|
305
|
+
"FuseFaceUltraRequest": {
|
306
|
+
"document": "FuseFaceUltra请求参数结构体",
|
307
|
+
"members": [
|
308
|
+
{
|
309
|
+
"disabled": false,
|
310
|
+
"document": "返回融合结果图片方式(url 或 base64) ,二选一。url有效期为1天。",
|
311
|
+
"example": "url",
|
312
|
+
"member": "string",
|
313
|
+
"name": "RspImgType",
|
314
|
+
"required": true,
|
315
|
+
"type": "string"
|
316
|
+
},
|
317
|
+
{
|
318
|
+
"disabled": false,
|
319
|
+
"document": "用户人脸图片、素材模板图的人脸位置信息。主要用于素材模版中人脸以及用作融合的用户人脸相关信息,两种人脸都需要提供人脸图片,可选择提供人脸框位置,具体见MergeInfo说明 \n目前最多支持融合模板图片中的6张人脸。",
|
320
|
+
"example": "[]",
|
321
|
+
"member": "MergeInfo",
|
322
|
+
"name": "MergeInfos",
|
323
|
+
"required": true,
|
324
|
+
"type": "list"
|
325
|
+
},
|
326
|
+
{
|
327
|
+
"disabled": false,
|
328
|
+
"document": "素材模版图片的url地址。\n●base64 和 url 必须提供一个,如果都提供以 base64 为准。\n●素材图片限制:图片中面部尺寸大于34 * 34;图片尺寸大于64 * 64,小于8000 * 8000(单边限制)。图片url或者图片 base64 数据,base64 编码后大小不可超过10M(图片编码之后可能会大30%左右,建议合理控制图片大小)\n●图片格式:支持jpg或png",
|
329
|
+
"example": "http://xxx.jpg",
|
330
|
+
"member": "string",
|
331
|
+
"name": "ModelUrl",
|
332
|
+
"required": false,
|
333
|
+
"type": "string"
|
334
|
+
},
|
335
|
+
{
|
336
|
+
"disabled": false,
|
337
|
+
"document": "素材模版图片base64数据。\n●base64 和 url 必须提供一个,如果都提供以 base64 为准。\n●素材图片限制:图片中面部尺寸大于34 * 34;图片尺寸大于64 * 64,小于8000*8000(单边限制)。图片url或者图片 base64 数据,base64 编码后大小不可超过10M(图片编码之后可能会大30%左右,建议合理控制图片大小)\n●支持图片格式:支持jpg或png",
|
338
|
+
"example": "base64",
|
339
|
+
"member": "string",
|
340
|
+
"name": "ModelImage",
|
341
|
+
"required": false,
|
342
|
+
"type": "string"
|
343
|
+
},
|
344
|
+
{
|
345
|
+
"disabled": false,
|
346
|
+
"document": "图片人脸融合(专业版)效果参数。\n可用于设置拉脸、人脸增强、磨皮、牙齿增强等融合效果参数,生成理想的融合效果。不传默认使用接口推荐值。具体见FusionUltraParam说明\n",
|
347
|
+
"example": "无",
|
348
|
+
"member": "FusionUltraParam",
|
349
|
+
"name": "FusionUltraParam",
|
350
|
+
"required": false,
|
351
|
+
"type": "object"
|
352
|
+
},
|
353
|
+
{
|
354
|
+
"disabled": false,
|
355
|
+
"document": "为融合结果图添加合成标识的开关,默认为1。\n1:添加标识。\n0:不添加标识。\n其他数值:默认按1处理。\n建议您使用显著标识来提示结果图使用了人脸融合技术,是AI合成的图片。",
|
356
|
+
"example": "1",
|
357
|
+
"member": "int64",
|
358
|
+
"name": "LogoAdd",
|
359
|
+
"required": false,
|
360
|
+
"type": "int"
|
361
|
+
},
|
362
|
+
{
|
363
|
+
"disabled": false,
|
364
|
+
"document": "标识内容设置。\n默认在融合结果图右下角添加“本图片为AI合成图片”字样,您可根据自身需要替换为其他的Logo图片。",
|
365
|
+
"example": "无",
|
366
|
+
"member": "LogoParam",
|
367
|
+
"name": "LogoParam",
|
368
|
+
"required": false,
|
369
|
+
"type": "object"
|
370
|
+
},
|
371
|
+
{
|
372
|
+
"disabled": false,
|
373
|
+
"document": "融合模型类型参数:默认为1。\n图片人脸融合(专业版)针对不同场景,提供多种模型供选择。如您的产品是泛娱乐场景,推荐使用1;如您主要用于影像场景,推荐使用5。其他模型类型也可以结合您的产品使用场景进行选择,也许会有意想不到的效果\n1:默认泛娱乐场景,画面偏锐。\n2:影视级场景,画面偏自然。\n3:影视级场景,高分辨率,画面偏自然。\n4:影视级场景,高分辨率,画面偏自然。\n5:影视级场景,高分辨率,对闭眼和遮挡更友好。",
|
374
|
+
"example": "1",
|
375
|
+
"member": "int64",
|
376
|
+
"name": "SwapModelType",
|
377
|
+
"required": false,
|
378
|
+
"type": "int"
|
379
|
+
}
|
380
|
+
],
|
381
|
+
"type": "object"
|
382
|
+
},
|
383
|
+
"FuseFaceUltraResponse": {
|
384
|
+
"document": "FuseFaceUltra返回参数结构体",
|
385
|
+
"members": [
|
386
|
+
{
|
387
|
+
"disabled": false,
|
388
|
+
"document": "RspImgType 为 url 时,返回结果的 url, RspImgType 为 base64 时返回 base64 数据。url有效期为1天。",
|
389
|
+
"example": "string",
|
390
|
+
"member": "string",
|
391
|
+
"name": "FusedImage",
|
392
|
+
"output_required": true,
|
393
|
+
"type": "string",
|
394
|
+
"value_allowed_null": false
|
395
|
+
},
|
396
|
+
{
|
397
|
+
"document": "唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。",
|
398
|
+
"member": "string",
|
399
|
+
"name": "RequestId",
|
400
|
+
"type": "string"
|
401
|
+
}
|
402
|
+
],
|
403
|
+
"type": "object"
|
404
|
+
},
|
298
405
|
"FuseParam": {
|
299
406
|
"document": "融合参数",
|
300
407
|
"members": [
|
@@ -310,6 +417,67 @@
|
|
310
417
|
],
|
311
418
|
"usage": "in"
|
312
419
|
},
|
420
|
+
"FusionUltraParam": {
|
421
|
+
"document": "高精度融合参数",
|
422
|
+
"members": [
|
423
|
+
{
|
424
|
+
"disabled": false,
|
425
|
+
"document": "拉脸强度。主要用于调整生成结果人脸脸型更像素材模板还是用户人脸。取值越大越像用户人脸。\n取值范围:0-1之间。默认取值0.7。\n注意:此字段可能返回 null,表示取不到有效值。",
|
426
|
+
"example": "0.1",
|
427
|
+
"member": "float",
|
428
|
+
"name": "WarpRadio",
|
429
|
+
"output_required": false,
|
430
|
+
"required": false,
|
431
|
+
"type": "float",
|
432
|
+
"value_allowed_null": true
|
433
|
+
},
|
434
|
+
{
|
435
|
+
"disabled": false,
|
436
|
+
"document": "人脸增强强度。对整个人脸进行增强,增加清晰度,改善质量。当生成的人脸不够清晰,质感不够好的时候可以设置。取值越大增强强度越大。\n取值范围:0-1之间。默认取值1。\n注意:此字段可能返回 null,表示取不到有效值。",
|
437
|
+
"example": "0.8",
|
438
|
+
"member": "float",
|
439
|
+
"name": "EnhanceRadio",
|
440
|
+
"output_required": false,
|
441
|
+
"required": false,
|
442
|
+
"type": "float",
|
443
|
+
"value_allowed_null": true
|
444
|
+
},
|
445
|
+
{
|
446
|
+
"disabled": false,
|
447
|
+
"document": "磨皮强度。当生成脸的图像面部显脏时,可进行设置。\n取值范围:0-1之间。默认取值1。\n注意:此字段可能返回 null,表示取不到有效值。",
|
448
|
+
"example": "0.8",
|
449
|
+
"member": "float",
|
450
|
+
"name": "MpRadio",
|
451
|
+
"output_required": false,
|
452
|
+
"required": false,
|
453
|
+
"type": "float",
|
454
|
+
"value_allowed_null": true
|
455
|
+
},
|
456
|
+
{
|
457
|
+
"disabled": false,
|
458
|
+
"document": "人脸模糊开关(暂不支持)\n当生成人脸比较清晰时,将人脸模糊到接近模板的清晰度的程度\n注意:此字段可能返回 null,表示取不到有效值。",
|
459
|
+
"example": "无",
|
460
|
+
"member": "float",
|
461
|
+
"name": "BlurRadio",
|
462
|
+
"output_required": false,
|
463
|
+
"required": false,
|
464
|
+
"type": "float",
|
465
|
+
"value_allowed_null": true
|
466
|
+
},
|
467
|
+
{
|
468
|
+
"disabled": false,
|
469
|
+
"document": "牙齿增强开关,默认取值为1\n牙齿增强,修复牙齿。当生成牙齿不好(如牙齿裂开)可以打开此开关\n0:牙齿增强关闭\n1:牙齿增强打开\n注意:此字段可能返回 null,表示取不到有效值。",
|
470
|
+
"example": "1",
|
471
|
+
"member": "float",
|
472
|
+
"name": "TeethEnhanceRadio",
|
473
|
+
"output_required": false,
|
474
|
+
"required": false,
|
475
|
+
"type": "float",
|
476
|
+
"value_allowed_null": true
|
477
|
+
}
|
478
|
+
],
|
479
|
+
"usage": "both"
|
480
|
+
},
|
313
481
|
"ImageCodecParam": {
|
314
482
|
"document": "图片编码参数",
|
315
483
|
"members": [
|
@@ -15,6 +15,20 @@
|
|
15
15
|
"output": "{\n \"Response\": {\n \"FusedImage\": \"result.jpg\",\n \"RequestId\": \"1a2e88a4-3614-48a0-96b9-d09bf6de2fe4\"\n }\n}",
|
16
16
|
"title": "选脸融合"
|
17
17
|
}
|
18
|
+
],
|
19
|
+
"FuseFaceUltra": [
|
20
|
+
{
|
21
|
+
"document": "调用失败示例",
|
22
|
+
"input": "POST / HTTP/1.1\nHost: facefusion.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: FuseFaceUltra\n<公共请求参数>\n\n{\n \"ModelUrl\": \"https://host.com/1.jpg\",\n \"RspImgType\": \"base64\",\n \"MergeInfos\": [\n {\n \"Url\": \"https://host.com/2.jpg\"\n }\n ],\n \"FusionUltraParam\": {\n \"WarpRadio\": 1.2\n }\n}",
|
23
|
+
"output": "{\n \"Response\": {\n \"Error\": {\n \"Code\": \"FailedOperation.ParameterValueError\",\n \"Message\": \"FusionParam值不合法。\"\n },\n \"RequestId\": \"89cdd6c5-cb8f-4cbe-959b-e249f3753f55\"\n }\n}",
|
24
|
+
"title": "调用失败示例"
|
25
|
+
},
|
26
|
+
{
|
27
|
+
"document": "调用成功示例",
|
28
|
+
"input": "POST / HTTP/1.1\nHost: facefusion.tencentcloudapi.com\nContent-Type: application/json\nX-TC-Action: FuseFaceUltra\n<公共请求参数>\n\n{\n \"ModelUrl\": \"https://host.com/1.jpg\",\n \"RspImgType\": \"url\",\n \"MergeInfos\": [\n {\n \"Url\": \"https://host.com/2.jpg\"\n }\n ],\n \"FusionUltraParam\": {\n \"WarpRadio\": 0.7\n }\n}",
|
29
|
+
"output": "{\n \"Response\": {\n \"FusedImage\": \"https://xxxx.cos.ap-guangzhou.myqcloud.com/facefusion/FuseFaceUltra/xxxxx\",\n \"RequestId\": \"06f9b251-fa48-435e-b391-145d67919b2c\"\n }\n}",
|
30
|
+
"title": "调用成功示例"
|
31
|
+
}
|
18
32
|
]
|
19
33
|
},
|
20
34
|
"version": "1.0"
|
@@ -15,7 +15,7 @@
|
|
15
15
|
"status": "online"
|
16
16
|
},
|
17
17
|
"ChatStd": {
|
18
|
-
"document": "<span style=\"font-size:1.5em;\">注意:本接口将于 5 月 15 日下线;下线后将不再提供文档指引,接口本身可继续调用,建议使用 [hunyuan](https://cloud.tencent.com/document/api/1729/105701) 接入。</span>\n\n
|
18
|
+
"document": "<span style=\"font-size:1.5em;\">注意:本接口将于 5 月 15 日下线;下线后将不再提供文档指引,接口本身可继续调用,建议使用 [hunyuan](https://cloud.tencent.com/document/api/1729/105701) 接入。</span>\n\n腾讯混元大模型(hunyuan-standard)是由腾讯研发的大语言模型,具备强大的中文创作能力,复杂语境下的逻辑推理能力,以及可靠的任务执行能力。本接口支持流式或非流式调用,当使用流式调用时为 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**” 部分提供。",
|
19
19
|
"input": "ChatStdRequest",
|
20
20
|
"name": "hunyuan-standard (即将下线)",
|
21
21
|
"output": "ChatStdResponse",
|
@@ -63,7 +63,7 @@
|
|
63
63
|
{
|
64
64
|
"disabled": false,
|
65
65
|
"document": "模型名称,可选值包括 hunyuan-lite、hunyuan-standard、hunyuan-standard-256K、hunyuan-pro。\n各模型介绍请阅读 [产品概述](https://cloud.tencent.com/document/product/1729/104753) 中的说明。\n\n注意:\n不同的模型计费不同,请根据 [购买指南](https://cloud.tencent.com/document/product/1729/97731) 按需调用。",
|
66
|
-
"example": "hunyuan-
|
66
|
+
"example": "hunyuan-pro",
|
67
67
|
"member": "string",
|
68
68
|
"name": "Model",
|
69
69
|
"required": true,
|
@@ -255,7 +255,7 @@
|
|
255
255
|
{
|
256
256
|
"disabled": false,
|
257
257
|
"document": "Unix 时间戳,单位为秒。",
|
258
|
-
"example": "
|
258
|
+
"example": "1705634032",
|
259
259
|
"member": "int64",
|
260
260
|
"name": "Created",
|
261
261
|
"output_required": false,
|
@@ -275,7 +275,7 @@
|
|
275
275
|
{
|
276
276
|
"disabled": false,
|
277
277
|
"document": "免责声明。",
|
278
|
-
"example": "
|
278
|
+
"example": "以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记",
|
279
279
|
"member": "string",
|
280
280
|
"name": "Note",
|
281
281
|
"output_required": false,
|
@@ -285,7 +285,7 @@
|
|
285
285
|
{
|
286
286
|
"disabled": false,
|
287
287
|
"document": "本轮对话的 ID。",
|
288
|
-
"example": "
|
288
|
+
"example": "9c772634-8824-43e8-bc24-8bc4c19b9151",
|
289
289
|
"member": "string",
|
290
290
|
"name": "Id",
|
291
291
|
"output_required": false,
|
@@ -378,7 +378,7 @@
|
|
378
378
|
{
|
379
379
|
"disabled": false,
|
380
380
|
"document": "Unix 时间戳,单位为秒。",
|
381
|
-
"example": "
|
381
|
+
"example": "1705634032",
|
382
382
|
"member": "int64",
|
383
383
|
"name": "Created",
|
384
384
|
"output_required": false,
|
@@ -398,7 +398,7 @@
|
|
398
398
|
{
|
399
399
|
"disabled": false,
|
400
400
|
"document": "免责声明。",
|
401
|
-
"example": "
|
401
|
+
"example": "以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记",
|
402
402
|
"member": "string",
|
403
403
|
"name": "Note",
|
404
404
|
"output_required": false,
|
@@ -408,7 +408,7 @@
|
|
408
408
|
{
|
409
409
|
"disabled": false,
|
410
410
|
"document": "本轮对话的 ID。",
|
411
|
-
"example": "
|
411
|
+
"example": "9c772634-8824-43e8-bc24-8bc4c19b9151",
|
412
412
|
"member": "string",
|
413
413
|
"name": "Id",
|
414
414
|
"output_required": false,
|
@@ -511,7 +511,7 @@
|
|
511
511
|
"members": [
|
512
512
|
{
|
513
513
|
"disabled": false,
|
514
|
-
"document": "
|
514
|
+
"document": "Embedding 信息,目前为 1024 维浮点数。\n注意:此字段可能返回 null,表示取不到有效值。",
|
515
515
|
"example": "无",
|
516
516
|
"member": "float",
|
517
517
|
"name": "Embedding",
|
@@ -521,8 +521,8 @@
|
|
521
521
|
},
|
522
522
|
{
|
523
523
|
"disabled": false,
|
524
|
-
"document": "
|
525
|
-
"example": "
|
524
|
+
"document": "下标,目前不支持批量,因此固定为 0。\n注意:此字段可能返回 null,表示取不到有效值。",
|
525
|
+
"example": "0",
|
526
526
|
"member": "int64",
|
527
527
|
"name": "Index",
|
528
528
|
"output_required": false,
|
@@ -531,8 +531,8 @@
|
|
531
531
|
},
|
532
532
|
{
|
533
533
|
"disabled": false,
|
534
|
-
"document": "embedding\n注意:此字段可能返回 null,表示取不到有效值。",
|
535
|
-
"example": "
|
534
|
+
"document": "目前固定为 \"embedding\"。\n注意:此字段可能返回 null,表示取不到有效值。",
|
535
|
+
"example": "embedding",
|
536
536
|
"member": "string",
|
537
537
|
"name": "Object",
|
538
538
|
"output_required": false,
|
@@ -662,7 +662,7 @@
|
|
662
662
|
{
|
663
663
|
"disabled": false,
|
664
664
|
"document": "token计数",
|
665
|
-
"example": "
|
665
|
+
"example": "2",
|
666
666
|
"member": "int64",
|
667
667
|
"name": "TokenCount",
|
668
668
|
"output_required": false,
|
@@ -672,7 +672,7 @@
|
|
672
672
|
{
|
673
673
|
"disabled": false,
|
674
674
|
"document": "字符计数",
|
675
|
-
"example": "
|
675
|
+
"example": "3",
|
676
676
|
"member": "int64",
|
677
677
|
"name": "CharacterCount",
|
678
678
|
"output_required": false,
|
@@ -3,14 +3,14 @@
|
|
3
3
|
"ChatCompletions": [
|
4
4
|
{
|
5
5
|
"document": "推荐使用 API Explorer 调用接口,见本文档顶部说明。该示例说明 system prompt 的使用方法。",
|
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-pro\",\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}}",
|
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-pro\",\n \"Stream\": true,\n \"Messages\": [\n {\n \"Role\": \"system\",\n \"Content\": \"将英文单词转换为包括中文翻译、英文释义和一个例句的完整解释。请检查所有信息是否准确,并在回答时保持简洁,不需要任何其他反馈。\"\n },\n {\n \"Role\": \"user\",\n \"Content\": \"nice\"\n }\n ]\n}",
|
7
|
+
"output": "HTTP/1.1 200 OK\nCache-Control: no-cache\nConnection: keep-alive\nContent-Type: text/event-stream\nDate: Tue, 21 Nov 2023 06:56:00 GMT\nTransfer-Encoding: chunked\nX-TC-RequestId: 61a8459b-27c8-4868-af8f-f374db0245f8\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"很好\"}}],\"Created\":1705634813,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":1,\"TotalTokens\":37}}\n\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\":\"}}],\"Created\":1705634813,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":2,\"TotalTokens\":38}}\n\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"英文\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":5,\"TotalTokens\":41}}\n\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"释义\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":6,\"TotalTokens\":42}}\n\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\":\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":7,\"TotalTokens\":43}}\n\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"例\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":13,\"TotalTokens\":49}}\n\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"句\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":14,\"TotalTokens\":50}}\n\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\":\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":15,\"TotalTokens\":51}}\n\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"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\t\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\".\"}}],\"Created\":1705634814,\"Id\":\"681ef57e-9f1e-4faa-a2d3-07b655a1fa1f\",\"Usage\":{\"PromptTokens\":36,\"CompletionTokens\":21,\"TotalTokens\":57}}\n\t\ndata: {\"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
8
|
"title": "system prompt 示例"
|
9
9
|
},
|
10
10
|
{
|
11
11
|
"document": "推荐使用 API Explorer 调用接口,见本文档顶部说明。该示例说明如何给模型传入多轮消息。",
|
12
|
-
"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-pro\",\n \"Messages\": [\n {\n \"Role\": \"user\",\n \"Content\": \"请介绍下自己\"\n },\n {\n \"Role\": \"assistant\",\n \"Content\": \"我的名字是腾讯混元大模型,是腾讯开发的一款大型语言模型。我能够理解人类语言,擅长提供问答服务、常识推理、文本创作、数学计算和互动问答等服务。如果您需要帮助或有任何问题,请随时向我提问。\"\n },\n {\n \"Role\": \"user\",\n \"Content\": \"请给我讲个字数小于10个字的搞笑笑话\"\n },\n {\n \"Role\": \"assistant\",\n \"Content\": \"猫头鹰遇见眯眯眼,看得眼睛都眯成线。”\"\n },\n {\n \"Role\": \"user\",\n \"Content\": \"不好笑,换一个吧\"\n }\n ]\n}",
|
13
|
-
"output": "{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"青蛙\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":1,\"TotalTokens\":86}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"跳\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":2,\"TotalTokens\":87}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"高\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":3,\"TotalTokens\":88}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\",\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":4,\"TotalTokens\":89}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"比\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":5,\"TotalTokens\":90}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"下马\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":6,\"TotalTokens\":91}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"。\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":7,\"TotalTokens\":92}}\n{\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"stop\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":7,\"TotalTokens\":92}}",
|
12
|
+
"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-pro\",\n \"Stream\": true,\n \"Messages\": [\n {\n \"Role\": \"user\",\n \"Content\": \"请介绍下自己\"\n },\n {\n \"Role\": \"assistant\",\n \"Content\": \"我的名字是腾讯混元大模型,是腾讯开发的一款大型语言模型。我能够理解人类语言,擅长提供问答服务、常识推理、文本创作、数学计算和互动问答等服务。如果您需要帮助或有任何问题,请随时向我提问。\"\n },\n {\n \"Role\": \"user\",\n \"Content\": \"请给我讲个字数小于10个字的搞笑笑话\"\n },\n {\n \"Role\": \"assistant\",\n \"Content\": \"猫头鹰遇见眯眯眼,看得眼睛都眯成线。”\"\n },\n {\n \"Role\": \"user\",\n \"Content\": \"不好笑,换一个吧\"\n }\n ]\n}",
|
13
|
+
"output": "HTTP/1.1 200 OK\nCache-Control: no-cache\nConnection: keep-alive\nContent-Type: text/event-stream\nDate: Tue, 21 Nov 2023 06:56:00 GMT\nTransfer-Encoding: chunked\nX-TC-RequestId: 61a8459b-27c8-4868-af8f-f374db0245f8\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"青蛙\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":1,\"TotalTokens\":86}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"跳\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":2,\"TotalTokens\":87}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"高\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":3,\"TotalTokens\":88}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\",\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":4,\"TotalTokens\":89}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"比\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":5,\"TotalTokens\":90}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"下马\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":6,\"TotalTokens\":91}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"。\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":7,\"TotalTokens\":92}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"stop\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"\"}}],\"Created\":1705634032,\"Id\":\"9c772634-8824-43e8-bc24-8bc4c19b9151\",\"Usage\":{\"PromptTokens\":85,\"CompletionTokens\":7,\"TotalTokens\":92}}",
|
14
14
|
"title": "多轮对话示例"
|
15
15
|
},
|
16
16
|
{
|
@@ -21,7 +21,7 @@
|
|
21
21
|
},
|
22
22
|
{
|
23
23
|
"document": "推荐使用 API Explorer 调用接口,见本文档顶部说明。该示例给出接口正常调用时的响应例子。",
|
24
|
-
"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-pro\",\n \"Messages\": [\n {\n \"Role\": \"user\",\n \"Content\": \"计算1+1\"\n }\n ]\n}",
|
24
|
+
"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-pro\",\n \"Stream\": true,\n \"Messages\": [\n {\n \"Role\": \"user\",\n \"Content\": \"计算1+1\"\n }\n ]\n}",
|
25
25
|
"output": "HTTP/1.1 200 OK\nCache-Control: no-cache\nConnection: keep-alive\nContent-Type: text/event-stream\nDate: Tue, 21 Nov 2023 06:56:00 GMT\nTransfer-Encoding: chunked\nX-TC-RequestId: 61a8459b-27c8-4868-af8f-f374db0245f8\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"1\"}}],\"Created\":1700549760,\"Id\":\"148b89ef-14e1-489f-8e70-b767e5b27d56\",\"Usage\":{\"PromptTokens\":4,\"CompletionTokens\":2,\"TotalTokens\":6}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"+\"}}],\"Created\":1700549760,\"Id\":\"148b89ef-14e1-489f-8e70-b767e5b27d56\",\"Usage\":{\"PromptTokens\":4,\"CompletionTokens\":3,\"TotalTokens\":7}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"1\"}}],\"Created\":1700549760,\"Id\":\"148b89ef-14e1-489f-8e70-b767e5b27d56\",\"Usage\":{\"PromptTokens\":4,\"CompletionTokens\":4,\"TotalTokens\":8}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"=\"}}],\"Created\":1700549760,\"Id\":\"148b89ef-14e1-489f-8e70-b767e5b27d56\",\"Usage\":{\"PromptTokens\":4,\"CompletionTokens\":5,\"TotalTokens\":9}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"2\"}}],\"Created\":1700549760,\"Id\":\"148b89ef-14e1-489f-8e70-b767e5b27d56\",\"Usage\":{\"PromptTokens\":4,\"CompletionTokens\":5,\"TotalTokens\":9}}\n\ndata: {\"Note\":\"以上内容为AI生成,不代表开发者立场,请勿删除或修改本标记\",\"Choices\":[{\"FinishReason\":\"stop\",\"Delta\":{\"Role\":\"assistant\",\"Content\":\"\"}}],\"Created\":1700549760,\"Id\":\"148b89ef-14e1-489f-8e70-b767e5b27d56\",\"Usage\":{\"PromptTokens\":4,\"CompletionTokens\":5,\"TotalTokens\":9}}",
|
26
26
|
"title": "流式请求成功示例"
|
27
27
|
},
|