release notes
release notes
Published 3/12/2025
Contains breaking changesStarting v0.4.9, the team state is using the agent name as the key instead of the agent ID, and the team_id field is removed from the state. This is to allow the state to be portable across different teams and runtimes. States saved with the old format may not be compatible with the new format in the future.
See migration scripts here: https://github.com/ekzhu/autogen-migration/
Native support for Anthropic models. Get your update: Â
pip install -U "autogen-ext[anthropic]"
The new client follows the same interface as OpenAIChatCompletionClient so you can use it directly in your agents and teams.
import asyncio
from autogen_ext.models.anthropic import AnthropicChatCompletionClient
from autogen_core.models import UserMessage
async def main():
anthropic_client = AnthropicChatCompletionClient(
model="claude-3-sonnet-20240229",
api_key="your-api-key", # Optional if ANTHROPIC_API_KEY is set in environment
)
result = await anthropic_client.create([UserMessage(content="What is the capital of France?", source="user")]) # type: ignore
print(result)
if __name__ == "__main__":
asyncio.run(main())
You can also load the model client directly from a configuration dictionary:
from autogen_core.models import ChatCompletionClient
config = {
"provider": "AnthropicChatCompletionClient",
"config": {"model": "claude-3-sonnet-20240229"},
}
client = ChatCompletionClient.load_component(config)
To use with AssistantAgent and run the agent in a loop to match the behavior of Claude agents, you can use Single-Agent Team.
LlamaCpp is a great project for working with local models. Now we have native support via its official SDK.
pip install -U "autogen-ext[llama-cpp]"
To use a local model file:
import asyncio
from autogen_core.models import UserMessage
from autogen_ext.models.llama_cpp import LlamaCppChatCompletionClient
async def main():
llama_client = LlamaCppChatCompletionClient(model_path="/path/to/your/model.gguf")
result = await llama_client.create([UserMessage(content="What is the capital of France?", source="user")])
print(result)
asyncio.run(main())
To use it with a Hugging Face model:
import asyncio
from autogen_core.models import UserMessage
from autogen_ext.models.llama_cpp import LlamaCppChatCompletionClient
async def main():
llama_client = LlamaCppChatCompletionClient(
repo_id="unsloth/phi-4-GGUF", filename="phi-4-Q2_K_L.gguf", n_gpu_layers=-1, seed=1337, n_ctx=5000
)
result = await llama_client.create([UserMessage(content="What is the capital of France?", source="user")])
print(result)
asyncio.run(main())
Task-Centric memory is an experimental module that can give agents the ability to:
For example, you can use Teachability as a memory for AssistantAgent so your agent can learn from user teaching.
from autogen_agentchat.agents import AssistantAgent
from autogen_agentchat.ui import Console
from autogen_ext.models.openai import OpenAIChatCompletionClient
from autogen_ext.experimental.task_centric_memory import MemoryController
from autogen_ext.experimental.task_centric_memory.utils import Teachability
async def main():
# Create a client
client = OpenAIChatCompletionClient(model="gpt-4o-2024-08-06", )
# Create an instance of Task-Centric Memory, passing minimal parameters for this simple example
memory_controller = MemoryController(reset=False, client=client)
# Wrap the memory controller in a Teachability instance
teachability = Teachability(memory_controller=memory_controller)
# Create an AssistantAgent, and attach teachability as its memory
assistant_agent = AssistantAgent(
name="teachable_agent",
system_message = "You are a helpful AI assistant, with the special ability to remember user teachings from prior conversations.",
model_client=client,
memory=[teachability],
)
# Enter a loop to chat with the teachable agent
print("Now chatting with a teachable agent. Please enter your first message. Type 'exit' or 'quit' to quit.")
while True:
user_input = input("\nYou: ")
if user_input.lower() in ["exit", "quit"]:
break
await Console(assistant_agent.run_stream(task=user_input))
if __name__ == "__main__":
import asyncio
asyncio.run(main())
Head over to its README for details, and the samples for runnable examples.
Gitty is an experimental application built to help easing the burden on open-source project maintainers. Currently, it can generate auto reply to issues.
To use:
gitty --repo microsoft/autogen issue 5212
Head over to Gitty to see details.
In this version, we made a number of improvements on tracing and logging.
LocalCommandLineCodeExecutor@peterychang has made huge improvements to the accessibility of our documentation website. Thank you @peterychang!
Full Changelog: https://github.com/microsoft/autogen/compare/python-v0.4.8...python-v0.4.9
release notes
Published 3/12/2025
Contains breaking changesStarting v0.4.9, the team state is using the agent name as the key instead of the agent ID, and the team_id field is removed from the state. This is to allow the state to be portable across different teams and runtimes. States saved with the old format may not be compatible with the new format in the future.
See migration scripts here: https://github.com/ekzhu/autogen-migration/
Native support for Anthropic models. Get your update: Â
pip install -U "autogen-ext[anthropic]"
The new client follows the same interface as OpenAIChatCompletionClient so you can use it directly in your agents and teams.
import asyncio
from autogen_ext.models.anthropic import AnthropicChatCompletionClient
from autogen_core.models import UserMessage
async def main():
anthropic_client = AnthropicChatCompletionClient(
model="claude-3-sonnet-20240229",
api_key="your-api-key", # Optional if ANTHROPIC_API_KEY is set in environment
)
result = await anthropic_client.create([UserMessage(content="What is the capital of France?", source="user")]) # type: ignore
print(result)
if __name__ == "__main__":
asyncio.run(main())
You can also load the model client directly from a configuration dictionary:
from autogen_core.models import ChatCompletionClient
config = {
"provider": "AnthropicChatCompletionClient",
"config": {"model": "claude-3-sonnet-20240229"},
}
client = ChatCompletionClient.load_component(config)
To use with AssistantAgent and run the agent in a loop to match the behavior of Claude agents, you can use Single-Agent Team.
LlamaCpp is a great project for working with local models. Now we have native support via its official SDK.
pip install -U "autogen-ext[llama-cpp]"
To use a local model file:
import asyncio
from autogen_core.models import UserMessage
from autogen_ext.models.llama_cpp import LlamaCppChatCompletionClient
async def main():
llama_client = LlamaCppChatCompletionClient(model_path="/path/to/your/model.gguf")
result = await llama_client.create([UserMessage(content="What is the capital of France?", source="user")])
print(result)
asyncio.run(main())
To use it with a Hugging Face model:
import asyncio
from autogen_core.models import UserMessage
from autogen_ext.models.llama_cpp import LlamaCppChatCompletionClient
async def main():
llama_client = LlamaCppChatCompletionClient(
repo_id="unsloth/phi-4-GGUF", filename="phi-4-Q2_K_L.gguf", n_gpu_layers=-1, seed=1337, n_ctx=5000
)
result = await llama_client.create([UserMessage(content="What is the capital of France?", source="user")])
print(result)
asyncio.run(main())
Task-Centric memory is an experimental module that can give agents the ability to:
For example, you can use Teachability as a memory for AssistantAgent so your agent can learn from user teaching.
from autogen_agentchat.agents import AssistantAgent
from autogen_agentchat.ui import Console
from autogen_ext.models.openai import OpenAIChatCompletionClient
from autogen_ext.experimental.task_centric_memory import MemoryController
from autogen_ext.experimental.task_centric_memory.utils import Teachability
async def main():
# Create a client
client = OpenAIChatCompletionClient(model="gpt-4o-2024-08-06", )
# Create an instance of Task-Centric Memory, passing minimal parameters for this simple example
memory_controller = MemoryController(reset=False, client=client)
# Wrap the memory controller in a Teachability instance
teachability = Teachability(memory_controller=memory_controller)
# Create an AssistantAgent, and attach teachability as its memory
assistant_agent = AssistantAgent(
name="teachable_agent",
system_message = "You are a helpful AI assistant, with the special ability to remember user teachings from prior conversations.",
model_client=client,
memory=[teachability],
)
# Enter a loop to chat with the teachable agent
print("Now chatting with a teachable agent. Please enter your first message. Type 'exit' or 'quit' to quit.")
while True:
user_input = input("\nYou: ")
if user_input.lower() in ["exit", "quit"]:
break
await Console(assistant_agent.run_stream(task=user_input))
if __name__ == "__main__":
import asyncio
asyncio.run(main())
Head over to its README for details, and the samples for runnable examples.
Gitty is an experimental application built to help easing the burden on open-source project maintainers. Currently, it can generate auto reply to issues.
To use:
gitty --repo microsoft/autogen issue 5212
Head over to Gitty to see details.
In this version, we made a number of improvements on tracing and logging.
LocalCommandLineCodeExecutor@peterychang has made huge improvements to the accessibility of our documentation website. Thank you @peterychang!
Full Changelog: https://github.com/microsoft/autogen/compare/python-v0.4.8...python-v0.4.9
A programming framework for agentic AI