tencentcloud-sdk-python 3.0.1442__py2.py3-none-any.whl → 3.0.1444__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/batch/v20170312/models.py +30 -50
- tencentcloud/ckafka/v20190819/models.py +23 -23
- tencentcloud/clb/v20180317/models.py +426 -30
- tencentcloud/cls/v20201016/cls_client.py +4 -4
- tencentcloud/cls/v20201016/errorcodes.py +3 -0
- tencentcloud/cls/v20201016/models.py +1089 -324
- tencentcloud/common/credential.py +20 -2
- tencentcloud/dnspod/v20210323/errorcodes.py +3 -0
- tencentcloud/dnspod/v20210323/models.py +17 -2
- tencentcloud/es/v20180416/models.py +30 -0
- tencentcloud/ess/v20201111/ess_client.py +3 -1
- tencentcloud/ess/v20201111/models.py +2 -2
- tencentcloud/essbasic/v20210526/essbasic_client.py +3 -1
- tencentcloud/essbasic/v20210526/models.py +2 -2
- tencentcloud/iai/v20200303/models.py +19 -0
- tencentcloud/keewidb/v20220308/errorcodes.py +3 -0
- tencentcloud/keewidb/v20220308/models.py +2 -2
- tencentcloud/lcic/v20220817/errorcodes.py +15 -0
- tencentcloud/lcic/v20220817/models.py +67 -16
- tencentcloud/lighthouse/v20200324/errorcodes.py +27 -0
- tencentcloud/lighthouse/v20200324/lighthouse_client.py +53 -0
- tencentcloud/lighthouse/v20200324/models.py +534 -0
- tencentcloud/live/v20180801/models.py +2 -10
- tencentcloud/lke/v20231130/lke_client.py +0 -23
- tencentcloud/lke/v20231130/models.py +40 -128
- tencentcloud/lkeap/v20240522/errorcodes.py +1 -1
- tencentcloud/mongodb/v20190725/models.py +4 -4
- tencentcloud/mps/v20190612/models.py +64 -0
- tencentcloud/ocr/v20181119/models.py +65 -16
- tencentcloud/organization/v20210331/models.py +24 -26
- tencentcloud/postgres/v20170312/errorcodes.py +0 -12
- tencentcloud/postgres/v20170312/models.py +191 -1527
- tencentcloud/postgres/v20170312/postgres_client.py +0 -75
- tencentcloud/ssl/v20191205/models.py +2 -2
- tencentcloud/sts/v20180813/sts_client.py +21 -7
- tencentcloud/tbaas/v20180416/errorcodes.py +6 -0
- tencentcloud/tcbr/v20220217/models.py +151 -0
- tencentcloud/tcss/v20201101/models.py +45 -0
- tencentcloud/teo/v20220901/models.py +18 -18
- tencentcloud/tke/v20180525/models.py +17 -2
- tencentcloud/tms/v20201229/errorcodes.py +3 -0
- tencentcloud/trabbit/v20230418/models.py +60 -0
- tencentcloud/trocket/v20230308/models.py +319 -0
- tencentcloud/trocket/v20230308/trocket_client.py +25 -0
- tencentcloud/trtc/v20190722/errorcodes.py +18 -0
- tencentcloud/trtc/v20190722/models.py +486 -2
- tencentcloud/trtc/v20190722/trtc_client.py +64 -0
- tencentcloud/tse/v20201207/models.py +30 -0
- tencentcloud/tsf/v20180326/errorcodes.py +41 -11
- tencentcloud/tsf/v20180326/models.py +1705 -1263
- tencentcloud/tsf/v20180326/tsf_client.py +18 -18
- tencentcloud/vod/v20180717/models.py +78 -10
- tencentcloud/vod/v20180717/vod_client.py +1 -0
- tencentcloud/vpc/v20170312/models.py +35 -0
- tencentcloud/vpc/v20170312/vpc_client.py +1 -1
- tencentcloud/waf/v20180125/errorcodes.py +6 -0
- tencentcloud/waf/v20180125/models.py +1926 -744
- tencentcloud/waf/v20180125/waf_client.py +161 -0
- tencentcloud/wedata/v20210820/models.py +204 -0
- tencentcloud/wsa/v20250508/models.py +42 -6
- {tencentcloud_sdk_python-3.0.1442.dist-info → tencentcloud_sdk_python-3.0.1444.dist-info}/METADATA +1 -1
- {tencentcloud_sdk_python-3.0.1442.dist-info → tencentcloud_sdk_python-3.0.1444.dist-info}/RECORD +66 -66
- {tencentcloud_sdk_python-3.0.1442.dist-info → tencentcloud_sdk_python-3.0.1444.dist-info}/LICENSE +0 -0
- {tencentcloud_sdk_python-3.0.1442.dist-info → tencentcloud_sdk_python-3.0.1444.dist-info}/WHEEL +0 -0
- {tencentcloud_sdk_python-3.0.1442.dist-info → tencentcloud_sdk_python-3.0.1444.dist-info}/top_level.txt +0 -0
|
@@ -725,6 +725,42 @@ class AudioEncodeParams(AbstractModel):
|
|
|
725
725
|
|
|
726
726
|
|
|
727
727
|
|
|
728
|
+
class AudioFormat(AbstractModel):
|
|
729
|
+
"""TTS音频输出的格式
|
|
730
|
+
|
|
731
|
+
"""
|
|
732
|
+
|
|
733
|
+
def __init__(self):
|
|
734
|
+
r"""
|
|
735
|
+
:param _Format: 生成的音频格式,默认pcm,目前支持的格式列表:[pcm]。
|
|
736
|
+
:type Format: str
|
|
737
|
+
"""
|
|
738
|
+
self._Format = None
|
|
739
|
+
|
|
740
|
+
@property
|
|
741
|
+
def Format(self):
|
|
742
|
+
"""生成的音频格式,默认pcm,目前支持的格式列表:[pcm]。
|
|
743
|
+
:rtype: str
|
|
744
|
+
"""
|
|
745
|
+
return self._Format
|
|
746
|
+
|
|
747
|
+
@Format.setter
|
|
748
|
+
def Format(self, Format):
|
|
749
|
+
self._Format = Format
|
|
750
|
+
|
|
751
|
+
|
|
752
|
+
def _deserialize(self, params):
|
|
753
|
+
self._Format = params.get("Format")
|
|
754
|
+
memeber_set = set(params.keys())
|
|
755
|
+
for name, value in vars(self).items():
|
|
756
|
+
property_name = name[1:]
|
|
757
|
+
if property_name in memeber_set:
|
|
758
|
+
memeber_set.remove(property_name)
|
|
759
|
+
if len(memeber_set) > 0:
|
|
760
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
761
|
+
|
|
762
|
+
|
|
763
|
+
|
|
728
764
|
class AudioParams(AbstractModel):
|
|
729
765
|
"""录制音频转码参数。
|
|
730
766
|
|
|
@@ -3353,6 +3389,7 @@ bigvHeight:上/下行分辨率高;
|
|
|
3353
3389
|
aCapEnergy:音频采集能量;
|
|
3354
3390
|
aPlayEnergy:音频播放能量;
|
|
3355
3391
|
rtt:SDK到云端的往返延时;单位: ms
|
|
3392
|
+
bigvRecFps: 云端送达帧率;
|
|
3356
3393
|
:type DataType: list of str
|
|
3357
3394
|
:param _PageNumber: 当前页数,默认为0,
|
|
3358
3395
|
注意:PageNumber和PageSize 其中一个不填均默认返回6条数据。
|
|
@@ -3448,6 +3485,7 @@ bigvHeight:上/下行分辨率高;
|
|
|
3448
3485
|
aCapEnergy:音频采集能量;
|
|
3449
3486
|
aPlayEnergy:音频播放能量;
|
|
3450
3487
|
rtt:SDK到云端的往返延时;单位: ms
|
|
3488
|
+
bigvRecFps: 云端送达帧率;
|
|
3451
3489
|
:rtype: list of str
|
|
3452
3490
|
"""
|
|
3453
3491
|
return self._DataType
|
|
@@ -14029,7 +14067,7 @@ class StartAIConversationRequest(AbstractModel):
|
|
|
14029
14067
|
:param _STTConfig: 语音识别配置。
|
|
14030
14068
|
:type STTConfig: :class:`tencentcloud.trtc.v20190722.models.STTConfig`
|
|
14031
14069
|
:param _LLMConfig: LLM配置。需符合openai规范,为JSON字符串,示例如下:
|
|
14032
|
-
<pre> { <br>   "LLMType": "大模型类型", // String 必填,如:"openai" <br>   "Model": "您的模型名称", // String 必填,指定使用的模型<br> "APIKey": "您的LLM API密钥", // String 必填 <br>   "APIUrl": "https://api.xxx.com/chat/completions", // String 必填,LLM API访问的URL<br>   "Streaming": true // Boolean 非必填,指定是否使用流式传输<br>  } </pre>
|
|
14070
|
+
<pre> { <br>   "LLMType": "大模型类型", // String 必填,如:"openai" <br>   "Model": "您的模型名称", // String 必填,指定使用的模型<br> "APIKey": "您的LLM API密钥", // String 必填 <br>   "APIUrl": "https://api.xxx.com/chat/completions", // String 必填,LLM API访问的URL<br>   "History": 10, // Integer 选填,设置 LLM 的上下文轮次,默认值为0,最大值50<br>   "HistoryMode": 1, // Integer 选填,1表示LLM上下文中的内容会和播放音频做同步,没有播放的音频对应的文本不会出现在上下文中。0表示不会做同步,默认值为0<br>   "Streaming": true // Boolean 非必填,指定是否使用流式传输<br>  } </pre>
|
|
14033
14071
|
|
|
14034
14072
|
:type LLMConfig: str
|
|
14035
14073
|
:param _TTSConfig: TTS配置,为JSON字符串,腾讯云TTS示例如下: <pre>{ <br>   "AppId": 您的应用ID, // Integer 必填<br>   "TTSType": "TTS类型", // String TTS类型, 固定为"tencent"<br>   "SecretId": "您的密钥ID", // String 必填<br>   "SecretKey": "您的密钥Key", // String 必填<br>   "VoiceType": 101001, // Integer 必填,音色 ID,包括标准音色与精品音色,精品音色拟真度更高,价格不同于标准音色,请参见<a href="https://cloud.tencent.com/document/product/1073/34112">语音合成计费概述</a>。完整的音色 ID 列表请参见<a href="https://cloud.tencent.com/document/product/1073/92668#55924b56-1a73-4663-a7a1-a8dd82d6e823">语音合成音色列表</a>。<br>   "Speed": 1.25, // Integer 非必填,语速,范围:[-2,6],分别对应不同语速: -2: 代表0.6倍 -1: 代表0.8倍 0: 代表1.0倍(默认) 1: 代表1.2倍 2: 代表1.5倍 6: 代表2.5倍 如果需要更细化的语速,可以保留小数点后 2 位,例如0.5/1.25/2.81等。 参数值与实际语速转换,可参考 <a href="https://sdk-1300466766.cos.ap-shanghai.myqcloud.com/sample/speed_sample.tar.gz">语速转换</a><br>   "Volume": 5, // Integer 非必填,音量大小,范围:[0,10],分别对应11个等级的音量,默认值为0,代表正常音量。<br>   "EmotionCategory": "angry", // String 非必填 控制合成音频的情感,仅支持多情感音色使用。取值: neutral(中性)、sad(悲伤)、happy(高兴)、angry(生气)、fear(恐惧)、news(新闻)、story(故事)、radio(广播)、poetry(诗歌)、call(客服)、sajiao(撒娇)、disgusted(厌恶)、amaze(震惊)、peaceful(平静)、exciting(兴奋)、aojiao(傲娇)、jieshuo(解说)。<br>   "EmotionIntensity": 150 // Integer 非必填 控制合成音频情感程度,取值范围为 [50,200],默认为 100;只有 EmotionCategory 不为空时生效。<br>   }</pre>
|
|
@@ -14119,7 +14157,7 @@ class StartAIConversationRequest(AbstractModel):
|
|
|
14119
14157
|
@property
|
|
14120
14158
|
def LLMConfig(self):
|
|
14121
14159
|
"""LLM配置。需符合openai规范,为JSON字符串,示例如下:
|
|
14122
|
-
<pre> { <br>   "LLMType": "大模型类型", // String 必填,如:"openai" <br>   "Model": "您的模型名称", // String 必填,指定使用的模型<br> "APIKey": "您的LLM API密钥", // String 必填 <br>   "APIUrl": "https://api.xxx.com/chat/completions", // String 必填,LLM API访问的URL<br>   "Streaming": true // Boolean 非必填,指定是否使用流式传输<br>  } </pre>
|
|
14160
|
+
<pre> { <br>   "LLMType": "大模型类型", // String 必填,如:"openai" <br>   "Model": "您的模型名称", // String 必填,指定使用的模型<br> "APIKey": "您的LLM API密钥", // String 必填 <br>   "APIUrl": "https://api.xxx.com/chat/completions", // String 必填,LLM API访问的URL<br>   "History": 10, // Integer 选填,设置 LLM 的上下文轮次,默认值为0,最大值50<br>   "HistoryMode": 1, // Integer 选填,1表示LLM上下文中的内容会和播放音频做同步,没有播放的音频对应的文本不会出现在上下文中。0表示不会做同步,默认值为0<br>   "Streaming": true // Boolean 非必填,指定是否使用流式传输<br>  } </pre>
|
|
14123
14161
|
|
|
14124
14162
|
:rtype: str
|
|
14125
14163
|
"""
|
|
@@ -16660,6 +16698,277 @@ class TencentVod(AbstractModel):
|
|
|
16660
16698
|
|
|
16661
16699
|
|
|
16662
16700
|
|
|
16701
|
+
class TextToSpeechRequest(AbstractModel):
|
|
16702
|
+
"""TextToSpeech请求参数结构体
|
|
16703
|
+
|
|
16704
|
+
"""
|
|
16705
|
+
|
|
16706
|
+
def __init__(self):
|
|
16707
|
+
r"""
|
|
16708
|
+
:param _Text: 需要转语音的文字内容,长度范围:[1, 255]
|
|
16709
|
+
:type Text: str
|
|
16710
|
+
:param _Voice: 文本转语音的声音配置
|
|
16711
|
+
:type Voice: :class:`tencentcloud.trtc.v20190722.models.Voice`
|
|
16712
|
+
:param _SdkAppId: TRTC的SdkAppId
|
|
16713
|
+
:type SdkAppId: int
|
|
16714
|
+
:param _AudioFormat: 文本转语音的输出音频的格式
|
|
16715
|
+
:type AudioFormat: :class:`tencentcloud.trtc.v20190722.models.AudioFormat`
|
|
16716
|
+
:param _APIKey: TTS的API密钥
|
|
16717
|
+
:type APIKey: str
|
|
16718
|
+
"""
|
|
16719
|
+
self._Text = None
|
|
16720
|
+
self._Voice = None
|
|
16721
|
+
self._SdkAppId = None
|
|
16722
|
+
self._AudioFormat = None
|
|
16723
|
+
self._APIKey = None
|
|
16724
|
+
|
|
16725
|
+
@property
|
|
16726
|
+
def Text(self):
|
|
16727
|
+
"""需要转语音的文字内容,长度范围:[1, 255]
|
|
16728
|
+
:rtype: str
|
|
16729
|
+
"""
|
|
16730
|
+
return self._Text
|
|
16731
|
+
|
|
16732
|
+
@Text.setter
|
|
16733
|
+
def Text(self, Text):
|
|
16734
|
+
self._Text = Text
|
|
16735
|
+
|
|
16736
|
+
@property
|
|
16737
|
+
def Voice(self):
|
|
16738
|
+
"""文本转语音的声音配置
|
|
16739
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.Voice`
|
|
16740
|
+
"""
|
|
16741
|
+
return self._Voice
|
|
16742
|
+
|
|
16743
|
+
@Voice.setter
|
|
16744
|
+
def Voice(self, Voice):
|
|
16745
|
+
self._Voice = Voice
|
|
16746
|
+
|
|
16747
|
+
@property
|
|
16748
|
+
def SdkAppId(self):
|
|
16749
|
+
"""TRTC的SdkAppId
|
|
16750
|
+
:rtype: int
|
|
16751
|
+
"""
|
|
16752
|
+
return self._SdkAppId
|
|
16753
|
+
|
|
16754
|
+
@SdkAppId.setter
|
|
16755
|
+
def SdkAppId(self, SdkAppId):
|
|
16756
|
+
self._SdkAppId = SdkAppId
|
|
16757
|
+
|
|
16758
|
+
@property
|
|
16759
|
+
def AudioFormat(self):
|
|
16760
|
+
"""文本转语音的输出音频的格式
|
|
16761
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.AudioFormat`
|
|
16762
|
+
"""
|
|
16763
|
+
return self._AudioFormat
|
|
16764
|
+
|
|
16765
|
+
@AudioFormat.setter
|
|
16766
|
+
def AudioFormat(self, AudioFormat):
|
|
16767
|
+
self._AudioFormat = AudioFormat
|
|
16768
|
+
|
|
16769
|
+
@property
|
|
16770
|
+
def APIKey(self):
|
|
16771
|
+
"""TTS的API密钥
|
|
16772
|
+
:rtype: str
|
|
16773
|
+
"""
|
|
16774
|
+
return self._APIKey
|
|
16775
|
+
|
|
16776
|
+
@APIKey.setter
|
|
16777
|
+
def APIKey(self, APIKey):
|
|
16778
|
+
self._APIKey = APIKey
|
|
16779
|
+
|
|
16780
|
+
|
|
16781
|
+
def _deserialize(self, params):
|
|
16782
|
+
self._Text = params.get("Text")
|
|
16783
|
+
if params.get("Voice") is not None:
|
|
16784
|
+
self._Voice = Voice()
|
|
16785
|
+
self._Voice._deserialize(params.get("Voice"))
|
|
16786
|
+
self._SdkAppId = params.get("SdkAppId")
|
|
16787
|
+
if params.get("AudioFormat") is not None:
|
|
16788
|
+
self._AudioFormat = AudioFormat()
|
|
16789
|
+
self._AudioFormat._deserialize(params.get("AudioFormat"))
|
|
16790
|
+
self._APIKey = params.get("APIKey")
|
|
16791
|
+
memeber_set = set(params.keys())
|
|
16792
|
+
for name, value in vars(self).items():
|
|
16793
|
+
property_name = name[1:]
|
|
16794
|
+
if property_name in memeber_set:
|
|
16795
|
+
memeber_set.remove(property_name)
|
|
16796
|
+
if len(memeber_set) > 0:
|
|
16797
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
16798
|
+
|
|
16799
|
+
|
|
16800
|
+
|
|
16801
|
+
class TextToSpeechResponse(AbstractModel):
|
|
16802
|
+
"""TextToSpeech返回参数结构体
|
|
16803
|
+
|
|
16804
|
+
"""
|
|
16805
|
+
|
|
16806
|
+
def __init__(self):
|
|
16807
|
+
r"""
|
|
16808
|
+
:param _Audio: Base64编码的音频数据
|
|
16809
|
+
:type Audio: str
|
|
16810
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
16811
|
+
:type RequestId: str
|
|
16812
|
+
"""
|
|
16813
|
+
self._Audio = None
|
|
16814
|
+
self._RequestId = None
|
|
16815
|
+
|
|
16816
|
+
@property
|
|
16817
|
+
def Audio(self):
|
|
16818
|
+
"""Base64编码的音频数据
|
|
16819
|
+
:rtype: str
|
|
16820
|
+
"""
|
|
16821
|
+
return self._Audio
|
|
16822
|
+
|
|
16823
|
+
@Audio.setter
|
|
16824
|
+
def Audio(self, Audio):
|
|
16825
|
+
self._Audio = Audio
|
|
16826
|
+
|
|
16827
|
+
@property
|
|
16828
|
+
def RequestId(self):
|
|
16829
|
+
"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
16830
|
+
:rtype: str
|
|
16831
|
+
"""
|
|
16832
|
+
return self._RequestId
|
|
16833
|
+
|
|
16834
|
+
@RequestId.setter
|
|
16835
|
+
def RequestId(self, RequestId):
|
|
16836
|
+
self._RequestId = RequestId
|
|
16837
|
+
|
|
16838
|
+
|
|
16839
|
+
def _deserialize(self, params):
|
|
16840
|
+
self._Audio = params.get("Audio")
|
|
16841
|
+
self._RequestId = params.get("RequestId")
|
|
16842
|
+
|
|
16843
|
+
|
|
16844
|
+
class TextToSpeechSSERequest(AbstractModel):
|
|
16845
|
+
"""TextToSpeechSSE请求参数结构体
|
|
16846
|
+
|
|
16847
|
+
"""
|
|
16848
|
+
|
|
16849
|
+
def __init__(self):
|
|
16850
|
+
r"""
|
|
16851
|
+
:param _Text: 需要转语音的文字内容,长度范围:[1, 255]
|
|
16852
|
+
:type Text: str
|
|
16853
|
+
:param _Voice: 文本转语音的声音配置
|
|
16854
|
+
:type Voice: :class:`tencentcloud.trtc.v20190722.models.Voice`
|
|
16855
|
+
:param _SdkAppId: TRTC的SdkAppId
|
|
16856
|
+
:type SdkAppId: int
|
|
16857
|
+
:param _AudioFormat: 文本转语音的输出音频的格式
|
|
16858
|
+
:type AudioFormat: :class:`tencentcloud.trtc.v20190722.models.AudioFormat`
|
|
16859
|
+
:param _APIKey: TTS的API密钥
|
|
16860
|
+
:type APIKey: str
|
|
16861
|
+
"""
|
|
16862
|
+
self._Text = None
|
|
16863
|
+
self._Voice = None
|
|
16864
|
+
self._SdkAppId = None
|
|
16865
|
+
self._AudioFormat = None
|
|
16866
|
+
self._APIKey = None
|
|
16867
|
+
|
|
16868
|
+
@property
|
|
16869
|
+
def Text(self):
|
|
16870
|
+
"""需要转语音的文字内容,长度范围:[1, 255]
|
|
16871
|
+
:rtype: str
|
|
16872
|
+
"""
|
|
16873
|
+
return self._Text
|
|
16874
|
+
|
|
16875
|
+
@Text.setter
|
|
16876
|
+
def Text(self, Text):
|
|
16877
|
+
self._Text = Text
|
|
16878
|
+
|
|
16879
|
+
@property
|
|
16880
|
+
def Voice(self):
|
|
16881
|
+
"""文本转语音的声音配置
|
|
16882
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.Voice`
|
|
16883
|
+
"""
|
|
16884
|
+
return self._Voice
|
|
16885
|
+
|
|
16886
|
+
@Voice.setter
|
|
16887
|
+
def Voice(self, Voice):
|
|
16888
|
+
self._Voice = Voice
|
|
16889
|
+
|
|
16890
|
+
@property
|
|
16891
|
+
def SdkAppId(self):
|
|
16892
|
+
"""TRTC的SdkAppId
|
|
16893
|
+
:rtype: int
|
|
16894
|
+
"""
|
|
16895
|
+
return self._SdkAppId
|
|
16896
|
+
|
|
16897
|
+
@SdkAppId.setter
|
|
16898
|
+
def SdkAppId(self, SdkAppId):
|
|
16899
|
+
self._SdkAppId = SdkAppId
|
|
16900
|
+
|
|
16901
|
+
@property
|
|
16902
|
+
def AudioFormat(self):
|
|
16903
|
+
"""文本转语音的输出音频的格式
|
|
16904
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.AudioFormat`
|
|
16905
|
+
"""
|
|
16906
|
+
return self._AudioFormat
|
|
16907
|
+
|
|
16908
|
+
@AudioFormat.setter
|
|
16909
|
+
def AudioFormat(self, AudioFormat):
|
|
16910
|
+
self._AudioFormat = AudioFormat
|
|
16911
|
+
|
|
16912
|
+
@property
|
|
16913
|
+
def APIKey(self):
|
|
16914
|
+
"""TTS的API密钥
|
|
16915
|
+
:rtype: str
|
|
16916
|
+
"""
|
|
16917
|
+
return self._APIKey
|
|
16918
|
+
|
|
16919
|
+
@APIKey.setter
|
|
16920
|
+
def APIKey(self, APIKey):
|
|
16921
|
+
self._APIKey = APIKey
|
|
16922
|
+
|
|
16923
|
+
|
|
16924
|
+
def _deserialize(self, params):
|
|
16925
|
+
self._Text = params.get("Text")
|
|
16926
|
+
if params.get("Voice") is not None:
|
|
16927
|
+
self._Voice = Voice()
|
|
16928
|
+
self._Voice._deserialize(params.get("Voice"))
|
|
16929
|
+
self._SdkAppId = params.get("SdkAppId")
|
|
16930
|
+
if params.get("AudioFormat") is not None:
|
|
16931
|
+
self._AudioFormat = AudioFormat()
|
|
16932
|
+
self._AudioFormat._deserialize(params.get("AudioFormat"))
|
|
16933
|
+
self._APIKey = params.get("APIKey")
|
|
16934
|
+
memeber_set = set(params.keys())
|
|
16935
|
+
for name, value in vars(self).items():
|
|
16936
|
+
property_name = name[1:]
|
|
16937
|
+
if property_name in memeber_set:
|
|
16938
|
+
memeber_set.remove(property_name)
|
|
16939
|
+
if len(memeber_set) > 0:
|
|
16940
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
16941
|
+
|
|
16942
|
+
|
|
16943
|
+
|
|
16944
|
+
class TextToSpeechSSEResponse(AbstractModel):
|
|
16945
|
+
"""TextToSpeechSSE返回参数结构体
|
|
16946
|
+
|
|
16947
|
+
"""
|
|
16948
|
+
|
|
16949
|
+
def __init__(self):
|
|
16950
|
+
r"""
|
|
16951
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。本接口为流式响应接口,当请求成功时,RequestId 会被放在 HTTP 响应的 Header "X-TC-RequestId" 中。
|
|
16952
|
+
:type RequestId: str
|
|
16953
|
+
"""
|
|
16954
|
+
self._RequestId = None
|
|
16955
|
+
|
|
16956
|
+
@property
|
|
16957
|
+
def RequestId(self):
|
|
16958
|
+
"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。本接口为流式响应接口,当请求成功时,RequestId 会被放在 HTTP 响应的 Header "X-TC-RequestId" 中。
|
|
16959
|
+
:rtype: str
|
|
16960
|
+
"""
|
|
16961
|
+
return self._RequestId
|
|
16962
|
+
|
|
16963
|
+
@RequestId.setter
|
|
16964
|
+
def RequestId(self, RequestId):
|
|
16965
|
+
self._RequestId = RequestId
|
|
16966
|
+
|
|
16967
|
+
|
|
16968
|
+
def _deserialize(self, params):
|
|
16969
|
+
self._RequestId = params.get("RequestId")
|
|
16970
|
+
|
|
16971
|
+
|
|
16663
16972
|
class TimeValue(AbstractModel):
|
|
16664
16973
|
"""返回的质量数据,时间:值
|
|
16665
16974
|
|
|
@@ -18135,6 +18444,181 @@ class VideoParams(AbstractModel):
|
|
|
18135
18444
|
|
|
18136
18445
|
|
|
18137
18446
|
|
|
18447
|
+
class Voice(AbstractModel):
|
|
18448
|
+
"""TTS的声音参数
|
|
18449
|
+
|
|
18450
|
+
"""
|
|
18451
|
+
|
|
18452
|
+
def __init__(self):
|
|
18453
|
+
r"""
|
|
18454
|
+
:param _VoiceId: TTS的声音的ID
|
|
18455
|
+
:type VoiceId: str
|
|
18456
|
+
"""
|
|
18457
|
+
self._VoiceId = None
|
|
18458
|
+
|
|
18459
|
+
@property
|
|
18460
|
+
def VoiceId(self):
|
|
18461
|
+
"""TTS的声音的ID
|
|
18462
|
+
:rtype: str
|
|
18463
|
+
"""
|
|
18464
|
+
return self._VoiceId
|
|
18465
|
+
|
|
18466
|
+
@VoiceId.setter
|
|
18467
|
+
def VoiceId(self, VoiceId):
|
|
18468
|
+
self._VoiceId = VoiceId
|
|
18469
|
+
|
|
18470
|
+
|
|
18471
|
+
def _deserialize(self, params):
|
|
18472
|
+
self._VoiceId = params.get("VoiceId")
|
|
18473
|
+
memeber_set = set(params.keys())
|
|
18474
|
+
for name, value in vars(self).items():
|
|
18475
|
+
property_name = name[1:]
|
|
18476
|
+
if property_name in memeber_set:
|
|
18477
|
+
memeber_set.remove(property_name)
|
|
18478
|
+
if len(memeber_set) > 0:
|
|
18479
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
18480
|
+
|
|
18481
|
+
|
|
18482
|
+
|
|
18483
|
+
class VoiceCloneRequest(AbstractModel):
|
|
18484
|
+
"""VoiceClone请求参数结构体
|
|
18485
|
+
|
|
18486
|
+
"""
|
|
18487
|
+
|
|
18488
|
+
def __init__(self):
|
|
18489
|
+
r"""
|
|
18490
|
+
:param _SdkAppId: TRTC的SdkAppId
|
|
18491
|
+
:type SdkAppId: int
|
|
18492
|
+
:param _APIKey: TTS的API密钥
|
|
18493
|
+
:type APIKey: str
|
|
18494
|
+
:param _VoiceName: 声音克隆的名称, 只允许使用数字、字母、下划线,不能超过36位
|
|
18495
|
+
:type VoiceName: str
|
|
18496
|
+
:param _PromptAudio: 声音克隆的参考音频,必须为16k单声道的wav的base64字符串, 长度在5秒~12秒之间
|
|
18497
|
+
:type PromptAudio: str
|
|
18498
|
+
:param _PromptText: 声音克隆的参考文本,为参考音频对应的文字。
|
|
18499
|
+
:type PromptText: str
|
|
18500
|
+
"""
|
|
18501
|
+
self._SdkAppId = None
|
|
18502
|
+
self._APIKey = None
|
|
18503
|
+
self._VoiceName = None
|
|
18504
|
+
self._PromptAudio = None
|
|
18505
|
+
self._PromptText = None
|
|
18506
|
+
|
|
18507
|
+
@property
|
|
18508
|
+
def SdkAppId(self):
|
|
18509
|
+
"""TRTC的SdkAppId
|
|
18510
|
+
:rtype: int
|
|
18511
|
+
"""
|
|
18512
|
+
return self._SdkAppId
|
|
18513
|
+
|
|
18514
|
+
@SdkAppId.setter
|
|
18515
|
+
def SdkAppId(self, SdkAppId):
|
|
18516
|
+
self._SdkAppId = SdkAppId
|
|
18517
|
+
|
|
18518
|
+
@property
|
|
18519
|
+
def APIKey(self):
|
|
18520
|
+
"""TTS的API密钥
|
|
18521
|
+
:rtype: str
|
|
18522
|
+
"""
|
|
18523
|
+
return self._APIKey
|
|
18524
|
+
|
|
18525
|
+
@APIKey.setter
|
|
18526
|
+
def APIKey(self, APIKey):
|
|
18527
|
+
self._APIKey = APIKey
|
|
18528
|
+
|
|
18529
|
+
@property
|
|
18530
|
+
def VoiceName(self):
|
|
18531
|
+
"""声音克隆的名称, 只允许使用数字、字母、下划线,不能超过36位
|
|
18532
|
+
:rtype: str
|
|
18533
|
+
"""
|
|
18534
|
+
return self._VoiceName
|
|
18535
|
+
|
|
18536
|
+
@VoiceName.setter
|
|
18537
|
+
def VoiceName(self, VoiceName):
|
|
18538
|
+
self._VoiceName = VoiceName
|
|
18539
|
+
|
|
18540
|
+
@property
|
|
18541
|
+
def PromptAudio(self):
|
|
18542
|
+
"""声音克隆的参考音频,必须为16k单声道的wav的base64字符串, 长度在5秒~12秒之间
|
|
18543
|
+
:rtype: str
|
|
18544
|
+
"""
|
|
18545
|
+
return self._PromptAudio
|
|
18546
|
+
|
|
18547
|
+
@PromptAudio.setter
|
|
18548
|
+
def PromptAudio(self, PromptAudio):
|
|
18549
|
+
self._PromptAudio = PromptAudio
|
|
18550
|
+
|
|
18551
|
+
@property
|
|
18552
|
+
def PromptText(self):
|
|
18553
|
+
"""声音克隆的参考文本,为参考音频对应的文字。
|
|
18554
|
+
:rtype: str
|
|
18555
|
+
"""
|
|
18556
|
+
return self._PromptText
|
|
18557
|
+
|
|
18558
|
+
@PromptText.setter
|
|
18559
|
+
def PromptText(self, PromptText):
|
|
18560
|
+
self._PromptText = PromptText
|
|
18561
|
+
|
|
18562
|
+
|
|
18563
|
+
def _deserialize(self, params):
|
|
18564
|
+
self._SdkAppId = params.get("SdkAppId")
|
|
18565
|
+
self._APIKey = params.get("APIKey")
|
|
18566
|
+
self._VoiceName = params.get("VoiceName")
|
|
18567
|
+
self._PromptAudio = params.get("PromptAudio")
|
|
18568
|
+
self._PromptText = params.get("PromptText")
|
|
18569
|
+
memeber_set = set(params.keys())
|
|
18570
|
+
for name, value in vars(self).items():
|
|
18571
|
+
property_name = name[1:]
|
|
18572
|
+
if property_name in memeber_set:
|
|
18573
|
+
memeber_set.remove(property_name)
|
|
18574
|
+
if len(memeber_set) > 0:
|
|
18575
|
+
warnings.warn("%s fileds are useless." % ",".join(memeber_set))
|
|
18576
|
+
|
|
18577
|
+
|
|
18578
|
+
|
|
18579
|
+
class VoiceCloneResponse(AbstractModel):
|
|
18580
|
+
"""VoiceClone返回参数结构体
|
|
18581
|
+
|
|
18582
|
+
"""
|
|
18583
|
+
|
|
18584
|
+
def __init__(self):
|
|
18585
|
+
r"""
|
|
18586
|
+
:param _VoiceId: 克隆出的音色ID,可以用此id进行语音合成
|
|
18587
|
+
:type VoiceId: str
|
|
18588
|
+
:param _RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
18589
|
+
:type RequestId: str
|
|
18590
|
+
"""
|
|
18591
|
+
self._VoiceId = None
|
|
18592
|
+
self._RequestId = None
|
|
18593
|
+
|
|
18594
|
+
@property
|
|
18595
|
+
def VoiceId(self):
|
|
18596
|
+
"""克隆出的音色ID,可以用此id进行语音合成
|
|
18597
|
+
:rtype: str
|
|
18598
|
+
"""
|
|
18599
|
+
return self._VoiceId
|
|
18600
|
+
|
|
18601
|
+
@VoiceId.setter
|
|
18602
|
+
def VoiceId(self, VoiceId):
|
|
18603
|
+
self._VoiceId = VoiceId
|
|
18604
|
+
|
|
18605
|
+
@property
|
|
18606
|
+
def RequestId(self):
|
|
18607
|
+
"""唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
|
|
18608
|
+
:rtype: str
|
|
18609
|
+
"""
|
|
18610
|
+
return self._RequestId
|
|
18611
|
+
|
|
18612
|
+
@RequestId.setter
|
|
18613
|
+
def RequestId(self, RequestId):
|
|
18614
|
+
self._RequestId = RequestId
|
|
18615
|
+
|
|
18616
|
+
|
|
18617
|
+
def _deserialize(self, params):
|
|
18618
|
+
self._VoiceId = params.get("VoiceId")
|
|
18619
|
+
self._RequestId = params.get("RequestId")
|
|
18620
|
+
|
|
18621
|
+
|
|
18138
18622
|
class VoicePrint(AbstractModel):
|
|
18139
18623
|
"""声纹配置参数
|
|
18140
18624
|
|
|
@@ -1706,6 +1706,47 @@ class TrtcClient(AbstractClient):
|
|
|
1706
1706
|
raise TencentCloudSDKException(type(e).__name__, str(e))
|
|
1707
1707
|
|
|
1708
1708
|
|
|
1709
|
+
def TextToSpeech(self, request):
|
|
1710
|
+
"""语音合成接口
|
|
1711
|
+
|
|
1712
|
+
:param request: Request instance for TextToSpeech.
|
|
1713
|
+
:type request: :class:`tencentcloud.trtc.v20190722.models.TextToSpeechRequest`
|
|
1714
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.TextToSpeechResponse`
|
|
1715
|
+
|
|
1716
|
+
"""
|
|
1717
|
+
try:
|
|
1718
|
+
params = request._serialize()
|
|
1719
|
+
headers = request.headers
|
|
1720
|
+
body = self.call("TextToSpeech", params, headers=headers)
|
|
1721
|
+
response = json.loads(body)
|
|
1722
|
+
model = models.TextToSpeechResponse()
|
|
1723
|
+
model._deserialize(response["Response"])
|
|
1724
|
+
return model
|
|
1725
|
+
except Exception as e:
|
|
1726
|
+
if isinstance(e, TencentCloudSDKException):
|
|
1727
|
+
raise
|
|
1728
|
+
else:
|
|
1729
|
+
raise TencentCloudSDKException(type(e).__name__, str(e))
|
|
1730
|
+
|
|
1731
|
+
|
|
1732
|
+
def TextToSpeechSSE(self, request):
|
|
1733
|
+
"""SSE流式文本转语音
|
|
1734
|
+
|
|
1735
|
+
:param request: Request instance for TextToSpeechSSE.
|
|
1736
|
+
:type request: :class:`tencentcloud.trtc.v20190722.models.TextToSpeechSSERequest`
|
|
1737
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.TextToSpeechSSEResponse`
|
|
1738
|
+
|
|
1739
|
+
"""
|
|
1740
|
+
try:
|
|
1741
|
+
params = request._serialize()
|
|
1742
|
+
return self._call_and_deserialize("TextToSpeechSSE", params, models.TextToSpeechSSEResponse, headers=request.headers)
|
|
1743
|
+
except Exception as e:
|
|
1744
|
+
if isinstance(e, TencentCloudSDKException):
|
|
1745
|
+
raise
|
|
1746
|
+
else:
|
|
1747
|
+
raise TencentCloudSDKException(type(e).__name__, str(e))
|
|
1748
|
+
|
|
1749
|
+
|
|
1709
1750
|
def UpdateAIConversation(self, request):
|
|
1710
1751
|
"""更新AIConversation参数
|
|
1711
1752
|
|
|
@@ -1793,6 +1834,29 @@ class TrtcClient(AbstractClient):
|
|
|
1793
1834
|
model = models.UpdateVoicePrintResponse()
|
|
1794
1835
|
model._deserialize(response["Response"])
|
|
1795
1836
|
return model
|
|
1837
|
+
except Exception as e:
|
|
1838
|
+
if isinstance(e, TencentCloudSDKException):
|
|
1839
|
+
raise
|
|
1840
|
+
else:
|
|
1841
|
+
raise TencentCloudSDKException(type(e).__name__, str(e))
|
|
1842
|
+
|
|
1843
|
+
|
|
1844
|
+
def VoiceClone(self, request):
|
|
1845
|
+
"""声音克隆
|
|
1846
|
+
|
|
1847
|
+
:param request: Request instance for VoiceClone.
|
|
1848
|
+
:type request: :class:`tencentcloud.trtc.v20190722.models.VoiceCloneRequest`
|
|
1849
|
+
:rtype: :class:`tencentcloud.trtc.v20190722.models.VoiceCloneResponse`
|
|
1850
|
+
|
|
1851
|
+
"""
|
|
1852
|
+
try:
|
|
1853
|
+
params = request._serialize()
|
|
1854
|
+
headers = request.headers
|
|
1855
|
+
body = self.call("VoiceClone", params, headers=headers)
|
|
1856
|
+
response = json.loads(body)
|
|
1857
|
+
model = models.VoiceCloneResponse()
|
|
1858
|
+
model._deserialize(response["Response"])
|
|
1859
|
+
return model
|
|
1796
1860
|
except Exception as e:
|
|
1797
1861
|
if isinstance(e, TencentCloudSDKException):
|
|
1798
1862
|
raise
|
|
@@ -6944,6 +6944,10 @@ zk专业版可以为:CLOUD_SSD,CLOUD_SSD_PLUS,CLOUD_PREMIUM
|
|
|
6944
6944
|
:type StorageOption: list of StorageOption
|
|
6945
6945
|
:param _AffinityConstraint: ZK引擎实例,可用区分布约束,STRICT:强约束,PERMISSIVE: 弱约束
|
|
6946
6946
|
:type AffinityConstraint: str
|
|
6947
|
+
:param _ZoneIds: 指定zone id列表
|
|
6948
|
+
:type ZoneIds: list of int
|
|
6949
|
+
:param _EngineRegionTag: 地域特殊标签,用于区分相同地域,不通的业务属性
|
|
6950
|
+
:type EngineRegionTag: str
|
|
6947
6951
|
"""
|
|
6948
6952
|
self._EngineType = None
|
|
6949
6953
|
self._EngineVersion = None
|
|
@@ -6965,6 +6969,8 @@ zk专业版可以为:CLOUD_SSD,CLOUD_SSD_PLUS,CLOUD_PREMIUM
|
|
|
6965
6969
|
self._StorageCapacity = None
|
|
6966
6970
|
self._StorageOption = None
|
|
6967
6971
|
self._AffinityConstraint = None
|
|
6972
|
+
self._ZoneIds = None
|
|
6973
|
+
self._EngineRegionTag = None
|
|
6968
6974
|
|
|
6969
6975
|
@property
|
|
6970
6976
|
def EngineType(self):
|
|
@@ -7250,6 +7256,28 @@ zk专业版可以为:CLOUD_SSD,CLOUD_SSD_PLUS,CLOUD_PREMIUM
|
|
|
7250
7256
|
def AffinityConstraint(self, AffinityConstraint):
|
|
7251
7257
|
self._AffinityConstraint = AffinityConstraint
|
|
7252
7258
|
|
|
7259
|
+
@property
|
|
7260
|
+
def ZoneIds(self):
|
|
7261
|
+
"""指定zone id列表
|
|
7262
|
+
:rtype: list of int
|
|
7263
|
+
"""
|
|
7264
|
+
return self._ZoneIds
|
|
7265
|
+
|
|
7266
|
+
@ZoneIds.setter
|
|
7267
|
+
def ZoneIds(self, ZoneIds):
|
|
7268
|
+
self._ZoneIds = ZoneIds
|
|
7269
|
+
|
|
7270
|
+
@property
|
|
7271
|
+
def EngineRegionTag(self):
|
|
7272
|
+
"""地域特殊标签,用于区分相同地域,不通的业务属性
|
|
7273
|
+
:rtype: str
|
|
7274
|
+
"""
|
|
7275
|
+
return self._EngineRegionTag
|
|
7276
|
+
|
|
7277
|
+
@EngineRegionTag.setter
|
|
7278
|
+
def EngineRegionTag(self, EngineRegionTag):
|
|
7279
|
+
self._EngineRegionTag = EngineRegionTag
|
|
7280
|
+
|
|
7253
7281
|
|
|
7254
7282
|
def _deserialize(self, params):
|
|
7255
7283
|
self._EngineType = params.get("EngineType")
|
|
@@ -7294,6 +7322,8 @@ zk专业版可以为:CLOUD_SSD,CLOUD_SSD_PLUS,CLOUD_PREMIUM
|
|
|
7294
7322
|
obj._deserialize(item)
|
|
7295
7323
|
self._StorageOption.append(obj)
|
|
7296
7324
|
self._AffinityConstraint = params.get("AffinityConstraint")
|
|
7325
|
+
self._ZoneIds = params.get("ZoneIds")
|
|
7326
|
+
self._EngineRegionTag = params.get("EngineRegionTag")
|
|
7297
7327
|
memeber_set = set(params.keys())
|
|
7298
7328
|
for name, value in vars(self).items():
|
|
7299
7329
|
property_name = name[1:]
|