google-cloud-automl 0.1.0 → 0.2.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (29) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +3 -3
  3. data/lib/google/cloud/automl.rb +2 -2
  4. data/lib/google/cloud/automl/v1beta1.rb +2 -2
  5. data/lib/google/cloud/automl/v1beta1/automl_client.rb +4 -20
  6. data/lib/google/cloud/automl/v1beta1/classification_pb.rb +1 -0
  7. data/lib/google/cloud/automl/v1beta1/data_items_pb.rb +40 -1
  8. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/classification.rb +9 -0
  9. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/column_spec.rb +1 -6
  10. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/data_items.rb +125 -9
  11. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/data_types.rb +0 -8
  12. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/detection.rb +4 -8
  13. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/image.rb +10 -3
  14. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/io.rb +257 -125
  15. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/model.rb +4 -8
  16. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/model_evaluation.rb +5 -9
  17. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/prediction_service.rb +56 -6
  18. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/service.rb +3 -18
  19. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/table_spec.rb +4 -0
  20. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/tables.rb +26 -30
  21. data/lib/google/cloud/automl/v1beta1/doc/google/cloud/automl/v1beta1/text.rb +2 -4
  22. data/lib/google/cloud/automl/v1beta1/prediction_service_client.rb +40 -7
  23. data/lib/google/cloud/automl/v1beta1/prediction_service_pb.rb +3 -1
  24. data/lib/google/cloud/automl/v1beta1/prediction_service_services_pb.rb +10 -5
  25. data/lib/google/cloud/automl/v1beta1/service_services_pb.rb +1 -2
  26. data/lib/google/cloud/automl/v1beta1/table_spec_pb.rb +1 -0
  27. data/lib/google/cloud/automl/v1beta1/tables_pb.rb +0 -4
  28. data/lib/google/cloud/automl/version.rb +1 -1
  29. metadata +3 -3
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 44613cf4959c68f127ddd4c930407cb1bfea6dd682403f5ff23cf0f649c6ab03
4
- data.tar.gz: 2fa3e0fd92a7e467c169d4564efebeb7c2c2264cfbf89f4a8e79869a9f590e33
3
+ metadata.gz: 5a884b6557b601de476761217ec7144f1a61fa1dc293f5cfe48e9d7cddfb9d1e
4
+ data.tar.gz: b8e9291961dadca99ce64ca4283d93748f6483908c630381f8f973fdedc19476
5
5
  SHA512:
6
- metadata.gz: fb7e7ce17d8846715557f58f9fb4338317b19eb80914e54c40c4351aeccde572091e7de7c4e0d227c5779944f4c9b61cc41bc4a6ef34f44ee26950fedc4ec409
7
- data.tar.gz: ebe48cbdce7ecf87a5a7e8bcdcc8e161b12204aec1a334e1a66ec8ffc7c63f0937a36f4594ca9f4ba273b7cf7bbfec8b813d3075eb7461d1c5db9fca73a4e092
6
+ metadata.gz: 563d9105be5fe9c0884267090cfd4c7fafbbf17de4587b586268fc9ab5d0dcbcb7fddcbde93ce196be4a86f448d6c4d96ff439d4f90d6fcf38648a30efa1719b
7
+ data.tar.gz: 60f027e0ab389a58f6ffe09b7da80fc3f075665d0ff7f76fb5c770340f83132e178d7a0a5ea3eff36126d5584587a0f133e7e3de578a2dc4618efcb99c2c5cb4
data/README.md CHANGED
@@ -13,7 +13,7 @@ steps:
13
13
  1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project)
14
14
  2. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project)
15
15
  3. [Enable the Cloud AutoML API.](https://console.cloud.google.com/apis/library/automl.googleapis.com)
16
- 4. [Setup Authentication.](https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud/master/guides/authentication)
16
+ 4. [Setup Authentication.](https://googleapis.dev/ruby/google-cloud-automl/latest/file.AUTHENTICATION.html)
17
17
 
18
18
  ### Installation
19
19
  ```
@@ -28,14 +28,14 @@ $ gem install google-cloud-automl
28
28
  - View this [repository's main README](https://github.com/googleapis/google-cloud-ruby/blob/master/README.md)
29
29
  to see the full list of Cloud APIs that we cover.
30
30
 
31
- [Client Library Documentation]: https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud-automl/latest/google/cloud/automl/v1beta1
31
+ [Client Library Documentation]: https://googleapis.dev/ruby/google-cloud-automl/latest
32
32
  [Product Documentation]: https://cloud.google.com/automl
33
33
 
34
34
  ## Enabling Logging
35
35
 
36
36
  To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
37
37
  The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/stdlib-2.5.0/libdoc/logger/rdoc/Logger.html) as shown below,
38
- or a [`Google::Cloud::Logging::Logger`](https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud-logging/latest/google/cloud/logging/logger)
38
+ or a [`Google::Cloud::Logging::Logger`](https://googleapis.dev/ruby/google-cloud-logging/latest)
39
39
  that will write logs to [Stackdriver Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
40
40
  and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
41
41
 
@@ -35,7 +35,7 @@ module Google
35
35
  # 1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project)
36
36
  # 2. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project)
37
37
  # 3. [Enable the Cloud AutoML API.](https://console.cloud.google.com/apis/library/automl.googleapis.com)
38
- # 4. [Setup Authentication.](https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud/master/guides/authentication)
38
+ # 4. [Setup Authentication.](https://googleapis.dev/ruby/google-cloud-automl/latest/file.AUTHENTICATION.html)
39
39
  #
40
40
  # ### Installation
41
41
  # ```
@@ -54,7 +54,7 @@ module Google
54
54
  #
55
55
  # To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
56
56
  # The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/stdlib-2.5.0/libdoc/logger/rdoc/Logger.html) as shown below,
57
- # or a [`Google::Cloud::Logging::Logger`](https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud-logging/latest/google/cloud/logging/logger)
57
+ # or a [`Google::Cloud::Logging::Logger`](https://googleapis.dev/ruby/google-cloud-logging/latest)
58
58
  # that will write logs to [Stackdriver Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
59
59
  # and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
60
60
  #
@@ -38,7 +38,7 @@ module Google
38
38
  # 1. [Select or create a Cloud Platform project.](https://console.cloud.google.com/project)
39
39
  # 2. [Enable billing for your project.](https://cloud.google.com/billing/docs/how-to/modify-project#enable_billing_for_a_project)
40
40
  # 3. [Enable the Cloud AutoML API.](https://console.cloud.google.com/apis/library/automl.googleapis.com)
41
- # 4. [Setup Authentication.](https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud/master/guides/authentication)
41
+ # 4. [Setup Authentication.](https://googleapis.dev/ruby/google-cloud-automl/latest/file.AUTHENTICATION.html)
42
42
  #
43
43
  # ### Installation
44
44
  # ```
@@ -57,7 +57,7 @@ module Google
57
57
  #
58
58
  # To enable logging for this library, set the logger for the underlying [gRPC](https://github.com/grpc/grpc/tree/master/src/ruby) library.
59
59
  # The logger that you set may be a Ruby stdlib [`Logger`](https://ruby-doc.org/stdlib-2.5.0/libdoc/logger/rdoc/Logger.html) as shown below,
60
- # or a [`Google::Cloud::Logging::Logger`](https://googleapis.github.io/google-cloud-ruby/#/docs/google-cloud-logging/latest/google/cloud/logging/logger)
60
+ # or a [`Google::Cloud::Logging::Logger`](https://googleapis.dev/ruby/google-cloud-logging/latest)
61
61
  # that will write logs to [Stackdriver Logging](https://cloud.google.com/logging/). See [grpc/logconfig.rb](https://github.com/grpc/grpc/blob/master/src/ruby/lib/grpc/logconfig.rb)
62
62
  # and the gRPC [spec_helper.rb](https://github.com/grpc/grpc/blob/master/src/ruby/spec/spec_helper.rb) for additional information.
63
63
  #
@@ -607,12 +607,7 @@ module Google
607
607
  # A hash of the same form as `Google::Cloud::AutoML::V1beta1::Dataset`
608
608
  # can also be provided.
609
609
  # @param update_mask [Google::Protobuf::FieldMask | Hash]
610
- # The update mask applies to the resource. For the `FieldMask` definition,
611
- # see
612
- #
613
- # https:
614
- # //developers.google.com/protocol-buffers
615
- # // /docs/reference/google.protobuf#fieldmask
610
+ # The update mask applies to the resource.
616
611
  # A hash of the same form as `Google::Protobuf::FieldMask`
617
612
  # can also be provided.
618
613
  # @param options [Google::Gax::CallOptions]
@@ -1193,8 +1188,7 @@ module Google
1193
1188
  # {Google::Cloud::AutoML::V1beta1::ImageObjectDetectionModelDeploymentMetadata#node_number node_number})
1194
1189
  # will reset the deployment state without pausing the model's availability.
1195
1190
  #
1196
- # Only applicable for Text Classification, Image Object Detection and Tables;
1197
- # all other domains manage deployment automatically.
1191
+ # Only applicable for Text Classification, Image Object Detection and Tables; all other domains manage deployment automatically.
1198
1192
  #
1199
1193
  # Returns an empty response in the
1200
1194
  # {Google::Longrunning::Operation#response response} field when it completes.
@@ -1725,12 +1719,7 @@ module Google
1725
1719
  # A hash of the same form as `Google::Cloud::AutoML::V1beta1::TableSpec`
1726
1720
  # can also be provided.
1727
1721
  # @param update_mask [Google::Protobuf::FieldMask | Hash]
1728
- # The update mask applies to the resource. For the `FieldMask` definition,
1729
- # see
1730
- #
1731
- # https:
1732
- # //developers.google.com/protocol-buffers
1733
- # // /docs/reference/google.protobuf#fieldmask
1722
+ # The update mask applies to the resource.
1734
1723
  # A hash of the same form as `Google::Protobuf::FieldMask`
1735
1724
  # can also be provided.
1736
1725
  # @param options [Google::Gax::CallOptions]
@@ -1870,12 +1859,7 @@ module Google
1870
1859
  # A hash of the same form as `Google::Cloud::AutoML::V1beta1::ColumnSpec`
1871
1860
  # can also be provided.
1872
1861
  # @param update_mask [Google::Protobuf::FieldMask | Hash]
1873
- # The update mask applies to the resource. For the `FieldMask` definition,
1874
- # see
1875
- #
1876
- # https:
1877
- # //developers.google.com/protocol-buffers
1878
- # // /docs/reference/google.protobuf#fieldmask
1862
+ # The update mask applies to the resource.
1879
1863
  # A hash of the same form as `Google::Protobuf::FieldMask`
1880
1864
  # can also be provided.
1881
1865
  # @param options [Google::Gax::CallOptions]
@@ -42,6 +42,7 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
42
42
  end
43
43
  add_message "google.cloud.automl.v1beta1.ClassificationEvaluationMetrics.ConfusionMatrix" do
44
44
  repeated :annotation_spec_id, :string, 1
45
+ repeated :display_name, :string, 3
45
46
  repeated :row, :message, 2, "google.cloud.automl.v1beta1.ClassificationEvaluationMetrics.ConfusionMatrix.Row"
46
47
  end
47
48
  add_message "google.cloud.automl.v1beta1.ClassificationEvaluationMetrics.ConfusionMatrix.Row" do
@@ -4,11 +4,13 @@
4
4
 
5
5
  require 'google/protobuf'
6
6
 
7
+ require 'google/api/annotations_pb'
8
+ require 'google/cloud/automl/v1beta1/geometry_pb'
7
9
  require 'google/cloud/automl/v1beta1/io_pb'
10
+ require 'google/cloud/automl/v1beta1/text_segment_pb'
8
11
  require 'google/protobuf/any_pb'
9
12
  require 'google/protobuf/duration_pb'
10
13
  require 'google/protobuf/struct_pb'
11
- require 'google/api/annotations_pb'
12
14
  Google::Protobuf::DescriptorPool.generated_pool.build do
13
15
  add_message "google.cloud.automl.v1beta1.Image" do
14
16
  optional :thumbnail_uri, :string, 4
@@ -22,8 +24,41 @@ Google::Protobuf::DescriptorPool.generated_pool.build do
22
24
  optional :mime_type, :string, 2
23
25
  optional :content_uri, :string, 4
24
26
  end
27
+ add_message "google.cloud.automl.v1beta1.DocumentDimensions" do
28
+ optional :unit, :enum, 1, "google.cloud.automl.v1beta1.DocumentDimensions.DocumentDimensionUnit"
29
+ optional :width, :float, 2
30
+ optional :height, :float, 3
31
+ end
32
+ add_enum "google.cloud.automl.v1beta1.DocumentDimensions.DocumentDimensionUnit" do
33
+ value :DOCUMENT_DIMENSION_UNIT_UNSPECIFIED, 0
34
+ value :INCH, 1
35
+ value :CENTIMETER, 2
36
+ value :POINT, 3
37
+ end
25
38
  add_message "google.cloud.automl.v1beta1.Document" do
26
39
  optional :input_config, :message, 1, "google.cloud.automl.v1beta1.DocumentInputConfig"
40
+ optional :document_text, :message, 2, "google.cloud.automl.v1beta1.TextSnippet"
41
+ repeated :layout, :message, 3, "google.cloud.automl.v1beta1.Document.Layout"
42
+ optional :document_dimensions, :message, 4, "google.cloud.automl.v1beta1.DocumentDimensions"
43
+ optional :page_count, :int32, 5
44
+ end
45
+ add_message "google.cloud.automl.v1beta1.Document.Layout" do
46
+ optional :text_segment, :message, 1, "google.cloud.automl.v1beta1.TextSegment"
47
+ optional :page_number, :int32, 2
48
+ optional :bounding_poly, :message, 3, "google.cloud.automl.v1beta1.BoundingPoly"
49
+ optional :text_segment_type, :enum, 4, "google.cloud.automl.v1beta1.Document.Layout.TextSegmentType"
50
+ end
51
+ add_enum "google.cloud.automl.v1beta1.Document.Layout.TextSegmentType" do
52
+ value :TEXT_SEGMENT_TYPE_UNSPECIFIED, 0
53
+ value :TOKEN, 1
54
+ value :PARAGRAPH, 2
55
+ value :FORM_FIELD, 3
56
+ value :FORM_FIELD_NAME, 4
57
+ value :FORM_FIELD_CONTENTS, 5
58
+ value :TABLE, 6
59
+ value :TABLE_HEADER, 7
60
+ value :TABLE_ROW, 8
61
+ value :TABLE_CELL, 9
27
62
  end
28
63
  add_message "google.cloud.automl.v1beta1.Row" do
29
64
  repeated :column_spec_ids, :string, 2
@@ -42,7 +77,11 @@ end
42
77
  module Google::Cloud::AutoML::V1beta1
43
78
  Image = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.Image").msgclass
44
79
  TextSnippet = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.TextSnippet").msgclass
80
+ DocumentDimensions = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.DocumentDimensions").msgclass
81
+ DocumentDimensions::DocumentDimensionUnit = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.DocumentDimensions.DocumentDimensionUnit").enummodule
45
82
  Document = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.Document").msgclass
83
+ Document::Layout = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.Document.Layout").msgclass
84
+ Document::Layout::TextSegmentType = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.Document.Layout.TextSegmentType").enummodule
46
85
  Row = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.Row").msgclass
47
86
  ExamplePayload = Google::Protobuf::DescriptorPool.generated_pool.lookup("google.cloud.automl.v1beta1.ExamplePayload").msgclass
48
87
  end
@@ -167,6 +167,15 @@ module Google
167
167
  #
168
168
  # {Google::Cloud::AutoML::V1beta1::TablesModelMetadata#prediction_type prediction_type}
169
169
  # only list of {Annotation_spec_display_name-s} is populated.
170
+ # @!attribute [rw] display_name
171
+ # @return [Array<String>]
172
+ # Output only. Display name of the annotation specs used in the confusion
173
+ # matrix, as they were at the moment of the evaluation. For Tables
174
+ # CLASSIFICATION
175
+ #
176
+ # {Google::Cloud::AutoML::V1beta1::TablesModelMetadata#prediction_type prediction_type-s},
177
+ # distinct values of the target column at the moment of the model
178
+ # evaluation are populated here.
170
179
  # @!attribute [rw] row
171
180
  # @return [Array<Google::Cloud::AutoML::V1beta1::ClassificationEvaluationMetrics::ConfusionMatrix::Row>]
172
181
  # Output only. Rows in the confusion matrix. The number of rows is equal to
@@ -44,12 +44,7 @@ module Google
44
44
  # for the timestamp at which these stats were last updated.
45
45
  # @!attribute [rw] top_correlated_columns
46
46
  # @return [Array<Google::Cloud::AutoML::V1beta1::ColumnSpec::CorrelatedColumn>]
47
- # Output only. Top 10 most correlated with this column columns of the table,
48
- # ordered by
49
- # {Google::Cloud::AutoML::V1beta1::CorrelationStats#cramers_v cramers_v} metric.
50
- # This field may be stale, see the ancestor's
51
- # Dataset.tables_dataset_metadata.stats_update_time field
52
- # for the timestamp at which these stats were last updated.
47
+ # Deprecated.
53
48
  # @!attribute [rw] etag
54
49
  # @return [String]
55
50
  # Used to perform consistent read-modify-write updates. If not set, a blind
@@ -39,26 +39,142 @@ module Google
39
39
  # characters long.
40
40
  # @!attribute [rw] mime_type
41
41
  # @return [String]
42
- # The format of the source text. Currently the only two allowed values are
43
- # "text/html" and "text/plain". If left blank the format is automatically
44
- # determined from the type of the uploaded content.
42
+ # Optional. The format of
43
+ # {Google::Cloud::AutoML::V1beta1::TextSnippet#content content}. Currently the
44
+ # only two allowed values are "text/html" and "text/plain". If left blank,
45
+ # the format is automatically determined from the type of the uploaded
46
+ # {Google::Cloud::AutoML::V1beta1::TextSnippet#content content}.
45
47
  # @!attribute [rw] content_uri
46
48
  # @return [String]
47
49
  # Output only. HTTP URI where you can download the content.
48
50
  class TextSnippet; end
49
51
 
52
+ # Message that describes dimension of a document.
53
+ # @!attribute [rw] unit
54
+ # @return [Google::Cloud::AutoML::V1beta1::DocumentDimensions::DocumentDimensionUnit]
55
+ # Unit of the dimension.
56
+ # @!attribute [rw] width
57
+ # @return [Float]
58
+ # Width value of the document, works together with the unit.
59
+ # @!attribute [rw] height
60
+ # @return [Float]
61
+ # Height value of the document, works together with the unit.
62
+ class DocumentDimensions
63
+ # Unit of the document dimension.
64
+ module DocumentDimensionUnit
65
+ # Should not be used.
66
+ DOCUMENT_DIMENSION_UNIT_UNSPECIFIED = 0
67
+
68
+ # Document dimension is measured in inches.
69
+ INCH = 1
70
+
71
+ # Document dimension is measured in centimeters.
72
+ CENTIMETER = 2
73
+
74
+ # Document dimension is measured in points. 72 points = 1 inch.
75
+ POINT = 3
76
+ end
77
+ end
78
+
50
79
  # A structured text document e.g. a PDF.
51
80
  # @!attribute [rw] input_config
52
81
  # @return [Google::Cloud::AutoML::V1beta1::DocumentInputConfig]
53
82
  # An input config specifying the content of the document.
54
- class Document; end
83
+ # @!attribute [rw] document_text
84
+ # @return [Google::Cloud::AutoML::V1beta1::TextSnippet]
85
+ # The plain text version of this document.
86
+ # @!attribute [rw] layout
87
+ # @return [Array<Google::Cloud::AutoML::V1beta1::Document::Layout>]
88
+ # Describes the layout of the document.
89
+ # Sorted by \\{Page_number}.
90
+ # @!attribute [rw] document_dimensions
91
+ # @return [Google::Cloud::AutoML::V1beta1::DocumentDimensions]
92
+ # The dimensions of the page in the document.
93
+ # @!attribute [rw] page_count
94
+ # @return [Integer]
95
+ # Number of pages in the document.
96
+ class Document
97
+ # Describes the layout information of a
98
+ # {Google::Cloud::AutoML::V1beta1::Document::Layout#text_segment text_segment} in
99
+ # the document.
100
+ # @!attribute [rw] text_segment
101
+ # @return [Google::Cloud::AutoML::V1beta1::TextSegment]
102
+ # Text Segment that represents a segment in
103
+ # {Google::Cloud::AutoML::V1beta1::Document#document_text document_text}.
104
+ # @!attribute [rw] page_number
105
+ # @return [Integer]
106
+ # Page number of the
107
+ # {Google::Cloud::AutoML::V1beta1::Document::Layout#text_segment text_segment}
108
+ # in the original document, starts from 1.
109
+ # @!attribute [rw] bounding_poly
110
+ # @return [Google::Cloud::AutoML::V1beta1::BoundingPoly]
111
+ # The position of the
112
+ # {Google::Cloud::AutoML::V1beta1::Document::Layout#text_segment text_segment}
113
+ # in the page. Contains exactly 4
114
+ #
115
+ # {Google::Cloud::AutoML::V1beta1::BoundingPoly#normalized_vertices normalized_vertices}
116
+ # and they are connected by edges in the order provided, which will
117
+ # represent a rectangle parallel to the frame. The
118
+ # {Google::Cloud::AutoML::V1beta1::NormalizedVertex NormalizedVertex-s} are
119
+ # relative to the page.
120
+ # Coordinates are based on top-left as point (0,0).
121
+ # @!attribute [rw] text_segment_type
122
+ # @return [Google::Cloud::AutoML::V1beta1::Document::Layout::TextSegmentType]
123
+ # The type of the
124
+ # {Google::Cloud::AutoML::V1beta1::Document::Layout#text_segment text_segment}
125
+ # in document.
126
+ class Layout
127
+ # The type of TextSegment in the context of the original document.
128
+ module TextSegmentType
129
+ # Should not be used.
130
+ TEXT_SEGMENT_TYPE_UNSPECIFIED = 0
131
+
132
+ # The text segment is a token. e.g. word.
133
+ TOKEN = 1
134
+
135
+ # The text segment is a paragraph.
136
+ PARAGRAPH = 2
137
+
138
+ # The text segment is a form field.
139
+ FORM_FIELD = 3
140
+
141
+ # The text segment is the name part of a form field. It will be treated
142
+ # as child of another FORM_FIELD TextSegment if its span is subspan of
143
+ # another TextSegment with type FORM_FIELD.
144
+ FORM_FIELD_NAME = 4
145
+
146
+ # The text segment is the text content part of a form field. It will be
147
+ # treated as child of another FORM_FIELD TextSegment if its span is
148
+ # subspan of another TextSegment with type FORM_FIELD.
149
+ FORM_FIELD_CONTENTS = 5
150
+
151
+ # The text segment is a whole table, including headers, and all rows.
152
+ TABLE = 6
153
+
154
+ # The text segment is a table's headers. It will be treated as child of
155
+ # another TABLE TextSegment if its span is subspan of another TextSegment
156
+ # with type TABLE.
157
+ TABLE_HEADER = 7
158
+
159
+ # The text segment is a row in table. It will be treated as child of
160
+ # another TABLE TextSegment if its span is subspan of another TextSegment
161
+ # with type TABLE.
162
+ TABLE_ROW = 8
163
+
164
+ # The text segment is a cell in table. It will be treated as child of
165
+ # another TABLE_ROW TextSegment if its span is subspan of another
166
+ # TextSegment with type TABLE_ROW.
167
+ TABLE_CELL = 9
168
+ end
169
+ end
170
+ end
55
171
 
56
172
  # A representation of a row in a relational table.
57
173
  # @!attribute [rw] column_spec_ids
58
174
  # @return [Array<String>]
59
- # Input Only.
60
175
  # The resource IDs of the column specs describing the columns of the row.
61
- # If set must contain, but possibly in a different order, all input feature
176
+ # If set must contain, but possibly in a different order, all input
177
+ # feature
62
178
  #
63
179
  # {Google::Cloud::AutoML::V1beta1::TablesModelMetadata#input_feature_column_specs column_spec_ids}
64
180
  # of the Model this row is being passed to.
@@ -66,9 +182,9 @@ module Google
66
182
  # field is set.
67
183
  # @!attribute [rw] values
68
184
  # @return [Array<Google::Protobuf::Value>]
69
- # Input Only.
70
- # The values of the row cells, given in the same order as the
71
- # column_spec_ids, or, if not set, then in the same order as input feature
185
+ # Required. The values of the row cells, given in the same order as the
186
+ # column_spec_ids, or, if not set, then in the same order as input
187
+ # feature
72
188
  #
73
189
  # {Google::Cloud::AutoML::V1beta1::TablesModelMetadata#input_feature_column_specs column_specs}
74
190
  # of the Model this row is being passed to.
@@ -59,14 +59,6 @@ module Google
59
59
 
60
60
  # `TypeCode` is used as a part of
61
61
  # {Google::Cloud::AutoML::V1beta1::DataType DataType}.
62
- #
63
- # Each legal value of a DataType can be encoded to or decoded from a JSON
64
- # value, using the encodings listed below, and definitions of which can be
65
- # found at
66
- #
67
- # https:
68
- # //developers.google.com/protocol-buffers
69
- # // /docs/reference/google.protobuf#value.
70
62
  module TypeCode
71
63
  # Not specified. Should not be used.
72
64
  TYPE_CODE_UNSPECIFIED = 0
@@ -20,20 +20,17 @@ module Google
20
20
  # Annotation details for image object detection.
21
21
  # @!attribute [rw] bounding_box
22
22
  # @return [Google::Cloud::AutoML::V1beta1::BoundingPoly]
23
- # Output only.
24
- # The rectangle representing the object location.
23
+ # Output only. The rectangle representing the object location.
25
24
  # @!attribute [rw] score
26
25
  # @return [Float]
27
- # Output only.
28
- # The confidence that this annotation is positive for the parent example,
26
+ # Output only. The confidence that this annotation is positive for the parent example,
29
27
  # value in [0, 1], higher means higher positivity confidence.
30
28
  class ImageObjectDetectionAnnotation; end
31
29
 
32
30
  # Annotation details for video object tracking.
33
31
  # @!attribute [rw] instance_id
34
32
  # @return [String]
35
- # Optional.
36
- # The instance of the object, expressed as a positive integer. Used to tell
33
+ # Optional. The instance of the object, expressed as a positive integer. Used to tell
37
34
  # apart objects of the same type (i.e. AnnotationSpec) when multiple are
38
35
  # present on a single example.
39
36
  # NOTE: Instance ID prediction quality is not a part of model evaluation and
@@ -50,8 +47,7 @@ module Google
50
47
  # at the time_offset of the video).
51
48
  # @!attribute [rw] score
52
49
  # @return [Float]
53
- # Output only.
54
- # The confidence that this annotation is positive for the video at
50
+ # Output only. The confidence that this annotation is positive for the video at
55
51
  # the time_offset, value in [0, 1], higher means higher positivity
56
52
  # confidence. For annotations created by the user the score is 1. When
57
53
  # user approves an annotation, the original float score is kept (and not