-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(specs): add transformation copilot to ingestion (generated)
algolia/api-clients-automation#3479 Co-authored-by: algolia-bot <accounts+algolia-api-client-bot@algolia.com> Co-authored-by: Thomas Raffray <Fluf22@users.noreply.github.com>
- Loading branch information
1 parent
412b1b3
commit b802d68
Showing
3 changed files
with
309 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,151 @@ | ||
// | ||
// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT. | ||
// | ||
using System; | ||
using System.Text; | ||
using System.Linq; | ||
using System.Text.Json.Serialization; | ||
using System.Collections.Generic; | ||
using Algolia.Search.Serializer; | ||
using System.Text.Json; | ||
|
||
namespace Algolia.Search.Models.Ingestion; | ||
|
||
/// <summary> | ||
/// Model | ||
/// </summary> | ||
public partial class Model | ||
{ | ||
/// <summary> | ||
/// Initializes a new instance of the Model class. | ||
/// </summary> | ||
[JsonConstructor] | ||
public Model() { } | ||
/// <summary> | ||
/// Initializes a new instance of the Model class. | ||
/// </summary> | ||
/// <param name="fullname">fullname (required).</param> | ||
/// <param name="modelName">modelName (required).</param> | ||
/// <param name="systemPrompt">systemPrompt (required).</param> | ||
/// <param name="id">id (required).</param> | ||
/// <param name="provider">provider (required).</param> | ||
public Model(string fullname, string modelName, string systemPrompt, string id, string provider) | ||
{ | ||
Fullname = fullname ?? throw new ArgumentNullException(nameof(fullname)); | ||
ModelName = modelName ?? throw new ArgumentNullException(nameof(modelName)); | ||
SystemPrompt = systemPrompt ?? throw new ArgumentNullException(nameof(systemPrompt)); | ||
Id = id ?? throw new ArgumentNullException(nameof(id)); | ||
Provider = provider ?? throw new ArgumentNullException(nameof(provider)); | ||
} | ||
|
||
/// <summary> | ||
/// Gets or Sets Fullname | ||
/// </summary> | ||
[JsonPropertyName("fullname")] | ||
public string Fullname { get; set; } | ||
|
||
/// <summary> | ||
/// Gets or Sets ModelName | ||
/// </summary> | ||
[JsonPropertyName("modelName")] | ||
public string ModelName { get; set; } | ||
|
||
/// <summary> | ||
/// Gets or Sets SystemPrompt | ||
/// </summary> | ||
[JsonPropertyName("systemPrompt")] | ||
public string SystemPrompt { get; set; } | ||
|
||
/// <summary> | ||
/// Gets or Sets Id | ||
/// </summary> | ||
[JsonPropertyName("id")] | ||
public string Id { get; set; } | ||
|
||
/// <summary> | ||
/// Gets or Sets Provider | ||
/// </summary> | ||
[JsonPropertyName("provider")] | ||
public string Provider { get; set; } | ||
|
||
/// <summary> | ||
/// Returns the string presentation of the object | ||
/// </summary> | ||
/// <returns>String presentation of the object</returns> | ||
public override string ToString() | ||
{ | ||
StringBuilder sb = new StringBuilder(); | ||
sb.Append("class Model {\n"); | ||
sb.Append(" Fullname: ").Append(Fullname).Append("\n"); | ||
sb.Append(" ModelName: ").Append(ModelName).Append("\n"); | ||
sb.Append(" SystemPrompt: ").Append(SystemPrompt).Append("\n"); | ||
sb.Append(" Id: ").Append(Id).Append("\n"); | ||
sb.Append(" Provider: ").Append(Provider).Append("\n"); | ||
sb.Append("}\n"); | ||
return sb.ToString(); | ||
} | ||
|
||
/// <summary> | ||
/// Returns the JSON string presentation of the object | ||
/// </summary> | ||
/// <returns>JSON string presentation of the object</returns> | ||
public virtual string ToJson() | ||
{ | ||
return JsonSerializer.Serialize(this, JsonConfig.Options); | ||
} | ||
|
||
/// <summary> | ||
/// Returns true if objects are equal | ||
/// </summary> | ||
/// <param name="obj">Object to be compared</param> | ||
/// <returns>Boolean</returns> | ||
public override bool Equals(object obj) | ||
{ | ||
if (obj is not Model input) | ||
{ | ||
return false; | ||
} | ||
|
||
return | ||
(Fullname == input.Fullname || (Fullname != null && Fullname.Equals(input.Fullname))) && | ||
(ModelName == input.ModelName || (ModelName != null && ModelName.Equals(input.ModelName))) && | ||
(SystemPrompt == input.SystemPrompt || (SystemPrompt != null && SystemPrompt.Equals(input.SystemPrompt))) && | ||
(Id == input.Id || (Id != null && Id.Equals(input.Id))) && | ||
(Provider == input.Provider || (Provider != null && Provider.Equals(input.Provider))); | ||
} | ||
|
||
/// <summary> | ||
/// Gets the hash code | ||
/// </summary> | ||
/// <returns>Hash code</returns> | ||
public override int GetHashCode() | ||
{ | ||
unchecked // Overflow is fine, just wrap | ||
{ | ||
int hashCode = 41; | ||
if (Fullname != null) | ||
{ | ||
hashCode = (hashCode * 59) + Fullname.GetHashCode(); | ||
} | ||
if (ModelName != null) | ||
{ | ||
hashCode = (hashCode * 59) + ModelName.GetHashCode(); | ||
} | ||
if (SystemPrompt != null) | ||
{ | ||
hashCode = (hashCode * 59) + SystemPrompt.GetHashCode(); | ||
} | ||
if (Id != null) | ||
{ | ||
hashCode = (hashCode * 59) + Id.GetHashCode(); | ||
} | ||
if (Provider != null) | ||
{ | ||
hashCode = (hashCode * 59) + Provider.GetHashCode(); | ||
} | ||
return hashCode; | ||
} | ||
} | ||
|
||
} | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,95 @@ | ||
// | ||
// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost - read more on https://github.com/algolia/api-clients-automation. DO NOT EDIT. | ||
// | ||
using System; | ||
using System.Text; | ||
using System.Linq; | ||
using System.Text.Json.Serialization; | ||
using System.Collections.Generic; | ||
using Algolia.Search.Serializer; | ||
using System.Text.Json; | ||
|
||
namespace Algolia.Search.Models.Ingestion; | ||
|
||
/// <summary> | ||
/// List of available AI models for transformation purposes. | ||
/// </summary> | ||
public partial class TransformationModels | ||
{ | ||
/// <summary> | ||
/// Initializes a new instance of the TransformationModels class. | ||
/// </summary> | ||
[JsonConstructor] | ||
public TransformationModels() { } | ||
/// <summary> | ||
/// Initializes a new instance of the TransformationModels class. | ||
/// </summary> | ||
/// <param name="llms">llms (required).</param> | ||
public TransformationModels(List<Model> llms) | ||
{ | ||
Llms = llms ?? throw new ArgumentNullException(nameof(llms)); | ||
} | ||
|
||
/// <summary> | ||
/// Gets or Sets Llms | ||
/// </summary> | ||
[JsonPropertyName("llms")] | ||
public List<Model> Llms { get; set; } | ||
|
||
/// <summary> | ||
/// Returns the string presentation of the object | ||
/// </summary> | ||
/// <returns>String presentation of the object</returns> | ||
public override string ToString() | ||
{ | ||
StringBuilder sb = new StringBuilder(); | ||
sb.Append("class TransformationModels {\n"); | ||
sb.Append(" Llms: ").Append(Llms).Append("\n"); | ||
sb.Append("}\n"); | ||
return sb.ToString(); | ||
} | ||
|
||
/// <summary> | ||
/// Returns the JSON string presentation of the object | ||
/// </summary> | ||
/// <returns>JSON string presentation of the object</returns> | ||
public virtual string ToJson() | ||
{ | ||
return JsonSerializer.Serialize(this, JsonConfig.Options); | ||
} | ||
|
||
/// <summary> | ||
/// Returns true if objects are equal | ||
/// </summary> | ||
/// <param name="obj">Object to be compared</param> | ||
/// <returns>Boolean</returns> | ||
public override bool Equals(object obj) | ||
{ | ||
if (obj is not TransformationModels input) | ||
{ | ||
return false; | ||
} | ||
|
||
return | ||
(Llms == input.Llms || Llms != null && input.Llms != null && Llms.SequenceEqual(input.Llms)); | ||
} | ||
|
||
/// <summary> | ||
/// Gets the hash code | ||
/// </summary> | ||
/// <returns>Hash code</returns> | ||
public override int GetHashCode() | ||
{ | ||
unchecked // Overflow is fine, just wrap | ||
{ | ||
int hashCode = 41; | ||
if (Llms != null) | ||
{ | ||
hashCode = (hashCode * 59) + Llms.GetHashCode(); | ||
} | ||
return hashCode; | ||
} | ||
} | ||
|
||
} | ||
|