Skip to content

Commit

Permalink
feat: Updated OpenAPI spec
Browse files Browse the repository at this point in the history
  • Loading branch information
github-actions[bot] committed Sep 13, 2024
1 parent 6abbdae commit 0b61163
Show file tree
Hide file tree
Showing 9 changed files with 15 additions and 18 deletions.
6 changes: 3 additions & 3 deletions src/libs/Cohere/Generated/Cohere.CohereApi.Chat.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ partial void ProcessChatResponseContent(
/// <summary>
/// Chat<br/>
/// Generates a text response to a user message.<br/>
/// To learn how to use the Chat API and RAG follow our [Text Generation guides](https://docs.cohere.com/docs/chat-api).
/// To learn how to use the Chat API with Streaming and RAG follow our [Text Generation guides](https://docs.cohere.com/docs/chat-api).
/// </summary>
/// <param name="xClientName"></param>
/// <param name="accepts"></param>
Expand Down Expand Up @@ -111,7 +111,7 @@ partial void ProcessChatResponseContent(
/// <summary>
/// Chat<br/>
/// Generates a text response to a user message.<br/>
/// To learn how to use the Chat API and RAG follow our [Text Generation guides](https://docs.cohere.com/docs/chat-api).
/// To learn how to use the Chat API with Streaming and RAG follow our [Text Generation guides](https://docs.cohere.com/docs/chat-api).
/// </summary>
/// <param name="xClientName"></param>
/// <param name="accepts"></param>
Expand Down Expand Up @@ -157,7 +157,7 @@ partial void ProcessChatResponseContent(
/// - AUTO_PRESERVE_ORDER: Azure, AWS Sagemaker/Bedrock, Private Deployments
/// </param>
/// <param name="connectors">
/// Accepts `{"id": "web-search"}`, and/or the `"id"` for a custom [connector](https://docs.cohere.com/docs/overview-rag-connectors), if you've [created](https://docs.cohere.com/docs/creating-and-deploying-a-connector) one.<br/>
/// Accepts `{"id": "web-search"}`, and/or the `"id"` for a custom [connector](https://docs.cohere.com/docs/connectors), if you've [created](https://docs.cohere.com/docs/creating-and-deploying-a-connector) one.<br/>
/// When specified, the model's reply will be enriched with information found by querying each of the connectors (RAG).<br/>
/// Compatible Deployments: Cohere Platform
/// </param>
Expand Down
2 changes: 1 addition & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Embed.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,8 @@ partial void ProcessEmbedResponseContent(
/// <param name="cancellationToken">The token to cancel the operation with</param>
/// <exception cref="global::System.InvalidOperationException"></exception>
public async global::System.Threading.Tasks.Task<global::System.OneOf<global::Cohere.EmbedFloatsResponse, global::Cohere.EmbedByTypeResponse>> EmbedAsync(
global::System.Collections.Generic.IList<string> texts,
string? xClientName = default,
global::System.Collections.Generic.IList<string>? texts = default,
string? model = default,
global::Cohere.EmbedInputType? inputType = default,
global::System.Collections.Generic.IList<global::Cohere.EmbeddingType>? embeddingTypes = default,
Expand Down
2 changes: 1 addition & 1 deletion src/libs/Cohere/Generated/Cohere.CohereApi.Generate.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -134,7 +134,7 @@ partial void ProcessGenerateResponseContent(
/// </param>
/// <param name="maxTokens">
/// The maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.<br/>
/// This parameter is off by default, and if it's not specified, the model will continue generating until it emits an EOS completion token.<br/>
/// This parameter is off by default, and if it's not specified, the model will continue generating until it emits an EOS completion token. See [BPE Tokens](/bpe-tokens-wiki) for more details.<br/>
/// Can only be set to `0` if `return_likelihoods` is set to `ALL` to get the likelihood of the prompt.
/// </param>
/// <param name="truncate">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ partial void ProcessDeleteConnectorResponseContent(

/// <summary>
/// Delete a Connector<br/>
/// Delete a connector by ID. See ['Connectors'](https://docs.cohere.com/docs/overview-rag-connectors) for more information.
/// Delete a connector by ID. See ['Connectors'](https://docs.cohere.com/docs/connectors) for more information.
/// </summary>
/// <param name="id"></param>
/// <param name="xClientName"></param>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ partial void ProcessGetConnectorResponseContent(

/// <summary>
/// Get a Connector<br/>
/// Retrieve a connector by ID. See ['Connectors'](https://docs.cohere.com/docs/overview-rag-connectors) for more information.
/// Retrieve a connector by ID. See ['Connectors'](https://docs.cohere.com/docs/connectors) for more information.
/// </summary>
/// <param name="id"></param>
/// <param name="xClientName"></param>
Expand Down
2 changes: 1 addition & 1 deletion src/libs/Cohere/Generated/Cohere.Models.ChatRequest.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ public sealed partial class ChatRequest
public global::Cohere.ChatRequestPromptTruncation? PromptTruncation { get; set; }

/// <summary>
/// Accepts `{"id": "web-search"}`, and/or the `"id"` for a custom [connector](https://docs.cohere.com/docs/overview-rag-connectors), if you've [created](https://docs.cohere.com/docs/creating-and-deploying-a-connector) one.<br/>
/// Accepts `{"id": "web-search"}`, and/or the `"id"` for a custom [connector](https://docs.cohere.com/docs/connectors), if you've [created](https://docs.cohere.com/docs/creating-and-deploying-a-connector) one.<br/>
/// When specified, the model's reply will be enriched with information found by querying each of the connectors (RAG).<br/>
/// Compatible Deployments: Cohere Platform
/// </summary>
Expand Down
3 changes: 1 addition & 2 deletions src/libs/Cohere/Generated/Cohere.Models.EmbedRequest.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -12,8 +12,7 @@ public sealed partial class EmbedRequest
/// An array of strings for the model to embed. Maximum number of texts per call is `96`. We recommend reducing the length of each text to be under `512` tokens for optimal quality.
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("texts")]
[global::System.Text.Json.Serialization.JsonRequired]
public required global::System.Collections.Generic.IList<string> Texts { get; set; }
public global::System.Collections.Generic.IList<string>? Texts { get; set; }

/// <summary>
/// Defaults to embed-english-v2.0<br/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public sealed partial class GenerateRequest

/// <summary>
/// The maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.<br/>
/// This parameter is off by default, and if it's not specified, the model will continue generating until it emits an EOS completion token.<br/>
/// This parameter is off by default, and if it's not specified, the model will continue generating until it emits an EOS completion token. See [BPE Tokens](/bpe-tokens-wiki) for more details.<br/>
/// Can only be set to `0` if `return_likelihoods` is set to `ALL` to get the likelihood of the prompt.
/// </summary>
[global::System.Text.Json.Serialization.JsonPropertyName("max_tokens")]
Expand Down
12 changes: 5 additions & 7 deletions src/libs/Cohere/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ paths:
/v1/chat:
post:
summary: Chat
description: "Generates a text response to a user message.\nTo learn how to use the Chat API and RAG follow our [Text Generation guides](https://docs.cohere.com/docs/chat-api).\n"
description: "Generates a text response to a user message.\nTo learn how to use the Chat API with Streaming and RAG follow our [Text Generation guides](https://docs.cohere.com/docs/chat-api).\n"
operationId: chat
parameters:
- $ref: '#/components/parameters/RequestSource'
Expand Down Expand Up @@ -87,7 +87,7 @@ paths:
type: array
items:
$ref: '#/components/schemas/ChatConnector'
description: "Accepts `{\"id\": \"web-search\"}`, and/or the `\"id\"` for a custom [connector](https://docs.cohere.com/docs/overview-rag-connectors), if you've [created](https://docs.cohere.com/docs/creating-and-deploying-a-connector) one.\n\nWhen specified, the model's reply will be enriched with information found by querying each of the connectors (RAG).\n\nCompatible Deployments: Cohere Platform\n"
description: "Accepts `{\"id\": \"web-search\"}`, and/or the `\"id\"` for a custom [connector](https://docs.cohere.com/docs/connectors), if you've [created](https://docs.cohere.com/docs/creating-and-deploying-a-connector) one.\n\nWhen specified, the model's reply will be enriched with information found by querying each of the connectors (RAG).\n\nCompatible Deployments: Cohere Platform\n"
x-fern-audiences:
- public
search_queries_only:
Expand Down Expand Up @@ -1269,7 +1269,7 @@ paths:
- public
max_tokens:
type: integer
description: "The maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.\n\nThis parameter is off by default, and if it's not specified, the model will continue generating until it emits an EOS completion token.\n\nCan only be set to `0` if `return_likelihoods` is set to `ALL` to get the likelihood of the prompt.\n"
description: "The maximum number of tokens the model will generate as part of the response. Note: Setting a low value may result in incomplete generations.\n\nThis parameter is off by default, and if it's not specified, the model will continue generating until it emits an EOS completion token. See [BPE Tokens](/bpe-tokens-wiki) for more details.\n\nCan only be set to `0` if `return_likelihoods` is set to `ALL` to get the likelihood of the prompt.\n"
writeOnly: true
x-fern-audiences:
- public
Expand Down Expand Up @@ -1496,8 +1496,6 @@ paths:
content:
application/json:
schema:
required:
- texts
type: object
properties:
texts:
Expand Down Expand Up @@ -5556,7 +5554,7 @@ paths:
tags:
- /connectors
summary: Get a Connector
description: 'Retrieve a connector by ID. See [''Connectors''](https://docs.cohere.com/docs/overview-rag-connectors) for more information.'
description: 'Retrieve a connector by ID. See [''Connectors''](https://docs.cohere.com/docs/connectors) for more information.'
operationId: get-connector
parameters:
- name: id
Expand Down Expand Up @@ -5704,7 +5702,7 @@ paths:
tags:
- /connectors
summary: Delete a Connector
description: 'Delete a connector by ID. See [''Connectors''](https://docs.cohere.com/docs/overview-rag-connectors) for more information.'
description: 'Delete a connector by ID. See [''Connectors''](https://docs.cohere.com/docs/connectors) for more information.'
operationId: delete-connector
parameters:
- name: id
Expand Down

0 comments on commit 0b61163

Please sign in to comment.