Skip to content

Commit f1829df

Browse files
committed
test: Updated snapshot tests
1 parent 81ed468 commit f1829df

17,673 files changed

Lines changed: 637679 additions & 168381 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#AnyOf.2.g.verified.cs

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -29,37 +29,36 @@ namespace G
2929
/// <summary>
3030
///
3131
/// </summary>
32-
public static implicit operator AnyOf<T1, T2>(T1 value) => new AnyOf<T1, T2>((T1?)value);
32+
#if NET6_0_OR_GREATER
33+
public T2? Value2 { get; init; }
34+
#else
35+
public T2? Value2 { get; }
36+
#endif
3337

3438
/// <summary>
3539
///
3640
/// </summary>
37-
public static implicit operator T1?(AnyOf<T1, T2> @this) => @this.Value1;
38-
41+
#if NET6_0_OR_GREATER
42+
[global::System.Diagnostics.CodeAnalysis.MemberNotNullWhen(true, nameof(Value2))]
43+
#endif
44+
public bool IsValue2 => Value2 != null;
3945
/// <summary>
4046
///
4147
/// </summary>
42-
public AnyOf(T1? value)
43-
{
44-
Value1 = value;
45-
}
48+
public static implicit operator AnyOf<T1, T2>(T1 value) => new AnyOf<T1, T2>((T1?)value);
4649

4750
/// <summary>
4851
///
4952
/// </summary>
50-
#if NET6_0_OR_GREATER
51-
public T2? Value2 { get; init; }
52-
#else
53-
public T2? Value2 { get; }
54-
#endif
53+
public static implicit operator T1?(AnyOf<T1, T2> @this) => @this.Value1;
5554

5655
/// <summary>
5756
///
5857
/// </summary>
59-
#if NET6_0_OR_GREATER
60-
[global::System.Diagnostics.CodeAnalysis.MemberNotNullWhen(true, nameof(Value2))]
61-
#endif
62-
public bool IsValue2 => Value2 != null;
58+
public AnyOf(T1? value)
59+
{
60+
Value1 = value;
61+
}
6362

6463
/// <summary>
6564
///

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.Api.g.verified.cs

Lines changed: 84 additions & 94 deletions
Large diffs are not rendered by default.

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.Commands.BetaMessagesCountTokensPostCommand.g.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ partial void Validate(
1515
string? anthropicBeta,
1616
string? anthropicVersion,
1717
global::G.BetaToolChoice? toolChoice,
18-
global::System.Collections.Generic.IList<global::G.ToolsItem>? tools,
18+
global::System.Collections.Generic.IList<global::G.OneOf<global::G.BetaTool, global::G.BetaComputerUseTool20241022, global::G.BetaBashTool20241022, global::G.BetaTextEditor20241022, global::G.BetaComputerUseTool20250124, global::G.BetaBashTool20250124, global::G.BetaTextEditor20250124>>? tools,
1919
global::System.Collections.Generic.IList<global::G.BetaInputMessage> messages,
2020
global::G.AnyOf<string, global::System.Collections.Generic.IList<global::G.BetaRequestTextBlock>>? system,
2121
global::G.BetaThinkingConfigParam? thinking,
@@ -123,7 +123,7 @@ Read more about versioning and our version history [here](https://docs.anthropic
123123
Description = @"How the model should use the provided tools. The model can use a specific tool, any available tool, or decide by itself.",
124124
};
125125

126-
private global::System.CommandLine.Option<global::System.Collections.Generic.IList<global::G.ToolsItem>?> Tools { get; } = new(
126+
private global::System.CommandLine.Option<global::System.Collections.Generic.IList<global::G.OneOf<global::G.BetaTool, global::G.BetaComputerUseTool20241022, global::G.BetaBashTool20241022, global::G.BetaTextEditor20241022, global::G.BetaComputerUseTool20250124, global::G.BetaBashTool20250124, global::G.BetaTextEditor20250124>>?> Tools { get; } = new(
127127
name: "tools")
128128
{
129129
Description = @"Definitions of tools that the model may use.

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.Commands.BetaMessagesPostCommand.g.verified.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ partial void Validate(
2424
double? temperature,
2525
global::G.BetaThinkingConfigParam? thinking,
2626
global::G.BetaToolChoice? toolChoice,
27-
global::System.Collections.Generic.IList<global::G.ToolsItem2>? tools,
27+
global::System.Collections.Generic.IList<global::G.OneOf<global::G.BetaTool, global::G.BetaComputerUseTool20241022, global::G.BetaBashTool20241022, global::G.BetaTextEditor20241022, global::G.BetaComputerUseTool20250124, global::G.BetaBashTool20250124, global::G.BetaTextEditor20250124>>? tools,
2828
int? topK,
2929
double? topP,
3030
global::System.Threading.CancellationToken cancellationToken);
@@ -192,7 +192,7 @@ Read more about versioning and our version history [here](https://docs.anthropic
192192
Description = @"How the model should use the provided tools. The model can use a specific tool, any available tool, or decide by itself.",
193193
};
194194

195-
private global::System.CommandLine.Option<global::System.Collections.Generic.IList<global::G.ToolsItem2>?> Tools { get; } = new(
195+
private global::System.CommandLine.Option<global::System.Collections.Generic.IList<global::G.OneOf<global::G.BetaTool, global::G.BetaComputerUseTool20241022, global::G.BetaBashTool20241022, global::G.BetaTextEditor20241022, global::G.BetaComputerUseTool20250124, global::G.BetaBashTool20250124, global::G.BetaTextEditor20250124>>?> Tools { get; } = new(
196196
name: "tools")
197197
{
198198
Description = @"Definitions of tools that the model may use.

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.IMessagesClient.BetaMessagesCountTokensPost.g.verified.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,7 @@ public partial interface IMessagesClient
146146
/// </param>
147147
/// <param name="system">
148148
/// System prompt.<br/>
149-
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).<br/>
150-
/// Example: []
149+
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).
151150
/// </param>
152151
/// <param name="thinking">
153152
/// Configuration for enabling Claude's extended thinking. <br/>
@@ -167,7 +166,7 @@ public partial interface IMessagesClient
167166
string? anthropicBeta = default,
168167
string? anthropicVersion = default,
169168
global::G.BetaToolChoice? toolChoice = default,
170-
global::System.Collections.Generic.IList<global::G.ToolsItem>? tools = default,
169+
global::System.Collections.Generic.IList<global::G.OneOf<global::G.BetaTool, global::G.BetaComputerUseTool20241022, global::G.BetaBashTool20241022, global::G.BetaTextEditor20241022, global::G.BetaComputerUseTool20250124, global::G.BetaBashTool20250124, global::G.BetaTextEditor20250124>>? tools = default,
171170
global::G.AnyOf<string, global::System.Collections.Generic.IList<global::G.BetaRequestTextBlock>>? system = default,
172171
global::G.BetaThinkingConfigParam? thinking = default,
173172
global::System.Threading.CancellationToken cancellationToken = default);

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.IMessagesClient.BetaMessagesPost.g.verified.cs

Lines changed: 6 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -97,8 +97,7 @@ public partial interface IMessagesClient
9797
/// <param name="maxTokens">
9898
/// The maximum number of tokens to generate before stopping.<br/>
9999
/// Note that our models may stop _before_ reaching this maximum. This parameter only specifies the absolute maximum number of tokens to generate.<br/>
100-
/// Different models have different maximum values for this parameter. See [models](https://docs.anthropic.com/en/docs/models-overview) for details.<br/>
101-
/// Example: 1024
100+
/// Different models have different maximum values for this parameter. See [models](https://docs.anthropic.com/en/docs/models-overview) for details.
102101
/// </param>
103102
/// <param name="metadata">
104103
/// An object describing metadata about the request.
@@ -114,14 +113,12 @@ public partial interface IMessagesClient
114113
/// </param>
115114
/// <param name="system">
116115
/// System prompt.<br/>
117-
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).<br/>
118-
/// Example: []
116+
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).
119117
/// </param>
120118
/// <param name="temperature">
121119
/// Amount of randomness injected into the response.<br/>
122120
/// Defaults to `1.0`. Ranges from `0.0` to `1.0`. Use `temperature` closer to `0.0` for analytical / multiple choice, and closer to `1.0` for creative and generative tasks.<br/>
123-
/// Note that even with `temperature` of `0.0`, the results will not be fully deterministic.<br/>
124-
/// Example: 1
121+
/// Note that even with `temperature` of `0.0`, the results will not be fully deterministic.
125122
/// </param>
126123
/// <param name="thinking">
127124
/// Configuration for enabling Claude's extended thinking. <br/>
@@ -184,14 +181,12 @@ public partial interface IMessagesClient
184181
/// <param name="topK">
185182
/// Only sample from the top K options for each subsequent token.<br/>
186183
/// Used to remove "long tail" low probability responses. [Learn more technical details here](https://towardsdatascience.com/how-to-sample-from-language-models-682bceb97277).<br/>
187-
/// Recommended for advanced use cases only. You usually only need to use `temperature`.<br/>
188-
/// Example: 5
184+
/// Recommended for advanced use cases only. You usually only need to use `temperature`.
189185
/// </param>
190186
/// <param name="topP">
191187
/// Use nucleus sampling.<br/>
192188
/// In nucleus sampling, we compute the cumulative distribution over all the options for each subsequent token in decreasing probability order and cut it off once it reaches a particular probability specified by `top_p`. You should either alter `temperature` or `top_p`, but not both.<br/>
193-
/// Recommended for advanced use cases only. You usually only need to use `temperature`.<br/>
194-
/// Example: 0.7
189+
/// Recommended for advanced use cases only. You usually only need to use `temperature`.
195190
/// </param>
196191
/// <param name="cancellationToken">The token to cancel the operation with</param>
197192
/// <exception cref="global::System.InvalidOperationException"></exception>
@@ -210,7 +205,7 @@ public partial interface IMessagesClient
210205
double? temperature = default,
211206
global::G.BetaThinkingConfigParam? thinking = default,
212207
global::G.BetaToolChoice? toolChoice = default,
213-
global::System.Collections.Generic.IList<global::G.ToolsItem2>? tools = default,
208+
global::System.Collections.Generic.IList<global::G.OneOf<global::G.BetaTool, global::G.BetaComputerUseTool20241022, global::G.BetaBashTool20241022, global::G.BetaTextEditor20241022, global::G.BetaComputerUseTool20250124, global::G.BetaBashTool20250124, global::G.BetaTextEditor20250124>>? tools = default,
214209
int? topK = default,
215210
double? topP = default,
216211
global::System.Threading.CancellationToken cancellationToken = default);

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.IMessagesClient.MessagesCountTokensPost.g.verified.cs

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,8 +137,7 @@ public partial interface IMessagesClient
137137
/// </param>
138138
/// <param name="system">
139139
/// System prompt.<br/>
140-
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).<br/>
141-
/// Example: []
140+
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).
142141
/// </param>
143142
/// <param name="thinking">
144143
/// Configuration for enabling Claude's extended thinking. <br/>

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.IMessagesClient.MessagesPost.g.verified.cs

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -88,8 +88,7 @@ public partial interface IMessagesClient
8888
/// <param name="maxTokens">
8989
/// The maximum number of tokens to generate before stopping.<br/>
9090
/// Note that our models may stop _before_ reaching this maximum. This parameter only specifies the absolute maximum number of tokens to generate.<br/>
91-
/// Different models have different maximum values for this parameter. See [models](https://docs.anthropic.com/en/docs/models-overview) for details.<br/>
92-
/// Example: 1024
91+
/// Different models have different maximum values for this parameter. See [models](https://docs.anthropic.com/en/docs/models-overview) for details.
9392
/// </param>
9493
/// <param name="metadata">
9594
/// An object describing metadata about the request.
@@ -105,14 +104,12 @@ public partial interface IMessagesClient
105104
/// </param>
106105
/// <param name="system">
107106
/// System prompt.<br/>
108-
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).<br/>
109-
/// Example: []
107+
/// A system prompt is a way of providing context and instructions to Claude, such as specifying a particular goal or role. See our [guide to system prompts](https://docs.anthropic.com/en/docs/system-prompts).
110108
/// </param>
111109
/// <param name="temperature">
112110
/// Amount of randomness injected into the response.<br/>
113111
/// Defaults to `1.0`. Ranges from `0.0` to `1.0`. Use `temperature` closer to `0.0` for analytical / multiple choice, and closer to `1.0` for creative and generative tasks.<br/>
114-
/// Note that even with `temperature` of `0.0`, the results will not be fully deterministic.<br/>
115-
/// Example: 1
112+
/// Note that even with `temperature` of `0.0`, the results will not be fully deterministic.
116113
/// </param>
117114
/// <param name="thinking">
118115
/// Configuration for enabling Claude's extended thinking. <br/>
@@ -175,14 +172,12 @@ public partial interface IMessagesClient
175172
/// <param name="topK">
176173
/// Only sample from the top K options for each subsequent token.<br/>
177174
/// Used to remove "long tail" low probability responses. [Learn more technical details here](https://towardsdatascience.com/how-to-sample-from-language-models-682bceb97277).<br/>
178-
/// Recommended for advanced use cases only. You usually only need to use `temperature`.<br/>
179-
/// Example: 5
175+
/// Recommended for advanced use cases only. You usually only need to use `temperature`.
180176
/// </param>
181177
/// <param name="topP">
182178
/// Use nucleus sampling.<br/>
183179
/// In nucleus sampling, we compute the cumulative distribution over all the options for each subsequent token in decreasing probability order and cut it off once it reaches a particular probability specified by `top_p`. You should either alter `temperature` or `top_p`, but not both.<br/>
184-
/// Recommended for advanced use cases only. You usually only need to use `temperature`.<br/>
185-
/// Example: 0.7
180+
/// Recommended for advanced use cases only. You usually only need to use `temperature`.
186181
/// </param>
187182
/// <param name="cancellationToken">The token to cancel the operation with</param>
188183
/// <exception cref="global::System.InvalidOperationException"></exception>

src/tests/AutoSDK.SnapshotTests/Snapshots/CLI/anthropic/_#G.ITextCompletionsClient.CompletePost.g.verified.cs

Lines changed: 5 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -42,15 +42,11 @@ public partial interface ITextCompletionsClient
4242
/// ```<br/>
4343
/// "\n\nHuman: {userQuestion}\n\nAssistant:"<br/>
4444
/// ```<br/>
45-
/// See [prompt validation](https://docs.anthropic.com/en/api/prompt-validation) and our guide to [prompt design](https://docs.anthropic.com/en/docs/intro-to-prompting) for more details.<br/>
46-
/// Example: <br/>
47-
/// Human: Hello, world!<br/>
48-
/// Assistant:
45+
/// See [prompt validation](https://docs.anthropic.com/en/api/prompt-validation) and our guide to [prompt design](https://docs.anthropic.com/en/docs/intro-to-prompting) for more details.
4946
/// </param>
5047
/// <param name="maxTokensToSample">
5148
/// The maximum number of tokens to generate before stopping.<br/>
52-
/// Note that our models may stop _before_ reaching this maximum. This parameter only specifies the absolute maximum number of tokens to generate.<br/>
53-
/// Example: 256
49+
/// Note that our models may stop _before_ reaching this maximum. This parameter only specifies the absolute maximum number of tokens to generate.
5450
/// </param>
5551
/// <param name="stopSequences">
5652
/// Sequences that will cause the model to stop generating.<br/>
@@ -59,20 +55,17 @@ public partial interface ITextCompletionsClient
5955
/// <param name="temperature">
6056
/// Amount of randomness injected into the response.<br/>
6157
/// Defaults to `1.0`. Ranges from `0.0` to `1.0`. Use `temperature` closer to `0.0` for analytical / multiple choice, and closer to `1.0` for creative and generative tasks.<br/>
62-
/// Note that even with `temperature` of `0.0`, the results will not be fully deterministic.<br/>
63-
/// Example: 1
58+
/// Note that even with `temperature` of `0.0`, the results will not be fully deterministic.
6459
/// </param>
6560
/// <param name="topP">
6661
/// Use nucleus sampling.<br/>
6762
/// In nucleus sampling, we compute the cumulative distribution over all the options for each subsequent token in decreasing probability order and cut it off once it reaches a particular probability specified by `top_p`. You should either alter `temperature` or `top_p`, but not both.<br/>
68-
/// Recommended for advanced use cases only. You usually only need to use `temperature`.<br/>
69-
/// Example: 0.7
63+
/// Recommended for advanced use cases only. You usually only need to use `temperature`.
7064
/// </param>
7165
/// <param name="topK">
7266
/// Only sample from the top K options for each subsequent token.<br/>
7367
/// Used to remove "long tail" low probability responses. [Learn more technical details here](https://towardsdatascience.com/how-to-sample-from-language-models-682bceb97277).<br/>
74-
/// Recommended for advanced use cases only. You usually only need to use `temperature`.<br/>
75-
/// Example: 5
68+
/// Recommended for advanced use cases only. You usually only need to use `temperature`.
7669
/// </param>
7770
/// <param name="metadata">
7871
/// An object describing metadata about the request.

0 commit comments

Comments
 (0)