google-cloud-document_ai-v1beta3 0.2.0 → 0.3.0
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 +4 -4
- data/lib/google/cloud/document_ai/v1beta3/document_processor_service/client.rb +16 -3
- data/lib/google/cloud/document_ai/v1beta3/version.rb +1 -1
- data/lib/google/cloud/documentai/v1beta3/document_io_pb.rb +54 -0
- data/lib/google/cloud/documentai/v1beta3/document_processor_service_pb.rb +44 -0
- data/proto_docs/google/cloud/documentai/v1beta3/document_io.rb +100 -0
- data/proto_docs/google/cloud/documentai/v1beta3/document_processor_service.rb +106 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 8250140801da44a43abf013014bb672f5152c3a58c5bb7fd4a2d0f8b6c8b8bc9
|
4
|
+
data.tar.gz: 458937c2b824644df0f4cb9c6b9d7d18bef5c9fed6b9b80245626a0bf95c71eb
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 579729a6b88659f3398bf225a075ff47aaced17f5f071ca1b2eff4efe73b62353a3372fa8fb7925480e8aa1cee00b2ef836e5564d70ec42779773262805a3e72
|
7
|
+
data.tar.gz: ffc69be5817e8c81445c8d0baaff0886c324bf5be378428b1201ebb91138404508e87243258477401a4f6b024e836a9823902399dd951a2adde0131c6cb29d35
|
@@ -202,11 +202,15 @@ module Google
|
|
202
202
|
# @param options [::Gapic::CallOptions, ::Hash]
|
203
203
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
204
204
|
#
|
205
|
-
# @overload process_document(name: nil, document: nil, skip_human_review: nil)
|
205
|
+
# @overload process_document(inline_document: nil, raw_document: nil, name: nil, document: nil, skip_human_review: nil)
|
206
206
|
# Pass arguments to `process_document` via keyword arguments. Note that at
|
207
207
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
208
208
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
209
209
|
#
|
210
|
+
# @param inline_document [::Google::Cloud::DocumentAI::V1beta3::Document, ::Hash]
|
211
|
+
# An inline document proto.
|
212
|
+
# @param raw_document [::Google::Cloud::DocumentAI::V1beta3::RawDocument, ::Hash]
|
213
|
+
# A raw document content (bytes).
|
210
214
|
# @param name [::String]
|
211
215
|
# Required. The processor resource name.
|
212
216
|
# @param document [::Google::Cloud::DocumentAI::V1beta3::Document, ::Hash]
|
@@ -274,7 +278,7 @@ module Google
|
|
274
278
|
# @param options [::Gapic::CallOptions, ::Hash]
|
275
279
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
276
280
|
#
|
277
|
-
# @overload batch_process_documents(name: nil, input_configs: nil, output_config: nil)
|
281
|
+
# @overload batch_process_documents(name: nil, input_configs: nil, output_config: nil, input_documents: nil, document_output_config: nil, skip_human_review: nil)
|
278
282
|
# Pass arguments to `batch_process_documents` via keyword arguments. Note that at
|
279
283
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
280
284
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
@@ -285,6 +289,13 @@ module Google
|
|
285
289
|
# The input config for each single document in the batch process.
|
286
290
|
# @param output_config [::Google::Cloud::DocumentAI::V1beta3::BatchProcessRequest::BatchOutputConfig, ::Hash]
|
287
291
|
# The overall output config for batch process.
|
292
|
+
# @param input_documents [::Google::Cloud::DocumentAI::V1beta3::BatchDocumentsInputConfig, ::Hash]
|
293
|
+
# The input documents for batch process.
|
294
|
+
# @param document_output_config [::Google::Cloud::DocumentAI::V1beta3::DocumentOutputConfig, ::Hash]
|
295
|
+
# The overall output config for batch process.
|
296
|
+
# @param skip_human_review [::Boolean]
|
297
|
+
# Whether Human Review feature should be skipped for this request. Default to
|
298
|
+
# false.
|
288
299
|
#
|
289
300
|
# @yield [response, operation] Access the result along with the RPC operation
|
290
301
|
# @yieldparam response [::Gapic::Operation]
|
@@ -346,11 +357,13 @@ module Google
|
|
346
357
|
# @param options [::Gapic::CallOptions, ::Hash]
|
347
358
|
# Overrides the default settings for this call, e.g, timeout, retries, etc. Optional.
|
348
359
|
#
|
349
|
-
# @overload review_document(human_review_config: nil, document: nil)
|
360
|
+
# @overload review_document(inline_document: nil, human_review_config: nil, document: nil)
|
350
361
|
# Pass arguments to `review_document` via keyword arguments. Note that at
|
351
362
|
# least one keyword argument is required. To specify no parameters, or to keep all
|
352
363
|
# the default parameter values, pass an empty Hash as a request object (see above).
|
353
364
|
#
|
365
|
+
# @param inline_document [::Google::Cloud::DocumentAI::V1beta3::Document, ::Hash]
|
366
|
+
# An inline document proto.
|
354
367
|
# @param human_review_config [::String]
|
355
368
|
# Required. The resource name of the HumanReviewConfig that the document will be
|
356
369
|
# reviewed with.
|
@@ -0,0 +1,54 @@
|
|
1
|
+
# Generated by the protocol buffer compiler. DO NOT EDIT!
|
2
|
+
# source: google/cloud/documentai/v1beta3/document_io.proto
|
3
|
+
|
4
|
+
require 'google/protobuf'
|
5
|
+
|
6
|
+
require 'google/api/annotations_pb'
|
7
|
+
Google::Protobuf::DescriptorPool.generated_pool.build do
|
8
|
+
add_file("google/cloud/documentai/v1beta3/document_io.proto", :syntax => :proto3) do
|
9
|
+
add_message "google.cloud.documentai.v1beta3.RawDocument" do
|
10
|
+
optional :content, :bytes, 1
|
11
|
+
optional :mime_type, :string, 2
|
12
|
+
end
|
13
|
+
add_message "google.cloud.documentai.v1beta3.GcsDocument" do
|
14
|
+
optional :gcs_uri, :string, 1
|
15
|
+
optional :mime_type, :string, 2
|
16
|
+
end
|
17
|
+
add_message "google.cloud.documentai.v1beta3.GcsDocuments" do
|
18
|
+
repeated :documents, :message, 1, "google.cloud.documentai.v1beta3.GcsDocument"
|
19
|
+
end
|
20
|
+
add_message "google.cloud.documentai.v1beta3.GcsPrefix" do
|
21
|
+
optional :gcs_uri_prefix, :string, 1
|
22
|
+
end
|
23
|
+
add_message "google.cloud.documentai.v1beta3.BatchDocumentsInputConfig" do
|
24
|
+
oneof :source do
|
25
|
+
optional :gcs_prefix, :message, 1, "google.cloud.documentai.v1beta3.GcsPrefix"
|
26
|
+
optional :gcs_documents, :message, 2, "google.cloud.documentai.v1beta3.GcsDocuments"
|
27
|
+
end
|
28
|
+
end
|
29
|
+
add_message "google.cloud.documentai.v1beta3.DocumentOutputConfig" do
|
30
|
+
oneof :destination do
|
31
|
+
optional :gcs_output_config, :message, 1, "google.cloud.documentai.v1beta3.DocumentOutputConfig.GcsOutputConfig"
|
32
|
+
end
|
33
|
+
end
|
34
|
+
add_message "google.cloud.documentai.v1beta3.DocumentOutputConfig.GcsOutputConfig" do
|
35
|
+
optional :gcs_uri, :string, 1
|
36
|
+
end
|
37
|
+
end
|
38
|
+
end
|
39
|
+
|
40
|
+
module Google
|
41
|
+
module Cloud
|
42
|
+
module DocumentAI
|
43
|
+
module V1beta3
|
44
|
+
RawDocument = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.RawDocument").msgclass
|
45
|
+
GcsDocument = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.GcsDocument").msgclass
|
46
|
+
GcsDocuments = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.GcsDocuments").msgclass
|
47
|
+
GcsPrefix = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.GcsPrefix").msgclass
|
48
|
+
BatchDocumentsInputConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.BatchDocumentsInputConfig").msgclass
|
49
|
+
DocumentOutputConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.DocumentOutputConfig").msgclass
|
50
|
+
DocumentOutputConfig::GcsOutputConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.DocumentOutputConfig.GcsOutputConfig").msgclass
|
51
|
+
end
|
52
|
+
end
|
53
|
+
end
|
54
|
+
end
|
@@ -8,6 +8,7 @@ require 'google/api/client_pb'
|
|
8
8
|
require 'google/api/field_behavior_pb'
|
9
9
|
require 'google/api/resource_pb'
|
10
10
|
require 'google/cloud/documentai/v1beta3/document_pb'
|
11
|
+
require 'google/cloud/documentai/v1beta3/document_io_pb'
|
11
12
|
require 'google/longrunning/operations_pb'
|
12
13
|
require 'google/protobuf/field_mask_pb'
|
13
14
|
require 'google/protobuf/timestamp_pb'
|
@@ -18,15 +19,35 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
18
19
|
optional :name, :string, 1
|
19
20
|
optional :document, :message, 2, "google.cloud.documentai.v1beta3.Document"
|
20
21
|
optional :skip_human_review, :bool, 3
|
22
|
+
oneof :source do
|
23
|
+
optional :inline_document, :message, 4, "google.cloud.documentai.v1beta3.Document"
|
24
|
+
optional :raw_document, :message, 5, "google.cloud.documentai.v1beta3.RawDocument"
|
25
|
+
end
|
26
|
+
end
|
27
|
+
add_message "google.cloud.documentai.v1beta3.HumanReviewStatus" do
|
28
|
+
optional :state, :enum, 1, "google.cloud.documentai.v1beta3.HumanReviewStatus.State"
|
29
|
+
optional :state_message, :string, 2
|
30
|
+
optional :human_review_operation, :string, 3
|
31
|
+
end
|
32
|
+
add_enum "google.cloud.documentai.v1beta3.HumanReviewStatus.State" do
|
33
|
+
value :STATE_UNSPECIFIED, 0
|
34
|
+
value :SKIPPED, 1
|
35
|
+
value :VALIDATION_PASSED, 2
|
36
|
+
value :IN_PROGRESS, 3
|
37
|
+
value :ERROR, 4
|
21
38
|
end
|
22
39
|
add_message "google.cloud.documentai.v1beta3.ProcessResponse" do
|
23
40
|
optional :document, :message, 1, "google.cloud.documentai.v1beta3.Document"
|
24
41
|
optional :human_review_operation, :string, 2
|
42
|
+
optional :human_review_status, :message, 3, "google.cloud.documentai.v1beta3.HumanReviewStatus"
|
25
43
|
end
|
26
44
|
add_message "google.cloud.documentai.v1beta3.BatchProcessRequest" do
|
27
45
|
optional :name, :string, 1
|
28
46
|
repeated :input_configs, :message, 2, "google.cloud.documentai.v1beta3.BatchProcessRequest.BatchInputConfig"
|
29
47
|
optional :output_config, :message, 3, "google.cloud.documentai.v1beta3.BatchProcessRequest.BatchOutputConfig"
|
48
|
+
optional :input_documents, :message, 5, "google.cloud.documentai.v1beta3.BatchDocumentsInputConfig"
|
49
|
+
optional :document_output_config, :message, 6, "google.cloud.documentai.v1beta3.DocumentOutputConfig"
|
50
|
+
optional :skip_human_review, :bool, 4
|
30
51
|
end
|
31
52
|
add_message "google.cloud.documentai.v1beta3.BatchProcessRequest.BatchInputConfig" do
|
32
53
|
optional :gcs_source, :string, 1
|
@@ -49,6 +70,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
49
70
|
optional :status, :message, 2, "google.rpc.Status"
|
50
71
|
optional :output_gcs_destination, :string, 3
|
51
72
|
optional :human_review_operation, :string, 4
|
73
|
+
optional :human_review_status, :message, 5, "google.cloud.documentai.v1beta3.HumanReviewStatus"
|
52
74
|
end
|
53
75
|
add_enum "google.cloud.documentai.v1beta3.BatchProcessMetadata.State" do
|
54
76
|
value :STATE_UNSPECIFIED, 0
|
@@ -62,6 +84,9 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
62
84
|
add_message "google.cloud.documentai.v1beta3.ReviewDocumentRequest" do
|
63
85
|
optional :human_review_config, :string, 1
|
64
86
|
optional :document, :message, 2, "google.cloud.documentai.v1beta3.Document"
|
87
|
+
oneof :source do
|
88
|
+
optional :inline_document, :message, 4, "google.cloud.documentai.v1beta3.Document"
|
89
|
+
end
|
65
90
|
end
|
66
91
|
add_message "google.cloud.documentai.v1beta3.ReviewDocumentResponse" do
|
67
92
|
optional :gcs_destination, :string, 1
|
@@ -71,6 +96,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
71
96
|
optional :state_message, :string, 2
|
72
97
|
optional :create_time, :message, 3, "google.protobuf.Timestamp"
|
73
98
|
optional :update_time, :message, 4, "google.protobuf.Timestamp"
|
99
|
+
optional :common_metadata, :message, 5, "google.cloud.documentai.v1beta3.CommonOperationMetadata"
|
74
100
|
end
|
75
101
|
add_enum "google.cloud.documentai.v1beta3.ReviewDocumentOperationMetadata.State" do
|
76
102
|
value :STATE_UNSPECIFIED, 0
|
@@ -80,6 +106,20 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
|
|
80
106
|
value :FAILED, 4
|
81
107
|
value :CANCELLED, 5
|
82
108
|
end
|
109
|
+
add_message "google.cloud.documentai.v1beta3.CommonOperationMetadata" do
|
110
|
+
optional :state, :enum, 1, "google.cloud.documentai.v1beta3.CommonOperationMetadata.State"
|
111
|
+
optional :state_message, :string, 2
|
112
|
+
optional :create_time, :message, 3, "google.protobuf.Timestamp"
|
113
|
+
optional :update_time, :message, 4, "google.protobuf.Timestamp"
|
114
|
+
end
|
115
|
+
add_enum "google.cloud.documentai.v1beta3.CommonOperationMetadata.State" do
|
116
|
+
value :STATE_UNSPECIFIED, 0
|
117
|
+
value :RUNNING, 1
|
118
|
+
value :CANCELLING, 2
|
119
|
+
value :SUCCEEDED, 3
|
120
|
+
value :FAILED, 4
|
121
|
+
value :CANCELLED, 5
|
122
|
+
end
|
83
123
|
end
|
84
124
|
end
|
85
125
|
|
@@ -88,6 +128,8 @@ module Google
|
|
88
128
|
module DocumentAI
|
89
129
|
module V1beta3
|
90
130
|
ProcessRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.ProcessRequest").msgclass
|
131
|
+
HumanReviewStatus = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.HumanReviewStatus").msgclass
|
132
|
+
HumanReviewStatus::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.HumanReviewStatus.State").enummodule
|
91
133
|
ProcessResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.ProcessResponse").msgclass
|
92
134
|
BatchProcessRequest = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.BatchProcessRequest").msgclass
|
93
135
|
BatchProcessRequest::BatchInputConfig = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.BatchProcessRequest.BatchInputConfig").msgclass
|
@@ -100,6 +142,8 @@ module Google
|
|
100
142
|
ReviewDocumentResponse = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.ReviewDocumentResponse").msgclass
|
101
143
|
ReviewDocumentOperationMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.ReviewDocumentOperationMetadata").msgclass
|
102
144
|
ReviewDocumentOperationMetadata::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.ReviewDocumentOperationMetadata.State").enummodule
|
145
|
+
CommonOperationMetadata = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.CommonOperationMetadata").msgclass
|
146
|
+
CommonOperationMetadata::State = ::Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.documentai.v1beta3.CommonOperationMetadata.State").enummodule
|
103
147
|
end
|
104
148
|
end
|
105
149
|
end
|
@@ -0,0 +1,100 @@
|
|
1
|
+
# frozen_string_literal: true
|
2
|
+
|
3
|
+
# Copyright 2021 Google LLC
|
4
|
+
#
|
5
|
+
# Licensed under the Apache License, Version 2.0 (the "License");
|
6
|
+
# you may not use this file except in compliance with the License.
|
7
|
+
# You may obtain a copy of the License at
|
8
|
+
#
|
9
|
+
# https://www.apache.org/licenses/LICENSE-2.0
|
10
|
+
#
|
11
|
+
# Unless required by applicable law or agreed to in writing, software
|
12
|
+
# distributed under the License is distributed on an "AS IS" BASIS,
|
13
|
+
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
14
|
+
# See the License for the specific language governing permissions and
|
15
|
+
# limitations under the License.
|
16
|
+
|
17
|
+
# Auto-generated by gapic-generator-ruby. DO NOT EDIT!
|
18
|
+
|
19
|
+
|
20
|
+
module Google
|
21
|
+
module Cloud
|
22
|
+
module DocumentAI
|
23
|
+
module V1beta3
|
24
|
+
# Payload message of raw document content (bytes).
|
25
|
+
# @!attribute [rw] content
|
26
|
+
# @return [::String]
|
27
|
+
# Inline document content.
|
28
|
+
# @!attribute [rw] mime_type
|
29
|
+
# @return [::String]
|
30
|
+
# An IANA MIME type (RFC6838) indicating the nature and format of the
|
31
|
+
# [content].
|
32
|
+
class RawDocument
|
33
|
+
include ::Google::Protobuf::MessageExts
|
34
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
35
|
+
end
|
36
|
+
|
37
|
+
# Specifies a document stored on Cloud Storage.
|
38
|
+
# @!attribute [rw] gcs_uri
|
39
|
+
# @return [::String]
|
40
|
+
# The Cloud Storage object uri.
|
41
|
+
# @!attribute [rw] mime_type
|
42
|
+
# @return [::String]
|
43
|
+
# An IANA MIME type (RFC6838) of the content.
|
44
|
+
class GcsDocument
|
45
|
+
include ::Google::Protobuf::MessageExts
|
46
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
47
|
+
end
|
48
|
+
|
49
|
+
# Specifies a set of documents on Cloud Storage.
|
50
|
+
# @!attribute [rw] documents
|
51
|
+
# @return [::Array<::Google::Cloud::DocumentAI::V1beta3::GcsDocument>]
|
52
|
+
# The list of documents.
|
53
|
+
class GcsDocuments
|
54
|
+
include ::Google::Protobuf::MessageExts
|
55
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
56
|
+
end
|
57
|
+
|
58
|
+
# Specifies all documents on Cloud Storage with a common prefix.
|
59
|
+
# @!attribute [rw] gcs_uri_prefix
|
60
|
+
# @return [::String]
|
61
|
+
# The URI prefix.
|
62
|
+
class GcsPrefix
|
63
|
+
include ::Google::Protobuf::MessageExts
|
64
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
65
|
+
end
|
66
|
+
|
67
|
+
# The common config to specify a set of documents used as input.
|
68
|
+
# @!attribute [rw] gcs_prefix
|
69
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::GcsPrefix]
|
70
|
+
# The set of documents that match the specified Cloud Storage [gcs_prefix].
|
71
|
+
# @!attribute [rw] gcs_documents
|
72
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::GcsDocuments]
|
73
|
+
# The set of documents individually specified on Cloud Storage.
|
74
|
+
class BatchDocumentsInputConfig
|
75
|
+
include ::Google::Protobuf::MessageExts
|
76
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
77
|
+
end
|
78
|
+
|
79
|
+
# Config that controls the output of documents. All documents will be written
|
80
|
+
# as a JSON file.
|
81
|
+
# @!attribute [rw] gcs_output_config
|
82
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::DocumentOutputConfig::GcsOutputConfig]
|
83
|
+
# Output config to write the results to Cloud Storage.
|
84
|
+
class DocumentOutputConfig
|
85
|
+
include ::Google::Protobuf::MessageExts
|
86
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
87
|
+
|
88
|
+
# The configuration used when outputting documents.
|
89
|
+
# @!attribute [rw] gcs_uri
|
90
|
+
# @return [::String]
|
91
|
+
# The Cloud Storage uri (a directory) of the output.
|
92
|
+
class GcsOutputConfig
|
93
|
+
include ::Google::Protobuf::MessageExts
|
94
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
95
|
+
end
|
96
|
+
end
|
97
|
+
end
|
98
|
+
end
|
99
|
+
end
|
100
|
+
end
|
@@ -22,6 +22,12 @@ module Google
|
|
22
22
|
module DocumentAI
|
23
23
|
module V1beta3
|
24
24
|
# Request message for the process document method.
|
25
|
+
# @!attribute [rw] inline_document
|
26
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::Document]
|
27
|
+
# An inline document proto.
|
28
|
+
# @!attribute [rw] raw_document
|
29
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::RawDocument]
|
30
|
+
# A raw document content (bytes).
|
25
31
|
# @!attribute [rw] name
|
26
32
|
# @return [::String]
|
27
33
|
# Required. The processor resource name.
|
@@ -37,6 +43,45 @@ module Google
|
|
37
43
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
38
44
|
end
|
39
45
|
|
46
|
+
# The status of human review on a processed document.
|
47
|
+
# @!attribute [rw] state
|
48
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::HumanReviewStatus::State]
|
49
|
+
# The state of human review on the processing request.
|
50
|
+
# @!attribute [rw] state_message
|
51
|
+
# @return [::String]
|
52
|
+
# A message providing more details about the human review state.
|
53
|
+
# @!attribute [rw] human_review_operation
|
54
|
+
# @return [::String]
|
55
|
+
# The name of the operation triggered by the processed document. This field
|
56
|
+
# is populated only when the [state] is [HUMAN_REVIEW_IN_PROGRESS]. It has
|
57
|
+
# the same response type and metadata as the long running operation returned
|
58
|
+
# by [ReviewDocument] method.
|
59
|
+
class HumanReviewStatus
|
60
|
+
include ::Google::Protobuf::MessageExts
|
61
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
62
|
+
|
63
|
+
# The final state of human review on a processed document.
|
64
|
+
module State
|
65
|
+
# Human review state is unspecified. Most likely due to an internal error.
|
66
|
+
STATE_UNSPECIFIED = 0
|
67
|
+
|
68
|
+
# Human review is skipped for the document. This can happen because human
|
69
|
+
# review is not enabled on the processor or the processing request has
|
70
|
+
# been set to skip this document.
|
71
|
+
SKIPPED = 1
|
72
|
+
|
73
|
+
# Human review validation is triggered and passed, so no review is needed.
|
74
|
+
VALIDATION_PASSED = 2
|
75
|
+
|
76
|
+
# Human review validation is triggered and the document is under review.
|
77
|
+
IN_PROGRESS = 3
|
78
|
+
|
79
|
+
# Some error happened during triggering human review, see the
|
80
|
+
# [state_message] for details.
|
81
|
+
ERROR = 4
|
82
|
+
end
|
83
|
+
end
|
84
|
+
|
40
85
|
# Response message for the process document method.
|
41
86
|
# @!attribute [rw] document
|
42
87
|
# @return [::Google::Cloud::DocumentAI::V1beta3::Document]
|
@@ -48,6 +93,9 @@ module Google
|
|
48
93
|
# review process is not triggered, this field will be empty. It has the same
|
49
94
|
# response type and metadata as the long running operation returned by
|
50
95
|
# ReviewDocument method.
|
96
|
+
# @!attribute [rw] human_review_status
|
97
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::HumanReviewStatus]
|
98
|
+
# The status of human review on the processed document.
|
51
99
|
class ProcessResponse
|
52
100
|
include ::Google::Protobuf::MessageExts
|
53
101
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -63,6 +111,16 @@ module Google
|
|
63
111
|
# @!attribute [rw] output_config
|
64
112
|
# @return [::Google::Cloud::DocumentAI::V1beta3::BatchProcessRequest::BatchOutputConfig]
|
65
113
|
# The overall output config for batch process.
|
114
|
+
# @!attribute [rw] input_documents
|
115
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::BatchDocumentsInputConfig]
|
116
|
+
# The input documents for batch process.
|
117
|
+
# @!attribute [rw] document_output_config
|
118
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::DocumentOutputConfig]
|
119
|
+
# The overall output config for batch process.
|
120
|
+
# @!attribute [rw] skip_human_review
|
121
|
+
# @return [::Boolean]
|
122
|
+
# Whether Human Review feature should be skipped for this request. Default to
|
123
|
+
# false.
|
66
124
|
class BatchProcessRequest
|
67
125
|
include ::Google::Protobuf::MessageExts
|
68
126
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -138,6 +196,9 @@ module Google
|
|
138
196
|
# human review process is not triggered, this field will be empty. It has
|
139
197
|
# the same response type and metadata as the long running operation
|
140
198
|
# returned by ReviewDocument method.
|
199
|
+
# @!attribute [rw] human_review_status
|
200
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::HumanReviewStatus]
|
201
|
+
# The status of human review on the processed document.
|
141
202
|
class IndividualProcessStatus
|
142
203
|
include ::Google::Protobuf::MessageExts
|
143
204
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -169,6 +230,9 @@ module Google
|
|
169
230
|
end
|
170
231
|
|
171
232
|
# Request message for review document method.
|
233
|
+
# @!attribute [rw] inline_document
|
234
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::Document]
|
235
|
+
# An inline document proto.
|
172
236
|
# @!attribute [rw] human_review_config
|
173
237
|
# @return [::String]
|
174
238
|
# Required. The resource name of the HumanReviewConfig that the document will be
|
@@ -204,6 +268,9 @@ module Google
|
|
204
268
|
# @!attribute [rw] update_time
|
205
269
|
# @return [::Google::Protobuf::Timestamp]
|
206
270
|
# The last update time of the operation.
|
271
|
+
# @!attribute [rw] common_metadata
|
272
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::CommonOperationMetadata]
|
273
|
+
# The basic metadata of the long running operation.
|
207
274
|
class ReviewDocumentOperationMetadata
|
208
275
|
include ::Google::Protobuf::MessageExts
|
209
276
|
extend ::Google::Protobuf::MessageExts::ClassMethods
|
@@ -229,6 +296,45 @@ module Google
|
|
229
296
|
CANCELLED = 5
|
230
297
|
end
|
231
298
|
end
|
299
|
+
|
300
|
+
# The common metadata for long running operations.
|
301
|
+
# @!attribute [rw] state
|
302
|
+
# @return [::Google::Cloud::DocumentAI::V1beta3::CommonOperationMetadata::State]
|
303
|
+
# The state of the operation.
|
304
|
+
# @!attribute [rw] state_message
|
305
|
+
# @return [::String]
|
306
|
+
# A message providing more details about the current state of processing.
|
307
|
+
# @!attribute [rw] create_time
|
308
|
+
# @return [::Google::Protobuf::Timestamp]
|
309
|
+
# The creation time of the operation.
|
310
|
+
# @!attribute [rw] update_time
|
311
|
+
# @return [::Google::Protobuf::Timestamp]
|
312
|
+
# The last update time of the operation.
|
313
|
+
class CommonOperationMetadata
|
314
|
+
include ::Google::Protobuf::MessageExts
|
315
|
+
extend ::Google::Protobuf::MessageExts::ClassMethods
|
316
|
+
|
317
|
+
# State of the longrunning operation.
|
318
|
+
module State
|
319
|
+
# Unspecified state.
|
320
|
+
STATE_UNSPECIFIED = 0
|
321
|
+
|
322
|
+
# Operation is still running.
|
323
|
+
RUNNING = 1
|
324
|
+
|
325
|
+
# Operation is being cancelled.
|
326
|
+
CANCELLING = 2
|
327
|
+
|
328
|
+
# Operation succeeded.
|
329
|
+
SUCCEEDED = 3
|
330
|
+
|
331
|
+
# Operation failed.
|
332
|
+
FAILED = 4
|
333
|
+
|
334
|
+
# Operation is cancelled.
|
335
|
+
CANCELLED = 5
|
336
|
+
end
|
337
|
+
end
|
232
338
|
end
|
233
339
|
end
|
234
340
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: google-cloud-document_ai-v1beta3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 0.3.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: 2021-02-
|
11
|
+
date: 2021-02-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: gapic-common
|
@@ -172,6 +172,7 @@ files:
|
|
172
172
|
- lib/google/cloud/document_ai/v1beta3/document_processor_service/operations.rb
|
173
173
|
- lib/google/cloud/document_ai/v1beta3/document_processor_service/paths.rb
|
174
174
|
- lib/google/cloud/document_ai/v1beta3/version.rb
|
175
|
+
- lib/google/cloud/documentai/v1beta3/document_io_pb.rb
|
175
176
|
- lib/google/cloud/documentai/v1beta3/document_pb.rb
|
176
177
|
- lib/google/cloud/documentai/v1beta3/document_processor_service_pb.rb
|
177
178
|
- lib/google/cloud/documentai/v1beta3/document_processor_service_services_pb.rb
|
@@ -180,6 +181,7 @@ files:
|
|
180
181
|
- proto_docs/google/api/field_behavior.rb
|
181
182
|
- proto_docs/google/api/resource.rb
|
182
183
|
- proto_docs/google/cloud/documentai/v1beta3/document.rb
|
184
|
+
- proto_docs/google/cloud/documentai/v1beta3/document_io.rb
|
183
185
|
- proto_docs/google/cloud/documentai/v1beta3/document_processor_service.rb
|
184
186
|
- proto_docs/google/cloud/documentai/v1beta3/geometry.rb
|
185
187
|
- proto_docs/google/longrunning/operations.rb
|