Are you sure you want to delete this task? Once this task is deleted, it cannot be recovered.
|
|
1 year ago | |
|---|---|---|
| .. | ||
| .config | 2 years ago | |
| .tools | 2 years ago | |
| eng | 1 year ago | |
| nuget | 1 year ago | |
| resource/images | 2 years ago | |
| samples | 1 year ago | |
| src | 1 year ago | |
| test | 1 year ago | |
| website | 1 year ago | |
| .editorconfig | 1 year ago | |
| .gitattributes | 2 years ago | |
| .gitignore | 1 year ago | |
| AutoGen.sln | 1 year ago | |
| Directory.Build.props | 1 year ago | |
| Directory.Build.targets | 2 years ago | |
| Directory.Packages.props | 1 year ago | |
| NuGet.config | 2 years ago | |
| README.md | 1 year ago | |
| global.json | 1 year ago | |
| spelling.dic | 2 years ago | |
Thre are two sets of packages here
Autogen.* the older packages derived from Autogen 0.2 for .NET - these will gradually be deprecated and ported into the new packages
Microsoft.AutoGen.* the new packages for .NET that use the event-driven model - These APIs are not yet stable and are subject to change
The remaining content is for the older Autogen.* packages.
[!NOTE]
Nightly build is available at:
Firstly, following the installation guide to install AutoGen packages.
Then you can start with the following code snippet to create a conversable agent and chat with it.
using AutoGen;
using AutoGen.OpenAI;
var openAIKey = Environment.GetEnvironmentVariable("OPENAI_API_KEY") ?? throw new Exception("Please set OPENAI_API_KEY environment variable.");
var gpt35Config = new OpenAIConfig(openAIKey, "gpt-3.5-turbo");
var assistantAgent = new AssistantAgent(
name: "assistant",
systemMessage: "You are an assistant that help user to do some tasks.",
llmConfig: new ConversableAgentConfig
{
Temperature = 0,
ConfigList = [gpt35Config],
})
.RegisterPrintMessage(); // register a hook to print message nicely to console
// set human input mode to ALWAYS so that user always provide input
var userProxyAgent = new UserProxyAgent(
name: "user",
humanInputMode: ConversableAgent.HumanInputMode.ALWAYS)
.RegisterPrintMessage();
// start the conversation
await userProxyAgent.InitiateChatAsync(
receiver: assistantAgent,
message: "Hey assistant, please do me a favor.",
maxRound: 10);
You can find more examples under the sample project.
ConversableAgent
Agent communication
Exclusive for dotnet
This is a mirror of AutoGen from GitHub. AutoGen is a framework that enables the development of LLM applications using multiple agents that can converse with each other to solve tasks.
Python SVG Jupyter Notebook C# TSX other