google-apis-developerknowledge_v1alpha 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/CHANGELOG.md +4 -0
- data/lib/google/apis/developerknowledge_v1alpha/classes.rb +108 -0
- data/lib/google/apis/developerknowledge_v1alpha/gem_version.rb +2 -2
- data/lib/google/apis/developerknowledge_v1alpha/representations.rb +61 -0
- data/lib/google/apis/developerknowledge_v1alpha/service.rb +1 -4
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 45d466c1c89c82b02ddb579023ea8d6945246902659ea12934494d771f2c307e
|
|
4
|
+
data.tar.gz: 358555ec4db354462935d327d0dc134bca78ec54a5557224b027a1a419655874
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 4508e4458cc63dddf8edb4017ec35a26069fe4b690cd5dbd87d716068b1c98b498a97368af94ffb9726030e07a509fb6aaeee5e8cd26bde8c66d60c2018afa46
|
|
7
|
+
data.tar.gz: bfb78ace905ddee8d1a81730ff42b27d50a4847662c383d00339df73c7b06b31df021057d0355b4822362dd0d24b8574d4430f7b6dcf39aa9d2073ffd5061eef
|
data/CHANGELOG.md
CHANGED
|
@@ -31,6 +31,16 @@ module Google
|
|
|
31
31
|
# @return [String]
|
|
32
32
|
attr_accessor :answer_text
|
|
33
33
|
|
|
34
|
+
# Output only. Contains citations for the answer.
|
|
35
|
+
# Corresponds to the JSON property `citations`
|
|
36
|
+
# @return [Array<Google::Apis::DeveloperknowledgeV1alpha::AnswerCitation>]
|
|
37
|
+
attr_accessor :citations
|
|
38
|
+
|
|
39
|
+
# Output only. Contains references for the answer.
|
|
40
|
+
# Corresponds to the JSON property `references`
|
|
41
|
+
# @return [Array<Google::Apis::DeveloperknowledgeV1alpha::AnswerReference>]
|
|
42
|
+
attr_accessor :references
|
|
43
|
+
|
|
34
44
|
def initialize(**args)
|
|
35
45
|
update!(**args)
|
|
36
46
|
end
|
|
@@ -38,6 +48,43 @@ module Google
|
|
|
38
48
|
# Update properties of this object
|
|
39
49
|
def update!(**args)
|
|
40
50
|
@answer_text = args[:answer_text] if args.key?(:answer_text)
|
|
51
|
+
@citations = args[:citations] if args.key?(:citations)
|
|
52
|
+
@references = args[:references] if args.key?(:references)
|
|
53
|
+
end
|
|
54
|
+
end
|
|
55
|
+
|
|
56
|
+
# Citation info for a segment.
|
|
57
|
+
class AnswerCitation
|
|
58
|
+
include Google::Apis::Core::Hashable
|
|
59
|
+
|
|
60
|
+
# Output only. Indicates the end of the segment, measured in bytes (UTF-8
|
|
61
|
+
# unicode), exclusive. If there are multi-byte characters, such as non-ASCII
|
|
62
|
+
# characters, the index measurement is longer than the string length.
|
|
63
|
+
# Corresponds to the JSON property `endIndex`
|
|
64
|
+
# @return [Fixnum]
|
|
65
|
+
attr_accessor :end_index
|
|
66
|
+
|
|
67
|
+
# Output only. Contains citation sources for the attributed segment.
|
|
68
|
+
# Corresponds to the JSON property `sources`
|
|
69
|
+
# @return [Array<Google::Apis::DeveloperknowledgeV1alpha::CitationSource>]
|
|
70
|
+
attr_accessor :sources
|
|
71
|
+
|
|
72
|
+
# Output only. Indicates the start of the segment, measured in bytes (UTF-8
|
|
73
|
+
# unicode), inclusive. If there are multi-byte characters, such as non-ASCII
|
|
74
|
+
# characters, the index measurement is longer than the string length.
|
|
75
|
+
# Corresponds to the JSON property `startIndex`
|
|
76
|
+
# @return [Fixnum]
|
|
77
|
+
attr_accessor :start_index
|
|
78
|
+
|
|
79
|
+
def initialize(**args)
|
|
80
|
+
update!(**args)
|
|
81
|
+
end
|
|
82
|
+
|
|
83
|
+
# Update properties of this object
|
|
84
|
+
def update!(**args)
|
|
85
|
+
@end_index = args[:end_index] if args.key?(:end_index)
|
|
86
|
+
@sources = args[:sources] if args.key?(:sources)
|
|
87
|
+
@start_index = args[:start_index] if args.key?(:start_index)
|
|
41
88
|
end
|
|
42
89
|
end
|
|
43
90
|
|
|
@@ -79,6 +126,25 @@ module Google
|
|
|
79
126
|
end
|
|
80
127
|
end
|
|
81
128
|
|
|
129
|
+
# Represents a reference to a source.
|
|
130
|
+
class AnswerReference
|
|
131
|
+
include Google::Apis::Core::Hashable
|
|
132
|
+
|
|
133
|
+
# Represents a reference to a document.
|
|
134
|
+
# Corresponds to the JSON property `documentReference`
|
|
135
|
+
# @return [Google::Apis::DeveloperknowledgeV1alpha::DocumentReference]
|
|
136
|
+
attr_accessor :document_reference
|
|
137
|
+
|
|
138
|
+
def initialize(**args)
|
|
139
|
+
update!(**args)
|
|
140
|
+
end
|
|
141
|
+
|
|
142
|
+
# Update properties of this object
|
|
143
|
+
def update!(**args)
|
|
144
|
+
@document_reference = args[:document_reference] if args.key?(:document_reference)
|
|
145
|
+
end
|
|
146
|
+
end
|
|
147
|
+
|
|
82
148
|
# Response message for DeveloperKnowledge.BatchGetDocuments.
|
|
83
149
|
class BatchGetDocumentsResponse
|
|
84
150
|
include Google::Apis::Core::Hashable
|
|
@@ -98,6 +164,26 @@ module Google
|
|
|
98
164
|
end
|
|
99
165
|
end
|
|
100
166
|
|
|
167
|
+
# Citation source.
|
|
168
|
+
class CitationSource
|
|
169
|
+
include Google::Apis::Core::Hashable
|
|
170
|
+
|
|
171
|
+
# Output only. Contains the index of the Answer.AnswerReference in the `
|
|
172
|
+
# references` repeated field.
|
|
173
|
+
# Corresponds to the JSON property `referenceIndex`
|
|
174
|
+
# @return [Fixnum]
|
|
175
|
+
attr_accessor :reference_index
|
|
176
|
+
|
|
177
|
+
def initialize(**args)
|
|
178
|
+
update!(**args)
|
|
179
|
+
end
|
|
180
|
+
|
|
181
|
+
# Update properties of this object
|
|
182
|
+
def update!(**args)
|
|
183
|
+
@reference_index = args[:reference_index] if args.key?(:reference_index)
|
|
184
|
+
end
|
|
185
|
+
end
|
|
186
|
+
|
|
101
187
|
# A Document represents a piece of content from the Developer Knowledge corpus.
|
|
102
188
|
class Document
|
|
103
189
|
include Google::Apis::Core::Hashable
|
|
@@ -208,6 +294,28 @@ module Google
|
|
|
208
294
|
end
|
|
209
295
|
end
|
|
210
296
|
|
|
297
|
+
# Represents a reference to a document.
|
|
298
|
+
class DocumentReference
|
|
299
|
+
include Google::Apis::Core::Hashable
|
|
300
|
+
|
|
301
|
+
# A DocumentChunk represents a piece of content from a Document in the
|
|
302
|
+
# DeveloperKnowledge corpus. To fetch the entire document content, pass the `
|
|
303
|
+
# parent` to DeveloperKnowledge.GetDocument or DeveloperKnowledge.
|
|
304
|
+
# BatchGetDocuments.
|
|
305
|
+
# Corresponds to the JSON property `documentChunk`
|
|
306
|
+
# @return [Google::Apis::DeveloperknowledgeV1alpha::DocumentChunk]
|
|
307
|
+
attr_accessor :document_chunk
|
|
308
|
+
|
|
309
|
+
def initialize(**args)
|
|
310
|
+
update!(**args)
|
|
311
|
+
end
|
|
312
|
+
|
|
313
|
+
# Update properties of this object
|
|
314
|
+
def update!(**args)
|
|
315
|
+
@document_chunk = args[:document_chunk] if args.key?(:document_chunk)
|
|
316
|
+
end
|
|
317
|
+
end
|
|
318
|
+
|
|
211
319
|
# Response message for DeveloperKnowledge.SearchDocumentChunks.
|
|
212
320
|
class SearchDocumentChunksResponse
|
|
213
321
|
include Google::Apis::Core::Hashable
|
|
@@ -16,13 +16,13 @@ module Google
|
|
|
16
16
|
module Apis
|
|
17
17
|
module DeveloperknowledgeV1alpha
|
|
18
18
|
# Version of the google-apis-developerknowledge_v1alpha gem
|
|
19
|
-
GEM_VERSION = "0.
|
|
19
|
+
GEM_VERSION = "0.3.0"
|
|
20
20
|
|
|
21
21
|
# Version of the code generator used to generate this client
|
|
22
22
|
GENERATOR_VERSION = "0.18.0"
|
|
23
23
|
|
|
24
24
|
# Revision of the discovery document this client was generated from
|
|
25
|
-
REVISION = "
|
|
25
|
+
REVISION = "20260524"
|
|
26
26
|
end
|
|
27
27
|
end
|
|
28
28
|
end
|
|
@@ -28,6 +28,12 @@ module Google
|
|
|
28
28
|
include Google::Apis::Core::JsonObjectSupport
|
|
29
29
|
end
|
|
30
30
|
|
|
31
|
+
class AnswerCitation
|
|
32
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
33
|
+
|
|
34
|
+
include Google::Apis::Core::JsonObjectSupport
|
|
35
|
+
end
|
|
36
|
+
|
|
31
37
|
class AnswerQueryRequest
|
|
32
38
|
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
33
39
|
|
|
@@ -40,12 +46,24 @@ module Google
|
|
|
40
46
|
include Google::Apis::Core::JsonObjectSupport
|
|
41
47
|
end
|
|
42
48
|
|
|
49
|
+
class AnswerReference
|
|
50
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
51
|
+
|
|
52
|
+
include Google::Apis::Core::JsonObjectSupport
|
|
53
|
+
end
|
|
54
|
+
|
|
43
55
|
class BatchGetDocumentsResponse
|
|
44
56
|
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
45
57
|
|
|
46
58
|
include Google::Apis::Core::JsonObjectSupport
|
|
47
59
|
end
|
|
48
60
|
|
|
61
|
+
class CitationSource
|
|
62
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
63
|
+
|
|
64
|
+
include Google::Apis::Core::JsonObjectSupport
|
|
65
|
+
end
|
|
66
|
+
|
|
49
67
|
class Document
|
|
50
68
|
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
51
69
|
|
|
@@ -58,6 +76,12 @@ module Google
|
|
|
58
76
|
include Google::Apis::Core::JsonObjectSupport
|
|
59
77
|
end
|
|
60
78
|
|
|
79
|
+
class DocumentReference
|
|
80
|
+
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
81
|
+
|
|
82
|
+
include Google::Apis::Core::JsonObjectSupport
|
|
83
|
+
end
|
|
84
|
+
|
|
61
85
|
class SearchDocumentChunksResponse
|
|
62
86
|
class Representation < Google::Apis::Core::JsonRepresentation; end
|
|
63
87
|
|
|
@@ -68,6 +92,20 @@ module Google
|
|
|
68
92
|
# @private
|
|
69
93
|
class Representation < Google::Apis::Core::JsonRepresentation
|
|
70
94
|
property :answer_text, as: 'answerText'
|
|
95
|
+
collection :citations, as: 'citations', class: Google::Apis::DeveloperknowledgeV1alpha::AnswerCitation, decorator: Google::Apis::DeveloperknowledgeV1alpha::AnswerCitation::Representation
|
|
96
|
+
|
|
97
|
+
collection :references, as: 'references', class: Google::Apis::DeveloperknowledgeV1alpha::AnswerReference, decorator: Google::Apis::DeveloperknowledgeV1alpha::AnswerReference::Representation
|
|
98
|
+
|
|
99
|
+
end
|
|
100
|
+
end
|
|
101
|
+
|
|
102
|
+
class AnswerCitation
|
|
103
|
+
# @private
|
|
104
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
|
105
|
+
property :end_index, as: 'endIndex'
|
|
106
|
+
collection :sources, as: 'sources', class: Google::Apis::DeveloperknowledgeV1alpha::CitationSource, decorator: Google::Apis::DeveloperknowledgeV1alpha::CitationSource::Representation
|
|
107
|
+
|
|
108
|
+
property :start_index, as: 'startIndex'
|
|
71
109
|
end
|
|
72
110
|
end
|
|
73
111
|
|
|
@@ -86,6 +124,14 @@ module Google
|
|
|
86
124
|
end
|
|
87
125
|
end
|
|
88
126
|
|
|
127
|
+
class AnswerReference
|
|
128
|
+
# @private
|
|
129
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
|
130
|
+
property :document_reference, as: 'documentReference', class: Google::Apis::DeveloperknowledgeV1alpha::DocumentReference, decorator: Google::Apis::DeveloperknowledgeV1alpha::DocumentReference::Representation
|
|
131
|
+
|
|
132
|
+
end
|
|
133
|
+
end
|
|
134
|
+
|
|
89
135
|
class BatchGetDocumentsResponse
|
|
90
136
|
# @private
|
|
91
137
|
class Representation < Google::Apis::Core::JsonRepresentation
|
|
@@ -94,6 +140,13 @@ module Google
|
|
|
94
140
|
end
|
|
95
141
|
end
|
|
96
142
|
|
|
143
|
+
class CitationSource
|
|
144
|
+
# @private
|
|
145
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
|
146
|
+
property :reference_index, as: 'referenceIndex'
|
|
147
|
+
end
|
|
148
|
+
end
|
|
149
|
+
|
|
97
150
|
class Document
|
|
98
151
|
# @private
|
|
99
152
|
class Representation < Google::Apis::Core::JsonRepresentation
|
|
@@ -119,6 +172,14 @@ module Google
|
|
|
119
172
|
end
|
|
120
173
|
end
|
|
121
174
|
|
|
175
|
+
class DocumentReference
|
|
176
|
+
# @private
|
|
177
|
+
class Representation < Google::Apis::Core::JsonRepresentation
|
|
178
|
+
property :document_chunk, as: 'documentChunk', class: Google::Apis::DeveloperknowledgeV1alpha::DocumentChunk, decorator: Google::Apis::DeveloperknowledgeV1alpha::DocumentChunk::Representation
|
|
179
|
+
|
|
180
|
+
end
|
|
181
|
+
end
|
|
182
|
+
|
|
122
183
|
class SearchDocumentChunksResponse
|
|
123
184
|
# @private
|
|
124
185
|
class Representation < Google::Apis::Core::JsonRepresentation
|
|
@@ -56,10 +56,7 @@ module Google
|
|
|
56
56
|
# Required. Specifies the names of the documents to retrieve. A maximum of 20
|
|
57
57
|
# documents can be retrieved in a batch. The documents are returned in the same
|
|
58
58
|
# order as the `names` in the request. Format: `documents/`uri_without_scheme``
|
|
59
|
-
# Example: `documents/docs.cloud.google.com/storage/docs/creating-buckets`
|
|
60
|
-
# you are changing the batch size, consider the value of `
|
|
61
|
-
# maxConcurrentGCSFetches` constant in the service implementation: http://cs///
|
|
62
|
-
# depot/google3/devrel/boq/developerknowledge/service/developerknowledge.go
|
|
59
|
+
# Example: `documents/docs.cloud.google.com/storage/docs/creating-buckets`
|
|
63
60
|
# @param [String] view
|
|
64
61
|
# Optional. Specifies the DocumentView of the document. If unspecified,
|
|
65
62
|
# DeveloperKnowledge.BatchGetDocuments defaults to `DOCUMENT_VIEW_CONTENT`.
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: google-apis-developerknowledge_v1alpha
|
|
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
|
|
@@ -57,7 +57,7 @@ licenses:
|
|
|
57
57
|
metadata:
|
|
58
58
|
bug_tracker_uri: https://github.com/googleapis/google-api-ruby-client/issues
|
|
59
59
|
changelog_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-developerknowledge_v1alpha/CHANGELOG.md
|
|
60
|
-
documentation_uri: https://googleapis.dev/ruby/google-apis-developerknowledge_v1alpha/v0.
|
|
60
|
+
documentation_uri: https://googleapis.dev/ruby/google-apis-developerknowledge_v1alpha/v0.3.0
|
|
61
61
|
source_code_uri: https://github.com/googleapis/google-api-ruby-client/tree/main/generated/google-apis-developerknowledge_v1alpha
|
|
62
62
|
rdoc_options: []
|
|
63
63
|
require_paths:
|