openai/openai-dotnet

Public

mirrored from https://github.com/openai/openai-dotnetAvailable

CodeCommitsIssuesPull requestsActionsInsightsSecurity
OpenAI_2.0.0-beta.1

Branches

Tags

  • No tags available.
0Branches0Tags
Go to file
Add file
Code

Clone

HTTPS

Download ZIP

src/Custom/Assistants/AssistantModificationOptions.cs

43lines · modecode

1using System.Collections.Generic;
2
3namespace OpenAI.Assistants;
4
5/// <summary>
6/// Represents additional options available when modifying an existing <see cref="Assistant"/>.
7/// </summary>
8[CodeGenModel("ModifyAssistantRequest")]
9public partial class AssistantModificationOptions
10{
11 /// <summary>
12 /// The replacement model that the assistant should use.
13 /// </summary>
14 public string Model { get; init; }
15
16 /// <summary>
17 /// <para>
18 /// A list of tool enabled on the assistant.
19 /// </para>
20 /// There can be a maximum of 128 tools per assistant. Tools can be of types `code_interpreter`, `file_search`, or `function`.
21 /// </summary>
22 [CodeGenMember("Tools")]
23 public IList<ToolDefinition> DefaultTools { get; init; } = new ChangeTrackingList<ToolDefinition>();
24
25 // CUSTOM: reuse common request/response models for tool resources. Note that modification operations use the
26 // response models (which do not contain resource initialization helpers).
27
28 /// <inheritdoc cref="ToolResources"/>
29 [CodeGenMember("ToolResources")]
30 public ToolResources ToolResources { get; init; }
31
32 /// <inheritdoc cref="AssistantResponseFormat"/>
33 [CodeGenMember("ResponseFormat")]
34 public AssistantResponseFormat ResponseFormat { get; init; }
35
36 /// <summary>
37 /// An alternative to sampling with temperature, called nucleus sampling, where the model considers the results of the tokens with top_p probability mass. So 0.1 means only the tokens comprising the top 10% probability mass are considered.
38 ///
39 /// We generally recommend altering this or temperature but not both.
40 /// </summary>
41 [CodeGenMember("TopP")]
42 public float? NucleusSamplingFactor { get; init; }
43}