mirror of
https://github.com/microsoft/autogen.git
synced 2025-08-15 04:01:26 +00:00
rysweet-4677-rename-agents-project-to-core-trim-dependencies (#4696)
* move optional base agents to separate package * rename main sdk to Core * reduce dependency graph Co-authored-by: @rysweet Authored-by: @kostapetan Co-authored-by: @kopetan-ms
This commit is contained in:
parent
127d988bd3
commit
a19c848622
@ -164,14 +164,14 @@ git switch staging-dev
|
|||||||
# Build the project
|
# Build the project
|
||||||
cd dotnet && dotnet build AutoGen.sln
|
cd dotnet && dotnet build AutoGen.sln
|
||||||
# In your source code, add AutoGen to your project
|
# In your source code, add AutoGen to your project
|
||||||
dotnet add <your.csproj> reference <path to your checkout of autogen>/dotnet/src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj
|
dotnet add <your.csproj> reference <path to your checkout of autogen>/dotnet/src/Microsoft.AutoGen/Core/Microsoft.AutoGen.Core.csproj
|
||||||
```
|
```
|
||||||
|
|
||||||
Then, define and run your first agent:
|
Then, define and run your first agent:
|
||||||
|
|
||||||
```csharp
|
```csharp
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
|
||||||
|
@ -78,9 +78,7 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
|
|||||||
spelling.dic = spelling.dic
|
spelling.dic = spelling.dic
|
||||||
EndProjectSection
|
EndProjectSection
|
||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Agents", "src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj", "{FD87BD33-4616-460B-AC85-A412BA08BB78}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Core", "src\Microsoft.AutoGen\Core\Microsoft.AutoGen.Core.csproj", "{FD87BD33-4616-460B-AC85-A412BA08BB78}"
|
||||||
EndProject
|
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Contracts", "src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj", "{E0C991D9-0DB8-471C-ADC9-5FB16E2A0106}"
|
|
||||||
EndProject
|
EndProject
|
||||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Extensions.SemanticKernel", "src\Microsoft.AutoGen\Extensions\SemanticKernel\Microsoft.AutoGen.Extensions.SemanticKernel.csproj", "{952827D4-8D4C-4327-AE4D-E8D25811EF35}"
|
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Extensions.SemanticKernel", "src\Microsoft.AutoGen\Extensions\SemanticKernel\Microsoft.AutoGen.Extensions.SemanticKernel.csproj", "{952827D4-8D4C-4327-AE4D-E8D25811EF35}"
|
||||||
EndProject
|
EndProject
|
||||||
@ -142,6 +140,8 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Core.Grpc
|
|||||||
EndProject
|
EndProject
|
||||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Runtime.Grpc", "src\Microsoft.AutoGen\Runtime.Grpc\Microsoft.AutoGen.Runtime.Grpc.csproj", "{8457B68C-CC86-4A3F-8559-C1AE199EC366}"
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Runtime.Grpc", "src\Microsoft.AutoGen\Runtime.Grpc\Microsoft.AutoGen.Runtime.Grpc.csproj", "{8457B68C-CC86-4A3F-8559-C1AE199EC366}"
|
||||||
EndProject
|
EndProject
|
||||||
|
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Agents", "src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj", "{3892C83E-7F5D-41DF-A88C-4854EAD38856}"
|
||||||
|
EndProject
|
||||||
Global
|
Global
|
||||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||||
Debug|Any CPU = Debug|Any CPU
|
Debug|Any CPU = Debug|Any CPU
|
||||||
@ -368,6 +368,10 @@ Global
|
|||||||
{8457B68C-CC86-4A3F-8559-C1AE199EC366}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
{8457B68C-CC86-4A3F-8559-C1AE199EC366}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
{8457B68C-CC86-4A3F-8559-C1AE199EC366}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
{8457B68C-CC86-4A3F-8559-C1AE199EC366}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
{8457B68C-CC86-4A3F-8559-C1AE199EC366}.Release|Any CPU.Build.0 = Release|Any CPU
|
{8457B68C-CC86-4A3F-8559-C1AE199EC366}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
|
{3892C83E-7F5D-41DF-A88C-4854EAD38856}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||||
|
{3892C83E-7F5D-41DF-A88C-4854EAD38856}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||||
|
{3892C83E-7F5D-41DF-A88C-4854EAD38856}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||||
|
{3892C83E-7F5D-41DF-A88C-4854EAD38856}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(SolutionProperties) = preSolution
|
GlobalSection(SolutionProperties) = preSolution
|
||||||
HideSolutionNode = FALSE
|
HideSolutionNode = FALSE
|
||||||
@ -432,6 +436,7 @@ Global
|
|||||||
{7F60934B-3E59-48D0-B26D-04A39FEC13EF} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
{7F60934B-3E59-48D0-B26D-04A39FEC13EF} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
||||||
{9653676C-147D-4CBE-BB53-A30FD3634F4C} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
{9653676C-147D-4CBE-BB53-A30FD3634F4C} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
||||||
{8457B68C-CC86-4A3F-8559-C1AE199EC366} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
{8457B68C-CC86-4A3F-8559-C1AE199EC366} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
||||||
|
{3892C83E-7F5D-41DF-A88C-4854EAD38856} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
|
||||||
EndGlobalSection
|
EndGlobalSection
|
||||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||||
SolutionGuid = {93384647-528D-46C8-922C-8DB36A382F0B}
|
SolutionGuid = {93384647-528D-46C8-922C-8DB36A382F0B}
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// HelloAIAgent.cs
|
// HelloAIAgent.cs
|
||||||
|
|
||||||
using Microsoft.AutoGen.Agents;
|
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.AI;
|
using Microsoft.Extensions.AI;
|
||||||
|
|
||||||
namespace Hello;
|
namespace Hello;
|
||||||
|
@ -11,8 +11,9 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
||||||
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
||||||
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Core\Microsoft.AutoGen.Core.csproj" />
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\MEAI\Microsoft.AutoGen.Extensions.MEAI.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\MEAI\Microsoft.AutoGen.Extensions.MEAI.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using Hello;
|
using Hello;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
// send a message to the agent
|
// send a message to the agent
|
||||||
var builder = WebApplication.CreateBuilder();
|
var builder = WebApplication.CreateBuilder();
|
||||||
|
@ -15,7 +15,8 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
||||||
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
||||||
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Core\Microsoft.AutoGen.Core.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// Program.cs
|
// Program.cs
|
||||||
|
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
|
||||||
|
@ -12,7 +12,8 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
||||||
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
||||||
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Core\Microsoft.AutoGen.Core.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using System.Text.Json;
|
using System.Text.Json;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
// send a message to the agent
|
// send a message to the agent
|
||||||
var app = await AgentsApp.PublishMessageAsync("HelloAgents", new NewMessageReceived
|
var app = await AgentsApp.PublishMessageAsync("HelloAgents", new NewMessageReceived
|
||||||
|
@ -9,7 +9,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="../../../src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Core/Microsoft.AutoGen.Core.csproj" />
|
||||||
<ProjectReference Include="../../../src/Microsoft.AutoGen/Runtime.Grpc/Microsoft.AutoGen.Runtime.Grpc.csproj" />
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Runtime.Grpc/Microsoft.AutoGen.Runtime.Grpc.csproj" />
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
@ -8,8 +8,8 @@
|
|||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
|
||||||
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Core/Microsoft.AutoGen.Core.csproj" />
|
||||||
<ProjectReference Include="../../../src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj" />
|
||||||
|
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
||||||
<ProjectReference Include="..\DevTeam.Shared\DevTeam.Shared.csproj" />
|
<ProjectReference Include="..\DevTeam.Shared\DevTeam.Shared.csproj" />
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\SemanticKernel\Microsoft.AutoGen.Extensions.SemanticKernel.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\SemanticKernel\Microsoft.AutoGen.Extensions.SemanticKernel.csproj" />
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using DevTeam.Shared;
|
using DevTeam.Shared;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.SemanticKernel;
|
using Microsoft.SemanticKernel;
|
||||||
using Microsoft.SemanticKernel.Memory;
|
using Microsoft.SemanticKernel.Memory;
|
||||||
|
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using DevTeam.Shared;
|
using DevTeam.Shared;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.SemanticKernel;
|
using Microsoft.SemanticKernel;
|
||||||
using Microsoft.SemanticKernel.Connectors.OpenAI;
|
using Microsoft.SemanticKernel.Connectors.OpenAI;
|
||||||
using Microsoft.SemanticKernel.Memory;
|
using Microsoft.SemanticKernel.Memory;
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using DevTeam.Shared;
|
using DevTeam.Shared;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.SemanticKernel;
|
using Microsoft.SemanticKernel;
|
||||||
using Microsoft.SemanticKernel.Memory;
|
using Microsoft.SemanticKernel.Memory;
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
// Program.cs
|
// Program.cs
|
||||||
|
|
||||||
using DevTeam.Agents;
|
using DevTeam.Agents;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.AutoGen.Extensions.SemanticKernel;
|
using Microsoft.AutoGen.Extensions.SemanticKernel;
|
||||||
|
|
||||||
var builder = WebApplication.CreateBuilder(args);
|
var builder = WebApplication.CreateBuilder(args);
|
||||||
|
@ -4,6 +4,7 @@
|
|||||||
using DevTeam.Backend;
|
using DevTeam.Backend;
|
||||||
using DevTeam.Shared;
|
using DevTeam.Shared;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.SemanticKernel;
|
using Microsoft.SemanticKernel;
|
||||||
using Microsoft.SemanticKernel.Memory;
|
using Microsoft.SemanticKernel.Memory;
|
||||||
namespace Microsoft.AI.DevTeam;
|
namespace Microsoft.AI.DevTeam;
|
||||||
|
@ -6,6 +6,7 @@ using DevTeam;
|
|||||||
using DevTeam.Backend;
|
using DevTeam.Backend;
|
||||||
using DevTeam.Shared;
|
using DevTeam.Shared;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Agents;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.SemanticKernel;
|
using Microsoft.SemanticKernel;
|
||||||
using Microsoft.SemanticKernel.Memory;
|
using Microsoft.SemanticKernel.Memory;
|
||||||
|
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk.Web">
|
<Project Sdk="Microsoft.NET.Sdk.Web">
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="../../../src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Core/Microsoft.AutoGen.Core.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
@ -29,6 +29,7 @@
|
|||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj" />
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
||||||
<ProjectReference Include="..\DevTeam.Shared\DevTeam.Shared.csproj" />
|
<ProjectReference Include="..\DevTeam.Shared\DevTeam.Shared.csproj" />
|
||||||
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\SemanticKernel\Microsoft.AutoGen.Extensions.SemanticKernel.csproj" />
|
<ProjectReference Include="..\..\..\src\Microsoft.AutoGen\Extensions\SemanticKernel\Microsoft.AutoGen.Extensions.SemanticKernel.csproj" />
|
||||||
|
@ -5,7 +5,7 @@ using Azure.Identity;
|
|||||||
using DevTeam.Backend;
|
using DevTeam.Backend;
|
||||||
using DevTeam.Options;
|
using DevTeam.Options;
|
||||||
using Microsoft.AI.DevTeam;
|
using Microsoft.AI.DevTeam;
|
||||||
using Microsoft.AutoGen.Agents;
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.AutoGen.Extensions.SemanticKernel;
|
using Microsoft.AutoGen.Extensions.SemanticKernel;
|
||||||
using Microsoft.Extensions.Azure;
|
using Microsoft.Extensions.Azure;
|
||||||
using Microsoft.Extensions.Options;
|
using Microsoft.Extensions.Options;
|
||||||
|
@ -3,8 +3,8 @@
|
|||||||
|
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using DevTeam.Shared;
|
using DevTeam.Shared;
|
||||||
using Microsoft.AutoGen.Agents;
|
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Octokit.Webhooks;
|
using Octokit.Webhooks;
|
||||||
using Octokit.Webhooks.Events;
|
using Octokit.Webhooks.Events;
|
||||||
using Octokit.Webhooks.Events.IssueComment;
|
using Octokit.Webhooks.Events.IssueComment;
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
<Project Sdk="Microsoft.NET.Sdk">
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="../../../src/Microsoft.AutoGen/Agents/Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="../../../src/Microsoft.AutoGen/Core/Microsoft.AutoGen.Core.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// InferenceAgent.cs
|
// InferenceAgent.cs
|
||||||
|
|
||||||
using Google.Protobuf;
|
using Google.Protobuf;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.AI;
|
using Microsoft.Extensions.AI;
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Agents;
|
||||||
public abstract class InferenceAgent<T>(
|
public abstract class InferenceAgent<T>(
|
@ -1,8 +1,8 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// SKAiAgent.cs
|
// SKAiAgent.cs
|
||||||
|
|
||||||
using System.Globalization;
|
using System.Globalization;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.SemanticKernel;
|
using Microsoft.SemanticKernel;
|
||||||
using Microsoft.SemanticKernel.Connectors.OpenAI;
|
using Microsoft.SemanticKernel.Connectors.OpenAI;
|
||||||
using Microsoft.SemanticKernel.Memory;
|
using Microsoft.SemanticKernel.Memory;
|
@ -1,7 +1,7 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// ConsoleAgent.cs
|
// ConsoleAgent.cs
|
||||||
|
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Agents;
|
@ -3,6 +3,7 @@
|
|||||||
|
|
||||||
using Google.Protobuf;
|
using Google.Protobuf;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Agents;
|
||||||
|
|
@ -1,7 +1,7 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// FileAgent.cs
|
// FileAgent.cs
|
||||||
|
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
@ -2,7 +2,7 @@
|
|||||||
// IOAgent.cs
|
// IOAgent.cs
|
||||||
|
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Agents;
|
||||||
|
|
||||||
public abstract class IOAgent : Agent
|
public abstract class IOAgent : Agent
|
@ -1,9 +1,9 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// WebAPIAgent.cs
|
// WebAPIAgent.cs
|
||||||
|
|
||||||
using Microsoft.AspNetCore.Builder;
|
using Microsoft.AspNetCore.Builder;
|
||||||
using Microsoft.AspNetCore.Http;
|
using Microsoft.AspNetCore.Http;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
using Microsoft.AutoGen.Core;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
@ -8,15 +8,14 @@
|
|||||||
|
|
||||||
<Import Project="$(RepoRoot)/nuget/nuget-package.props" />
|
<Import Project="$(RepoRoot)/nuget/nuget-package.props" />
|
||||||
|
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
<ProjectReference Include="..\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
||||||
|
<ProjectReference Include="..\Core\Microsoft.AutoGen.Core.csproj" />
|
||||||
<ProjectReference Include="..\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
<ProjectReference Include="..\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Microsoft.SemanticKernel" />
|
||||||
<PackageReference Include="Microsoft.Extensions.AI.Abstractions" />
|
<PackageReference Include="Microsoft.Extensions.AI.Abstractions" />
|
||||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection" />
|
|
||||||
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
|
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -18,6 +18,5 @@
|
|||||||
<PackageReference Include="Grpc.AspNetCore" />
|
<PackageReference Include="Grpc.AspNetCore" />
|
||||||
<PackageReference Include="Grpc.Net.ClientFactory" />
|
<PackageReference Include="Grpc.Net.ClientFactory" />
|
||||||
<PackageReference Include="Grpc.Tools" PrivateAssets="All" />
|
<PackageReference Include="Grpc.Tools" PrivateAssets="All" />
|
||||||
<PackageReference Include="Microsoft.SemanticKernel" />
|
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
||||||
|
@ -4,7 +4,6 @@ using System.Diagnostics;
|
|||||||
using System.Diagnostics.CodeAnalysis;
|
using System.Diagnostics.CodeAnalysis;
|
||||||
using Google.Protobuf;
|
using Google.Protobuf;
|
||||||
using Microsoft.AspNetCore.Builder;
|
using Microsoft.AspNetCore.Builder;
|
||||||
using Microsoft.AutoGen.Agents;
|
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.DependencyInjection.Extensions;
|
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
@ -11,7 +11,7 @@ using Microsoft.Extensions.DependencyInjection;
|
|||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public sealed class GrpcAgentWorker(
|
public sealed class GrpcAgentWorker(
|
||||||
AgentRpc.AgentRpcClient client,
|
AgentRpc.AgentRpcClient client,
|
||||||
|
@ -2,7 +2,6 @@
|
|||||||
// GrpcAgentWorkerHostBuilderExtension.cs
|
// GrpcAgentWorkerHostBuilderExtension.cs
|
||||||
using Grpc.Core;
|
using Grpc.Core;
|
||||||
using Grpc.Net.Client.Configuration;
|
using Grpc.Net.Client.Configuration;
|
||||||
using Microsoft.AutoGen.Agents;
|
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\Agents\Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="..\Core\Microsoft.AutoGen.Core.csproj" />
|
||||||
<ProjectReference Include="..\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
<ProjectReference Include="..\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
@ -12,7 +12,7 @@ using Google.Protobuf;
|
|||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public abstract class Agent : IDisposable, IHandle
|
public abstract class Agent : IDisposable, IHandle
|
||||||
{
|
{
|
@ -5,7 +5,7 @@ using System.Diagnostics;
|
|||||||
using Google.Protobuf.Collections;
|
using Google.Protobuf.Collections;
|
||||||
using static Microsoft.AutoGen.Contracts.CloudEvent.Types;
|
using static Microsoft.AutoGen.Contracts.CloudEvent.Types;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Provides extension methods for the <see cref="Agent"/> class.
|
/// Provides extension methods for the <see cref="Agent"/> class.
|
@ -7,7 +7,7 @@ using Microsoft.AutoGen.Contracts;
|
|||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using static Microsoft.AutoGen.Contracts.CloudEvent.Types;
|
using static Microsoft.AutoGen.Contracts.CloudEvent.Types;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public sealed class AgentRuntime(AgentId agentId, IAgentWorker worker, ILogger<Agent> logger, DistributedContextPropagator distributedContextPropagator) : IAgentRuntime
|
public sealed class AgentRuntime(AgentId agentId, IAgentWorker worker, ILogger<Agent> logger, DistributedContextPropagator distributedContextPropagator) : IAgentRuntime
|
||||||
{
|
{
|
@ -1,7 +1,7 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// AgentTypes.cs
|
// AgentTypes.cs
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents
|
namespace Microsoft.AutoGen.Core
|
||||||
;
|
;
|
||||||
public sealed class AgentTypes(Dictionary<string, Type> types)
|
public sealed class AgentTypes(Dictionary<string, Type> types)
|
||||||
{
|
{
|
@ -9,7 +9,7 @@ using Microsoft.Extensions.DependencyInjection;
|
|||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public class AgentWorker :
|
public class AgentWorker :
|
||||||
IHostedService,
|
IHostedService,
|
@ -8,7 +8,7 @@ using Microsoft.Extensions.DependencyInjection;
|
|||||||
using Microsoft.Extensions.DependencyInjection.Extensions;
|
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public static class AgentsApp
|
public static class AgentsApp
|
||||||
{
|
{
|
@ -6,7 +6,7 @@ using Microsoft.AutoGen.Contracts;
|
|||||||
using Microsoft.Extensions.DependencyInjection;
|
using Microsoft.Extensions.DependencyInjection;
|
||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
public sealed class Client(IAgentWorker runtime, DistributedContextPropagator distributedContextPropagator,
|
public sealed class Client(IAgentWorker runtime, DistributedContextPropagator distributedContextPropagator,
|
||||||
[FromKeyedServices("EventTypes")] EventTypes eventTypes, ILogger<Client> logger)
|
[FromKeyedServices("EventTypes")] EventTypes eventTypes, ILogger<Client> logger)
|
||||||
: Agent(new AgentRuntime(new AgentId("client", Guid.NewGuid().ToString()), runtime, logger, distributedContextPropagator), eventTypes)
|
: Agent(new AgentRuntime(new AgentId("client", Guid.NewGuid().ToString()), runtime, logger, distributedContextPropagator), eventTypes)
|
@ -2,7 +2,7 @@
|
|||||||
// EventTypes.cs
|
// EventTypes.cs
|
||||||
using Google.Protobuf.Reflection;
|
using Google.Protobuf.Reflection;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
public sealed class EventTypes(TypeRegistry typeRegistry, Dictionary<string, Type> types, Dictionary<Type, HashSet<string>> eventsMap)
|
public sealed class EventTypes(TypeRegistry typeRegistry, Dictionary<string, Type> types, Dictionary<Type, HashSet<string>> eventsMap)
|
||||||
{
|
{
|
||||||
public TypeRegistry TypeRegistry { get; } = typeRegistry;
|
public TypeRegistry TypeRegistry { get; } = typeRegistry;
|
@ -10,7 +10,7 @@ using Microsoft.Extensions.DependencyInjection;
|
|||||||
using Microsoft.Extensions.DependencyInjection.Extensions;
|
using Microsoft.Extensions.DependencyInjection.Extensions;
|
||||||
using Microsoft.Extensions.Hosting;
|
using Microsoft.Extensions.Hosting;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public static class HostBuilderExtensions
|
public static class HostBuilderExtensions
|
||||||
{
|
{
|
@ -4,7 +4,7 @@
|
|||||||
using System.Diagnostics;
|
using System.Diagnostics;
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public interface IAgentRuntime
|
public interface IAgentRuntime
|
||||||
{
|
{
|
@ -1,7 +1,7 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// IAgentWorker.cs
|
// IAgentWorker.cs
|
||||||
using Microsoft.AutoGen.Contracts;
|
using Microsoft.AutoGen.Contracts;
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
|
|
||||||
public interface IAgentWorker
|
public interface IAgentWorker
|
||||||
{
|
{
|
@ -1,6 +1,6 @@
|
|||||||
// Copyright (c) Microsoft Corporation. All rights reserved.
|
// Copyright (c) Microsoft Corporation. All rights reserved.
|
||||||
// IHandle.cs
|
// IHandle.cs
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
public interface IHandle
|
public interface IHandle
|
||||||
{
|
{
|
||||||
Task HandleObject(object item);
|
Task HandleObject(object item);
|
@ -0,0 +1,21 @@
|
|||||||
|
<Project Sdk="Microsoft.NET.Sdk">
|
||||||
|
|
||||||
|
<PropertyGroup>
|
||||||
|
<TargetFramework>net8.0</TargetFramework>
|
||||||
|
<ImplicitUsings>enable</ImplicitUsings>
|
||||||
|
<Nullable>enable</Nullable>
|
||||||
|
</PropertyGroup>
|
||||||
|
|
||||||
|
<Import Project="$(RepoRoot)/nuget/nuget-package.props" />
|
||||||
|
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<ProjectReference Include="..\Contracts\Microsoft.AutoGen.Contracts.csproj" />
|
||||||
|
<ProjectReference Include="..\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj" />
|
||||||
|
</ItemGroup>
|
||||||
|
|
||||||
|
<ItemGroup>
|
||||||
|
<PackageReference Include="Microsoft.Extensions.DependencyInjection" />
|
||||||
|
<PackageReference Include="Microsoft.Extensions.DependencyInjection.Abstractions" />
|
||||||
|
</ItemGroup>
|
||||||
|
</Project>
|
@ -4,7 +4,7 @@ using System.Reflection;
|
|||||||
using Google.Protobuf;
|
using Google.Protobuf;
|
||||||
using Google.Protobuf.Reflection;
|
using Google.Protobuf.Reflection;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents;
|
namespace Microsoft.AutoGen.Core;
|
||||||
public sealed class ReflectionHelper
|
public sealed class ReflectionHelper
|
||||||
{
|
{
|
||||||
public static bool IsSubclassOfGeneric(Type type, Type genericBaseType)
|
public static bool IsSubclassOfGeneric(Type type, Type genericBaseType)
|
@ -16,7 +16,7 @@
|
|||||||
|
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="../../Agents/Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="../../Core/Microsoft.AutoGen.Core.csproj" />
|
||||||
<ProjectReference Include="../MEAI/Microsoft.AutoGen.Extensions.MEAI.csproj" />
|
<ProjectReference Include="../MEAI/Microsoft.AutoGen.Extensions.MEAI.csproj" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
@ -11,9 +11,9 @@ using Microsoft.Extensions.Hosting;
|
|||||||
using Microsoft.Extensions.Logging;
|
using Microsoft.Extensions.Logging;
|
||||||
using Moq;
|
using Moq;
|
||||||
using Xunit;
|
using Xunit;
|
||||||
using static Microsoft.AutoGen.Agents.Tests.AgentTests;
|
using static Microsoft.AutoGen.Core.Tests.AgentTests;
|
||||||
|
|
||||||
namespace Microsoft.AutoGen.Agents.Tests;
|
namespace Microsoft.AutoGen.Core.Tests;
|
||||||
|
|
||||||
[Collection(ClusterFixtureCollection.Name)]
|
[Collection(ClusterFixtureCollection.Name)]
|
||||||
public class AgentTests(InMemoryAgentRuntimeFixture fixture)
|
public class AgentTests(InMemoryAgentRuntimeFixture fixture)
|
||||||
|
@ -8,7 +8,7 @@
|
|||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ProjectReference Include="..\..\src\Microsoft.AutoGen\Agents\Microsoft.AutoGen.Agents.csproj" />
|
<ProjectReference Include="..\..\src\Microsoft.AutoGen\Core\Microsoft.AutoGen.Core.csproj" />
|
||||||
<PackageReference Include="Microsoft.Extensions.Hosting" />
|
<PackageReference Include="Microsoft.Extensions.Hosting" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user