Skip to content

Commit

Permalink
feat(discoveryengine): update the api
Browse files Browse the repository at this point in the history
#### discoveryengine:v1alpha

The following keys were added:
- resources.projects.resources.locations.methods.estimateDataSize (Total Keys: 12)
- resources.projects.resources.locations.resources.collections.resources.dataStores.methods.getDocumentProcessingConfig (Total Keys: 11)
- resources.projects.resources.locations.resources.collections.resources.dataStores.methods.trainCustomModel (Total Keys: 12)
- resources.projects.resources.locations.resources.collections.resources.dataStores.methods.updateDocumentProcessingConfig (Total Keys: 15)
- resources.projects.resources.locations.resources.dataStores.methods.getDocumentProcessingConfig (Total Keys: 11)
- resources.projects.resources.locations.resources.dataStores.methods.updateDocumentProcessingConfig (Total Keys: 15)
- schemas.GoogleCloudDiscoveryengineV1alphaConverseConversationRequest.properties.filter.type (Total Keys: 1)
- schemas.GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig (Total Keys: 5)
- schemas.GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata (Total Keys: 4)
- schemas.GoogleCloudDiscoveryengineV1alphaEstimateDataSizeRequest (Total Keys: 17)
- schemas.GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaOcrConfig (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpec.properties.modelPromptSpec.$ref (Total Keys: 1)
- schemas.GoogleCloudDiscoveryengineV1alphaSearchRequestContentSearchSpecSummarySpecModelPromptSpec (Total Keys: 3)
- schemas.GoogleCloudDiscoveryengineV1alphaSearchResponseSummary.properties.summaryWithMetadata.$ref (Total Keys: 1)
- schemas.GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryCitation (Total Keys: 16)
- schemas.GoogleCloudDiscoveryengineV1alphaSearchResponseSummaryReference (Total Keys: 4)
- schemas.GoogleCloudDiscoveryengineV1alphaSearchResponseSummarySummaryWithMetadata (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaTrainCustomModelRequest (Total Keys: 11)
- schemas.GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse (Total Keys: 6)

#### discoveryengine:v1beta

The following keys were added:
- schemas.GoogleCloudDiscoveryengineV1alphaDocumentProcessingConfig (Total Keys: 5)
- schemas.GoogleCloudDiscoveryengineV1alphaEstimateDataSizeMetadata (Total Keys: 4)
- schemas.GoogleCloudDiscoveryengineV1alphaEstimateDataSizeResponse (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaOcrConfig (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaTrainCustomModelMetadata (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1alphaTrainCustomModelResponse (Total Keys: 6)
- schemas.GoogleCloudDiscoveryengineV1betaConverseConversationRequest.properties.filter.type (Total Keys: 1)
- schemas.GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpec.properties.modelPromptSpec.$ref (Total Keys: 1)
- schemas.GoogleCloudDiscoveryengineV1betaSearchRequestContentSearchSpecSummarySpecModelPromptSpec (Total Keys: 3)
- schemas.GoogleCloudDiscoveryengineV1betaSearchResponseSummary.properties.summaryWithMetadata.$ref (Total Keys: 1)
- schemas.GoogleCloudDiscoveryengineV1betaSearchResponseSummaryCitation (Total Keys: 16)
- schemas.GoogleCloudDiscoveryengineV1betaSearchResponseSummaryReference (Total Keys: 4)
- schemas.GoogleCloudDiscoveryengineV1betaSearchResponseSummarySummaryWithMetadata (Total Keys: 6)
  • Loading branch information
yoshi-automation committed Jan 4, 2024
1 parent 41731ac commit 6f13ac1
Show file tree
Hide file tree
Showing 18 changed files with 2,539 additions and 21 deletions.
108 changes: 105 additions & 3 deletions docs/dyn/discoveryengine_v1alpha.locations.html

Large diffs are not rendered by default.

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,9 @@ <h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#get">get(name, x__xgafv=None)</a></code></p>
<p class="firstline">Gets a DataStore.</p>
<p class="toc_element">
<code><a href="#getDocumentProcessingConfig">getDocumentProcessingConfig(name, x__xgafv=None)</a></code></p>
<p class="firstline">Gets a DocumentProcessingConfig.</p>
<p class="toc_element">
<code><a href="#getSiteSearchEngine">getSiteSearchEngine(name, x__xgafv=None)</a></code></p>
<p class="firstline">Gets the SiteSearchEngine.</p>
Expand All @@ -141,6 +144,12 @@ <h2>Instance Methods</h2>
<p class="toc_element">
<code><a href="#patch">patch(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
<p class="firstline">Updates a DataStore</p>
<p class="toc_element">
<code><a href="#trainCustomModel">trainCustomModel(dataStore, body=None, x__xgafv=None)</a></code></p>
<p class="firstline">Trains a custom model.</p>
<p class="toc_element">
<code><a href="#updateDocumentProcessingConfig">updateDocumentProcessingConfig(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
<p class="firstline">Updates the DocumentProcessingConfig. DocumentProcessingConfig is a singleon resource of DataStore. It's empty when DataStore is created. The first call to this method will set up DocumentProcessingConfig.</p>
<h3>Method Details</h3>
<div class="method">
<code class="details" id="close">close()</code>
Expand Down Expand Up @@ -292,6 +301,32 @@ <h3>Method Details</h3>
}</pre>
</div>

<div class="method">
<code class="details" id="getDocumentProcessingConfig">getDocumentProcessingConfig(name, x__xgafv=None)</code>
<pre>Gets a DocumentProcessingConfig.

Args:
name: string, Required. Full DocumentProcessingConfig resource name. Format: `projects/{project_number}/locations/{location_id}/collections/{collection_id}/dataStores/{data_store_id}/documentProcessingConfig` (required)
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format

Returns:
An object of the form:

{ # A singleton resource of DataStore. It&#x27;s empty when DataStore is created, which defaults to digital parser. The first call to DataStoreService.UpdateDocumentProcessingConfig method will initialize the config.
&quot;name&quot;: &quot;A String&quot;, # Output only. The full resource name of the Document Processing Config. Format: `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`.
&quot;ocrConfig&quot;: { # The OCR options for parsing documents. # The OCR config. Currently it only applies to PDFs.
&quot;enabled&quot;: True or False, # Required. If OCR is enabled or not. OCR must be enabled for other OcrConfig options to apply.
&quot;enhancedDocumentElements&quot;: [ # Apply additional enhanced OCR processing to a list of document elements. Supported values: * `table`: advanced table parsing model.
&quot;A String&quot;,
],
&quot;useNativeText&quot;: True or False, # If true, will use native text instead of OCR text on pages containing native text.
},
}</pre>
</div>

<div class="method">
<code class="details" id="getSiteSearchEngine">getSiteSearchEngine(name, x__xgafv=None)</code>
<pre>Gets the SiteSearchEngine.
Expand Down Expand Up @@ -403,4 +438,96 @@ <h3>Method Details</h3>
}</pre>
</div>

<div class="method">
<code class="details" id="trainCustomModel">trainCustomModel(dataStore, body=None, x__xgafv=None)</code>
<pre>Trains a custom model.

Args:
dataStore: string, Required. The resource name of the Data Store, such as `projects/*/locations/global/collections/default_collection/dataStores/default_data_store`. This field is used to identify the data store where to train the models. (required)
body: object, The request body.
The object takes the form of:

{ # Request message for SearchTuningService.TrainCustomModel method.
&quot;errorConfig&quot;: { # Configuration of destination for Import related errors. # The desired location of errors incurred during the data ingestion and training.
&quot;gcsPrefix&quot;: &quot;A String&quot;, # Cloud Storage prefix for import errors. This must be an empty, existing Cloud Storage directory. Import errors are written to sharded files in this directory, one per line, as a JSON-encoded `google.rpc.Status` message.
},
&quot;gcsTrainingInput&quot;: { # Gcs training data input. # Gcs training input.
&quot;corpusDataPath&quot;: &quot;A String&quot;, # The gcs corpus data which could be associated in train data. The data path format is gs:///. A newline delimited jsonl/ndjson file. * For search-tuning model, each line should have the _id, title and text. Example: {&quot;_id&quot;: &quot;doc1&quot;, title: &quot;relevant doc&quot;, &quot;text&quot;: &quot;relevant text&quot;}
&quot;queryDataPath&quot;: &quot;A String&quot;, # The gcs query data which could be associated in train data. The data path format is gs:///. A newline delimited jsonl/ndjson file. * For search-tuning model, each line should have the _id and text. Example: {&quot;_id&quot;: &quot;query1&quot;, &quot;text&quot;: &quot;example query&quot;}
&quot;testDataPath&quot;: &quot;A String&quot;, # Gcs test data. Same format as train_data_path. If not provided, a random 80/20 train/test split will be performed on train_data_path.
&quot;trainDataPath&quot;: &quot;A String&quot;, # Gcs training data path whose format should be gs:///. The file should be in tsv format. Each line should have the doc_id and query_id and score (number). * For search-tuning model, it should have the query-id corpus-id score as tsv file header. The score should be a number in [0, inf+). The larger the number is, the more relevant the pair is. Example: query-id\tcorpus-id\tscore query1\tdoc1\t1
},
&quot;modelType&quot;: &quot;A String&quot;, # Model to be trained. Supported values are: * **search-tuning**: Fine tuning the search system based on data provided.
}

x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format

Returns:
An object of the form:

{ # This resource represents a long-running operation that is the result of a network API call.
&quot;done&quot;: True or False, # If the value is `false`, it means the operation is still in progress. If `true`, the operation is completed, and either `error` or `response` is available.
&quot;error&quot;: { # The `Status` type defines a logical error model that is suitable for different programming environments, including REST APIs and RPC APIs. It is used by [gRPC](https://github.com/grpc). Each `Status` message contains three pieces of data: error code, error message, and error details. You can find out more about this error model and how to work with it in the [API Design Guide](https://cloud.google.com/apis/design/errors). # The error result of the operation in case of failure or cancellation.
&quot;code&quot;: 42, # The status code, which should be an enum value of google.rpc.Code.
&quot;details&quot;: [ # A list of messages that carry the error details. There is a common set of message types for APIs to use.
{
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
},
],
&quot;message&quot;: &quot;A String&quot;, # A developer-facing error message, which should be in English. Any user-facing error message should be localized and sent in the google.rpc.Status.details field, or localized by the client.
},
&quot;metadata&quot;: { # Service-specific metadata associated with the operation. It typically contains progress information and common metadata such as create time. Some services might not provide such metadata. Any method that returns a long-running operation should document the metadata type, if any.
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
},
&quot;name&quot;: &quot;A String&quot;, # The server-assigned name, which is only unique within the same service that originally returns it. If you use the default HTTP mapping, the `name` should be a resource name ending with `operations/{unique_id}`.
&quot;response&quot;: { # The normal, successful response of the operation. If the original method returns no data on success, such as `Delete`, the response is `google.protobuf.Empty`. If the original method is standard `Get`/`Create`/`Update`, the response should be the resource. For other methods, the response should have the type `XxxResponse`, where `Xxx` is the original method name. For example, if the original method name is `TakeSnapshot()`, the inferred response type is `TakeSnapshotResponse`.
&quot;a_key&quot;: &quot;&quot;, # Properties of the object. Contains field @type with type URL.
},
}</pre>
</div>

<div class="method">
<code class="details" id="updateDocumentProcessingConfig">updateDocumentProcessingConfig(name, body=None, updateMask=None, x__xgafv=None)</code>
<pre>Updates the DocumentProcessingConfig. DocumentProcessingConfig is a singleon resource of DataStore. It&#x27;s empty when DataStore is created. The first call to this method will set up DocumentProcessingConfig.

Args:
name: string, Output only. The full resource name of the Document Processing Config. Format: `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`. (required)
body: object, The request body.
The object takes the form of:

{ # A singleton resource of DataStore. It&#x27;s empty when DataStore is created, which defaults to digital parser. The first call to DataStoreService.UpdateDocumentProcessingConfig method will initialize the config.
&quot;name&quot;: &quot;A String&quot;, # Output only. The full resource name of the Document Processing Config. Format: `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`.
&quot;ocrConfig&quot;: { # The OCR options for parsing documents. # The OCR config. Currently it only applies to PDFs.
&quot;enabled&quot;: True or False, # Required. If OCR is enabled or not. OCR must be enabled for other OcrConfig options to apply.
&quot;enhancedDocumentElements&quot;: [ # Apply additional enhanced OCR processing to a list of document elements. Supported values: * `table`: advanced table parsing model.
&quot;A String&quot;,
],
&quot;useNativeText&quot;: True or False, # If true, will use native text instead of OCR text on pages containing native text.
},
}

updateMask: string, Indicates which fields in the provided DocumentProcessingConfig to update. The following are the only supported fields: * DocumentProcessingConfig.orc_config If not set, all supported fields are updated.
x__xgafv: string, V1 error format.
Allowed values
1 - v1 error format
2 - v2 error format

Returns:
An object of the form:

{ # A singleton resource of DataStore. It&#x27;s empty when DataStore is created, which defaults to digital parser. The first call to DataStoreService.UpdateDocumentProcessingConfig method will initialize the config.
&quot;name&quot;: &quot;A String&quot;, # Output only. The full resource name of the Document Processing Config. Format: `projects/*/locations/*/collections/*/dataStores/*/documentProcessingConfig`.
&quot;ocrConfig&quot;: { # The OCR options for parsing documents. # The OCR config. Currently it only applies to PDFs.
&quot;enabled&quot;: True or False, # Required. If OCR is enabled or not. OCR must be enabled for other OcrConfig options to apply.
&quot;enhancedDocumentElements&quot;: [ # Apply additional enhanced OCR processing to a list of document elements. Supported values: * `table`: advanced table parsing model.
&quot;A String&quot;,
],
&quot;useNativeText&quot;: True or False, # If true, will use native text instead of OCR text on pages containing native text.
},
}</pre>
</div>

</body></html>
Original file line number Diff line number Diff line change
Expand Up @@ -266,8 +266,11 @@ <h3>Method Details</h3>
&quot;ignoreNonSummarySeekingQuery&quot;: True or False, # Specifies whether to filter out queries that are not summary-seeking. The default value is `false`. Google employs search-query classification to detect summary-seeking queries. No summary is returned if the search query is classified as a non-summary seeking query. For example, `why is the sky blue` and `Who is the best soccer player in the world?` are summary-seeking queries, but `SFO airport` and `world cup 2026` are not. They are most likely navigational queries. If this field is set to `true`, we skip generating summaries for non-summary seeking queries and return fallback messages instead.
&quot;includeCitations&quot;: True or False, # Specifies whether to include citations in the summary. The default value is `false`. When this field is set to `true`, summaries include in-line citation numbers. Example summary including citations: BigQuery is Google Cloud&#x27;s fully managed and completely serverless enterprise data warehouse [1]. BigQuery supports all data types, works across clouds, and has built-in machine learning and business intelligence, all within a unified platform [2, 3]. The citation numbers refer to the returned search results and are 1-indexed. For example, [1] means that the sentence is attributed to the first search result. [2, 3] means that the sentence is attributed to both the second and third search results.
&quot;languageCode&quot;: &quot;A String&quot;, # Language code for Summary. Use language tags defined by [BCP47](https://www.rfc-editor.org/rfc/bcp/bcp47.txt). Note: This is an experimental feature.
&quot;modelPromptSpec&quot;: { # Specification of the prompt to use with the model. # If specified, the spec will be used to modify the prompt provided to the LLM.
&quot;preamble&quot;: &quot;A String&quot;, # Text at the beginning of the prompt that instructs the assistant. Examples are available in the user guide.
},
&quot;modelSpec&quot;: { # Specification of the model. # If specified, the spec will be used to modify the model specification provided to the LLM.
&quot;version&quot;: &quot;A String&quot;, # The string format of the model version. e.g. stable, latest, etc.
&quot;version&quot;: &quot;A String&quot;, # The string format of the model version. e.g. stable, preview, etc.
},
&quot;summaryResultCount&quot;: 42, # The number of top results to generate the summary from. If the number of results returned is less than `summaryResultCount`, the summary is generated from all of the results. At most five results can be used to generate a summary.
},
Expand Down Expand Up @@ -443,6 +446,29 @@ <h3>Method Details</h3>
&quot;A String&quot;,
],
&quot;summaryText&quot;: &quot;A String&quot;, # The summary content.
&quot;summaryWithMetadata&quot;: { # Summary with metadata information.
&quot;citationMetadata&quot;: { # Citation metadata. # Citation metadata for given summary.
&quot;citations&quot;: [ # Citations for segments.
{ # Citation info for a segment.
&quot;endIndex&quot;: &quot;A String&quot;, # End of the attributed segment, exclusive.
&quot;sources&quot;: [ # Citation sources for the attributed segment.
{ # Citation source.
&quot;referenceIndex&quot;: &quot;A String&quot;, # Document reference index from SummaryWithMetadata.references. It is 0-indexed and the value will be zero if the reference_index is not set explicitly.
},
],
&quot;startIndex&quot;: &quot;A String&quot;, # Index indicates the start of the segment, measured in bytes/unicode.
},
],
},
&quot;references&quot;: [ # Document References.
{ # Document reference.
&quot;document&quot;: &quot;A String&quot;, # Required. Document.name of the document. Full resource name of the referenced document, in the format `projects/*/locations/*/collections/*/dataStores/*/branches/*/documents/*`.
&quot;title&quot;: &quot;A String&quot;, # Title of the document.
&quot;uri&quot;: &quot;A String&quot;, # GCS or HTTP uri for the document.
},
],
&quot;summary&quot;: &quot;A String&quot;, # Summary text with no citation information.
},
},
&quot;totalSize&quot;: 42, # The estimated total count of matched items irrespective of pagination. The count of results returned by pagination may be less than the total_size that matches.
}</pre>
Expand Down

0 comments on commit 6f13ac1

Please sign in to comment.