mirror of
https://github.com/microsoft/agent-framework.git
synced 2026-06-16 21:04:09 +08:00
.NET: [BREAKING] Renamed CreateAIAgent/GetAIAgent to AsAIAgent (#3222)
* Renamed chat client extension method * Additional renaming * Updated documentation * Fixed tests * Small fix * Small fix
This commit is contained in:
committed by
GitHub
Unverified
parent
e192af93a7
commit
2ab859dd94
@@ -32,7 +32,7 @@ public static class OpenAIResponseClientExtensions
|
||||
/// <param name="services">An optional <see cref="IServiceProvider"/> to use for resolving services required by the <see cref="AIFunction"/> instances being invoked.</param>
|
||||
/// <returns>An <see cref="ChatClientAgent"/> instance backed by the OpenAI Response service.</returns>
|
||||
/// <exception cref="ArgumentNullException">Thrown when <paramref name="client"/> is <see langword="null"/>.</exception>
|
||||
public static ChatClientAgent CreateAIAgent(
|
||||
public static ChatClientAgent AsAIAgent(
|
||||
this ResponsesClient client,
|
||||
string? instructions = null,
|
||||
string? name = null,
|
||||
@@ -44,7 +44,7 @@ public static class OpenAIResponseClientExtensions
|
||||
{
|
||||
Throw.IfNull(client);
|
||||
|
||||
return client.CreateAIAgent(
|
||||
return client.AsAIAgent(
|
||||
new ChatClientAgentOptions()
|
||||
{
|
||||
Name = name,
|
||||
@@ -70,7 +70,7 @@ public static class OpenAIResponseClientExtensions
|
||||
/// <param name="services">An optional <see cref="IServiceProvider"/> to use for resolving services required by the <see cref="AIFunction"/> instances being invoked.</param>
|
||||
/// <returns>An <see cref="ChatClientAgent"/> instance backed by the OpenAI Response service.</returns>
|
||||
/// <exception cref="ArgumentNullException">Thrown when <paramref name="client"/> or <paramref name="options"/> is <see langword="null"/>.</exception>
|
||||
public static ChatClientAgent CreateAIAgent(
|
||||
public static ChatClientAgent AsAIAgent(
|
||||
this ResponsesClient client,
|
||||
ChatClientAgentOptions options,
|
||||
Func<IChatClient, IChatClient>? clientFactory = null,
|
||||
|
||||
Reference in New Issue
Block a user