AutoGen is a framework that enables the development of agent systems using TypeScript. It provides
a flexible, type-safe foundation for building multi-agent applications.
Install AutoGen TypeScript using npm:
npm install @microsoft/autogen-ts
Here's a simple example of creating and using agents:
import { AgentsApp } from '@microsoft/autogen-ts';
async function main() {
const app = await new AgentsAppBuilder()
.useInProcessRuntime()
.build();
await app.start();
try {
// Create an agent instance
const agentId = { type: "MyAgent", key: "instance1" };
await app.runtime.sendMessageAsync(
{ content: "Hello!" },
agentId
);
} finally {
await app.shutdown();
}
}
For detailed API documentation, see the API Reference.