Skip to content

feat:@coderabbitai #220

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 18, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Chat.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Chatv2.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.CheckAPIKey.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Classify.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Detokenize.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Embed.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Embedv2.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Generate.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Rerank.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Rerankv2.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Summarize.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.CohereClient.Tokenize.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.ConnectorsClient.CreateConnector.g.cs

Large diffs are not rendered by default.

276 changes: 192 additions & 84 deletions src/libs/Cohere/Generated/Cohere.ConnectorsClient.DeleteConnector.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.ConnectorsClient.GetConnector.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.ConnectorsClient.ListConnectors.g.cs

Large diffs are not rendered by default.

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.ConnectorsClient.UpdateConnector.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.DatasetsClient.CreateDataset.g.cs

Large diffs are not rendered by default.

276 changes: 192 additions & 84 deletions src/libs/Cohere/Generated/Cohere.DatasetsClient.DeleteDataset.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.DatasetsClient.GetDataset.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.DatasetsClient.GetDatasetUsage.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.DatasetsClient.ListDatasets.g.cs

Large diffs are not rendered by default.

272 changes: 190 additions & 82 deletions src/libs/Cohere/Generated/Cohere.EmbedJobsClient.CancelEmbedJob.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.EmbedJobsClient.CreateEmbedJob.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.EmbedJobsClient.GetEmbedJob.g.cs

Large diffs are not rendered by default.

284 changes: 196 additions & 88 deletions src/libs/Cohere/Generated/Cohere.EmbedJobsClient.ListEmbedJobs.g.cs

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions src/libs/Cohere/Generated/Cohere.Exceptions.g.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public ApiException(string message, global::System.Net.HttpStatusCode statusCode
/// <param name="message">The error message that explains the reason for the exception.</param>
/// <param name="innerException">The exception that is the cause of the current exception, or a null reference if no inner exception is specified.</param>
/// <param name="statusCode">The HTTP status code of the response.</param>
public ApiException(string message, global::System.Exception innerException, global::System.Net.HttpStatusCode statusCode) : base(message, innerException)
public ApiException(string message, global::System.Exception? innerException, global::System.Net.HttpStatusCode statusCode) : base(message, innerException)
{
StatusCode = statusCode;
}
Expand Down Expand Up @@ -83,7 +83,7 @@ public ApiException(string message, global::System.Net.HttpStatusCode statusCode
/// <param name="message">The error message that explains the reason for the exception.</param>
/// <param name="innerException">The exception that is the cause of the current exception, or a null reference if no inner exception is specified.</param>
/// <param name="statusCode">The HTTP status code of the response.</param>
public ApiException(string message, global::System.Exception innerException, global::System.Net.HttpStatusCode statusCode) : base(message, innerException, statusCode)
public ApiException(string message, global::System.Exception? innerException, global::System.Net.HttpStatusCode statusCode) : base(message, innerException, statusCode)
{
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -108,20 +108,29 @@ partial void ProcessCreateFinetunedModelResponseContent(
if ((int)__response.StatusCode == 400)
{
string? __content_400 = null;
global::System.Exception? __exception_400 = null;
global::Cohere.Error? __value_400 = null;
if (ReadResponseAsString)
try
{
__content_400 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_400 = global::Cohere.Error.FromJson(__content_400, JsonSerializerContext);
if (ReadResponseAsString)
{
__content_400 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_400 = global::Cohere.Error.FromJson(__content_400, JsonSerializerContext);
}
else
{
var __contentStream_400 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_400 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_400, JsonSerializerContext).ConfigureAwait(false);
}
}
else
catch (global::System.Exception __ex)
{
var __contentStream_400 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_400 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_400, JsonSerializerContext).ConfigureAwait(false);
__exception_400 = __ex;
}

throw new global::Cohere.ApiException<global::Cohere.Error>(
message: __content_400 ?? __response.ReasonPhrase ?? string.Empty,
innerException: __exception_400,
statusCode: __response.StatusCode)
{
ResponseBody = __content_400,
Expand All @@ -136,20 +145,29 @@ partial void ProcessCreateFinetunedModelResponseContent(
if ((int)__response.StatusCode == 401)
{
string? __content_401 = null;
global::System.Exception? __exception_401 = null;
global::Cohere.Error? __value_401 = null;
if (ReadResponseAsString)
try
{
__content_401 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_401 = global::Cohere.Error.FromJson(__content_401, JsonSerializerContext);
if (ReadResponseAsString)
{
__content_401 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_401 = global::Cohere.Error.FromJson(__content_401, JsonSerializerContext);
}
else
{
var __contentStream_401 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_401 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_401, JsonSerializerContext).ConfigureAwait(false);
}
}
else
catch (global::System.Exception __ex)
{
var __contentStream_401 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_401 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_401, JsonSerializerContext).ConfigureAwait(false);
__exception_401 = __ex;
}

throw new global::Cohere.ApiException<global::Cohere.Error>(
message: __content_401 ?? __response.ReasonPhrase ?? string.Empty,
innerException: __exception_401,
statusCode: __response.StatusCode)
{
ResponseBody = __content_401,
Expand All @@ -164,20 +182,29 @@ partial void ProcessCreateFinetunedModelResponseContent(
if ((int)__response.StatusCode == 403)
{
string? __content_403 = null;
global::System.Exception? __exception_403 = null;
global::Cohere.Error? __value_403 = null;
if (ReadResponseAsString)
try
{
__content_403 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_403 = global::Cohere.Error.FromJson(__content_403, JsonSerializerContext);
if (ReadResponseAsString)
{
__content_403 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_403 = global::Cohere.Error.FromJson(__content_403, JsonSerializerContext);
}
else
{
var __contentStream_403 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_403 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_403, JsonSerializerContext).ConfigureAwait(false);
}
}
else
catch (global::System.Exception __ex)
{
var __contentStream_403 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_403 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_403, JsonSerializerContext).ConfigureAwait(false);
__exception_403 = __ex;
}

throw new global::Cohere.ApiException<global::Cohere.Error>(
message: __content_403 ?? __response.ReasonPhrase ?? string.Empty,
innerException: __exception_403,
statusCode: __response.StatusCode)
{
ResponseBody = __content_403,
Expand All @@ -192,20 +219,29 @@ partial void ProcessCreateFinetunedModelResponseContent(
if ((int)__response.StatusCode == 404)
{
string? __content_404 = null;
global::System.Exception? __exception_404 = null;
global::Cohere.Error? __value_404 = null;
if (ReadResponseAsString)
try
{
__content_404 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_404 = global::Cohere.Error.FromJson(__content_404, JsonSerializerContext);
if (ReadResponseAsString)
{
__content_404 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_404 = global::Cohere.Error.FromJson(__content_404, JsonSerializerContext);
}
else
{
var __contentStream_404 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_404 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_404, JsonSerializerContext).ConfigureAwait(false);
}
}
else
catch (global::System.Exception __ex)
{
var __contentStream_404 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_404 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_404, JsonSerializerContext).ConfigureAwait(false);
__exception_404 = __ex;
}

throw new global::Cohere.ApiException<global::Cohere.Error>(
message: __content_404 ?? __response.ReasonPhrase ?? string.Empty,
innerException: __exception_404,
statusCode: __response.StatusCode)
{
ResponseBody = __content_404,
Expand All @@ -220,20 +256,29 @@ partial void ProcessCreateFinetunedModelResponseContent(
if ((int)__response.StatusCode == 500)
{
string? __content_500 = null;
global::System.Exception? __exception_500 = null;
global::Cohere.Error? __value_500 = null;
if (ReadResponseAsString)
try
{
__content_500 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_500 = global::Cohere.Error.FromJson(__content_500, JsonSerializerContext);
if (ReadResponseAsString)
{
__content_500 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_500 = global::Cohere.Error.FromJson(__content_500, JsonSerializerContext);
}
else
{
var __contentStream_500 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_500 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_500, JsonSerializerContext).ConfigureAwait(false);
}
}
else
catch (global::System.Exception __ex)
{
var __contentStream_500 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_500 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_500, JsonSerializerContext).ConfigureAwait(false);
__exception_500 = __ex;
}

throw new global::Cohere.ApiException<global::Cohere.Error>(
message: __content_500 ?? __response.ReasonPhrase ?? string.Empty,
innerException: __exception_500,
statusCode: __response.StatusCode)
{
ResponseBody = __content_500,
Expand All @@ -248,20 +293,29 @@ partial void ProcessCreateFinetunedModelResponseContent(
if ((int)__response.StatusCode == 503)
{
string? __content_503 = null;
global::System.Exception? __exception_503 = null;
global::Cohere.Error? __value_503 = null;
if (ReadResponseAsString)
try
{
__content_503 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_503 = global::Cohere.Error.FromJson(__content_503, JsonSerializerContext);
if (ReadResponseAsString)
{
__content_503 = await __response.Content.ReadAsStringAsync(cancellationToken).ConfigureAwait(false);
__value_503 = global::Cohere.Error.FromJson(__content_503, JsonSerializerContext);
}
else
{
var __contentStream_503 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_503 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_503, JsonSerializerContext).ConfigureAwait(false);
}
}
else
catch (global::System.Exception __ex)
{
var __contentStream_503 = await __response.Content.ReadAsStreamAsync(cancellationToken).ConfigureAwait(false);
__value_503 = await global::Cohere.Error.FromJsonStreamAsync(__contentStream_503, JsonSerializerContext).ConfigureAwait(false);
__exception_503 = __ex;
}

throw new global::Cohere.ApiException<global::Cohere.Error>(
message: __content_503 ?? __response.ReasonPhrase ?? string.Empty,
innerException: __exception_503,
statusCode: __response.StatusCode)
{
ResponseBody = __content_503,
Expand Down Expand Up @@ -293,8 +347,12 @@ partial void ProcessCreateFinetunedModelResponseContent(
try
{
__response.EnsureSuccessStatusCode();

return
global::Cohere.CreateFinetunedModelResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
}
catch (global::System.Net.Http.HttpRequestException __ex)
catch (global::System.Exception __ex)
{
throw new global::Cohere.ApiException(
message: __content ?? __response.ReasonPhrase ?? string.Empty,
Expand All @@ -308,18 +366,24 @@ partial void ProcessCreateFinetunedModelResponseContent(
h => h.Value),
};
}

return
global::Cohere.CreateFinetunedModelResponse.FromJson(__content, JsonSerializerContext) ??
throw new global::System.InvalidOperationException($"Response deserialization failed for \"{__content}\" ");
}
else
{
try
{
__response.EnsureSuccessStatusCode();

using var __content = await __response.Content.ReadAsStreamAsync(
#if NET5_0_OR_GREATER
cancellationToken
#endif
).ConfigureAwait(false);

return
await global::Cohere.CreateFinetunedModelResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
}
catch (global::System.Net.Http.HttpRequestException __ex)
catch (global::System.Exception __ex)
{
throw new global::Cohere.ApiException(
message: __response.ReasonPhrase ?? string.Empty,
Expand All @@ -332,16 +396,6 @@ partial void ProcessCreateFinetunedModelResponseContent(
h => h.Value),
};
}

using var __content = await __response.Content.ReadAsStreamAsync(
#if NET5_0_OR_GREATER
cancellationToken
#endif
).ConfigureAwait(false);

return
await global::Cohere.CreateFinetunedModelResponse.FromJsonStreamAsync(__content, JsonSerializerContext).ConfigureAwait(false) ??
throw new global::System.InvalidOperationException("Response deserialization failed.");
}
}

Expand Down
Loading