tencentcloud-sdk-asr 3.0.761 → 3.0.763

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6fb8878b2e3f81ad83449f054de4c94ce3a3e7ab
4
- data.tar.gz: 3dcf31ad2ecbee4259a937739fbc695cdaed4514
3
+ metadata.gz: 50df1f1bed86af67b99d619b7717d10b80d86e57
4
+ data.tar.gz: 32d8f64591c3c0ad16e477b9d7c3bcbec6d1da36
5
5
  SHA512:
6
- metadata.gz: 4a86aa5648928256ed8b83dae225c423c723f84dd9327bcabe13e7dcbdcf16c78118dc9abe514487abe57009988ba181e4db434cf69db1f885f3a37a50420c90
7
- data.tar.gz: c98ad1664a305611e43ac9bee8a7f3f234e5ac0ed63fcb4a51b59b61d05357b852a0d0149b581a188c669e4cf26d1a0a17d37ddcf9db4b4b48f830b18acbc2e4
6
+ metadata.gz: 6f9763ad4efd48a41798b5a6673dff48b1269f26f6290dcdb8a5d550f2be9bb651e2eb50abfc8061be4446096158facb8fb81628861a77ae101c2882241b851f
7
+ data.tar.gz: ace7eba73fa696cf1f906783f300911b24585c8ecb39b29bd1588e8ef53dd97b34346e4aa7b1401bfbcee6c144f389a8b21ae1d7bc2508e4c3ab32c2b0a3fd6b
data/lib/VERSION CHANGED
@@ -1 +1 @@
1
- 3.0.761
1
+ 3.0.763
@@ -537,6 +537,30 @@ module TencentCloud
537
537
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
538
538
  end
539
539
 
540
+ # 通过比对两段音频内说话人的声纹,得到一个打分,可通过打分判断两段音频声纹相似度, 打分区间[0 - 100]。 音频要求:16k采样率, 16bit位深,pcm或者wav格式, 单声道,总时长不超过30秒的音频,base64编码数据大小不超过2M,音频内容只有一个说话人声音,并且尽可能清晰,这样结果更加准确。
541
+
542
+ # @param request: Request instance for VoicePrintCompare.
543
+ # @type request: :class:`Tencentcloud::asr::V20190614::VoicePrintCompareRequest`
544
+ # @rtype: :class:`Tencentcloud::asr::V20190614::VoicePrintCompareResponse`
545
+ def VoicePrintCompare(request)
546
+ body = send_request('VoicePrintCompare', request.serialize)
547
+ response = JSON.parse(body)
548
+ if response['Response'].key?('Error') == false
549
+ model = VoicePrintCompareResponse.new
550
+ model.deserialize(response['Response'])
551
+ model
552
+ else
553
+ code = response['Response']['Error']['Code']
554
+ message = response['Response']['Error']['Message']
555
+ reqid = response['Response']['RequestId']
556
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
557
+ end
558
+ rescue TencentCloud::Common::TencentCloudSDKException => e
559
+ raise e
560
+ rescue StandardError => e
561
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
562
+ end
563
+
540
564
  # 统计并返回注册的说话人id总数
541
565
 
542
566
  # @param request: Request instance for VoicePrintCount.
@@ -1266,12 +1266,12 @@ module TencentCloud
1266
1266
 
1267
1267
  attr_accessor :EngSerViceType, :SourceType, :VoiceFormat, :ProjectId, :SubServiceType, :Url, :UsrAudioKey, :Data, :DataLen, :WordInfo, :FilterDirty, :FilterModal, :FilterPunc, :ConvertNumMode, :HotwordId, :CustomizationId, :ReinforceHotword, :HotwordList, :InputSampleRate
1268
1268
  extend Gem::Deprecate
1269
- deprecate :ProjectId, :none, 2024, 1
1270
- deprecate :ProjectId=, :none, 2024, 1
1271
- deprecate :SubServiceType, :none, 2024, 1
1272
- deprecate :SubServiceType=, :none, 2024, 1
1273
- deprecate :UsrAudioKey, :none, 2024, 1
1274
- deprecate :UsrAudioKey=, :none, 2024, 1
1269
+ deprecate :ProjectId, :none, 2024, 2
1270
+ deprecate :ProjectId=, :none, 2024, 2
1271
+ deprecate :SubServiceType, :none, 2024, 2
1272
+ deprecate :SubServiceType=, :none, 2024, 2
1273
+ deprecate :UsrAudioKey, :none, 2024, 2
1274
+ deprecate :UsrAudioKey=, :none, 2024, 2
1275
1275
 
1276
1276
  def initialize(engservicetype=nil, sourcetype=nil, voiceformat=nil, projectid=nil, subservicetype=nil, url=nil, usraudiokey=nil, data=nil, datalen=nil, wordinfo=nil, filterdirty=nil, filtermodal=nil, filterpunc=nil, convertnummode=nil, hotwordid=nil, customizationid=nil, reinforcehotword=nil, hotwordlist=nil, inputsamplerate=nil)
1277
1277
  @EngSerViceType = engservicetype
@@ -1649,6 +1649,79 @@ module TencentCloud
1649
1649
  end
1650
1650
  end
1651
1651
 
1652
+ # 音频声纹比对结果,包含比对分数
1653
+ class VoicePrintCompareData < TencentCloud::Common::AbstractModel
1654
+ # @param Score: 匹配度 取值范围(0.0 - 100.0)
1655
+ # 注意:此字段可能返回 null,表示取不到有效值。
1656
+ # @type Score: String
1657
+ # @param Decision: 验证结果 0: 未通过 1: 通过
1658
+ # 注意:此字段可能返回 null,表示取不到有效值。
1659
+ # @type Decision: Integer
1660
+
1661
+ attr_accessor :Score, :Decision
1662
+
1663
+ def initialize(score=nil, decision=nil)
1664
+ @Score = score
1665
+ @Decision = decision
1666
+ end
1667
+
1668
+ def deserialize(params)
1669
+ @Score = params['Score']
1670
+ @Decision = params['Decision']
1671
+ end
1672
+ end
1673
+
1674
+ # VoicePrintCompare请求参数结构体
1675
+ class VoicePrintCompareRequest < TencentCloud::Common::AbstractModel
1676
+ # @param VoiceFormat: 音频格式 0: pcm, 1: wav;pcm和wav音频无损压缩,识别准确度更高
1677
+ # @type VoiceFormat: Integer
1678
+ # @param SampleRate: 音频采样率,目前仅支持16k,请填写16000
1679
+ # @type SampleRate: Integer
1680
+ # @param SrcAudioData: 对比源音频数据, 音频要求:base64 编码,16k采样率, 16bit位深,pcm或者wav格式, 单声道,音频时长不超过30秒的音频,base64编码数据大小不超过2M
1681
+ # @type SrcAudioData: String
1682
+ # @param DestAudioData: 对比目标音频数据, 音频要求:base64 编码,16k采样率, 16bit位深,pcm或者wav格式, 单声道,音频时长不超过30秒的音频,base64编码数据大小不超过2M
1683
+ # @type DestAudioData: String
1684
+
1685
+ attr_accessor :VoiceFormat, :SampleRate, :SrcAudioData, :DestAudioData
1686
+
1687
+ def initialize(voiceformat=nil, samplerate=nil, srcaudiodata=nil, destaudiodata=nil)
1688
+ @VoiceFormat = voiceformat
1689
+ @SampleRate = samplerate
1690
+ @SrcAudioData = srcaudiodata
1691
+ @DestAudioData = destaudiodata
1692
+ end
1693
+
1694
+ def deserialize(params)
1695
+ @VoiceFormat = params['VoiceFormat']
1696
+ @SampleRate = params['SampleRate']
1697
+ @SrcAudioData = params['SrcAudioData']
1698
+ @DestAudioData = params['DestAudioData']
1699
+ end
1700
+ end
1701
+
1702
+ # VoicePrintCompare返回参数结构体
1703
+ class VoicePrintCompareResponse < TencentCloud::Common::AbstractModel
1704
+ # @param Data: 音频声纹比对结果,包含相似度打分
1705
+ # @type Data: :class:`Tencentcloud::Asr.v20190614.models.VoicePrintCompareData`
1706
+ # @param RequestId: 唯一请求 ID,每次请求都会返回。定位问题时需要提供该次请求的 RequestId。
1707
+ # @type RequestId: String
1708
+
1709
+ attr_accessor :Data, :RequestId
1710
+
1711
+ def initialize(data=nil, requestid=nil)
1712
+ @Data = data
1713
+ @RequestId = requestid
1714
+ end
1715
+
1716
+ def deserialize(params)
1717
+ unless params['Data'].nil?
1718
+ @Data = VoicePrintCompareData.new
1719
+ @Data.deserialize(params['Data'])
1720
+ end
1721
+ @RequestId = params['RequestId']
1722
+ end
1723
+ end
1724
+
1652
1725
  # 统计返回[说话人注册数量](https://cloud.tencent.com/document/product/1093/96061#3.-.E8.BE.93.E5.87.BA.E5.8F.82.E6.95.B0)
1653
1726
  class VoicePrintCountData < TencentCloud::Common::AbstractModel
1654
1727
  # @param Total: 总数
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tencentcloud-sdk-asr
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.761
4
+ version: 3.0.763
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tencent Cloud
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2024-01-30 00:00:00.000000000 Z
11
+ date: 2024-02-02 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: tencentcloud-sdk-common