google-cloud-document_ai-v1 0.7.0 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/google/cloud/document_ai/v1/document_processor_service/client.rb +124 -20
- data/lib/google/cloud/document_ai/v1/document_processor_service/paths.rb +19 -0
- data/lib/google/cloud/document_ai/v1/document_processor_service.rb +1 -1
- data/lib/google/cloud/document_ai/v1/version.rb +1 -1
- data/lib/google/cloud/document_ai/v1.rb +2 -2
- data/lib/google/cloud/documentai/v1/document_processor_service_pb.rb +4 -0
- data/lib/google/cloud/documentai/v1/document_processor_service_services_pb.rb +6 -2
- data/lib/google/cloud/documentai/v1/processor_type_pb.rb +1 -0
- data/proto_docs/google/cloud/documentai/v1/document.rb +134 -74
- data/proto_docs/google/cloud/documentai/v1/document_processor_service.rb +37 -18
- data/proto_docs/google/cloud/documentai/v1/document_schema.rb +1 -1
- data/proto_docs/google/cloud/documentai/v1/processor.rb +2 -1
- data/proto_docs/google/cloud/documentai/v1/processor_type.rb +3 -0
- metadata +7 -7
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 23ef9a502430698a1c55dbf3135c46b16db83bcea692d4d59486f2a412d5c8b8
|
4
|
+
data.tar.gz: fedc9cd1b4119b2a40e918c7d856ae6e6e9599d35fc62492a78577c93e05baf5
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3031d11fe9d45645810110bf58e728f7bf75cae916a4708b9d78a03a55df71408e35116934aa417975d5506001d0dff8ead57455636ba270c4922fd3bddae967
|
7
|
+
data.tar.gz: 154267b2196cefe2385f5a8f15ca6be64c721e484fe4d65e8fda516eead880b4bc9ffbf0166e67642dafe3c8f94734b1cb620eab390872e7c580b28f23f47ebb
|
@@ -212,11 +212,15 @@ module Google
|
|
212
212
|
# @param raw_document [::Google::Cloud::DocumentAI::V1::RawDocument, ::Hash]
|
213
213
|
# A raw document content (bytes).
|
214
214
|
# @param name [::String]
|
215
|
-
# Required. The resource name of the
|
215
|
+
# Required. The resource name of the
|
216
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} or
|
216
217
|
# {::Google::Cloud::DocumentAI::V1::ProcessorVersion ProcessorVersion}
|
217
|
-
# to use for processing. If a
|
218
|
-
#
|
219
|
-
#
|
218
|
+
# to use for processing. If a
|
219
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} is specified, the server
|
220
|
+
# will use its [default
|
221
|
+
# version][google.cloud.documentai.v1.Processor.default_processor_version].
|
222
|
+
# Format: `projects/{project}/locations/{location}/processors/{processor}`,
|
223
|
+
# or
|
220
224
|
# `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{processorVersion}`
|
221
225
|
# @param skip_human_review [::Boolean]
|
222
226
|
# Whether Human Review feature should be skipped for this request. Default to
|
@@ -310,7 +314,8 @@ module Google
|
|
310
314
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
311
315
|
#
|
312
316
|
# @param name [::String]
|
313
|
-
# Required. The resource name of
|
317
|
+
# Required. The resource name of
|
318
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} or
|
314
319
|
# {::Google::Cloud::DocumentAI::V1::ProcessorVersion ProcessorVersion}.
|
315
320
|
# Format: `projects/{project}/locations/{location}/processors/{processor}`,
|
316
321
|
# or
|
@@ -583,6 +588,91 @@ module Google
|
|
583
588
|
raise ::Google::Cloud::Error.from_error(e)
|
584
589
|
end
|
585
590
|
|
591
|
+
##
|
592
|
+
# Gets a processor type detail.
|
593
|
+
#
|
594
|
+
# @overload get_processor_type(request, options = nil)
|
595
|
+
# Pass arguments to `get_processor_type` via a request object, either of type
|
596
|
+
# {::Google::Cloud::DocumentAI::V1::GetProcessorTypeRequest} or an equivalent Hash.
|
597
|
+
#
|
598
|
+
# @param request [::Google::Cloud::DocumentAI::V1::GetProcessorTypeRequest, ::Hash]
|
599
|
+
# A request object representing the call parameters. Required. To specify no
|
600
|
+
# parameters, or to keep all the default parameter values, pass an empty Hash.
|
601
|
+
# @param options [::Gapic::CallOptions, ::Hash]
|
602
|
+
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
603
|
+
#
|
604
|
+
# @overload get_processor_type(name: nil)
|
605
|
+
# Pass arguments to `get_processor_type` via keyword arguments. Note that at
|
606
|
+
# least one keyword argument is required. To specify no parameters, or to keep all
|
607
|
+
# the default parameter values, pass an empty Hash as a request object (see above).
|
608
|
+
#
|
609
|
+
# @param name [::String]
|
610
|
+
# Required. The processor type resource name.
|
611
|
+
#
|
612
|
+
# @yield [response, operation] Access the result along with the RPC operation
|
613
|
+
# @yieldparam response [::Google::Cloud::DocumentAI::V1::ProcessorType]
|
614
|
+
# @yieldparam operation [::GRPC::ActiveCall::Operation]
|
615
|
+
#
|
616
|
+
# @return [::Google::Cloud::DocumentAI::V1::ProcessorType]
|
617
|
+
#
|
618
|
+
# @raise [::Google::Cloud::Error] if the RPC is aborted.
|
619
|
+
#
|
620
|
+
# @example Basic example
|
621
|
+
# require "google/cloud/document_ai/v1"
|
622
|
+
#
|
623
|
+
# # Create a client object. The client can be reused for multiple calls.
|
624
|
+
# client = Google::Cloud::DocumentAI::V1::DocumentProcessorService::Client.new
|
625
|
+
#
|
626
|
+
# # Create a request. To set request fields, pass in keyword arguments.
|
627
|
+
# request = Google::Cloud::DocumentAI::V1::GetProcessorTypeRequest.new
|
628
|
+
#
|
629
|
+
# # Call the get_processor_type method.
|
630
|
+
# result = client.get_processor_type request
|
631
|
+
#
|
632
|
+
# # The returned object is of type Google::Cloud::DocumentAI::V1::ProcessorType.
|
633
|
+
# p result
|
634
|
+
#
|
635
|
+
def get_processor_type request, options = nil
|
636
|
+
raise ::ArgumentError, "request must be provided" if request.nil?
|
637
|
+
|
638
|
+
request = ::Gapic::Protobuf.coerce request, to: ::Google::Cloud::DocumentAI::V1::GetProcessorTypeRequest
|
639
|
+
|
640
|
+
# Converts hash and nil to an options object
|
641
|
+
options = ::Gapic::CallOptions.new(**options.to_h) if options.respond_to? :to_h
|
642
|
+
|
643
|
+
# Customize the options with defaults
|
644
|
+
metadata = @config.rpcs.get_processor_type.metadata.to_h
|
645
|
+
|
646
|
+
# Set x-goog-api-client and x-goog-user-project headers
|
647
|
+
metadata[:"x-goog-api-client"] ||= ::Gapic::Headers.x_goog_api_client \
|
648
|
+
lib_name: @config.lib_name, lib_version: @config.lib_version,
|
649
|
+
gapic_version: ::Google::Cloud::DocumentAI::V1::VERSION
|
650
|
+
metadata[:"x-goog-user-project"] = @quota_project_id if @quota_project_id
|
651
|
+
|
652
|
+
header_params = {}
|
653
|
+
if request.name
|
654
|
+
header_params["name"] = request.name
|
655
|
+
end
|
656
|
+
|
657
|
+
request_params_header = header_params.map { |k, v| "#{k}=#{v}" }.join("&")
|
658
|
+
metadata[:"x-goog-request-params"] ||= request_params_header
|
659
|
+
|
660
|
+
options.apply_defaults timeout: @config.rpcs.get_processor_type.timeout,
|
661
|
+
metadata: metadata,
|
662
|
+
retry_policy: @config.rpcs.get_processor_type.retry_policy
|
663
|
+
|
664
|
+
options.apply_defaults timeout: @config.timeout,
|
665
|
+
metadata: @config.metadata,
|
666
|
+
retry_policy: @config.retry_policy
|
667
|
+
|
668
|
+
@document_processor_service_stub.call_rpc :get_processor_type, request, options: options do |response, operation|
|
669
|
+
yield response, operation if block_given?
|
670
|
+
return response
|
671
|
+
end
|
672
|
+
rescue ::GRPC::BadStatus => e
|
673
|
+
raise ::Google::Cloud::Error.from_error(e)
|
674
|
+
end
|
675
|
+
|
586
676
|
##
|
587
677
|
# Lists all processors which belong to this project.
|
588
678
|
#
|
@@ -602,8 +692,8 @@ module Google
|
|
602
692
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
603
693
|
#
|
604
694
|
# @param parent [::String]
|
605
|
-
# Required. The parent (project and location) which owns this collection of
|
606
|
-
# Format: `projects/{project}/locations/{location}`
|
695
|
+
# Required. The parent (project and location) which owns this collection of
|
696
|
+
# Processors. Format: `projects/{project}/locations/{location}`
|
607
697
|
# @param page_size [::Integer]
|
608
698
|
# The maximum number of processors to return.
|
609
699
|
# If unspecified, at most 50 processors will be returned.
|
@@ -872,8 +962,9 @@ module Google
|
|
872
962
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
873
963
|
#
|
874
964
|
# @param parent [::String]
|
875
|
-
# Required. The parent (project, location and processor) to list all
|
876
|
-
# Format:
|
965
|
+
# Required. The parent (project, location and processor) to list all
|
966
|
+
# versions. Format:
|
967
|
+
# `projects/{project}/locations/{location}/processors/{processor}`
|
877
968
|
# @param page_size [::Integer]
|
878
969
|
# The maximum number of processor versions to return.
|
879
970
|
# If unspecified, at most 10 processor versions will be returned.
|
@@ -1253,11 +1344,12 @@ module Google
|
|
1253
1344
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
1254
1345
|
#
|
1255
1346
|
# @param parent [::String]
|
1256
|
-
# Required. The parent (project and location) under which to create the
|
1257
|
-
# Format: `projects/{project}/locations/{location}`
|
1347
|
+
# Required. The parent (project and location) under which to create the
|
1348
|
+
# processor. Format: `projects/{project}/locations/{location}`
|
1258
1349
|
# @param processor [::Google::Cloud::DocumentAI::V1::Processor, ::Hash]
|
1259
|
-
# Required. The processor to be created, requires [processor_type] and
|
1260
|
-
# to be set. Also, the processor is under CMEK if CMEK fields
|
1350
|
+
# Required. The processor to be created, requires [processor_type] and
|
1351
|
+
# [display_name] to be set. Also, the processor is under CMEK if CMEK fields
|
1352
|
+
# are set.
|
1261
1353
|
#
|
1262
1354
|
# @yield [response, operation] Access the result along with the RPC operation
|
1263
1355
|
# @yieldparam response [::Google::Cloud::DocumentAI::V1::Processor]
|
@@ -1604,8 +1696,10 @@ module Google
|
|
1604
1696
|
end
|
1605
1697
|
|
1606
1698
|
##
|
1607
|
-
# Set the default (active) version of a
|
1608
|
-
# {::Google::Cloud::DocumentAI::V1::
|
1699
|
+
# Set the default (active) version of a
|
1700
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} that will be used in
|
1701
|
+
# {::Google::Cloud::DocumentAI::V1::DocumentProcessorService::Client#process_document ProcessDocument}
|
1702
|
+
# and
|
1609
1703
|
# {::Google::Cloud::DocumentAI::V1::DocumentProcessorService::Client#batch_process_documents BatchProcessDocuments}.
|
1610
1704
|
#
|
1611
1705
|
# @overload set_default_processor_version(request, options = nil)
|
@@ -1624,10 +1718,13 @@ module Google
|
|
1624
1718
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
1625
1719
|
#
|
1626
1720
|
# @param processor [::String]
|
1627
|
-
# Required. The resource name of the
|
1721
|
+
# Required. The resource name of the
|
1722
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} to change default
|
1723
|
+
# version.
|
1628
1724
|
# @param default_processor_version [::String]
|
1629
|
-
# Required. The resource name of child
|
1630
|
-
#
|
1725
|
+
# Required. The resource name of child
|
1726
|
+
# {::Google::Cloud::DocumentAI::V1::ProcessorVersion ProcessorVersion} to use as
|
1727
|
+
# default. Format:
|
1631
1728
|
# `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{version}`
|
1632
1729
|
#
|
1633
1730
|
# @yield [response, operation] Access the result along with the RPC operation
|
@@ -1724,8 +1821,8 @@ module Google
|
|
1724
1821
|
# @param inline_document [::Google::Cloud::DocumentAI::V1::Document, ::Hash]
|
1725
1822
|
# An inline document proto.
|
1726
1823
|
# @param human_review_config [::String]
|
1727
|
-
# Required. The resource name of the HumanReviewConfig that the document will
|
1728
|
-
# reviewed with.
|
1824
|
+
# Required. The resource name of the HumanReviewConfig that the document will
|
1825
|
+
# be reviewed with.
|
1729
1826
|
# @param enable_schema_validation [::Boolean]
|
1730
1827
|
# Whether the validation should be performed on the ad-hoc review request.
|
1731
1828
|
# @param priority [::Google::Cloud::DocumentAI::V1::ReviewDocumentRequest::Priority]
|
@@ -1961,6 +2058,11 @@ module Google
|
|
1961
2058
|
#
|
1962
2059
|
attr_reader :list_processor_types
|
1963
2060
|
##
|
2061
|
+
# RPC-specific configuration for `get_processor_type`
|
2062
|
+
# @return [::Gapic::Config::Method]
|
2063
|
+
#
|
2064
|
+
attr_reader :get_processor_type
|
2065
|
+
##
|
1964
2066
|
# RPC-specific configuration for `list_processors`
|
1965
2067
|
# @return [::Gapic::Config::Method]
|
1966
2068
|
#
|
@@ -2036,6 +2138,8 @@ module Google
|
|
2036
2138
|
@fetch_processor_types = ::Gapic::Config::Method.new fetch_processor_types_config
|
2037
2139
|
list_processor_types_config = parent_rpcs.list_processor_types if parent_rpcs.respond_to? :list_processor_types
|
2038
2140
|
@list_processor_types = ::Gapic::Config::Method.new list_processor_types_config
|
2141
|
+
get_processor_type_config = parent_rpcs.get_processor_type if parent_rpcs.respond_to? :get_processor_type
|
2142
|
+
@get_processor_type = ::Gapic::Config::Method.new get_processor_type_config
|
2039
2143
|
list_processors_config = parent_rpcs.list_processors if parent_rpcs.respond_to? :list_processors
|
2040
2144
|
@list_processors = ::Gapic::Config::Method.new list_processors_config
|
2041
2145
|
get_processor_config = parent_rpcs.get_processor if parent_rpcs.respond_to? :get_processor
|
@@ -79,6 +79,25 @@ module Google
|
|
79
79
|
"projects/#{project}/locations/#{location}/processors/#{processor}"
|
80
80
|
end
|
81
81
|
|
82
|
+
##
|
83
|
+
# Create a fully-qualified ProcessorType resource string.
|
84
|
+
#
|
85
|
+
# The resource will be in the following format:
|
86
|
+
#
|
87
|
+
# `projects/{project}/locations/{location}/processorTypes/{processor_type}`
|
88
|
+
#
|
89
|
+
# @param project [String]
|
90
|
+
# @param location [String]
|
91
|
+
# @param processor_type [String]
|
92
|
+
#
|
93
|
+
# @return [::String]
|
94
|
+
def processor_type_path project:, location:, processor_type:
|
95
|
+
raise ::ArgumentError, "project cannot contain /" if project.to_s.include? "/"
|
96
|
+
raise ::ArgumentError, "location cannot contain /" if location.to_s.include? "/"
|
97
|
+
|
98
|
+
"projects/#{project}/locations/#{location}/processorTypes/#{processor_type}"
|
99
|
+
end
|
100
|
+
|
82
101
|
##
|
83
102
|
# Create a fully-qualified ProcessorVersion resource string.
|
84
103
|
#
|
@@ -37,7 +37,7 @@ module Google
|
|
37
37
|
# AI such as natural language, computer vision, and translation to extract
|
38
38
|
# structured information from unstructured or semi-structured documents.
|
39
39
|
#
|
40
|
-
#
|
40
|
+
# @example Load this service and instantiate a gRPC client
|
41
41
|
#
|
42
42
|
# require "google/cloud/document_ai/v1/document_processor_service"
|
43
43
|
# client = ::Google::Cloud::DocumentAI::V1::DocumentProcessorService::Client.new
|
@@ -23,9 +23,9 @@ module Google
|
|
23
23
|
module Cloud
|
24
24
|
module DocumentAI
|
25
25
|
##
|
26
|
-
#
|
26
|
+
# API client module.
|
27
27
|
#
|
28
|
-
# @example
|
28
|
+
# @example Load this package, including all its services, and instantiate a gRPC client
|
29
29
|
#
|
30
30
|
# require "google/cloud/document_ai/v1"
|
31
31
|
# client = ::Google::Cloud::DocumentAI::V1::DocumentProcessorService::Client.new
|
@@ -99,6 +99,9 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
99
99
|
repeated :processors, :message, 1, "google.cloud.documentai.v1.Processor"
|
100
100
|
optional :next_page_token, :string, 2
|
101
101
|
end
|
102
|
+
add_message "google.cloud.documentai.v1.GetProcessorTypeRequest" do
|
103
|
+
optional :name, :string, 1
|
104
|
+
end
|
102
105
|
add_message "google.cloud.documentai.v1.GetProcessorRequest" do
|
103
106
|
optional :name, :string, 1
|
104
107
|
end
|
@@ -220,6 +223,7 @@ module Google
|
|
220
223
|
ListProcessorTypesResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.ListProcessorTypesResponse").msgclass
|
221
224
|
ListProcessorsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.ListProcessorsRequest").msgclass
|
222
225
|
ListProcessorsResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.ListProcessorsResponse").msgclass
|
226
|
+
GetProcessorTypeRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.GetProcessorTypeRequest").msgclass
|
223
227
|
GetProcessorRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.GetProcessorRequest").msgclass
|
224
228
|
GetProcessorVersionRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.GetProcessorVersionRequest").msgclass
|
225
229
|
ListProcessorVersionsRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1.ListProcessorVersionsRequest").msgclass
|
@@ -46,6 +46,8 @@ module Google
|
|
46
46
|
rpc :FetchProcessorTypes, ::Google::Cloud::DocumentAI::V1::FetchProcessorTypesRequest, ::Google::Cloud::DocumentAI::V1::FetchProcessorTypesResponse
|
47
47
|
# Lists the processor types that exist.
|
48
48
|
rpc :ListProcessorTypes, ::Google::Cloud::DocumentAI::V1::ListProcessorTypesRequest, ::Google::Cloud::DocumentAI::V1::ListProcessorTypesResponse
|
49
|
+
# Gets a processor type detail.
|
50
|
+
rpc :GetProcessorType, ::Google::Cloud::DocumentAI::V1::GetProcessorTypeRequest, ::Google::Cloud::DocumentAI::V1::ProcessorType
|
49
51
|
# Lists all processors which belong to this project.
|
50
52
|
rpc :ListProcessors, ::Google::Cloud::DocumentAI::V1::ListProcessorsRequest, ::Google::Cloud::DocumentAI::V1::ListProcessorsResponse
|
51
53
|
# Gets a processor detail.
|
@@ -71,8 +73,10 @@ module Google
|
|
71
73
|
rpc :EnableProcessor, ::Google::Cloud::DocumentAI::V1::EnableProcessorRequest, ::Google::Longrunning::Operation
|
72
74
|
# Disables a processor
|
73
75
|
rpc :DisableProcessor, ::Google::Cloud::DocumentAI::V1::DisableProcessorRequest, ::Google::Longrunning::Operation
|
74
|
-
# Set the default (active) version of a
|
75
|
-
# [
|
76
|
+
# Set the default (active) version of a
|
77
|
+
# [Processor][google.cloud.documentai.v1.Processor] that will be used in
|
78
|
+
# [ProcessDocument][google.cloud.documentai.v1.DocumentProcessorService.ProcessDocument]
|
79
|
+
# and
|
76
80
|
# [BatchProcessDocuments][google.cloud.documentai.v1.DocumentProcessorService.BatchProcessDocuments].
|
77
81
|
rpc :SetDefaultProcessorVersion, ::Google::Cloud::DocumentAI::V1::SetDefaultProcessorVersionRequest, ::Google::Longrunning::Operation
|
78
82
|
# Send a document for Human Review. The input document should be processed by
|
@@ -15,6 +15,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
15
15
|
repeated :available_locations, :message, 4, "google.cloud.documentai.v1.ProcessorType.LocationInfo"
|
16
16
|
optional :allow_creation, :bool, 6
|
17
17
|
optional :launch_stage, :enum, 8, "google.api.LaunchStage"
|
18
|
+
repeated :sample_document_uris, :string, 9
|
18
19
|
end
|
19
20
|
add_message "google.cloud.documentai.v1.ProcessorType.LocationInfo" do
|
20
21
|
optional :location_id, :string, 1
|
@@ -47,22 +47,25 @@ module Google
|
|
47
47
|
# Optional. UTF-8 encoded text in reading order from the document.
|
48
48
|
# @!attribute [rw] text_styles
|
49
49
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Style>]
|
50
|
-
#
|
50
|
+
# Styles for the {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
51
51
|
# @!attribute [rw] pages
|
52
52
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page>]
|
53
53
|
# Visual page layout for the {::Google::Cloud::DocumentAI::V1::Document Document}.
|
54
54
|
# @!attribute [rw] entities
|
55
55
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Entity>]
|
56
|
-
# A list of entities detected on
|
57
|
-
#
|
56
|
+
# A list of entities detected on
|
57
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}. For document
|
58
|
+
# shards, entities in this list may cross shard boundaries.
|
58
59
|
# @!attribute [rw] entity_relations
|
59
60
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::EntityRelation>]
|
60
|
-
# Placeholder. Relationship among
|
61
|
+
# Placeholder. Relationship among
|
62
|
+
# {::Google::Cloud::DocumentAI::V1::Document#entities Document.entities}.
|
61
63
|
# @!attribute [rw] text_changes
|
62
64
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::TextChange>]
|
63
|
-
# Placeholder. A list of text corrections made to
|
64
|
-
#
|
65
|
-
# for
|
65
|
+
# Placeholder. A list of text corrections made to
|
66
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}. This is usually
|
67
|
+
# used for annotating corrections to OCR mistakes. Text changes for a given
|
68
|
+
# revision may not overlap with each other.
|
66
69
|
# @!attribute [rw] shard_info
|
67
70
|
# @return [::Google::Cloud::DocumentAI::V1::Document::ShardInfo]
|
68
71
|
# Information about the sharding if this document is sharded part of a larger
|
@@ -88,7 +91,8 @@ module Google
|
|
88
91
|
# Total number of shards.
|
89
92
|
# @!attribute [rw] text_offset
|
90
93
|
# @return [::Integer]
|
91
|
-
# The index of the first character in
|
94
|
+
# The index of the first character in
|
95
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text} in the overall
|
92
96
|
# document global text.
|
93
97
|
class ShardInfo
|
94
98
|
include ::Google::Protobuf::MessageExts
|
@@ -99,7 +103,8 @@ module Google
|
|
99
103
|
# conventions as much as possible.
|
100
104
|
# @!attribute [rw] text_anchor
|
101
105
|
# @return [::Google::Cloud::DocumentAI::V1::Document::TextAnchor]
|
102
|
-
# Text anchor indexing into the
|
106
|
+
# Text anchor indexing into the
|
107
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
103
108
|
# @!attribute [rw] color
|
104
109
|
# @return [::Google::Type::Color]
|
105
110
|
# Text color.
|
@@ -146,9 +151,11 @@ module Google
|
|
146
151
|
# A page in a {::Google::Cloud::DocumentAI::V1::Document Document}.
|
147
152
|
# @!attribute [rw] page_number
|
148
153
|
# @return [::Integer]
|
149
|
-
# 1-based index for current
|
150
|
-
#
|
151
|
-
#
|
154
|
+
# 1-based index for current
|
155
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page Page} in a parent
|
156
|
+
# {::Google::Cloud::DocumentAI::V1::Document Document}. Useful when a page is
|
157
|
+
# taken out of a {::Google::Cloud::DocumentAI::V1::Document Document} for
|
158
|
+
# individual processing.
|
152
159
|
# @!attribute [rw] image
|
153
160
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Image]
|
154
161
|
# Rendered image for this page. This image is preprocessed to remove any
|
@@ -267,18 +274,23 @@ module Google
|
|
267
274
|
# Visual element describing a layout unit on a page.
|
268
275
|
# @!attribute [rw] text_anchor
|
269
276
|
# @return [::Google::Cloud::DocumentAI::V1::Document::TextAnchor]
|
270
|
-
# Text anchor indexing into the
|
277
|
+
# Text anchor indexing into the
|
278
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
271
279
|
# @!attribute [rw] confidence
|
272
280
|
# @return [::Float]
|
273
|
-
# Confidence of the current
|
274
|
-
#
|
275
|
-
#
|
281
|
+
# Confidence of the current
|
282
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} within
|
283
|
+
# context of the object this layout is for. e.g. confidence can be for a
|
284
|
+
# single token, a table, a visual element, etc. depending on context.
|
285
|
+
# Range `[0, 1]`.
|
276
286
|
# @!attribute [rw] bounding_poly
|
277
287
|
# @return [::Google::Cloud::DocumentAI::V1::BoundingPoly]
|
278
|
-
# The bounding polygon for the
|
288
|
+
# The bounding polygon for the
|
289
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout}.
|
279
290
|
# @!attribute [rw] orientation
|
280
291
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout::Orientation]
|
281
|
-
# Detected orientation for the
|
292
|
+
# Detected orientation for the
|
293
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout}.
|
282
294
|
class Layout
|
283
295
|
include ::Google::Protobuf::MessageExts
|
284
296
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -309,7 +321,8 @@ module Google
|
|
309
321
|
# common line-spacing and orientation.
|
310
322
|
# @!attribute [rw] layout
|
311
323
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
312
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
324
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
325
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Block Block}.
|
313
326
|
# @!attribute [rw] detected_languages
|
314
327
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
315
328
|
# A list of detected languages together with confidence.
|
@@ -324,7 +337,8 @@ module Google
|
|
324
337
|
# A collection of lines that a human would perceive as a paragraph.
|
325
338
|
# @!attribute [rw] layout
|
326
339
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
327
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
340
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
341
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Paragraph Paragraph}.
|
328
342
|
# @!attribute [rw] detected_languages
|
329
343
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
330
344
|
# A list of detected languages together with confidence.
|
@@ -340,7 +354,8 @@ module Google
|
|
340
354
|
# Does not cross column boundaries, can be horizontal, vertical, etc.
|
341
355
|
# @!attribute [rw] layout
|
342
356
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
343
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
357
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
358
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Line Line}.
|
344
359
|
# @!attribute [rw] detected_languages
|
345
360
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
346
361
|
# A list of detected languages together with confidence.
|
@@ -355,10 +370,12 @@ module Google
|
|
355
370
|
# A detected token.
|
356
371
|
# @!attribute [rw] layout
|
357
372
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
358
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
373
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
374
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Token Token}.
|
359
375
|
# @!attribute [rw] detected_break
|
360
376
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Token::DetectedBreak]
|
361
|
-
# Detected break at the end of a
|
377
|
+
# Detected break at the end of a
|
378
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Token Token}.
|
362
379
|
# @!attribute [rw] detected_languages
|
363
380
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
364
381
|
# A list of detected languages together with confidence.
|
@@ -369,7 +386,8 @@ module Google
|
|
369
386
|
include ::Google::Protobuf::MessageExts
|
370
387
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
371
388
|
|
372
|
-
# Detected break at the end of a
|
389
|
+
# Detected break at the end of a
|
390
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Token Token}.
|
373
391
|
# @!attribute [rw] type
|
374
392
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Token::DetectedBreak::Type]
|
375
393
|
# Detected break type.
|
@@ -397,7 +415,8 @@ module Google
|
|
397
415
|
# A detected symbol.
|
398
416
|
# @!attribute [rw] layout
|
399
417
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
400
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
418
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
419
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Symbol Symbol}.
|
401
420
|
# @!attribute [rw] detected_languages
|
402
421
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
403
422
|
# A list of detected languages together with confidence.
|
@@ -410,10 +429,12 @@ module Google
|
|
410
429
|
# page.
|
411
430
|
# @!attribute [rw] layout
|
412
431
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
413
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
432
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
433
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::VisualElement VisualElement}.
|
414
434
|
# @!attribute [rw] type
|
415
435
|
# @return [::String]
|
416
|
-
# Type of the
|
436
|
+
# Type of the
|
437
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::VisualElement VisualElement}.
|
417
438
|
# @!attribute [rw] detected_languages
|
418
439
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
419
440
|
# A list of detected languages together with confidence.
|
@@ -425,7 +446,8 @@ module Google
|
|
425
446
|
# A table representation similar to HTML table structure.
|
426
447
|
# @!attribute [rw] layout
|
427
448
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
428
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
449
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
450
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Table Table}.
|
429
451
|
# @!attribute [rw] header_rows
|
430
452
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::Table::TableRow>]
|
431
453
|
# Header rows of the table.
|
@@ -454,7 +476,8 @@ module Google
|
|
454
476
|
# A cell representation inside the table.
|
455
477
|
# @!attribute [rw] layout
|
456
478
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
457
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
479
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
480
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Table::TableCell TableCell}.
|
458
481
|
# @!attribute [rw] row_span
|
459
482
|
# @return [::Integer]
|
460
483
|
# How many rows this cell spans.
|
@@ -473,11 +496,13 @@ module Google
|
|
473
496
|
# A form field detected on the page.
|
474
497
|
# @!attribute [rw] field_name
|
475
498
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
476
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for the
|
477
|
-
#
|
499
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for the
|
500
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::FormField FormField} name.
|
501
|
+
# e.g. `Address`, `Email`, `Grand total`, `Phone number`, etc.
|
478
502
|
# @!attribute [rw] field_value
|
479
503
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
480
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for the
|
504
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for the
|
505
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::FormField FormField} value.
|
481
506
|
# @!attribute [rw] name_detected_languages
|
482
507
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Page::DetectedLanguage>]
|
483
508
|
# A list of detected languages for name together with confidence.
|
@@ -488,9 +513,10 @@ module Google
|
|
488
513
|
# @return [::String]
|
489
514
|
# If the value is non-textual, this field represents the type. Current
|
490
515
|
# valid values are:
|
491
|
-
#
|
492
|
-
# -
|
493
|
-
# -
|
516
|
+
#
|
517
|
+
# - blank (this indicates the `field_value` is normal text)
|
518
|
+
# - `unfilled_checkbox`
|
519
|
+
# - `filled_checkbox`
|
494
520
|
# @!attribute [rw] corrected_key_text
|
495
521
|
# @return [::String]
|
496
522
|
# Created for Labeling UI to export key text.
|
@@ -512,10 +538,12 @@ module Google
|
|
512
538
|
# A detected barcode.
|
513
539
|
# @!attribute [rw] layout
|
514
540
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Page::Layout]
|
515
|
-
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
541
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::Layout Layout} for
|
542
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::DetectedBarcode DetectedBarcode}.
|
516
543
|
# @!attribute [rw] barcode
|
517
544
|
# @return [::Google::Cloud::DocumentAI::V1::Barcode]
|
518
|
-
# Detailed barcode information of the
|
545
|
+
# Detailed barcode information of the
|
546
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page::DetectedBarcode DetectedBarcode}.
|
519
547
|
class DetectedBarcode
|
520
548
|
include ::Google::Protobuf::MessageExts
|
521
549
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -576,7 +604,8 @@ module Google
|
|
576
604
|
# @!attribute [rw] text_anchor
|
577
605
|
# @return [::Google::Cloud::DocumentAI::V1::Document::TextAnchor]
|
578
606
|
# Optional. Provenance of the entity.
|
579
|
-
# Text anchor indexing into the
|
607
|
+
# Text anchor indexing into the
|
608
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
580
609
|
# @!attribute [rw] type
|
581
610
|
# @return [::String]
|
582
611
|
# Required. Entity type from a schema e.g. `Address`.
|
@@ -591,28 +620,29 @@ module Google
|
|
591
620
|
# Optional. Confidence of detected Schema entity. Range `[0, 1]`.
|
592
621
|
# @!attribute [rw] page_anchor
|
593
622
|
# @return [::Google::Cloud::DocumentAI::V1::Document::PageAnchor]
|
594
|
-
# Optional. Represents the provenance of this entity wrt. the location on
|
595
|
-
# page where it was found.
|
623
|
+
# Optional. Represents the provenance of this entity wrt. the location on
|
624
|
+
# the page where it was found.
|
596
625
|
# @!attribute [rw] id
|
597
626
|
# @return [::String]
|
598
627
|
# Optional. Canonical id. This will be a unique value in the entity list
|
599
628
|
# for this document.
|
600
629
|
# @!attribute [rw] normalized_value
|
601
630
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Entity::NormalizedValue]
|
602
|
-
# Optional. Normalized entity value. Absent if the extracted value could
|
603
|
-
# converted or the type (e.g. address) is not supported for certain
|
631
|
+
# Optional. Normalized entity value. Absent if the extracted value could
|
632
|
+
# not be converted or the type (e.g. address) is not supported for certain
|
604
633
|
# parsers. This field is also only populated for certain supported document
|
605
634
|
# types.
|
606
635
|
# @!attribute [rw] properties
|
607
636
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::Entity>]
|
608
|
-
# Optional. Entities can be nested to form a hierarchical data structure
|
609
|
-
# the content in the document.
|
637
|
+
# Optional. Entities can be nested to form a hierarchical data structure
|
638
|
+
# representing the content in the document.
|
610
639
|
# @!attribute [rw] provenance
|
611
640
|
# @return [::Google::Cloud::DocumentAI::V1::Document::Provenance]
|
612
641
|
# Optional. The history of this annotation.
|
613
642
|
# @!attribute [rw] redacted
|
614
643
|
# @return [::Boolean]
|
615
|
-
# Optional. Whether the entity will be redacted for de-identification
|
644
|
+
# Optional. Whether the entity will be redacted for de-identification
|
645
|
+
# purposes.
|
616
646
|
class Entity
|
617
647
|
include ::Google::Protobuf::MessageExts
|
618
648
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -649,8 +679,8 @@ module Google
|
|
649
679
|
# Optional. An optional field to store a normalized string.
|
650
680
|
# For some entity types, one of respective `structured_value` fields may
|
651
681
|
# also be populated. Also not all the types of `structured_value` will be
|
652
|
-
# normalized. For example, some processors may not generate float
|
653
|
-
# or
|
682
|
+
# normalized. For example, some processors may not generate `float`
|
683
|
+
# or `integer` normalized text by default.
|
654
684
|
#
|
655
685
|
# Below are sample formats mapped to structured values.
|
656
686
|
#
|
@@ -663,7 +693,8 @@ module Google
|
|
663
693
|
end
|
664
694
|
end
|
665
695
|
|
666
|
-
# Relationship between
|
696
|
+
# Relationship between
|
697
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Entity Entities}.
|
667
698
|
# @!attribute [rw] subject_id
|
668
699
|
# @return [::String]
|
669
700
|
# Subject entity id.
|
@@ -678,10 +709,12 @@ module Google
|
|
678
709
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
679
710
|
end
|
680
711
|
|
681
|
-
# Text reference indexing into the
|
712
|
+
# Text reference indexing into the
|
713
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
682
714
|
# @!attribute [rw] text_segments
|
683
715
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::TextAnchor::TextSegment>]
|
684
|
-
# The text segments from the
|
716
|
+
# The text segments from the
|
717
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
685
718
|
# @!attribute [rw] content
|
686
719
|
# @return [::String]
|
687
720
|
# Contains the content of the text span so that users do
|
@@ -691,15 +724,20 @@ module Google
|
|
691
724
|
include ::Google::Protobuf::MessageExts
|
692
725
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
693
726
|
|
694
|
-
# A text segment in the
|
695
|
-
#
|
696
|
-
#
|
727
|
+
# A text segment in the
|
728
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}. The indices
|
729
|
+
# may be out of bounds which indicate that the text extends into another
|
730
|
+
# document shard for large sharded documents. See
|
731
|
+
# {::Google::Cloud::DocumentAI::V1::Document::ShardInfo#text_offset ShardInfo.text_offset}
|
697
732
|
# @!attribute [rw] start_index
|
698
733
|
# @return [::Integer]
|
699
|
-
# {::Google::Cloud::DocumentAI::V1::Document::TextAnchor::TextSegment TextSegment}
|
734
|
+
# {::Google::Cloud::DocumentAI::V1::Document::TextAnchor::TextSegment TextSegment}
|
735
|
+
# start UTF-8 char index in the
|
736
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
700
737
|
# @!attribute [rw] end_index
|
701
738
|
# @return [::Integer]
|
702
|
-
# {::Google::Cloud::DocumentAI::V1::Document::TextAnchor::TextSegment TextSegment}
|
739
|
+
# {::Google::Cloud::DocumentAI::V1::Document::TextAnchor::TextSegment TextSegment}
|
740
|
+
# half open end UTF-8 char index in the
|
703
741
|
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}.
|
704
742
|
class TextSegment
|
705
743
|
include ::Google::Protobuf::MessageExts
|
@@ -707,9 +745,10 @@ module Google
|
|
707
745
|
end
|
708
746
|
end
|
709
747
|
|
710
|
-
# Referencing the visual context of the entity in the
|
711
|
-
# Page anchors
|
712
|
-
#
|
748
|
+
# Referencing the visual context of the entity in the
|
749
|
+
# {::Google::Cloud::DocumentAI::V1::Document#pages Document.pages}. Page anchors
|
750
|
+
# can be cross-page, consist of multiple bounding polygons and optionally
|
751
|
+
# reference specific layout element types.
|
713
752
|
# @!attribute [rw] page_refs
|
714
753
|
# @return [::Array<::Google::Cloud::DocumentAI::V1::Document::PageAnchor::PageRef>]
|
715
754
|
# One or more references to visual page elements
|
@@ -720,22 +759,29 @@ module Google
|
|
720
759
|
# Represents a weak reference to a page element within a document.
|
721
760
|
# @!attribute [rw] page
|
722
761
|
# @return [::Integer]
|
723
|
-
# Required. Index into the
|
724
|
-
#
|
725
|
-
#
|
762
|
+
# Required. Index into the
|
763
|
+
# {::Google::Cloud::DocumentAI::V1::Document#pages Document.pages} element,
|
764
|
+
# for example using
|
765
|
+
# `[Document.pages][page_refs.page]` to locate the related page element.
|
766
|
+
# This field is skipped when its value is the default `0`. See
|
726
767
|
# https://developers.google.com/protocol-buffers/docs/proto3#json.
|
727
768
|
# @!attribute [rw] layout_type
|
728
769
|
# @return [::Google::Cloud::DocumentAI::V1::Document::PageAnchor::PageRef::LayoutType]
|
729
|
-
# Optional. The type of the layout element that is being referenced if
|
770
|
+
# Optional. The type of the layout element that is being referenced if
|
771
|
+
# any.
|
730
772
|
# @!attribute [rw] layout_id
|
731
773
|
# @return [::String]
|
732
|
-
# Optional. Deprecated. Use
|
774
|
+
# Optional. Deprecated. Use
|
775
|
+
# {::Google::Cloud::DocumentAI::V1::Document::PageAnchor::PageRef#bounding_poly PageRef.bounding_poly}
|
776
|
+
# instead.
|
733
777
|
# @!attribute [rw] bounding_poly
|
734
778
|
# @return [::Google::Cloud::DocumentAI::V1::BoundingPoly]
|
735
|
-
# Optional. Identifies the bounding polygon of a layout element on the
|
779
|
+
# Optional. Identifies the bounding polygon of a layout element on the
|
780
|
+
# page.
|
736
781
|
# @!attribute [rw] confidence
|
737
782
|
# @return [::Float]
|
738
|
-
# Optional. Confidence of detected page element, if applicable. Range
|
783
|
+
# Optional. Confidence of detected page element, if applicable. Range
|
784
|
+
# `[0, 1]`.
|
739
785
|
class PageRef
|
740
786
|
include ::Google::Protobuf::MessageExts
|
741
787
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -745,25 +791,38 @@ module Google
|
|
745
791
|
# Layout Unspecified.
|
746
792
|
LAYOUT_TYPE_UNSPECIFIED = 0
|
747
793
|
|
748
|
-
# References a
|
794
|
+
# References a
|
795
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#blocks Page.blocks}
|
796
|
+
# element.
|
749
797
|
BLOCK = 1
|
750
798
|
|
751
|
-
# References a
|
799
|
+
# References a
|
800
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#paragraphs Page.paragraphs}
|
801
|
+
# element.
|
752
802
|
PARAGRAPH = 2
|
753
803
|
|
754
|
-
# References a
|
804
|
+
# References a
|
805
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#lines Page.lines} element.
|
755
806
|
LINE = 3
|
756
807
|
|
757
|
-
# References a
|
808
|
+
# References a
|
809
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#tokens Page.tokens}
|
810
|
+
# element.
|
758
811
|
TOKEN = 4
|
759
812
|
|
760
|
-
# References a
|
813
|
+
# References a
|
814
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#visual_elements Page.visual_elements}
|
815
|
+
# element.
|
761
816
|
VISUAL_ELEMENT = 5
|
762
817
|
|
763
|
-
# Refrrences a
|
818
|
+
# Refrrences a
|
819
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#tables Page.tables}
|
820
|
+
# element.
|
764
821
|
TABLE = 6
|
765
822
|
|
766
|
-
# References a
|
823
|
+
# References a
|
824
|
+
# {::Google::Cloud::DocumentAI::V1::Document::Page#form_fields Page.form_fields}
|
825
|
+
# element.
|
767
826
|
FORM_FIELD = 7
|
768
827
|
end
|
769
828
|
end
|
@@ -882,8 +941,9 @@ module Google
|
|
882
941
|
# @!attribute [rw] text_anchor
|
883
942
|
# @return [::Google::Cloud::DocumentAI::V1::Document::TextAnchor]
|
884
943
|
# Provenance of the correction.
|
885
|
-
# Text anchor indexing into the
|
886
|
-
#
|
944
|
+
# Text anchor indexing into the
|
945
|
+
# {::Google::Cloud::DocumentAI::V1::Document#text Document.text}. There can
|
946
|
+
# only be a single `TextAnchor.text_segments` element. If the start and
|
887
947
|
# end index of the text segment are the same, the text change is inserted
|
888
948
|
# before that index.
|
889
949
|
# @!attribute [rw] changed_text
|
@@ -30,11 +30,15 @@ module Google
|
|
30
30
|
# A raw document content (bytes).
|
31
31
|
# @!attribute [rw] name
|
32
32
|
# @return [::String]
|
33
|
-
# Required. The resource name of the
|
33
|
+
# Required. The resource name of the
|
34
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} or
|
34
35
|
# {::Google::Cloud::DocumentAI::V1::ProcessorVersion ProcessorVersion}
|
35
|
-
# to use for processing. If a
|
36
|
-
#
|
37
|
-
#
|
36
|
+
# to use for processing. If a
|
37
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} is specified, the server
|
38
|
+
# will use its [default
|
39
|
+
# version][google.cloud.documentai.v1.Processor.default_processor_version].
|
40
|
+
# Format: `projects/{project}/locations/{location}/processors/{processor}`,
|
41
|
+
# or
|
38
42
|
# `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{processorVersion}`
|
39
43
|
# @!attribute [rw] skip_human_review
|
40
44
|
# @return [::Boolean]
|
@@ -105,7 +109,8 @@ module Google
|
|
105
109
|
# Request message for batch process document method.
|
106
110
|
# @!attribute [rw] name
|
107
111
|
# @return [::String]
|
108
|
-
# Required. The resource name of
|
112
|
+
# Required. The resource name of
|
113
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} or
|
109
114
|
# {::Google::Cloud::DocumentAI::V1::ProcessorVersion ProcessorVersion}.
|
110
115
|
# Format: `projects/{project}/locations/{location}/processors/{processor}`,
|
111
116
|
# or
|
@@ -253,8 +258,8 @@ module Google
|
|
253
258
|
# Request message for list all processors belongs to a project.
|
254
259
|
# @!attribute [rw] parent
|
255
260
|
# @return [::String]
|
256
|
-
# Required. The parent (project and location) which owns this collection of
|
257
|
-
# Format: `projects/{project}/locations/{location}`
|
261
|
+
# Required. The parent (project and location) which owns this collection of
|
262
|
+
# Processors. Format: `projects/{project}/locations/{location}`
|
258
263
|
# @!attribute [rw] page_size
|
259
264
|
# @return [::Integer]
|
260
265
|
# The maximum number of processors to return.
|
@@ -281,6 +286,15 @@ module Google
|
|
281
286
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
282
287
|
end
|
283
288
|
|
289
|
+
# Request message for get processor.
|
290
|
+
# @!attribute [rw] name
|
291
|
+
# @return [::String]
|
292
|
+
# Required. The processor type resource name.
|
293
|
+
class GetProcessorTypeRequest
|
294
|
+
include ::Google::Protobuf::MessageExts
|
295
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
296
|
+
end
|
297
|
+
|
284
298
|
# Request message for get processor.
|
285
299
|
# @!attribute [rw] name
|
286
300
|
# @return [::String]
|
@@ -302,8 +316,9 @@ module Google
|
|
302
316
|
# Request message for list all processor versions belongs to a processor.
|
303
317
|
# @!attribute [rw] parent
|
304
318
|
# @return [::String]
|
305
|
-
# Required. The parent (project, location and processor) to list all
|
306
|
-
# Format:
|
319
|
+
# Required. The parent (project, location and processor) to list all
|
320
|
+
# versions. Format:
|
321
|
+
# `projects/{project}/locations/{location}/processors/{processor}`
|
307
322
|
# @!attribute [rw] page_size
|
308
323
|
# @return [::Integer]
|
309
324
|
# The maximum number of processor versions to return.
|
@@ -402,12 +417,13 @@ module Google
|
|
402
417
|
# on that region, the creation will fail.
|
403
418
|
# @!attribute [rw] parent
|
404
419
|
# @return [::String]
|
405
|
-
# Required. The parent (project and location) under which to create the
|
406
|
-
# Format: `projects/{project}/locations/{location}`
|
420
|
+
# Required. The parent (project and location) under which to create the
|
421
|
+
# processor. Format: `projects/{project}/locations/{location}`
|
407
422
|
# @!attribute [rw] processor
|
408
423
|
# @return [::Google::Cloud::DocumentAI::V1::Processor]
|
409
|
-
# Required. The processor to be created, requires [processor_type] and
|
410
|
-
# to be set. Also, the processor is under CMEK if CMEK fields
|
424
|
+
# Required. The processor to be created, requires [processor_type] and
|
425
|
+
# [display_name] to be set. Also, the processor is under CMEK if CMEK fields
|
426
|
+
# are set.
|
411
427
|
class CreateProcessorRequest
|
412
428
|
include ::Google::Protobuf::MessageExts
|
413
429
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -484,11 +500,14 @@ module Google
|
|
484
500
|
# Request message for the set default processor version method.
|
485
501
|
# @!attribute [rw] processor
|
486
502
|
# @return [::String]
|
487
|
-
# Required. The resource name of the
|
503
|
+
# Required. The resource name of the
|
504
|
+
# {::Google::Cloud::DocumentAI::V1::Processor Processor} to change default
|
505
|
+
# version.
|
488
506
|
# @!attribute [rw] default_processor_version
|
489
507
|
# @return [::String]
|
490
|
-
# Required. The resource name of child
|
491
|
-
#
|
508
|
+
# Required. The resource name of child
|
509
|
+
# {::Google::Cloud::DocumentAI::V1::ProcessorVersion ProcessorVersion} to use as
|
510
|
+
# default. Format:
|
492
511
|
# `projects/{project}/locations/{location}/processors/{processor}/processorVersions/{version}`
|
493
512
|
class SetDefaultProcessorVersionRequest
|
494
513
|
include ::Google::Protobuf::MessageExts
|
@@ -517,8 +536,8 @@ module Google
|
|
517
536
|
# An inline document proto.
|
518
537
|
# @!attribute [rw] human_review_config
|
519
538
|
# @return [::String]
|
520
|
-
# Required. The resource name of the HumanReviewConfig that the document will
|
521
|
-
# reviewed with.
|
539
|
+
# Required. The resource name of the HumanReviewConfig that the document will
|
540
|
+
# be reviewed with.
|
522
541
|
# @!attribute [rw] enable_schema_validation
|
523
542
|
# @return [::Boolean]
|
524
543
|
# Whether the validation should be performed on the ad-hoc review request.
|
@@ -58,7 +58,7 @@ module Google
|
|
58
58
|
# conventions:
|
59
59
|
#
|
60
60
|
# - *use `snake_casing`*
|
61
|
-
# - name matching is case-
|
61
|
+
# - name matching is case-sensitive
|
62
62
|
# - Maximum 64 characters.
|
63
63
|
# - Must start with a letter.
|
64
64
|
# - Allowed characters: ASCII letters `[a-z0-9_-]`. (For backward
|
@@ -121,7 +121,8 @@ module Google
|
|
121
121
|
# The default processor version.
|
122
122
|
# @!attribute [r] process_endpoint
|
123
123
|
# @return [::String]
|
124
|
-
# Output only. Immutable. The http endpoint that can be called to invoke
|
124
|
+
# Output only. Immutable. The http endpoint that can be called to invoke
|
125
|
+
# processing.
|
125
126
|
# @!attribute [rw] create_time
|
126
127
|
# @return [::Google::Protobuf::Timestamp]
|
127
128
|
# The time the processor was created.
|
@@ -43,6 +43,9 @@ module Google
|
|
43
43
|
# @!attribute [rw] launch_stage
|
44
44
|
# @return [::Google::Api::LaunchStage]
|
45
45
|
# Launch stage of the processor type
|
46
|
+
# @!attribute [rw] sample_document_uris
|
47
|
+
# @return [::Array<::String>]
|
48
|
+
# A set of Cloud Storage URIs of sample documents for this processor.
|
46
49
|
class ProcessorType
|
47
50
|
include ::Google::Protobuf::MessageExts
|
48
51
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-document_ai-v1
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.9.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Google LLC
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-01-20 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gapic-common
|
@@ -16,7 +16,7 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version:
|
19
|
+
version: 0.16.0
|
20
20
|
- - "<"
|
21
21
|
- !ruby/object:Gem::Version
|
22
22
|
version: 2.a
|
@@ -26,7 +26,7 @@ dependencies:
|
|
26
26
|
requirements:
|
27
27
|
- - ">="
|
28
28
|
- !ruby/object:Gem::Version
|
29
|
-
version:
|
29
|
+
version: 0.16.0
|
30
30
|
- - "<"
|
31
31
|
- !ruby/object:Gem::Version
|
32
32
|
version: 2.a
|
@@ -50,7 +50,7 @@ dependencies:
|
|
50
50
|
requirements:
|
51
51
|
- - ">="
|
52
52
|
- !ruby/object:Gem::Version
|
53
|
-
version: '0.
|
53
|
+
version: '0.3'
|
54
54
|
- - "<"
|
55
55
|
- !ruby/object:Gem::Version
|
56
56
|
version: 2.a
|
@@ -60,7 +60,7 @@ dependencies:
|
|
60
60
|
requirements:
|
61
61
|
- - ">="
|
62
62
|
- !ruby/object:Gem::Version
|
63
|
-
version: '0.
|
63
|
+
version: '0.3'
|
64
64
|
- - "<"
|
65
65
|
- !ruby/object:Gem::Version
|
66
66
|
version: 2.a
|
@@ -254,7 +254,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
254
254
|
- !ruby/object:Gem::Version
|
255
255
|
version: '0'
|
256
256
|
requirements: []
|
257
|
-
rubygems_version: 3.
|
257
|
+
rubygems_version: 3.4.2
|
258
258
|
signing_key:
|
259
259
|
specification_version: 4
|
260
260
|
summary: API Client library for the Document AI V1 API
|