Skip to content

Commit 1821719

Browse files
committed
feat(discovery): adds new model, RetrievalDetails
1 parent 3bf1e5e commit 1821719

1 file changed

Lines changed: 41 additions & 33 deletions

File tree

discovery/v1-generated.ts

Lines changed: 41 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -352,7 +352,7 @@ class DiscoveryV1 extends BaseService {
352352
* @param {string} params.environment_id - The ID of the environment.
353353
* @param {string} params.name - The name of the configuration.
354354
* @param {string} [params.description] - The description of the configuration, if available.
355-
* @param {Conversions} [params.conversions] - The document conversion settings for the configuration.
355+
* @param {Conversions} [params.conversions] - Document conversion settings.
356356
* @param {Enrichment[]} [params.enrichments] - An array of document enrichment settings for the configuration.
357357
* @param {NormalizationOperation[]} [params.normalizations] - Defines operations that can be used to transform the
358358
* final output JSON into a normalized form. Operations are executed in the order that they appear in the array.
@@ -556,7 +556,7 @@ class DiscoveryV1 extends BaseService {
556556
* @param {string} params.configuration_id - The ID of the configuration.
557557
* @param {string} params.name - The name of the configuration.
558558
* @param {string} [params.description] - The description of the configuration, if available.
559-
* @param {Conversions} [params.conversions] - The document conversion settings for the configuration.
559+
* @param {Conversions} [params.conversions] - Document conversion settings.
560560
* @param {Enrichment[]} [params.enrichments] - An array of document enrichment settings for the configuration.
561561
* @param {NormalizationOperation[]} [params.normalizations] - Defines operations that can be used to transform the
562562
* final output JSON into a normalized form. Operations are executed in the order that they appear in the array.
@@ -2697,7 +2697,7 @@ class DiscoveryV1 extends BaseService {
26972697
*
26982698
* @param {Object} params - The parameters to send to the service.
26992699
* @param {string} params.type - The event type to be created.
2700-
* @param {EventData} params.data - Data object used to create a query event.
2700+
* @param {EventData} params.data - Query event data object.
27012701
* @param {Object} [params.headers] - Custom request headers
27022702
* @param {Function} [callback] - The callback that handles the response.
27032703
* @returns {NodeJS.ReadableStream|void}
@@ -3302,7 +3302,7 @@ namespace DiscoveryV1 {
33023302

33033303
/** Constants for the `createEnvironment` operation. */
33043304
export namespace CreateEnvironmentConstants {
3305-
/** Size of the environment. In the Lite plan the default and only accepted value is `LT`, in all other plans the default is `S`. */
3305+
/** Size of the environment. In the Lite plan the default and only accepted value is `LT`, in all other plans the default is `S`. */
33063306
export enum Size {
33073307
LT = 'LT',
33083308
XS = 'XS',
@@ -3362,7 +3362,7 @@ namespace DiscoveryV1 {
33623362

33633363
/** Constants for the `updateEnvironment` operation. */
33643364
export namespace UpdateEnvironmentConstants {
3365-
/** Size that the environment should be increased to. Environment size cannot be modified when using a Lite plan. Environment size can only increased and not decreased. */
3365+
/** Size that the environment should be increased to. Environment size cannot be modified when using a Lite plan. Environment size can only increased and not decreased. */
33663366
export enum Size {
33673367
S = 'S',
33683368
MS = 'MS',
@@ -3383,7 +3383,7 @@ namespace DiscoveryV1 {
33833383
name: string;
33843384
/** The description of the configuration, if available. */
33853385
description?: string;
3386-
/** The document conversion settings for the configuration. */
3386+
/** Document conversion settings. */
33873387
conversions?: Conversions;
33883388
/** An array of document enrichment settings for the configuration. */
33893389
enrichments?: Enrichment[];
@@ -3431,7 +3431,7 @@ namespace DiscoveryV1 {
34313431
name: string;
34323432
/** The description of the configuration, if available. */
34333433
description?: string;
3434-
/** The document conversion settings for the configuration. */
3434+
/** Document conversion settings. */
34353435
conversions?: Conversions;
34363436
/** An array of document enrichment settings for the configuration. */
34373437
enrichments?: Enrichment[];
@@ -3465,7 +3465,7 @@ namespace DiscoveryV1 {
34653465

34663466
/** Constants for the `testConfigurationInEnvironment` operation. */
34673467
export namespace TestConfigurationInEnvironmentConstants {
3468-
/** Specify to only run the input document through the given step instead of running the input document through the entire ingestion workflow. Valid values are `convert`, `enrich`, and `normalize`. */
3468+
/** Specify to only run the input document through the given step instead of running the input document through the entire ingestion workflow. Valid values are `convert`, `enrich`, and `normalize`. */
34693469
export enum Step {
34703470
HTML_INPUT = 'html_input',
34713471
HTML_OUTPUT = 'html_output',
@@ -3474,7 +3474,7 @@ namespace DiscoveryV1 {
34743474
ENRICHMENTS_OUTPUT = 'enrichments_output',
34753475
NORMALIZATIONS_OUTPUT = 'normalizations_output',
34763476
}
3477-
/** The content type of file. */
3477+
/** The content type of file. */
34783478
export enum FileContentType {
34793479
APPLICATION_JSON = 'application/json',
34803480
APPLICATION_MSWORD = 'application/msword',
@@ -3502,7 +3502,7 @@ namespace DiscoveryV1 {
35023502

35033503
/** Constants for the `createCollection` operation. */
35043504
export namespace CreateCollectionConstants {
3505-
/** The language of the documents stored in the collection, in the form of an ISO 639-1 language code. */
3505+
/** The language of the documents stored in the collection, in the form of an ISO 639-1 language code. */
35063506
export enum Language {
35073507
EN = 'en',
35083508
ES = 'es',
@@ -3645,7 +3645,7 @@ namespace DiscoveryV1 {
36453645

36463646
/** Constants for the `addDocument` operation. */
36473647
export namespace AddDocumentConstants {
3648-
/** The content type of file. */
3648+
/** The content type of file. */
36493649
export enum FileContentType {
36503650
APPLICATION_JSON = 'application/json',
36513651
APPLICATION_MSWORD = 'application/msword',
@@ -3699,7 +3699,7 @@ namespace DiscoveryV1 {
36993699

37003700
/** Constants for the `updateDocument` operation. */
37013701
export namespace UpdateDocumentConstants {
3702-
/** The content type of file. */
3702+
/** The content type of file. */
37033703
export enum FileContentType {
37043704
APPLICATION_JSON = 'application/json',
37053705
APPLICATION_MSWORD = 'application/msword',
@@ -3930,7 +3930,7 @@ namespace DiscoveryV1 {
39303930

39313931
/** Constants for the `queryRelations` operation. */
39323932
export namespace QueryRelationsConstants {
3933-
/** The sorting method for the relationships, can be `score` or `frequency`. `frequency` is the number of unique times each entity is identified. The default is `score`. This parameter cannot be used in the same query as the **bias** parameter. */
3933+
/** The sorting method for the relationships, can be `score` or `frequency`. `frequency` is the number of unique times each entity is identified. The default is `score`. This parameter cannot be used in the same query as the **bias** parameter. */
39343934
export enum Sort {
39353935
SCORE = 'score',
39363936
FREQUENCY = 'frequency',
@@ -4066,14 +4066,14 @@ namespace DiscoveryV1 {
40664066
export interface CreateEventParams {
40674067
/** The event type to be created. */
40684068
type: CreateEventConstants.Type | string;
4069-
/** Data object used to create a query event. */
4069+
/** Query event data object. */
40704070
data: EventData;
40714071
headers?: Object;
40724072
}
40734073

40744074
/** Constants for the `createEvent` operation. */
40754075
export namespace CreateEventConstants {
4076-
/** The event type to be created. */
4076+
/** The event type to be created. */
40774077
export enum Type {
40784078
CLICK = 'click',
40794079
}
@@ -4092,7 +4092,7 @@ namespace DiscoveryV1 {
40924092

40934093
/** Constants for the `getMetricsEventRate` operation. */
40944094
export namespace GetMetricsEventRateConstants {
4095-
/** The type of result to consider when calculating the metric. */
4095+
/** The type of result to consider when calculating the metric. */
40964096
export enum ResultType {
40974097
DOCUMENT = 'document',
40984098
}
@@ -4111,7 +4111,7 @@ namespace DiscoveryV1 {
41114111

41124112
/** Constants for the `getMetricsQuery` operation. */
41134113
export namespace GetMetricsQueryConstants {
4114-
/** The type of result to consider when calculating the metric. */
4114+
/** The type of result to consider when calculating the metric. */
41154115
export enum ResultType {
41164116
DOCUMENT = 'document',
41174117
}
@@ -4130,7 +4130,7 @@ namespace DiscoveryV1 {
41304130

41314131
/** Constants for the `getMetricsQueryEvent` operation. */
41324132
export namespace GetMetricsQueryEventConstants {
4133-
/** The type of result to consider when calculating the metric. */
4133+
/** The type of result to consider when calculating the metric. */
41344134
export enum ResultType {
41354135
DOCUMENT = 'document',
41364136
}
@@ -4149,7 +4149,7 @@ namespace DiscoveryV1 {
41494149

41504150
/** Constants for the `getMetricsQueryNoResults` operation. */
41514151
export namespace GetMetricsQueryNoResultsConstants {
4152-
/** The type of result to consider when calculating the metric. */
4152+
/** The type of result to consider when calculating the metric. */
41534153
export enum ResultType {
41544154
DOCUMENT = 'document',
41554155
}
@@ -4190,7 +4190,7 @@ namespace DiscoveryV1 {
41904190

41914191
/** Constants for the `createCredentials` operation. */
41924192
export namespace CreateCredentialsConstants {
4193-
/** The source that this credentials object connects to. - `box` indicates the credentials are used to connect an instance of Enterprise Box. - `salesforce` indicates the credentials are used to connect to Salesforce. - `sharepoint` indicates the credentials are used to connect to Microsoft SharePoint Online. */
4193+
/** The source that this credentials object connects to. - `box` indicates the credentials are used to connect an instance of Enterprise Box. - `salesforce` indicates the credentials are used to connect to Salesforce. - `sharepoint` indicates the credentials are used to connect to Microsoft SharePoint Online. */
41944194
export enum SourceType {
41954195
BOX = 'box',
41964196
SALESFORCE = 'salesforce',
@@ -4238,7 +4238,7 @@ namespace DiscoveryV1 {
42384238

42394239
/** Constants for the `updateCredentials` operation. */
42404240
export namespace UpdateCredentialsConstants {
4241-
/** The source that this credentials object connects to. - `box` indicates the credentials are used to connect an instance of Enterprise Box. - `salesforce` indicates the credentials are used to connect to Salesforce. - `sharepoint` indicates the credentials are used to connect to Microsoft SharePoint Online. */
4241+
/** The source that this credentials object connects to. - `box` indicates the credentials are used to connect an instance of Enterprise Box. - `salesforce` indicates the credentials are used to connect to Salesforce. - `sharepoint` indicates the credentials are used to connect to Microsoft SharePoint Online. */
42424242
export enum SourceType {
42434243
BOX = 'box',
42444244
SALESFORCE = 'salesforce',
@@ -4280,7 +4280,7 @@ namespace DiscoveryV1 {
42804280
language?: string;
42814281
/** The object providing information about the documents in the collection. Present only when retrieving details of a collection. */
42824282
document_counts?: DocumentCounts;
4283-
/** The object providing information about the disk usage of the collection. Present only when retrieving details of a collection. */
4283+
/** Summary of the disk usage statistics for this collection. */
42844284
disk_usage?: CollectionDiskUsage;
42854285
/** Provides information about the status of relevance training for collection. */
42864286
training_status?: TrainingStatus;
@@ -4314,7 +4314,7 @@ namespace DiscoveryV1 {
43144314
updated?: string;
43154315
/** The description of the configuration, if available. */
43164316
description?: string;
4317-
/** The document conversion settings for the configuration. */
4317+
/** Document conversion settings. */
43184318
conversions?: Conversions;
43194319
/** An array of document enrichment settings for the configuration. */
43204320
enrichments?: Enrichment[];
@@ -4512,7 +4512,7 @@ namespace DiscoveryV1 {
45124512
enrichment_name: string;
45134513
/** If true, then most errors generated during the enrichment process will be treated as warnings and will not cause the document to fail processing. */
45144514
ignore_downstream_errors?: boolean;
4515-
/** A list of options specific to the enrichment. */
4515+
/** Options which are specific to a particular enrichment. */
45164516
options?: EnrichmentOptions;
45174517
}
45184518

@@ -4548,7 +4548,7 @@ namespace DiscoveryV1 {
45484548
requested_size?: string;
45494549
/** Details about the resource usage and capacity of the environment. */
45504550
index_capacity?: IndexCapacity;
4551-
/** Information about Continuous Relevancy Training for this environment. */
4551+
/** Information about the Continuous Relevancy Training for this environment. */
45524552
search_status?: SearchStatus;
45534553
}
45544554

@@ -4624,11 +4624,11 @@ namespace DiscoveryV1 {
46244624
export interface IndexCapacity {
46254625
/** Summary of the document usage statistics for the environment. */
46264626
documents?: EnvironmentDocuments;
4627-
/** Summary of the disk usage of the environment. */
4627+
/** Summary of the disk usage statistics for the environment. */
46284628
disk_usage?: DiskUsage;
46294629
/** Summary of the collection usage in the environment. */
46304630
collections?: CollectionUsage;
4631-
/** **Deprecated**: Summary of the memory usage of the environment. */
4631+
/** **Deprecated**: Summary of the memory usage statistics for this environment. */
46324632
memory_usage?: MemoryUsage;
46334633
}
46344634

@@ -4826,7 +4826,7 @@ namespace DiscoveryV1 {
48264826
sentiment?: NluEnrichmentSentiment;
48274827
/** An object specifying the emotion detection enrichment and related parameters. */
48284828
emotion?: NluEnrichmentEmotion;
4829-
/** An object specifying the categories enrichment and related parameters. */
4829+
/** An object that indicates the Categories enrichment will be applied to the specified field. */
48304830
categories?: NluEnrichmentCategories;
48314831
/** An object specifiying the semantic roles enrichment and related parameters. */
48324832
semantic_roles?: NluEnrichmentSemanticRoles;
@@ -5001,7 +5001,7 @@ namespace DiscoveryV1 {
50015001
metadata?: Object;
50025002
/** The collection ID of the collection containing the document for this result. */
50035003
collection_id?: string;
5004-
/** Metadata of the query result. */
5004+
/** Metadata of a query result. */
50055005
result_metadata?: QueryResultResultMetadata;
50065006
/** The internal status code returned by the ingestion subsystem indicating the overall result of ingesting the source document. */
50075007
code?: number;
@@ -5084,6 +5084,8 @@ namespace DiscoveryV1 {
50845084
duplicates_removed?: number;
50855085
/** The session token for this query. The session token can be used to add events associated with this query to the query and event log. **Important:** Session tokens are case sensitive. */
50865086
session_token?: string;
5087+
/** An object contain retrieval type information. */
5088+
retrieval_details?: RetrievalDetails;
50875089
}
50885090

50895091
/** QueryResult. */
@@ -5096,7 +5098,7 @@ namespace DiscoveryV1 {
50965098
metadata?: Object;
50975099
/** The collection ID of the collection containing the document for this result. */
50985100
collection_id?: string;
5099-
/** Metadata of the query result. */
5101+
/** Metadata of a query result. */
51005102
result_metadata?: QueryResultResultMetadata;
51015103
/** QueryResult accepts additional properties. */
51025104
[propName: string]: any;
@@ -5105,9 +5107,15 @@ namespace DiscoveryV1 {
51055107
/** Metadata of a query result. */
51065108
export interface QueryResultResultMetadata {
51075109
/** An unbounded measure of the relevance of a particular result, dependent on the query and matching document. A higher score indicates a greater match to the query parameters. */
5108-
score?: number;
5109-
/** The confidence score for the given result. Calculated based on how relevant the result is estimated to be, compared to a trained relevancy model. confidence can range from `0.0` to `1.0`. The higher the number, the more relevant the document. */
5110-
confidence?: number;
5110+
score: number;
5111+
/** The confidence score for the given result. Calculated based on how relevant the result is estimated to be. confidence can range from `0.0` to `1.0`. The higher the number, the more relevant the document. The `confidence` value for a result was calculated using the model specified in the `document_retrieval_strategy` field of the result set. */
5112+
confidence: number;
5113+
}
5114+
5115+
/** An object contain retrieval type information. */
5116+
export interface RetrievalDetails {
5117+
/** Indentifies the document retrieval strategy used for this query. `relevancy_training` indicates that the results were returned using a relevancy trained model. `continuous_relevancy_training` indicates that the results were returned using the continuous relevancy training model created by result feedback analysis. `untrained` means the results were returned using the standard untrained model. **Note**: In the event of trained collections being queried, but the trained model is not used to return results, the **document_retrieval_strategy** will be listed as `untrained`. */
5118+
document_retrieval_strategy?: string;
51115119
}
51125120

51135121
/** Information about the Continuous Relevancy Training for this environment. */

0 commit comments

Comments
 (0)