diff --git a/README.md b/README.md
index 179067fe9106..a85b33992373 100644
--- a/README.md
+++ b/README.md
@@ -63,7 +63,6 @@ from autogen_agentchat.teams import RoundRobinGroupChat
from autogen_agentchat.ui import Console
from autogen_ext.models.openai import OpenAIChatCompletionClient
from autogen_ext.agents.web_surfer import MultimodalWebSurfer
-
async def main() -> None:
model_client = OpenAIChatCompletionClient(model="gpt-4o")
assistant = AssistantAgent("assistant", model_client)
diff --git a/dotnet/AutoGen.sln b/dotnet/AutoGen.sln
index d0707a89a7fd..76a759e37692 100644
--- a/dotnet/AutoGen.sln
+++ b/dotnet/AutoGen.sln
@@ -100,16 +100,10 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "AutoGen.WebAPI.Sample", "sa
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "DevTeam", "DevTeam", "{05B9C173-6441-4DCA-9AC4-E897EF75F331}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DevTeam.AgentHost", "samples\dev-team\DevTeam.AgentHost\DevTeam.AgentHost.csproj", "{462A357B-7BB9-4927-A9FD-4FB7675898E9}"
-EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DevTeam.Agents", "samples\dev-team\DevTeam.Agents\DevTeam.Agents.csproj", "{83BBB833-A2F0-4A4D-BA1B-8229FC9BCD4F}"
-EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DevTeam.AppHost", "samples\dev-team\DevTeam.AppHost\DevTeam.AppHost.csproj", "{63280C12-3BE3-4C4E-805E-584CDC6BC1F5}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DevTeam.Backend", "samples\dev-team\DevTeam.Backend\DevTeam.Backend.csproj", "{EDA3EF83-FC7F-4BCF-945D-B893620EE4B1}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DevTeam.Shared", "samples\dev-team\DevTeam.Shared\DevTeam.Shared.csproj", "{01F5D7C3-41EB-409C-9B77-A945C07FA7E8}"
-EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Hello", "Hello", "{7EB336C2-7C0A-4BC8-80C6-A3173AB8DC45}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Hello.AppHost", "samples\Hello\Hello.AppHost\Hello.AppHost.csproj", "{09A373A0-8169-409F-8C37-3FBC1654B122}"
@@ -126,8 +120,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "HelloAgentState", "samples\
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Extensions.Aspire", "src\Microsoft.AutoGen\Extensions\Aspire\Microsoft.AutoGen.Extensions.Aspire.csproj", "{65059914-5527-4A00-9308-9FAF23D5E85A}"
EndProject
-Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.AutoGen.Agents.Tests", "test\Microsoft.AutoGen.Agents.Tests\Microsoft.AutoGen.Agents.Tests.csproj", "{394FDAF8-74F9-4977-94A5-3371737EB774}"
-EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Integration.Tests", "test\Microsoft.AutoGen.Integration.Tests\Microsoft.AutoGen.Integration.Tests.csproj", "{D04C6153-8EAF-4E54-9852-52CEC1BE8D31}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "HelloAgent.AppHost", "test\Microsoft.AutoGen.Integration.Tests.AppHosts\HelloAgent.AppHost\HelloAgent.AppHost.csproj", "{99D7766B-076F-4E6F-A8D2-3DF1DAFA2599}"
@@ -142,6 +134,16 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Agents",
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Autogen.AgentHost", "src\Microsoft.AutoGen\AgentHost\Microsoft.Autogen.AgentHost.csproj", "{4CB42139-DEE4-40B9-AA81-1E4CCAA2F338}"
EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Runtime.Grpc.Tests", "test\Microsoft.AutoGen.Runtime.Grpc.Tests\Microsoft.AutoGen.Runtime.Grpc.Tests.csproj", "{0E7983BB-2602-421E-8B37-332E52870A10}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Tests.Shared", "test\Microsoft.AutoGen.Tests.Shared\Microsoft.AutoGen.Tests.Shared.csproj", "{14F90F79-580E-454D-BA7A-ED6D9723020D}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Core.Tests", "test\Microsoft.AutoGen.Core.Tests\Microsoft.AutoGen.Core.Tests.csproj", "{EAFFE339-26CB-4019-991D-BCCE8E7D33A1}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "DevTeam.ServiceDefaults", "samples\dev-team\DevTeam.ServiceDefaults\DevTeam.ServiceDefaults.csproj", "{599E1971-1DA9-453F-A7A8-42510BBC95C2}"
+EndProject
+Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.AutoGen.Core.Grpc.Tests", "test\Microsoft.AutoGen.Core.Grpc.Tests\Microsoft.AutoGen.Core.Grpc.Tests.csproj", "{33A28A4B-123B-4416-9631-0F759B8D6172}"
+EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
@@ -296,14 +298,6 @@ Global
{4385AFCF-AB4A-49B2-BEBA-D33C950E1EE6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4385AFCF-AB4A-49B2-BEBA-D33C950E1EE6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4385AFCF-AB4A-49B2-BEBA-D33C950E1EE6}.Release|Any CPU.Build.0 = Release|Any CPU
- {462A357B-7BB9-4927-A9FD-4FB7675898E9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {462A357B-7BB9-4927-A9FD-4FB7675898E9}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {462A357B-7BB9-4927-A9FD-4FB7675898E9}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {462A357B-7BB9-4927-A9FD-4FB7675898E9}.Release|Any CPU.Build.0 = Release|Any CPU
- {83BBB833-A2F0-4A4D-BA1B-8229FC9BCD4F}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {83BBB833-A2F0-4A4D-BA1B-8229FC9BCD4F}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {83BBB833-A2F0-4A4D-BA1B-8229FC9BCD4F}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {83BBB833-A2F0-4A4D-BA1B-8229FC9BCD4F}.Release|Any CPU.Build.0 = Release|Any CPU
{63280C12-3BE3-4C4E-805E-584CDC6BC1F5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{63280C12-3BE3-4C4E-805E-584CDC6BC1F5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{63280C12-3BE3-4C4E-805E-584CDC6BC1F5}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -312,10 +306,6 @@ Global
{EDA3EF83-FC7F-4BCF-945D-B893620EE4B1}.Debug|Any CPU.Build.0 = Debug|Any CPU
{EDA3EF83-FC7F-4BCF-945D-B893620EE4B1}.Release|Any CPU.ActiveCfg = Release|Any CPU
{EDA3EF83-FC7F-4BCF-945D-B893620EE4B1}.Release|Any CPU.Build.0 = Release|Any CPU
- {01F5D7C3-41EB-409C-9B77-A945C07FA7E8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {01F5D7C3-41EB-409C-9B77-A945C07FA7E8}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {01F5D7C3-41EB-409C-9B77-A945C07FA7E8}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {01F5D7C3-41EB-409C-9B77-A945C07FA7E8}.Release|Any CPU.Build.0 = Release|Any CPU
{09A373A0-8169-409F-8C37-3FBC1654B122}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{09A373A0-8169-409F-8C37-3FBC1654B122}.Debug|Any CPU.Build.0 = Debug|Any CPU
{09A373A0-8169-409F-8C37-3FBC1654B122}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -340,10 +330,6 @@ Global
{65059914-5527-4A00-9308-9FAF23D5E85A}.Debug|Any CPU.Build.0 = Debug|Any CPU
{65059914-5527-4A00-9308-9FAF23D5E85A}.Release|Any CPU.ActiveCfg = Release|Any CPU
{65059914-5527-4A00-9308-9FAF23D5E85A}.Release|Any CPU.Build.0 = Release|Any CPU
- {394FDAF8-74F9-4977-94A5-3371737EB774}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
- {394FDAF8-74F9-4977-94A5-3371737EB774}.Debug|Any CPU.Build.0 = Debug|Any CPU
- {394FDAF8-74F9-4977-94A5-3371737EB774}.Release|Any CPU.ActiveCfg = Release|Any CPU
- {394FDAF8-74F9-4977-94A5-3371737EB774}.Release|Any CPU.Build.0 = Release|Any CPU
{D04C6153-8EAF-4E54-9852-52CEC1BE8D31}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D04C6153-8EAF-4E54-9852-52CEC1BE8D31}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D04C6153-8EAF-4E54-9852-52CEC1BE8D31}.Release|Any CPU.ActiveCfg = Release|Any CPU
@@ -372,6 +358,26 @@ Global
{4CB42139-DEE4-40B9-AA81-1E4CCAA2F338}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4CB42139-DEE4-40B9-AA81-1E4CCAA2F338}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4CB42139-DEE4-40B9-AA81-1E4CCAA2F338}.Release|Any CPU.Build.0 = Release|Any CPU
+ {0E7983BB-2602-421E-8B37-332E52870A10}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {0E7983BB-2602-421E-8B37-332E52870A10}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {0E7983BB-2602-421E-8B37-332E52870A10}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {0E7983BB-2602-421E-8B37-332E52870A10}.Release|Any CPU.Build.0 = Release|Any CPU
+ {14F90F79-580E-454D-BA7A-ED6D9723020D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {14F90F79-580E-454D-BA7A-ED6D9723020D}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {14F90F79-580E-454D-BA7A-ED6D9723020D}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {14F90F79-580E-454D-BA7A-ED6D9723020D}.Release|Any CPU.Build.0 = Release|Any CPU
+ {EAFFE339-26CB-4019-991D-BCCE8E7D33A1}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {EAFFE339-26CB-4019-991D-BCCE8E7D33A1}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {EAFFE339-26CB-4019-991D-BCCE8E7D33A1}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {EAFFE339-26CB-4019-991D-BCCE8E7D33A1}.Release|Any CPU.Build.0 = Release|Any CPU
+ {599E1971-1DA9-453F-A7A8-42510BBC95C2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {599E1971-1DA9-453F-A7A8-42510BBC95C2}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {599E1971-1DA9-453F-A7A8-42510BBC95C2}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {599E1971-1DA9-453F-A7A8-42510BBC95C2}.Release|Any CPU.Build.0 = Release|Any CPU
+ {33A28A4B-123B-4416-9631-0F759B8D6172}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
+ {33A28A4B-123B-4416-9631-0F759B8D6172}.Debug|Any CPU.Build.0 = Debug|Any CPU
+ {33A28A4B-123B-4416-9631-0F759B8D6172}.Release|Any CPU.ActiveCfg = Release|Any CPU
+ {33A28A4B-123B-4416-9631-0F759B8D6172}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
@@ -417,11 +423,8 @@ Global
{CB8824F5-9475-451F-87E8-F2AEF2490A12} = {668726B9-77BC-45CF-B576-0F0773BF1615}
{4385AFCF-AB4A-49B2-BEBA-D33C950E1EE6} = {668726B9-77BC-45CF-B576-0F0773BF1615}
{05B9C173-6441-4DCA-9AC4-E897EF75F331} = {686480D7-8FEC-4ED3-9C5D-CEBE1057A7ED}
- {462A357B-7BB9-4927-A9FD-4FB7675898E9} = {05B9C173-6441-4DCA-9AC4-E897EF75F331}
- {83BBB833-A2F0-4A4D-BA1B-8229FC9BCD4F} = {05B9C173-6441-4DCA-9AC4-E897EF75F331}
{63280C12-3BE3-4C4E-805E-584CDC6BC1F5} = {05B9C173-6441-4DCA-9AC4-E897EF75F331}
{EDA3EF83-FC7F-4BCF-945D-B893620EE4B1} = {05B9C173-6441-4DCA-9AC4-E897EF75F331}
- {01F5D7C3-41EB-409C-9B77-A945C07FA7E8} = {05B9C173-6441-4DCA-9AC4-E897EF75F331}
{7EB336C2-7C0A-4BC8-80C6-A3173AB8DC45} = {686480D7-8FEC-4ED3-9C5D-CEBE1057A7ED}
{09A373A0-8169-409F-8C37-3FBC1654B122} = {7EB336C2-7C0A-4BC8-80C6-A3173AB8DC45}
{A20B9894-F352-4338-872A-F215A241D43D} = {7EB336C2-7C0A-4BC8-80C6-A3173AB8DC45}
@@ -429,7 +432,6 @@ Global
{97550E87-48C6-4EBF-85E1-413ABAE9DBFD} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
{64EF61E7-00A6-4E5E-9808-62E10993A0E5} = {7EB336C2-7C0A-4BC8-80C6-A3173AB8DC45}
{65059914-5527-4A00-9308-9FAF23D5E85A} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
- {394FDAF8-74F9-4977-94A5-3371737EB774} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
{D04C6153-8EAF-4E54-9852-52CEC1BE8D31} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
{99D7766B-076F-4E6F-A8D2-3DF1DAFA2599} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
{7F60934B-3E59-48D0-B26D-04A39FEC13EF} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
@@ -437,6 +439,11 @@ Global
{8457B68C-CC86-4A3F-8559-C1AE199EC366} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
{3892C83E-7F5D-41DF-A88C-4854EAD38856} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
{4CB42139-DEE4-40B9-AA81-1E4CCAA2F338} = {18BF8DD7-0585-48BF-8F97-AD333080CE06}
+ {0E7983BB-2602-421E-8B37-332E52870A10} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
+ {14F90F79-580E-454D-BA7A-ED6D9723020D} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
+ {EAFFE339-26CB-4019-991D-BCCE8E7D33A1} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
+ {599E1971-1DA9-453F-A7A8-42510BBC95C2} = {05B9C173-6441-4DCA-9AC4-E897EF75F331}
+ {33A28A4B-123B-4416-9631-0F759B8D6172} = {F823671B-3ECA-4AE6-86DA-25E920D3FE64}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution
SolutionGuid = {93384647-528D-46C8-922C-8DB36A382F0B}
diff --git a/dotnet/Directory.Packages.props b/dotnet/Directory.Packages.props
index 1e84c0badb2f..d0131825aab4 100644
--- a/dotnet/Directory.Packages.props
+++ b/dotnet/Directory.Packages.props
@@ -45,6 +45,7 @@
+
@@ -83,6 +84,7 @@
+
@@ -125,7 +127,6 @@
-
\ No newline at end of file
diff --git a/dotnet/samples/Hello/Hello.AppHost/Program.cs b/dotnet/samples/Hello/Hello.AppHost/Program.cs
index 8230a5b7c2d9..31dbeb8c2db7 100644
--- a/dotnet/samples/Hello/Hello.AppHost/Program.cs
+++ b/dotnet/samples/Hello/Hello.AppHost/Program.cs
@@ -12,7 +12,7 @@
.WaitFor(backend);
#pragma warning disable ASPIREHOSTINGPYTHON001 // Type is for evaluation purposes only and is subject to change or removal in future updates. Suppress this diagnostic to proceed.
// xlang is over http for now - in prod use TLS between containers
-builder.AddPythonApp("HelloAgentsPython", "../../../../python/packages/autogen-core/samples/xlang/hello_python_agent", "hello_python_agent.py", "../../../../../.venv")
+builder.AddPythonApp("HelloAgentsPython", "../../../../python/samples/core_xlang_hello_python_agent", "hello_python_agent.py", "../../.venv")
.WithReference(backend)
.WithEnvironment("AGENT_HOST", backend.GetEndpoint("http"))
.WithEnvironment("STAY_ALIVE_ON_GOODBYE", "true")
diff --git a/dotnet/samples/Hello/HelloAIAgents/HelloAIAgent.cs b/dotnet/samples/Hello/HelloAIAgents/HelloAIAgent.cs
index 0e195ca5b1dd..ba71b31a2017 100644
--- a/dotnet/samples/Hello/HelloAIAgents/HelloAIAgent.cs
+++ b/dotnet/samples/Hello/HelloAIAgents/HelloAIAgent.cs
@@ -8,17 +8,15 @@
namespace Hello;
[TopicSubscription("agents")]
public class HelloAIAgent(
- IAgentWorker worker,
- [FromKeyedServices("EventTypes")] EventTypes typeRegistry,
+ [FromKeyedServices("AgentsMetadata")] AgentsMetadata typeRegistry,
IHostApplicationLifetime hostApplicationLifetime,
IChatClient client) : HelloAgent(
- worker,
typeRegistry,
hostApplicationLifetime),
IHandle
{
// This Handle supercedes the one in the base class
- public new async Task Handle(NewMessageReceived item)
+ public new async Task Handle(NewMessageReceived item, CancellationToken cancellationToken = default)
{
var prompt = "Please write a limerick greeting someone with the name " + item.Message;
var response = await client.CompleteAsync(prompt);
diff --git a/dotnet/samples/Hello/HelloAIAgents/Program.cs b/dotnet/samples/Hello/HelloAIAgents/Program.cs
index f9780d62af98..035da0353f85 100644
--- a/dotnet/samples/Hello/HelloAIAgents/Program.cs
+++ b/dotnet/samples/Hello/HelloAIAgents/Program.cs
@@ -7,7 +7,7 @@
using Microsoft.AutoGen.Core;
// send a message to the agent
-var builder = WebApplication.CreateBuilder();
+var builder = new HostApplicationBuilder();
// put these in your environment or appsettings.json
builder.Configuration["HelloAIAgents:ModelType"] = "azureopenai";
builder.Configuration["HelloAIAgents:LlmModelName"] = "gpt-3.5-turbo";
@@ -33,16 +33,14 @@ namespace Hello
{
[TopicSubscription("agents")]
public class HelloAgent(
- IAgentWorker worker,
- [FromKeyedServices("EventTypes")] EventTypes typeRegistry,
+ [FromKeyedServices("AgentsMetadata")] AgentsMetadata typeRegistry,
IHostApplicationLifetime hostApplicationLifetime) : ConsoleAgent(
- worker,
typeRegistry),
ISayHello,
IHandle,
IHandle
{
- public async Task Handle(NewMessageReceived item)
+ public async Task Handle(NewMessageReceived item, CancellationToken cancellationToken = default)
{
var response = await SayHello(item.Message).ConfigureAwait(false);
var evt = new Output
@@ -57,7 +55,7 @@ public async Task Handle(NewMessageReceived item)
};
await PublishMessageAsync(goodbye).ConfigureAwait(false);
}
- public async Task Handle(ConversationClosed item)
+ public async Task Handle(ConversationClosed item, CancellationToken cancellationToken = default)
{
var goodbye = $"********************* {item.UserId} said {item.UserMessage} ************************";
var evt = new Output
diff --git a/dotnet/samples/Hello/HelloAgent/HelloAgent.csproj b/dotnet/samples/Hello/HelloAgent/HelloAgent.csproj
index 5067a673df4b..73d3f43dc0e4 100644
--- a/dotnet/samples/Hello/HelloAgent/HelloAgent.csproj
+++ b/dotnet/samples/Hello/HelloAgent/HelloAgent.csproj
@@ -15,6 +15,7 @@
+
diff --git a/dotnet/samples/Hello/HelloAgent/Program.cs b/dotnet/samples/Hello/HelloAgent/Program.cs
index dee73b1a47d3..70c3fde7a3e7 100644
--- a/dotnet/samples/Hello/HelloAgent/Program.cs
+++ b/dotnet/samples/Hello/HelloAgent/Program.cs
@@ -8,7 +8,7 @@
var local = true;
if (Environment.GetEnvironmentVariable("AGENT_HOST") != null) { local = false; }
-var app = await AgentsApp.PublishMessageAsync("HelloAgents", new NewMessageReceived
+var app = await Microsoft.AutoGen.Core.Grpc.AgentsApp.PublishMessageAsync("HelloAgents", new NewMessageReceived
{
Message = "World"
}, local: local).ConfigureAwait(false);
@@ -18,9 +18,8 @@ namespace Hello
{
[TopicSubscription("agents")]
public class HelloAgent(
- IAgentWorker worker, IHostApplicationLifetime hostApplicationLifetime,
- [FromKeyedServices("EventTypes")] EventTypes typeRegistry) : Agent(
- worker,
+ IHostApplicationLifetime hostApplicationLifetime,
+ [FromKeyedServices("AgentsMetadata")] AgentsMetadata typeRegistry) : Agent(
typeRegistry),
ISayHello,
IHandleConsole,
@@ -28,7 +27,7 @@ public class HelloAgent(
IHandle,
IHandle
{
- public async Task Handle(NewMessageReceived item)
+ public async Task Handle(NewMessageReceived item, CancellationToken cancellationToken)
{
var response = await SayHello(item.Message).ConfigureAwait(false);
var evt = new Output { Message = response };
@@ -40,7 +39,7 @@ public async Task Handle(NewMessageReceived item)
};
await PublishMessageAsync(goodbye).ConfigureAwait(false);
}
- public async Task Handle(ConversationClosed item)
+ public async Task Handle(ConversationClosed item, CancellationToken cancellationToken)
{
var goodbye = $"********************* {item.UserId} said {item.UserMessage} ************************";
var evt = new Output { Message = goodbye };
@@ -51,13 +50,13 @@ public async Task Handle(ConversationClosed item)
}
}
- public async Task Handle(Shutdown item)
+ public async Task Handle(Shutdown item, CancellationToken cancellationToken)
{
Console.WriteLine("Shutting down...");
hostApplicationLifetime.StopApplication();
}
- public async Task SayHello(string ask)
+ public async Task SayHello(string ask, CancellationToken cancellationToken = default)
{
var response = $"\n\n\n\n***************Hello {ask}**********************\n\n\n\n";
return response;
@@ -65,6 +64,6 @@ public async Task SayHello(string ask)
}
public interface ISayHello
{
- public Task SayHello(string ask);
+ public Task SayHello(string ask, CancellationToken cancellationToken = default);
}
}
diff --git a/dotnet/samples/Hello/HelloAgent/README.md b/dotnet/samples/Hello/HelloAgent/README.md
index 53e3d6a65eba..968f454905c3 100644
--- a/dotnet/samples/Hello/HelloAgent/README.md
+++ b/dotnet/samples/Hello/HelloAgent/README.md
@@ -25,10 +25,10 @@ Flow Diagram:
```mermaid
%%{init: {'theme':'forest'}}%%
graph LR;
- A[Main] --> |"PublishEventAsync(NewMessage('World'))"| B{"Handle(NewMessageReceived item)"}
+ A[Main] --> |"PublishEventAsync(NewMessage('World'))"| B{"Handle(NewMessageReceived item, CancellationToken cancellationToken = default)"}
B --> |"PublishEventAsync(Output('***Hello, World***'))"| C[ConsoleAgent]
C --> D{"WriteConsole()"}
- B --> |"PublishEventAsync(ConversationClosed('Goodbye'))"| E{"Handle(ConversationClosed item)"}
+ B --> |"PublishEventAsync(ConversationClosed('Goodbye'))"| E{"Handle(ConversationClosed item, CancellationToken cancellationToken = default)"}
B --> |"PublishEventAsync(Output('***Goodbye***'))"| C
E --> F{"Shutdown()"}
@@ -44,14 +44,14 @@ Within that event handler you may optionally *emit* new events, which are then s
TopicSubscription("HelloAgents")]
public class HelloAgent(
iAgentWorker worker,
- [FromKeyedServices("EventTypes")] EventTypes typeRegistry) : ConsoleAgent(
+ [FromKeyedServices("AgentsMetadata")] AgentsMetadata typeRegistry) : ConsoleAgent(
worker,
typeRegistry),
ISayHello,
IHandle,
IHandle
{
- public async Task Handle(NewMessageReceived item)
+ public async Task Handle(NewMessageReceived item, CancellationToken cancellationToken = default)
{
var response = await SayHello(item.Message).ConfigureAwait(false);
var evt = new Output
diff --git a/dotnet/samples/Hello/HelloAgentState/Program.cs b/dotnet/samples/Hello/HelloAgentState/Program.cs
index dbb16c3bbb9b..013d70786551 100644
--- a/dotnet/samples/Hello/HelloAgentState/Program.cs
+++ b/dotnet/samples/Hello/HelloAgentState/Program.cs
@@ -18,10 +18,8 @@ namespace Hello
{
[TopicSubscription("agents")]
public class HelloAgent(
- IAgentWorker worker,
IHostApplicationLifetime hostApplicationLifetime,
- [FromKeyedServices("EventTypes")] EventTypes typeRegistry) : Agent(
- worker,
+ [FromKeyedServices("AgentsMetadata")] AgentsMetadata typeRegistry) : Agent(
typeRegistry),
IHandleConsole,
IHandle,
@@ -29,7 +27,7 @@ public class HelloAgent(
IHandle
{
private AgentState? State { get; set; }
- public async Task Handle(NewMessageReceived item)
+ public async Task Handle(NewMessageReceived item, CancellationToken cancellationToken = default)
{
var response = await SayHello(item.Message).ConfigureAwait(false);
var evt = new Output
@@ -57,7 +55,7 @@ await StoreAsync(new AgentState
await PublishMessageAsync(new Shutdown { Message = this.AgentId.Key }).ConfigureAwait(false);
}
- public async Task Handle(ConversationClosed item)
+ public async Task Handle(ConversationClosed item, CancellationToken cancellationToken = default)
{
State = await ReadAsync(this.AgentId).ConfigureAwait(false);
var state = JsonSerializer.Deserialize>(State.TextData) ?? new Dictionary { { "data", "No state data found" } };
@@ -74,7 +72,7 @@ await StoreAsync(new AgentState
TextData = JsonSerializer.Serialize(state)
}).ConfigureAwait(false);
}
- public async Task Handle(Shutdown item)
+ public async Task Handle(Shutdown item, CancellationToken cancellationToken = default)
{
string? workflow = null;
// make sure the workflow is finished
diff --git a/dotnet/samples/Hello/HelloAgentState/README.md b/dotnet/samples/Hello/HelloAgentState/README.md
index f46c66df1e1d..801d79a7c8f0 100644
--- a/dotnet/samples/Hello/HelloAgentState/README.md
+++ b/dotnet/samples/Hello/HelloAgentState/README.md
@@ -25,10 +25,10 @@ Flow Diagram:
```mermaid
%%{init: {'theme':'forest'}}%%
graph LR;
- A[Main] --> |"PublishEventAsync(NewMessage('World'))"| B{"Handle(NewMessageReceived item)"}
+ A[Main] --> |"PublishEventAsync(NewMessage('World'))"| B{"Handle(NewMessageReceived item, CancellationToken cancellationToken = default)"}
B --> |"PublishEventAsync(Output('***Hello, World***'))"| C[ConsoleAgent]
C --> D{"WriteConsole()"}
- B --> |"PublishEventAsync(ConversationClosed('Goodbye'))"| E{"Handle(ConversationClosed item)"}
+ B --> |"PublishEventAsync(ConversationClosed('Goodbye'))"| E{"Handle(ConversationClosed item, CancellationToken cancellationToken = default)"}
B --> |"PublishEventAsync(Output('***Goodbye***'))"| C
E --> F{"Shutdown()"}
@@ -44,14 +44,14 @@ Within that event handler you may optionally *emit* new events, which are then s
TopicSubscription("HelloAgents")]
public class HelloAgent(
iAgentWorker worker,
- [FromKeyedServices("EventTypes")] EventTypes typeRegistry) : ConsoleAgent(
+ [FromKeyedServices("AgentsMetadata")] AgentsMetadata typeRegistry) : ConsoleAgent(
worker,
typeRegistry),
ISayHello,
IHandle,
IHandle
{
- public async Task Handle(NewMessageReceived item)
+ public async Task Handle(NewMessageReceived item, CancellationToken cancellationToken = default)
{
var response = await SayHello(item.Message).ConfigureAwait(false);
var evt = new Output
diff --git a/dotnet/samples/dev-team/DevTeam.AgentHost/DevTeam.AgentHost.csproj b/dotnet/samples/dev-team/DevTeam.AgentHost/DevTeam.AgentHost.csproj
deleted file mode 100644
index 4da4bfd8d7e6..000000000000
--- a/dotnet/samples/dev-team/DevTeam.AgentHost/DevTeam.AgentHost.csproj
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
- net8.0
- enable
- enable
-
- $(NoWarn);CS8002
-
-
-
-
-
-
-
-
-
diff --git a/dotnet/samples/dev-team/DevTeam.AgentHost/Program.cs b/dotnet/samples/dev-team/DevTeam.AgentHost/Program.cs
deleted file mode 100644
index 82a2bf22ce98..000000000000
--- a/dotnet/samples/dev-team/DevTeam.AgentHost/Program.cs
+++ /dev/null
@@ -1,15 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Program.cs
-using Microsoft.AutoGen.Runtime.Grpc;
-
-var builder = WebApplication.CreateBuilder(args);
-
-builder.AddServiceDefaults();
-builder.AddAgentService();
-
-var app = builder.Build();
-
-app.MapDefaultEndpoints();
-app.MapAgentService();
-
-app.Run();
diff --git a/dotnet/samples/dev-team/DevTeam.AgentHost/appsettings.Development.json b/dotnet/samples/dev-team/DevTeam.AgentHost/appsettings.Development.json
deleted file mode 100644
index 0c208ae9181e..000000000000
--- a/dotnet/samples/dev-team/DevTeam.AgentHost/appsettings.Development.json
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- "Logging": {
- "LogLevel": {
- "Default": "Information",
- "Microsoft.AspNetCore": "Warning"
- }
- }
-}
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/DevTeam.Agents.csproj b/dotnet/samples/dev-team/DevTeam.Agents/DevTeam.Agents.csproj
deleted file mode 100644
index bc70545810bc..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/DevTeam.Agents.csproj
+++ /dev/null
@@ -1,18 +0,0 @@
-
-
-
- net8.0
- enable
- enable
-
-
-
-
-
-
-
-
-
-
-
-
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/Developer/Developer.cs b/dotnet/samples/dev-team/DevTeam.Agents/Developer/Developer.cs
deleted file mode 100644
index ffc474a93124..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/Developer/Developer.cs
+++ /dev/null
@@ -1,63 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Developer.cs
-
-using DevTeam.Shared;
-using Microsoft.AutoGen.Agents;
-using Microsoft.AutoGen.Contracts;
-using Microsoft.AutoGen.Core;
-using Microsoft.SemanticKernel;
-using Microsoft.SemanticKernel.Memory;
-
-namespace DevTeam.Agents;
-
-[TopicSubscription("devteam")]
-public class Dev(IAgentWorker worker, Kernel kernel, ISemanticTextMemory memory, [FromKeyedServices("EventTypes")] EventTypes typeRegistry, ILogger logger)
- : SKAiAgent(worker, memory, kernel, typeRegistry), IDevelopApps,
- IHandle,
- IHandle
-{
- public async Task Handle(CodeGenerationRequested item)
- {
- var code = await GenerateCode(item.Ask);
- var evt = new CodeGenerated
- {
- Org = item.Org,
- Repo = item.Repo,
- IssueNumber = item.IssueNumber,
- Code = code
- };
- await PublishMessageAsync(evt);
- }
-
- public async Task Handle(CodeChainClosed item)
- {
- //TODO: Get code from state
- var lastCode = ""; // _state.State.History.Last().Message
- var evt = new CodeCreated
- {
- Code = lastCode
- };
- await PublishMessageAsync(evt);
- }
-
- public async Task GenerateCode(string ask)
- {
- try
- {
- var context = new KernelArguments { ["input"] = AppendChatHistory(ask) };
- var instruction = "Consider the following architectural guidelines:!waf!";
- var enhancedContext = await AddKnowledge(instruction, "waf", context);
- return await CallFunction(DeveloperSkills.Implement, enhancedContext);
- }
- catch (Exception ex)
- {
- logger.LogError(ex, "Error generating code");
- return "";
- }
- }
-}
-
-public interface IDevelopApps
-{
- public Task GenerateCode(string ask);
-}
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/DeveloperLead/DeveloperLead.cs b/dotnet/samples/dev-team/DevTeam.Agents/DeveloperLead/DeveloperLead.cs
deleted file mode 100644
index ffeefe7d430f..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/DeveloperLead/DeveloperLead.cs
+++ /dev/null
@@ -1,70 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// DeveloperLead.cs
-
-using DevTeam.Shared;
-using Microsoft.AutoGen.Agents;
-using Microsoft.AutoGen.Contracts;
-using Microsoft.AutoGen.Core;
-using Microsoft.SemanticKernel;
-using Microsoft.SemanticKernel.Connectors.OpenAI;
-using Microsoft.SemanticKernel.Memory;
-
-namespace DevTeam.Agents;
-
-[TopicSubscription("devteam")]
-public class DeveloperLead(IAgentWorker worker, Kernel kernel, ISemanticTextMemory memory, [FromKeyedServices("EventTypes")] EventTypes typeRegistry, ILogger logger)
- : SKAiAgent(worker, memory, kernel, typeRegistry), ILeadDevelopers,
- IHandle,
- IHandle
-{
- public async Task Handle(DevPlanRequested item)
- {
- var plan = await CreatePlan(item.Ask);
- var evt = new DevPlanGenerated
- {
- Org = item.Org,
- Repo = item.Repo,
- IssueNumber = item.IssueNumber,
- Plan = plan
- };
- await PublishMessageAsync(evt);
- }
-
- public async Task Handle(DevPlanChainClosed item)
- {
- // TODO: Get plan from state
- var lastPlan = ""; // _state.State.History.Last().Message
- var evt = new DevPlanCreated
- {
- Plan = lastPlan
- };
- await PublishMessageAsync(evt);
- }
- public async Task CreatePlan(string ask)
- {
- try
- {
- var context = new KernelArguments { ["input"] = AppendChatHistory(ask) };
- var instruction = "Consider the following architectural guidelines:!waf!";
- var enhancedContext = await AddKnowledge(instruction, "waf", context);
- var settings = new OpenAIPromptExecutionSettings
- {
- ResponseFormat = "json_object",
- MaxTokens = 4096,
- Temperature = 0.8,
- TopP = 1
- };
- return await CallFunction(DevLeadSkills.Plan, enhancedContext, settings);
- }
- catch (Exception ex)
- {
- logger.LogError(ex, "Error creating development plan");
- return "";
- }
- }
-}
-
-public interface ILeadDevelopers
-{
- public Task CreatePlan(string ask);
-}
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/ProductManager/ProductManager.cs b/dotnet/samples/dev-team/DevTeam.Agents/ProductManager/ProductManager.cs
deleted file mode 100644
index 5306a91838e3..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/ProductManager/ProductManager.cs
+++ /dev/null
@@ -1,63 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// ProductManager.cs
-
-using DevTeam.Shared;
-using Microsoft.AutoGen.Agents;
-using Microsoft.AutoGen.Contracts;
-using Microsoft.AutoGen.Core;
-using Microsoft.SemanticKernel;
-using Microsoft.SemanticKernel.Memory;
-
-namespace DevTeam.Agents;
-
-[TopicSubscription("devteam")]
-public class ProductManager(IAgentWorker worker, Kernel kernel, ISemanticTextMemory memory, [FromKeyedServices("EventTypes")] EventTypes typeRegistry, ILogger logger)
- : SKAiAgent(worker, memory, kernel, typeRegistry), IManageProducts,
- IHandle,
- IHandle
-{
- public async Task Handle(ReadmeChainClosed item)
- {
- // TODO: Get readme from state
- var lastReadme = ""; // _state.State.History.Last().Message
- var evt = new ReadmeCreated
- {
- Readme = lastReadme
- };
- await PublishMessageAsync(evt);
- }
-
- public async Task Handle(ReadmeRequested item)
- {
- var readme = await CreateReadme(item.Ask);
- var evt = new ReadmeGenerated
- {
- Readme = readme,
- Org = item.Org,
- Repo = item.Repo,
- IssueNumber = item.IssueNumber
- };
- await PublishMessageAsync(evt);
- }
-
- public async Task CreateReadme(string ask)
- {
- try
- {
- var context = new KernelArguments { ["input"] = AppendChatHistory(ask) };
- var instruction = "Consider the following architectural guidelines:!waf!";
- var enhancedContext = await AddKnowledge(instruction, "waf", context);
- return await CallFunction(PMSkills.Readme, enhancedContext);
- }
- catch (Exception ex)
- {
- logger.LogError(ex, "Error creating readme");
- return "";
- }
- }
-}
-
-public interface IManageProducts
-{
- public Task CreateReadme(string ask);
-}
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/Program.cs b/dotnet/samples/dev-team/DevTeam.Agents/Program.cs
deleted file mode 100644
index bd9e4ad24832..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/Program.cs
+++ /dev/null
@@ -1,23 +0,0 @@
-// Copyright (c) Microsoft Corporation. All rights reserved.
-// Program.cs
-
-using DevTeam.Agents;
-using Microsoft.AutoGen.Core;
-using Microsoft.AutoGen.Extensions.SemanticKernel;
-
-var builder = WebApplication.CreateBuilder(args);
-
-builder.AddServiceDefaults();
-
-builder.ConfigureSemanticKernel();
-
-builder.AddAgentWorker(builder.Configuration["AGENT_HOST"]!)
- .AddAgent(nameof(Dev))
- .AddAgent(nameof(ProductManager))
- .AddAgent(nameof(DeveloperLead));
-
-var app = builder.Build();
-
-app.MapDefaultEndpoints();
-
-app.Run();
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/Properties/launchSettings.json b/dotnet/samples/dev-team/DevTeam.Agents/Properties/launchSettings.json
deleted file mode 100644
index 8edfece6ad8d..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/Properties/launchSettings.json
+++ /dev/null
@@ -1,12 +0,0 @@
-{
- "profiles": {
- "DevTeam.Agents": {
- "commandName": "Project",
- "launchBrowser": true,
- "environmentVariables": {
- "ASPNETCORE_ENVIRONMENT": "Development"
- },
- "applicationUrl": "https://localhost:50669;http://localhost:50671"
- }
- }
-}
\ No newline at end of file
diff --git a/dotnet/samples/dev-team/DevTeam.Agents/appsettings.Development.json b/dotnet/samples/dev-team/DevTeam.Agents/appsettings.Development.json
deleted file mode 100644
index 0c208ae9181e..000000000000
--- a/dotnet/samples/dev-team/DevTeam.Agents/appsettings.Development.json
+++ /dev/null
@@ -1,8 +0,0 @@
-{
- "Logging": {
- "LogLevel": {
- "Default": "Information",
- "Microsoft.AspNetCore": "Warning"
- }
- }
-}
diff --git a/dotnet/samples/dev-team/DevTeam.AppHost/DevTeam.AppHost.csproj b/dotnet/samples/dev-team/DevTeam.AppHost/DevTeam.AppHost.csproj
index 89d121b303ea..eab38e3ba71a 100644
--- a/dotnet/samples/dev-team/DevTeam.AppHost/DevTeam.AppHost.csproj
+++ b/dotnet/samples/dev-team/DevTeam.AppHost/DevTeam.AppHost.csproj
@@ -21,8 +21,6 @@
-
-
diff --git a/dotnet/samples/dev-team/DevTeam.AppHost/Program.cs b/dotnet/samples/dev-team/DevTeam.AppHost/Program.cs
index 99dd61a790bc..227a35e6bcb5 100644
--- a/dotnet/samples/dev-team/DevTeam.AppHost/Program.cs
+++ b/dotnet/samples/dev-team/DevTeam.AppHost/Program.cs
@@ -7,22 +7,16 @@
var qdrant = builder.AddQdrant("qdrant");
-var orleans = builder.AddOrleans("orleans")
- .WithDevelopmentClustering();
+var agentHost = builder.AddContainer("agent-host", "autogen-host")
+ .WithEnvironment("ASPNETCORE_URLS", "https://+;http://+")
+ .WithEnvironment("ASPNETCORE_HTTPS_PORTS", "5001")
+ .WithEnvironment("ASPNETCORE_Kestrel__Certificates__Default__Password", "mysecurepass")
+ .WithEnvironment("ASPNETCORE_Kestrel__Certificates__Default__Path", "/https/devcert.pfx")
+ .WithBindMount("./certs", "/https/", true)
+ .WithHttpsEndpoint(targetPort: 5001);
-var agentHost = builder.AddProject("agenthost")
- .WithReference(orleans);
var agentHostHttps = agentHost.GetEndpoint("https");
-//TODO: pass the right variables - aca environment
-// var environmentId = builder.AddParameter("environmentId");
-// var acaSessions = builder.AddBicepTemplateString(
-// name: "aca-sessions",
-// bicepContent: BicepTemplates.Sessions
-// )
-// .WithParameter("environmentId", environmentId);
-// var acaSessionsEndpoint = acaSessions.GetOutput("endpoint");
-
builder.AddProject("backend")
.WithEnvironment("AGENT_HOST", $"{agentHostHttps.Property(EndpointProperty.Url)}")
.WithEnvironment("Qdrant__Endpoint", $"{qdrant.Resource.HttpEndpoint.Property(EndpointProperty.Url)}")
@@ -33,16 +27,10 @@
.WithEnvironment("Github__AppId", builder.Configuration["Github:AppId"])
.WithEnvironment("Github__InstallationId", builder.Configuration["Github:InstallationId"])
.WithEnvironment("Github__WebhookSecret", builder.Configuration["Github:WebhookSecret"])
- .WithEnvironment("Github__AppKey", builder.Configuration["Github:AppKey"]);
+ .WithEnvironment("Github__AppKey", builder.Configuration["Github:AppKey"])
+ .WaitFor(agentHost)
+ .WaitFor(qdrant);
//TODO: add this to the config in backend
//.WithEnvironment("", acaSessionsEndpoint);
-builder.AddProject("dev-agents")
- .WithEnvironment("AGENT_HOST", $"{agentHostHttps.Property(EndpointProperty.Url)}")
- .WithEnvironment("Qdrant__Endpoint", $"{qdrant.Resource.HttpEndpoint.Property(EndpointProperty.Url)}")
- .WithEnvironment("Qdrant__ApiKey", $"{qdrant.Resource.ApiKeyParameter.Value}")
- .WithEnvironment("Qdrant__VectorSize", "1536")
- .WithEnvironment("OpenAI__Key", builder.Configuration["OpenAI:Key"])
- .WithEnvironment("OpenAI__Endpoint", builder.Configuration["OpenAI:Endpoint"]);
-
builder.Build().Run();
diff --git a/dotnet/samples/dev-team/DevTeam.AppHost/Properties/launchSettings.json b/dotnet/samples/dev-team/DevTeam.AppHost/Properties/launchSettings.json
new file mode 100644
index 000000000000..eae31b662c3d
--- /dev/null
+++ b/dotnet/samples/dev-team/DevTeam.AppHost/Properties/launchSettings.json
@@ -0,0 +1,29 @@
+{
+ "$schema": "https://json.schemastore.org/launchsettings.json",
+ "profiles": {
+ "https": {
+ "commandName": "Project",
+ "dotnetRunMessages": true,
+ "launchBrowser": true,
+ "applicationUrl": "https://localhost:17034;http://localhost:15043",
+ "environmentVariables": {
+ "ASPNETCORE_ENVIRONMENT": "Development",
+ "DOTNET_ENVIRONMENT": "Development",
+ "DOTNET_DASHBOARD_OTLP_ENDPOINT_URL": "https://localhost:21249",
+ "DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "https://localhost:22030"
+ }
+ },
+ "http": {
+ "commandName": "Project",
+ "dotnetRunMessages": true,
+ "launchBrowser": true,
+ "applicationUrl": "http://localhost:15043",
+ "environmentVariables": {
+ "ASPNETCORE_ENVIRONMENT": "Development",
+ "DOTNET_ENVIRONMENT": "Development",
+ "DOTNET_DASHBOARD_OTLP_ENDPOINT_URL": "http://localhost:19105",
+ "DOTNET_RESOURCE_SERVICE_ENDPOINT_URL": "http://localhost:20096"
+ }
+ }
+ }
+ }
\ No newline at end of file
diff --git a/dotnet/samples/dev-team/DevTeam.Backend/Agents/AzureGenie.cs b/dotnet/samples/dev-team/DevTeam.Backend/Agents/AzureGenie.cs
index 85d498bcc5aa..59ac34ba45a3 100644
--- a/dotnet/samples/dev-team/DevTeam.Backend/Agents/AzureGenie.cs
+++ b/dotnet/samples/dev-team/DevTeam.Backend/Agents/AzureGenie.cs
@@ -1,21 +1,17 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// AzureGenie.cs
-using DevTeam.Backend;
-using DevTeam.Shared;
-using Microsoft.AutoGen.Agents;
+using DevTeam.Backend.Services;
using Microsoft.AutoGen.Core;
-using Microsoft.SemanticKernel;
-using Microsoft.SemanticKernel.Memory;
-namespace Microsoft.AI.DevTeam;
+namespace DevTeam.Backend.Agents;
-public class AzureGenie(IAgentWorker worker, Kernel kernel, ISemanticTextMemory memory, [FromKeyedServices("EventTypes")] EventTypes typeRegistry, IManageAzure azureService)
- : SKAiAgent