openai/openai-dotnet
Publicmirrored from https://github.com/openai/openai-dotnetAvailable
src/Custom/Assistants/Streaming/StreamingUpdateReason.cs
130lines · modeblame
79014abcShivangiReja1 years ago | 1 | using System.Diagnostics.CodeAnalysis; |
| 2 | | |
58f93c8dShivangiReja2 years ago | 3 | namespace OpenAI.Assistants; |
9f9f2936Jose Arriaga Maldonado2 years ago | 4 | |
| 5 | /// <summary> | |
| 6 | /// The collection of values associated with the event names of streaming update payloads. These correspond to the | |
| 7 | /// expected downcast data type of the <see cref="StreamingUpdate"/> as well as to the expected data present in the | |
| 8 | /// payload. | |
| 9 | /// </summary> | |
79014abcShivangiReja1 years ago | 10 | [Experimental("OPENAI001")] |
9f9f2936Jose Arriaga Maldonado2 years ago | 11 | public enum StreamingUpdateReason |
| 12 | { | |
| 13 | /// <summary> | |
| 14 | /// Indicates that there is no known reason associated with the streaming update. | |
| 15 | /// </summary> | |
| 16 | Unknown, | |
| 17 | /// <summary> | |
| 18 | /// Indicates that an update was generated as part of a <c>thread.created</c> event. | |
| 19 | /// </summary> | |
| 20 | /// <remarks> This reason is typically only associated with calls to | |
| 21 | /// <see cref="AssistantClient.CreateThreadAndRunStreaming(Assistant, ThreadCreationOptions, RunCreationOptions)"/>, | |
| 22 | /// as other run-related methods operate on a thread that has previously been created. | |
| 23 | /// </remarks> | |
| 24 | ThreadCreated, | |
| 25 | /// <summary> | |
| 26 | /// Indicates that an update was generated as part of a <c>thread.run.created</c> event. | |
| 27 | /// </summary> | |
| 28 | RunCreated, | |
| 29 | /// <summary> | |
| 30 | /// Indicates that an update was generated as part of a <c>thread.run.queued</c> event. | |
| 31 | /// </summary> | |
| 32 | RunQueued, | |
| 33 | /// <summary> | |
| 34 | /// Indicates that an update was generated as part of a <c>thread.run.in_progress</c> event. | |
| 35 | /// </summary> | |
| 36 | RunInProgress, | |
| 37 | /// <summary> | |
| 38 | /// Indicates that an update was generated as part of a <c>thread.run.requires_action</c> event. | |
| 39 | /// </summary> | |
| 40 | /// <remarks> | |
| 41 | /// Note that, if multiple actions occur within a single event, as can be the case with the parallel tool calling, | |
| 42 | /// distinct <see cref="RequiredActionUpdate"/> instances will be generated for each | |
| 43 | /// <see cref="RequiredAction"/>. | |
| 44 | /// </remarks> | |
| 45 | RunRequiresAction, | |
| 46 | /// <summary> | |
| 47 | /// Indicates that an update was generated as part of a <c>thread.run.completed</c> event. | |
| 48 | /// </summary> | |
| 49 | RunCompleted, | |
| 50 | /// <summary> | |
| 51 | /// Indicates that an update was generated as part of a <c>thread.run.incomplete</c> event. | |
| 52 | /// </summary> | |
| 53 | RunIncomplete, | |
| 54 | /// <summary> | |
| 55 | /// Indicates that an update was generated as part of a <c>thread.run.failed</c> event. | |
| 56 | /// </summary> | |
| 57 | RunFailed, | |
| 58 | /// <summary> | |
| 59 | /// Indicates that an update was generated as part of a <c>thread.run.cancelling</c> event. | |
| 60 | /// </summary> | |
| 61 | RunCancelling, | |
| 62 | /// <summary> | |
| 63 | /// Indicates that an update was generated as part of a <c>thread.run.cancelled</c> event. | |
| 64 | /// </summary> | |
| 65 | RunCancelled, | |
| 66 | /// <summary> | |
| 67 | /// Indicates that an update was generated as part of a <c>thread.run.expired</c> event. | |
| 68 | /// </summary> | |
| 69 | RunExpired, | |
| 70 | /// <summary> | |
| 71 | /// Indicates that an update was generated as part of a <c>thread.run.step.created</c> event. | |
| 72 | /// </summary> | |
| 73 | RunStepCreated, | |
| 74 | /// <summary> | |
| 75 | /// Indicates that an update was generated as part of a <c>thread.run.step.in_progress</c> event. | |
| 76 | /// </summary> | |
| 77 | RunStepInProgress, | |
| 78 | /// <summary> | |
| 79 | /// Indicates that an update was generated as part of a <c>thread.run.step.delta</c> event. | |
| 80 | /// </summary> | |
| 81 | RunStepUpdated, | |
| 82 | /// <summary> | |
| 83 | /// Indicates that an update was generated as part of a <c>thread.run.step.completed</c> event. | |
| 84 | /// </summary> | |
| 85 | RunStepCompleted, | |
| 86 | /// <summary> | |
| 87 | /// Indicates that an update was generated as part of a <c>thread.run.step.failed</c> event. | |
| 88 | /// </summary> | |
| 89 | RunStepFailed, | |
| 90 | /// <summary> | |
| 91 | /// Indicates that an update was generated as part of a <c>thread.run.step.cancelled</c> event. | |
| 92 | /// </summary> | |
| 93 | RunStepCancelled, | |
| 94 | /// <summary> | |
| 95 | /// Indicates that an update was generated as part of a <c>thread.run.step.expired</c> event. | |
| 96 | /// </summary> | |
| 97 | RunStepExpired, | |
| 98 | /// <summary> | |
| 99 | /// Indicates that an update was generated as part of a <c>thread.message.created</c> event. | |
| 100 | /// </summary> | |
| 101 | MessageCreated, | |
| 102 | /// <summary> | |
| 103 | /// Indicates that an update was generated as part of a <c>thread.message.in_progress</c> event. | |
| 104 | /// </summary> | |
| 105 | MessageInProgress, | |
| 106 | /// <summary> | |
| 107 | /// Indicates that an update was generated as part of a <c>thread.message.delta</c> event. | |
| 108 | /// </summary> | |
| 109 | /// <remarks> | |
| 110 | /// Distinct <see cref="MessageContentUpdate"/> instances will be created per each content update and/or content | |
| 111 | /// annotation present on the event. | |
| 112 | /// </remarks> | |
| 113 | MessageUpdated, | |
| 114 | /// <summary> | |
| 115 | /// Indicates that an update was generated as part of a <c>thread.message.completed</c> event. | |
| 116 | /// </summary> | |
| 117 | MessageCompleted, | |
| 118 | /// <summary> | |
| 119 | /// Indicates that an update was generated as part of a <c>thread.message.failed</c> event. | |
| 120 | /// </summary> | |
| 121 | MessageFailed, | |
| 122 | /// <summary> | |
| 123 | /// Indicates that an update was generated as part of a <c>thread.message.error</c> event. | |
| 124 | /// </summary> | |
| 125 | Error, | |
| 126 | /// <summary> | |
| 127 | /// Indicates the end of streaming update events. This value should never be typically observed. | |
| 128 | /// </summary> | |
| 129 | Done, | |
| 130 | } |