@@ -186,6 +186,22 @@ message RagCorpus {
186186 singular : "ragCorpus"
187187 };
188188
189+ // The backend config of the RagCorpus.
190+ // It can be data store and/or retrieval engine.
191+ oneof backend_config {
192+ // Optional. Immutable. The config for the Vector DBs.
193+ RagVectorDbConfig vector_db_config = 9 [
194+ (google.api.field_behavior ) = OPTIONAL ,
195+ (google.api.field_behavior ) = IMMUTABLE
196+ ];
197+
198+ // Optional. Immutable. The config for the Vertex AI Search.
199+ VertexAiSearchConfig vertex_ai_search_config = 10 [
200+ (google.api.field_behavior ) = OPTIONAL ,
201+ (google.api.field_behavior ) = IMMUTABLE
202+ ];
203+ }
204+
189205 // Output only. The resource name of the RagCorpus.
190206 string name = 1 [(google.api.field_behavior ) = OUTPUT_ONLY ];
191207
@@ -207,22 +223,6 @@ message RagCorpus {
207223
208224 // Output only. RagCorpus state.
209225 CorpusStatus corpus_status = 8 [(google.api.field_behavior ) = OUTPUT_ONLY ];
210-
211- // The backend config of the RagCorpus.
212- // It can be data store and/or retrieval engine.
213- oneof backend_config {
214- // Optional. Immutable. The config for the Vector DBs.
215- RagVectorDbConfig vector_db_config = 9 [
216- (google.api.field_behavior ) = OPTIONAL ,
217- (google.api.field_behavior ) = IMMUTABLE
218- ];
219-
220- // Optional. Immutable. The config for the Vertex AI Search.
221- VertexAiSearchConfig vertex_ai_search_config = 10 [
222- (google.api.field_behavior ) = OPTIONAL ,
223- (google.api.field_behavior ) = IMMUTABLE
224- ];
225- }
226226}
227227
228228// A RagFile contains user data for chunking, embedding and indexing.
@@ -284,6 +284,25 @@ message RagFile {
284284 FileStatus file_status = 13 [(google.api.field_behavior ) = OUTPUT_ONLY ];
285285}
286286
287+ // A RagChunk includes the content of a chunk of a RagFile, and associated
288+ // metadata.
289+ message RagChunk {
290+ // Represents where the chunk starts and ends in the document.
291+ message PageSpan {
292+ // Page where chunk starts in the document. Inclusive. 1-indexed.
293+ int32 first_page = 1 ;
294+
295+ // Page where chunk ends in the document. Inclusive. 1-indexed.
296+ int32 last_page = 2 ;
297+ }
298+
299+ // The content of the chunk.
300+ string text = 1 ;
301+
302+ // If populated, represents where the chunk starts and ends in the document.
303+ optional PageSpan page_span = 2 ;
304+ }
305+
287306// Specifies the size and overlap of chunks for RagFiles.
288307message RagFileChunkingConfig {
289308 // Specifies the fixed length chunking config.
0 commit comments