Skip to content

Commit f8e327e

Browse files
committed
fb
1 parent 2eb2a2a commit f8e327e

22 files changed

+4899
-4396
lines changed

api/OpenAI.net8.0.cs

Lines changed: 91 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4590,10 +4590,51 @@ public class TurnDetectionOptions : IJsonModel<TurnDetectionOptions>, IPersistab
45904590
}
45914591
}
45924592
namespace OpenAI.Responses {
4593+
public class AutomaticCodeInterpreterContainerConfiguration : CodeInterpreterContainerConfiguration {
4594+
public AutomaticCodeInterpreterContainerConfiguration(IEnumerable<string> fileIds = null);
4595+
public IList<string> FileIds { get; }
4596+
}
4597+
[Experimental("OPENAI001")]
4598+
public class CodeInterpreterCallResponseItem : ResponseItem, IJsonModel<CodeInterpreterCallResponseItem>, IPersistableModel<CodeInterpreterCallResponseItem> {
4599+
public CodeInterpreterCallResponseItem(CodeInterpreterCallStatus status, string code, IEnumerable<BinaryData> results);
4600+
public string Code { get; set; }
4601+
public string ContainerId { get; set; }
4602+
public IList<BinaryData> Results { get; }
4603+
public CodeInterpreterCallStatus Status { get; set; }
4604+
protected override ResponseItem JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4605+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4606+
protected override ResponseItem PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4607+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4608+
}
4609+
[Experimental("OPENAI001")]
4610+
public readonly partial struct CodeInterpreterCallStatus : IEquatable<CodeInterpreterCallStatus> {
4611+
public CodeInterpreterCallStatus(string value);
4612+
public static CodeInterpreterCallStatus Completed { get; }
4613+
public static CodeInterpreterCallStatus InProgress { get; }
4614+
public static CodeInterpreterCallStatus Interpreting { get; }
4615+
public readonly bool Equals(CodeInterpreterCallStatus other);
4616+
[EditorBrowsable(EditorBrowsableState.Never)]
4617+
public override readonly bool Equals(object obj);
4618+
[EditorBrowsable(EditorBrowsableState.Never)]
4619+
public override readonly int GetHashCode();
4620+
public static bool operator ==(CodeInterpreterCallStatus left, CodeInterpreterCallStatus right);
4621+
public static implicit operator CodeInterpreterCallStatus(string value);
4622+
public static implicit operator CodeInterpreterCallStatus?(string value);
4623+
public static bool operator !=(CodeInterpreterCallStatus left, CodeInterpreterCallStatus right);
4624+
public override readonly string ToString();
4625+
}
4626+
public class CodeInterpreterContainer {
4627+
public CodeInterpreterContainer(CodeInterpreterContainerConfiguration containerConfiguration);
4628+
public CodeInterpreterContainer(string containerId);
4629+
public CodeInterpreterContainerConfiguration ContainerConfiguration { get; }
4630+
public string ContainerId { get; }
4631+
}
4632+
public class CodeInterpreterContainerConfiguration {
4633+
public static AutomaticCodeInterpreterContainerConfiguration CreateAutomaticConfiguration(IEnumerable<string> fileIds = null);
4634+
}
45934635
[Experimental("OPENAI001")]
45944636
public class CodeInterpreterTool : ResponseTool, IJsonModel<CodeInterpreterTool>, IPersistableModel<CodeInterpreterTool> {
4595-
public CodeInterpreterTool(BinaryData container);
4596-
public BinaryData Container { get; set; }
4637+
public CodeInterpreterContainer Container { get; }
45974638
protected override ResponseTool JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
45984639
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
45994640
protected override ResponseTool PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
@@ -5484,8 +5525,7 @@ public class ResponseTokenUsage : IJsonModel<ResponseTokenUsage>, IPersistableMo
54845525
}
54855526
[Experimental("OPENAI001")]
54865527
public class ResponseTool : IJsonModel<ResponseTool>, IPersistableModel<ResponseTool> {
5487-
public static CodeInterpreterTool CreateCodeInterpreterTool(IEnumerable<string> fileIds = null);
5488-
public static CodeInterpreterTool CreateCodeInterpreterTool(string containerId);
5528+
public static CodeInterpreterTool CreateCodeInterpreterTool(CodeInterpreterContainer container);
54895529
[Experimental("OPENAICUA001")]
54905530
public static ComputerTool CreateComputerTool(ComputerToolEnvironment environment, int displayWidth, int displayHeight);
54915531
public static FileSearchTool CreateFileSearchTool(IEnumerable<string> vectorStoreIds, int? maxResultCount = null, FileSearchToolRankingOptions rankingOptions = null, BinaryData filters = null);
@@ -5538,6 +5578,53 @@ public enum ResponseToolChoiceKind {
55385578
public override readonly string ToString();
55395579
}
55405580
[Experimental("OPENAI001")]
5581+
public class StreamingResponseCodeInterpreterCallCodeDeltaUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallCodeDeltaUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallCodeDeltaUpdate> {
5582+
public string Delta { get; }
5583+
public string ItemId { get; }
5584+
public int OutputIndex { get; }
5585+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
5586+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
5587+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
5588+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
5589+
}
5590+
[Experimental("OPENAI001")]
5591+
public class StreamingResponseCodeInterpreterCallCodeDoneUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallCodeDoneUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallCodeDoneUpdate> {
5592+
public string Code { get; }
5593+
public string ItemId { get; }
5594+
public int OutputIndex { get; }
5595+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
5596+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
5597+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
5598+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
5599+
}
5600+
[Experimental("OPENAI001")]
5601+
public class StreamingResponseCodeInterpreterCallCompletedUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallCompletedUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallCompletedUpdate> {
5602+
public string ItemId { get; }
5603+
public int OutputIndex { get; }
5604+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
5605+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
5606+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
5607+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
5608+
}
5609+
[Experimental("OPENAI001")]
5610+
public class StreamingResponseCodeInterpreterCallInProgressUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallInProgressUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallInProgressUpdate> {
5611+
public string ItemId { get; }
5612+
public long OutputIndex { get; }
5613+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
5614+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
5615+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
5616+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
5617+
}
5618+
[Experimental("OPENAI001")]
5619+
public class StreamingResponseCodeInterpreterCallInterpretingUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallInterpretingUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallInterpretingUpdate> {
5620+
public string ItemId { get; }
5621+
public int OutputIndex { get; }
5622+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
5623+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
5624+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
5625+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
5626+
}
5627+
[Experimental("OPENAI001")]
55415628
public class StreamingResponseCompletedUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCompletedUpdate>, IPersistableModel<StreamingResponseCompletedUpdate> {
55425629
public OpenAIResponse Response { get; }
55435630
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);

api/OpenAI.netstandard2.0.cs

Lines changed: 84 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4023,9 +4023,48 @@ public class TurnDetectionOptions : IJsonModel<TurnDetectionOptions>, IPersistab
40234023
}
40244024
}
40254025
namespace OpenAI.Responses {
4026+
public class AutomaticCodeInterpreterContainerConfiguration : CodeInterpreterContainerConfiguration {
4027+
public AutomaticCodeInterpreterContainerConfiguration(IEnumerable<string> fileIds = null);
4028+
public IList<string> FileIds { get; }
4029+
}
4030+
public class CodeInterpreterCallResponseItem : ResponseItem, IJsonModel<CodeInterpreterCallResponseItem>, IPersistableModel<CodeInterpreterCallResponseItem> {
4031+
public CodeInterpreterCallResponseItem(CodeInterpreterCallStatus status, string code, IEnumerable<BinaryData> results);
4032+
public string Code { get; set; }
4033+
public string ContainerId { get; set; }
4034+
public IList<BinaryData> Results { get; }
4035+
public CodeInterpreterCallStatus Status { get; set; }
4036+
protected override ResponseItem JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4037+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4038+
protected override ResponseItem PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4039+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4040+
}
4041+
public readonly partial struct CodeInterpreterCallStatus : IEquatable<CodeInterpreterCallStatus> {
4042+
public CodeInterpreterCallStatus(string value);
4043+
public static CodeInterpreterCallStatus Completed { get; }
4044+
public static CodeInterpreterCallStatus InProgress { get; }
4045+
public static CodeInterpreterCallStatus Interpreting { get; }
4046+
public readonly bool Equals(CodeInterpreterCallStatus other);
4047+
[EditorBrowsable(EditorBrowsableState.Never)]
4048+
public override readonly bool Equals(object obj);
4049+
[EditorBrowsable(EditorBrowsableState.Never)]
4050+
public override readonly int GetHashCode();
4051+
public static bool operator ==(CodeInterpreterCallStatus left, CodeInterpreterCallStatus right);
4052+
public static implicit operator CodeInterpreterCallStatus(string value);
4053+
public static implicit operator CodeInterpreterCallStatus?(string value);
4054+
public static bool operator !=(CodeInterpreterCallStatus left, CodeInterpreterCallStatus right);
4055+
public override readonly string ToString();
4056+
}
4057+
public class CodeInterpreterContainer {
4058+
public CodeInterpreterContainer(CodeInterpreterContainerConfiguration containerConfiguration);
4059+
public CodeInterpreterContainer(string containerId);
4060+
public CodeInterpreterContainerConfiguration ContainerConfiguration { get; }
4061+
public string ContainerId { get; }
4062+
}
4063+
public class CodeInterpreterContainerConfiguration {
4064+
public static AutomaticCodeInterpreterContainerConfiguration CreateAutomaticConfiguration(IEnumerable<string> fileIds = null);
4065+
}
40264066
public class CodeInterpreterTool : ResponseTool, IJsonModel<CodeInterpreterTool>, IPersistableModel<CodeInterpreterTool> {
4027-
public CodeInterpreterTool(BinaryData container);
4028-
public BinaryData Container { get; set; }
4067+
public CodeInterpreterContainer Container { get; }
40294068
protected override ResponseTool JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
40304069
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
40314070
protected override ResponseTool PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
@@ -4842,8 +4881,7 @@ public class ResponseTokenUsage : IJsonModel<ResponseTokenUsage>, IPersistableMo
48424881
protected virtual BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
48434882
}
48444883
public class ResponseTool : IJsonModel<ResponseTool>, IPersistableModel<ResponseTool> {
4845-
public static CodeInterpreterTool CreateCodeInterpreterTool(IEnumerable<string> fileIds = null);
4846-
public static CodeInterpreterTool CreateCodeInterpreterTool(string containerId);
4884+
public static CodeInterpreterTool CreateCodeInterpreterTool(CodeInterpreterContainer container);
48474885
public static ComputerTool CreateComputerTool(ComputerToolEnvironment environment, int displayWidth, int displayHeight);
48484886
public static FileSearchTool CreateFileSearchTool(IEnumerable<string> vectorStoreIds, int? maxResultCount = null, FileSearchToolRankingOptions rankingOptions = null, BinaryData filters = null);
48494887
public static FunctionTool CreateFunctionTool(string functionName, BinaryData functionParameters, bool? strictModeEnabled, string functionDescription = null);
@@ -4890,6 +4928,48 @@ public enum ResponseToolChoiceKind {
48904928
public static bool operator !=(ResponseTruncationMode left, ResponseTruncationMode right);
48914929
public override readonly string ToString();
48924930
}
4931+
public class StreamingResponseCodeInterpreterCallCodeDeltaUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallCodeDeltaUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallCodeDeltaUpdate> {
4932+
public string Delta { get; }
4933+
public string ItemId { get; }
4934+
public int OutputIndex { get; }
4935+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4936+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4937+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4938+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4939+
}
4940+
public class StreamingResponseCodeInterpreterCallCodeDoneUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallCodeDoneUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallCodeDoneUpdate> {
4941+
public string Code { get; }
4942+
public string ItemId { get; }
4943+
public int OutputIndex { get; }
4944+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4945+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4946+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4947+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4948+
}
4949+
public class StreamingResponseCodeInterpreterCallCompletedUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallCompletedUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallCompletedUpdate> {
4950+
public string ItemId { get; }
4951+
public int OutputIndex { get; }
4952+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4953+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4954+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4955+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4956+
}
4957+
public class StreamingResponseCodeInterpreterCallInProgressUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallInProgressUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallInProgressUpdate> {
4958+
public string ItemId { get; }
4959+
public long OutputIndex { get; }
4960+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4961+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4962+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4963+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4964+
}
4965+
public class StreamingResponseCodeInterpreterCallInterpretingUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCodeInterpreterCallInterpretingUpdate>, IPersistableModel<StreamingResponseCodeInterpreterCallInterpretingUpdate> {
4966+
public string ItemId { get; }
4967+
public int OutputIndex { get; }
4968+
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);
4969+
protected override void JsonModelWriteCore(Utf8JsonWriter writer, ModelReaderWriterOptions options);
4970+
protected override StreamingResponseUpdate PersistableModelCreateCore(BinaryData data, ModelReaderWriterOptions options);
4971+
protected override BinaryData PersistableModelWriteCore(ModelReaderWriterOptions options);
4972+
}
48934973
public class StreamingResponseCompletedUpdate : StreamingResponseUpdate, IJsonModel<StreamingResponseCompletedUpdate>, IPersistableModel<StreamingResponseCompletedUpdate> {
48944974
public OpenAIResponse Response { get; }
48954975
protected override StreamingResponseUpdate JsonModelCreateCore(ref Utf8JsonReader reader, ModelReaderWriterOptions options);

0 commit comments

Comments
 (0)