Skip to content

Commit

Permalink
Merge pull request #117 from cohere-ai/fern-bot/01-18-2024-1218PM
Browse files Browse the repository at this point in the history
🌿 Fern Regeneration -- January 18, 2024
  • Loading branch information
billytrend-cohere authored Jan 18, 2024
2 parents e860d11 + d5e7d55 commit c7d0298
Show file tree
Hide file tree
Showing 9 changed files with 47 additions and 27 deletions.
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "cohere-ai",
"version": "7.7.2",
"version": "7.7.3",
"private": false,
"repository": "https://github.com/cohere-ai/cohere-typescript",
"main": "./index.js",
Expand Down
22 changes: 11 additions & 11 deletions src/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: {
Expand Down Expand Up @@ -124,7 +124,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: {
Expand Down Expand Up @@ -187,7 +187,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: {
Expand Down Expand Up @@ -266,7 +266,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: {
Expand Down Expand Up @@ -342,7 +342,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.EmbedRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -409,7 +409,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.RerankRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -472,7 +472,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.ClassifyRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -544,7 +544,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.DetectLanguageRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -604,7 +604,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.SummarizeRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -666,7 +666,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.TokenizeRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -733,7 +733,7 @@ export class CohereClient {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.DetokenizeRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down
12 changes: 6 additions & 6 deletions src/api/resources/connectors/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ export class Connectors {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
queryParameters: _queryParams,
Expand Down Expand Up @@ -131,7 +131,7 @@ export class Connectors {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.CreateConnectorRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -200,7 +200,7 @@ export class Connectors {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down Expand Up @@ -275,7 +275,7 @@ export class Connectors {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down Expand Up @@ -350,7 +350,7 @@ export class Connectors {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.UpdateConnectorRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -434,7 +434,7 @@ export class Connectors {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
queryParameters: _queryParams,
Expand Down
10 changes: 5 additions & 5 deletions src/api/resources/datasets/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ export class Datasets {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
queryParameters: _queryParams,
Expand Down Expand Up @@ -174,7 +174,7 @@ export class Datasets {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "multipart/form-data; boundary=" + _request.getBoundary(),
body: _request,
Expand Down Expand Up @@ -234,7 +234,7 @@ export class Datasets {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down Expand Up @@ -293,7 +293,7 @@ export class Datasets {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down Expand Up @@ -352,7 +352,7 @@ export class Datasets {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down
8 changes: 4 additions & 4 deletions src/api/resources/embedJobs/client/Client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ export class EmbedJobs {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down Expand Up @@ -116,7 +116,7 @@ export class EmbedJobs {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
body: await serializers.CreateEmbedJobRequest.jsonOrThrow(request, { unrecognizedObjectKeys: "strip" }),
Expand Down Expand Up @@ -183,7 +183,7 @@ export class EmbedJobs {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down Expand Up @@ -254,7 +254,7 @@ export class EmbedJobs {
: undefined,
"X-Fern-Language": "JavaScript",
"X-Fern-SDK-Name": "cohere-ai",
"X-Fern-SDK-Version": "7.7.2",
"X-Fern-SDK-Version": "7.7.3",
},
contentType: "application/json",
timeoutMs: requestOptions?.timeoutInSeconds != null ? requestOptions.timeoutInSeconds * 1000 : 60000,
Expand Down
2 changes: 2 additions & 0 deletions src/api/types/Dataset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,8 @@ export interface Dataset {
createdAt: Date;
/** The last update date */
updatedAt: Date;
datasetType: Cohere.DatasetType;
validationStatus: Cohere.DatasetValidationStatus;
/** Errors found during validation */
validationError?: string;
/** the avro schema of the dataset */
Expand Down
3 changes: 3 additions & 0 deletions src/api/types/SingleGenerationInStream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,13 @@
* This file was auto-generated by Fern from our API Definition.
*/

import * as Cohere from "..";

export interface SingleGenerationInStream {
id: string;
/** Full text of the generation. */
text: string;
/** Refers to the nth generation. Only present when `num_generations` is greater than zero. */
index?: number;
finishReason: Cohere.FinishReason;
}
10 changes: 10 additions & 0 deletions src/serialization/types/Dataset.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,14 @@ export const Dataset: core.serialization.ObjectSchema<serializers.Dataset.Raw, C
name: core.serialization.string(),
createdAt: core.serialization.property("created_at", core.serialization.date()),
updatedAt: core.serialization.property("updated_at", core.serialization.date()),
datasetType: core.serialization.property(
"dataset_type",
core.serialization.lazy(async () => (await import("..")).DatasetType)
),
validationStatus: core.serialization.property(
"validation_status",
core.serialization.lazy(async () => (await import("..")).DatasetValidationStatus)
),
validationError: core.serialization.property("validation_error", core.serialization.string().optional()),
schema: core.serialization.string().optional(),
requiredFields: core.serialization.property(
Expand Down Expand Up @@ -40,6 +48,8 @@ export declare namespace Dataset {
name: string;
created_at: string;
updated_at: string;
dataset_type: serializers.DatasetType.Raw;
validation_status: serializers.DatasetValidationStatus.Raw;
validation_error?: string | null;
schema?: string | null;
required_fields?: string[] | null;
Expand Down
5 changes: 5 additions & 0 deletions src/serialization/types/SingleGenerationInStream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,17 @@ export const SingleGenerationInStream: core.serialization.ObjectSchema<
id: core.serialization.string(),
text: core.serialization.string(),
index: core.serialization.number().optional(),
finishReason: core.serialization.property(
"finish_reason",
core.serialization.lazy(async () => (await import("..")).FinishReason)
),
});

export declare namespace SingleGenerationInStream {
interface Raw {
id: string;
text: string;
index?: number | null;
finish_reason: serializers.FinishReason.Raw;
}
}

0 comments on commit c7d0298

Please sign in to comment.