tencentcloud-sdk-ocr 3.0.1106 → 3.0.1109

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: aa52ca9187eeae4a4c9e7a0471e57955ba177e2a
4
- data.tar.gz: 58aae1b0858a6ca6c36152700afda0012f18a041
3
+ metadata.gz: 9d8ad8c5d339c104ad37d30667be6c78a76689c6
4
+ data.tar.gz: 669d1714248857559818611bffb71d784f00e062
5
5
  SHA512:
6
- metadata.gz: 488c909c8c00a23169d3b895ee760eeae86f46c160a435c3f99fa6181704ee8c58be64bd7617b281dad1d989febea6e754515167f3d6d53049e8febb862fd3a7
7
- data.tar.gz: 4f3bca32cd0fd798077d58ce166432d683cc513840cb1dc1877e748909189a9c4e9b0a2b0a8a96111f1bb74853460d8c2ad315c1c2ecae79ab2fa42f978bb5ae
6
+ metadata.gz: e936c14e0c3fd6b15672e7a9c2fc58c22e8c56b5d7e96a91966c48fdae1ddc0c99df5a527fa955e507f8a5de8f509109e7bf6d6bf9c018d6e290a22809ac0237
7
+ data.tar.gz: 699b28468d4d68efa063fd1a4157a242d0e903d59b3841475bcad20154f655ac191a297939ac62e58f1e94097bfc44dc029649df56a719ebfdc7954320a95ad9
data/lib/VERSION CHANGED
@@ -1 +1 @@
1
- 3.0.1106
1
+ 3.0.1109
@@ -2170,6 +2170,32 @@ module TencentCloud
2170
2170
  raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
2171
2171
  end
2172
2172
 
2173
+ # 基于MLLM(多模态大语言模型)的表格识别能力,针对复杂表格的算法识别效果更佳,适配财务报表识别场景,并可输出直接对接业务系统的Excel数据。
2174
+
2175
+ # 默认接口请求频率限制:1次/秒。
2176
+
2177
+ # @param request: Request instance for RecognizeTableMultiOCR.
2178
+ # @type request: :class:`Tencentcloud::ocr::V20181119::RecognizeTableMultiOCRRequest`
2179
+ # @rtype: :class:`Tencentcloud::ocr::V20181119::RecognizeTableMultiOCRResponse`
2180
+ def RecognizeTableMultiOCR(request)
2181
+ body = send_request('RecognizeTableMultiOCR', request.serialize)
2182
+ response = JSON.parse(body)
2183
+ if response['Response'].key?('Error') == false
2184
+ model = RecognizeTableMultiOCRResponse.new
2185
+ model.deserialize(response['Response'])
2186
+ model
2187
+ else
2188
+ code = response['Response']['Error']['Code']
2189
+ message = response['Response']['Error']['Message']
2190
+ reqid = response['Response']['RequestId']
2191
+ raise TencentCloud::Common::TencentCloudSDKException.new(code, message, reqid)
2192
+ end
2193
+ rescue TencentCloud::Common::TencentCloudSDKException => e
2194
+ raise e
2195
+ rescue StandardError => e
2196
+ raise TencentCloud::Common::TencentCloudSDKException.new(nil, e.inspect)
2197
+ end
2198
+
2173
2199
  # 本接口支持中英文图片/ PDF内常规表格、无线表格、多表格的检测和识别,支持日文有线表格识别,返回每个单元格的文字内容,支持旋转的表格图片识别,且支持将识别结果保存为 Excel 格式。
2174
2200
 
2175
2201
  # 默认接口请求频率限制:10次/秒。
@@ -5848,19 +5848,13 @@ module TencentCloud
5848
5848
 
5849
5849
  # MLIDCardOCR请求参数结构体
5850
5850
  class MLIDCardOCRRequest < TencentCloud::Common::AbstractModel
5851
- # @param ImageBase64: 图片的 Base64 值。
5852
- # 支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。
5853
- # 支持的图片大小:所下载图片经Base64编码后不超过 7M。图片下载时间不超过 3 秒。
5851
+ # @param ImageBase64: 图片的 Base64 值。支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。支持的图片大小:所下载图片经Base64编码后不超过 10M。图片下载时间不超过 3 秒。
5854
5852
  # @type ImageBase64: String
5855
- # @param BackImageBase64: 卡证背面图片的 Base64 值。支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。支持的图片大小:所下载图片经Base64编码后不超过 7M。图片下载时间不超过 3 秒。图片的 ImageUrl、ImageBase64 必须提供一个,如果都提供,只使用 ImageUrl。
5853
+ # @param BackImageBase64: 卡证背面图片的 Base64 值。支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。支持的图片大小:所下载图片经Base64编码后不超过 10M。图片下载时间不超过 3 秒。图片的 ImageUrl、ImageBase64 必须提供一个,如果都提供,只使用 ImageUrl。
5856
5854
  # @type BackImageBase64: String
5857
- # @param ImageUrl: 图片的 Url 地址。( 中国地区之外不支持这个字段 )
5858
- # 支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。
5859
- # 支持的图片大小:所下载图片经 Base64 编码后不超过 7M。图片下载时间不超过 3 秒。
5860
- # 图片存储于腾讯云的 Url 可保障更高的下载速度和稳定性,建议图片存储于腾讯云。
5861
- # 非腾讯云存储的 Url 速度和稳定性可能受一定影响。
5855
+ # @param ImageUrl: 图片的 Url 地址。( 中国地区之外不支持这个字段 )支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。支持的图片大小:所下载图片经 Base64 编码后不超过 10M。图片下载时间不超过 3 秒。图片存储于腾讯云的 Url 可保障更高的下载速度和稳定性,建议图片存储于腾讯云。非腾讯云存储的 Url 速度和稳定性可能受一定影响。
5862
5856
  # @type ImageUrl: String
5863
- # @param BackImageUrl: 卡证背面图片的 Url 地址。支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。支持的图片大小:所下载图片经 Base64 编码后不超过 7M。图片下载时间不超过 3 秒。图片存储于腾讯云的 Url 可保障更高的下载速度和稳定性,建议图片存储于腾讯云。非腾讯云存储的 Url 速度和稳定性可能受一定影响。
5857
+ # @param BackImageUrl: 卡证背面图片的 Url 地址。支持的图片格式:PNG、JPG、JPEG,暂不支持 GIF 格式。支持的图片大小:所下载图片经 Base64 编码后不超过 10M。图片下载时间不超过 3 秒。图片存储于腾讯云的 Url 可保障更高的下载速度和稳定性,建议图片存储于腾讯云。非腾讯云存储的 Url 速度和稳定性可能受一定影响。
5864
5858
  # @type BackImageUrl: String
5865
5859
  # @param RetImage: 是否返回图片,默认false
5866
5860
  # @type RetImage: Boolean
@@ -5894,21 +5888,11 @@ module TencentCloud
5894
5888
  # @type Address: String
5895
5889
  # @param Sex: 性别
5896
5890
  # @type Sex: String
5897
- # @param Warn: 告警码
5898
- # -9103 证照翻拍告警
5899
- # -9102 证照复印件告警
5900
- # -9106 证件遮挡告警
5901
- # -9107 模糊图片告警
5891
+ # @param Warn: 该字段已废弃, 将固定返回空数组,不建议使用。
5902
5892
  # @type Warn: Array
5903
5893
  # @param Image: 证件图片
5904
5894
  # @type Image: String
5905
- # @param AdvancedInfo: 此字段为扩展字段。
5906
- # 返回字段识别结果的置信度,格式如下
5907
- # {
5908
- # 字段名:{
5909
- # Confidence:0.9999
5910
- # }
5911
- # }
5895
+ # @param AdvancedInfo: 该字段已废弃, 将固定返回"1",不建议使用。
5912
5896
  # @type AdvancedInfo: String
5913
5897
  # @param Type: 证件类型
5914
5898
  # MyKad 身份证
@@ -5939,6 +5923,8 @@ module TencentCloud
5939
5923
  extend Gem::Deprecate
5940
5924
  deprecate :Warn, :none, 2025, 7
5941
5925
  deprecate :Warn=, :none, 2025, 7
5926
+ deprecate :AdvancedInfo, :none, 2025, 7
5927
+ deprecate :AdvancedInfo=, :none, 2025, 7
5942
5928
 
5943
5929
  def initialize(id=nil, name=nil, address=nil, sex=nil, warn=nil, image=nil, advancedinfo=nil, type=nil, birthday=nil, mykadnumber=nil, warncardinfos=nil, requestid=nil)
5944
5930
  @ID = id
@@ -5973,11 +5959,11 @@ module TencentCloud
5973
5959
 
5974
5960
  # MLIDPassportOCR请求参数结构体
5975
5961
  class MLIDPassportOCRRequest < TencentCloud::Common::AbstractModel
5976
- # @param ImageBase64: 图片的 Base64 值。要求图片经Base64编码后不超过 7M,分辨率建议500*800以上,支持PNG、JPG、JPEG、BMP、PDF格式。建议卡片部分占据图片2/3以上。
5962
+ # @param ImageBase64: 图片的 Base64 值。要求图片经Base64编码后不超过 10M,分辨率建议500*800以上,支持PNG、JPG、JPEG、BMP、PDF格式。建议卡片部分占据图片2/3以上。
5977
5963
  # @type ImageBase64: String
5978
5964
  # @param RetImage: 是否返回图片,默认false
5979
5965
  # @type RetImage: Boolean
5980
- # @param ImageUrl: 图片的 Url 地址。要求图片经Base64编码后不超过 7M,分辨率建议500*800以上,支持PNG、JPG、JPEG、BMP、PDF格式。建议卡片部分占据图片2/3以上。图片下载时间不超过 3 秒。建议图片存储于腾讯云,可保障更高的下载速度和稳定性。
5966
+ # @param ImageUrl: 图片的 Url 地址。要求图片经Base64编码后不超过 10M,分辨率建议500*800以上,支持PNG、JPG、JPEG、BMP、PDF格式。建议卡片部分占据图片2/3以上。图片下载时间不超过 3 秒。建议图片存储于腾讯云,可保障更高的下载速度和稳定性。
5981
5967
  # @type ImageUrl: String
5982
5968
 
5983
5969
  attr_accessor :ImageBase64, :RetImage, :ImageUrl
@@ -6011,22 +5997,11 @@ module TencentCloud
6011
5997
  # @type IssuingCountry: String
6012
5998
  # @param Nationality: 国家地区代码(机读码区的解析结果)
6013
5999
  # @type Nationality: String
6014
- # @param Warn: 告警码:
6015
- # -9103 证照翻拍告警
6016
- # -9102 证照复印件告警(包括黑白复印件、彩色复印件)
6017
- # -9106 证件遮挡告警
6000
+ # @param Warn: 该字段已废弃, 将固定返回空数组,不建议使用。
6018
6001
  # @type Warn: Array
6019
6002
  # @param Image: 证件中的人像图片base64
6020
6003
  # @type Image: String
6021
- # @param AdvancedInfo: 扩展字段:
6022
- # {
6023
- # ID:{
6024
- # Confidence:0.9999
6025
- # },
6026
- # Name:{
6027
- # Confidence:0.9996
6028
- # }
6029
- # }
6004
+ # @param AdvancedInfo: 该字段已废弃, 将固定返回"1",不建议使用。
6030
6005
  # @type AdvancedInfo: String
6031
6006
  # @param CodeSet: 最下方第一行 MRZ Code 序列
6032
6007
  # @type CodeSet: String
@@ -6055,6 +6030,11 @@ module TencentCloud
6055
6030
  # @type RequestId: String
6056
6031
 
6057
6032
  attr_accessor :ID, :Name, :DateOfBirth, :Sex, :DateOfExpiration, :IssuingCountry, :Nationality, :Warn, :Image, :AdvancedInfo, :CodeSet, :CodeCrc, :Surname, :GivenName, :Type, :PassportRecognizeInfos, :WarnCardInfos, :RequestId
6033
+ extend Gem::Deprecate
6034
+ deprecate :Warn, :none, 2025, 7
6035
+ deprecate :Warn=, :none, 2025, 7
6036
+ deprecate :AdvancedInfo, :none, 2025, 7
6037
+ deprecate :AdvancedInfo=, :none, 2025, 7
6058
6038
 
6059
6039
  def initialize(id=nil, name=nil, dateofbirth=nil, sex=nil, dateofexpiration=nil, issuingcountry=nil, nationality=nil, warn=nil, image=nil, advancedinfo=nil, codeset=nil, codecrc=nil, surname=nil, givenname=nil, type=nil, passportrecognizeinfos=nil, warncardinfos=nil, requestid=nil)
6060
6040
  @ID = id
@@ -9521,6 +9501,62 @@ module TencentCloud
9521
9501
  end
9522
9502
  end
9523
9503
 
9504
+ # RecognizeTableMultiOCR请求参数结构体
9505
+ class RecognizeTableMultiOCRRequest < TencentCloud::Common::AbstractModel
9506
+ # @param ImageBase64: 图片/PDF的 Base64 值。 要求图片/PDF经Base64编码后不超过 10M,分辨率建议600*800以上,支持PNG、JPG、JPEG、BMP、PDF格式。 图片支持的像素范围:需介于20-10000px之间。 图片的 ImageUrl、ImageBase64 必须提供一个,如果都提供,只使用 ImageUrl。
9507
+ # @type ImageBase64: String
9508
+ # @param ImageUrl: 图片/PDF的 Url 地址。 要求图片/PDF经Base64编码后不超过 10M,分辨率建议600*800以上,支持PNG、JPG、JPEG、BMP、PDF格式。 图片支持的像素范围:需介于20-10000px之间。 图片存储于腾讯云的 Url 可保障更高的下载速度和稳定性,建议图片存储于腾讯云。非腾讯云存储的 Url 速度和稳定性可能受一定影响。
9509
+ # @type ImageUrl: String
9510
+ # @param PdfStartPageNumber: 文档的起始页码。 当传入文件是PDF型时,用来指定识别的起始页码,识别的页码包含当前值。
9511
+ # @type PdfStartPageNumber: Integer
9512
+ # @param PdfEndPageNumber: 文档的结束页码。 当传入文件是PDF类型时,用来指定识别的结束页码,识别的页码包含当前值。单次调用最多支持识别3页内容,即PdfEndPageNumber-PdfStartPageNumber需要不大于3。
9513
+ # @type PdfEndPageNumber: Integer
9514
+ # @param DataFormat: 配置选项,支持配置输出数据格式。
9515
+
9516
+ # * **Mdbase64** 返回 base64 编码的 markdown 格式文本。
9517
+ # * **Excelbase64** 返回 base64 编码的 excel 文件。
9518
+ # @type DataFormat: String
9519
+
9520
+ attr_accessor :ImageBase64, :ImageUrl, :PdfStartPageNumber, :PdfEndPageNumber, :DataFormat
9521
+
9522
+ def initialize(imagebase64=nil, imageurl=nil, pdfstartpagenumber=nil, pdfendpagenumber=nil, dataformat=nil)
9523
+ @ImageBase64 = imagebase64
9524
+ @ImageUrl = imageurl
9525
+ @PdfStartPageNumber = pdfstartpagenumber
9526
+ @PdfEndPageNumber = pdfendpagenumber
9527
+ @DataFormat = dataformat
9528
+ end
9529
+
9530
+ def deserialize(params)
9531
+ @ImageBase64 = params['ImageBase64']
9532
+ @ImageUrl = params['ImageUrl']
9533
+ @PdfStartPageNumber = params['PdfStartPageNumber']
9534
+ @PdfEndPageNumber = params['PdfEndPageNumber']
9535
+ @DataFormat = params['DataFormat']
9536
+ end
9537
+ end
9538
+
9539
+ # RecognizeTableMultiOCR返回参数结构体
9540
+ class RecognizeTableMultiOCRResponse < TencentCloud::Common::AbstractModel
9541
+ # @param DataBase64: Base64 编码后的 Excel 数据或 Markdown 数据。 注意:此字段可能返回空,表示取不到有效值。
9542
+ # 注意:此字段可能返回 null,表示取不到有效值。
9543
+ # @type DataBase64: String
9544
+ # @param RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
9545
+ # @type RequestId: String
9546
+
9547
+ attr_accessor :DataBase64, :RequestId
9548
+
9549
+ def initialize(database64=nil, requestid=nil)
9550
+ @DataBase64 = database64
9551
+ @RequestId = requestid
9552
+ end
9553
+
9554
+ def deserialize(params)
9555
+ @DataBase64 = params['DataBase64']
9556
+ @RequestId = params['RequestId']
9557
+ end
9558
+ end
9559
+
9524
9560
  # RecognizeTableOCR请求参数结构体
9525
9561
  class RecognizeTableOCRRequest < TencentCloud::Common::AbstractModel
9526
9562
  # @param ImageBase64: 图片/PDF的 Base64 值。
@@ -9669,20 +9705,15 @@ module TencentCloud
9669
9705
  # -9108 证件模糊告警
9670
9706
  # -9109 告警能力未开通
9671
9707
  # @type WarnCardInfos: Array
9672
- # @param AdvancedInfo: 字段置信度:
9673
- # {
9674
- # "ID": {
9675
- # "Confidence": 0.9999
9676
- # },
9677
- # "ThaiName": {
9678
- # "Confidence": 0.9996
9679
- # }
9680
- # }
9708
+ # @param AdvancedInfo: 该字段已废弃, 将固定返回"1",不建议使用。
9681
9709
  # @type AdvancedInfo: String
9682
9710
  # @param RequestId: 唯一请求 ID,由服务端生成,每次请求都会返回(若请求因其他原因未能抵达服务端,则该次请求不会获得 RequestId)。定位问题时需要提供该次请求的 RequestId。
9683
9711
  # @type RequestId: String
9684
9712
 
9685
9713
  attr_accessor :ID, :ThaiName, :EnFirstName, :EnLastName, :IssueDate, :ExpirationDate, :EnIssueDate, :EnExpirationDate, :Birthday, :EnBirthday, :Religion, :SerialNumber, :Address, :LaserID, :PortraitImage, :WarnCardInfos, :AdvancedInfo, :RequestId
9714
+ extend Gem::Deprecate
9715
+ deprecate :AdvancedInfo, :none, 2025, 7
9716
+ deprecate :AdvancedInfo=, :none, 2025, 7
9686
9717
 
9687
9718
  def initialize(id=nil, thainame=nil, enfirstname=nil, enlastname=nil, issuedate=nil, expirationdate=nil, enissuedate=nil, enexpirationdate=nil, birthday=nil, enbirthday=nil, religion=nil, serialnumber=nil, address=nil, laserid=nil, portraitimage=nil, warncardinfos=nil, advancedinfo=nil, requestid=nil)
9688
9719
  @ID = id
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: tencentcloud-sdk-ocr
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.0.1106
4
+ version: 3.0.1109
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tencent Cloud
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2025-07-22 00:00:00.000000000 Z
11
+ date: 2025-07-27 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: tencentcloud-sdk-common