Skip to content

Commit d7c2489

Browse files
authored
Python: Add MultiAgent Orchestration to README. (#12073)
### Motivation and Context The new multi-agent orchestration samples are missing from the getting started with agents README. Add them in with their descriptions. Also, remove two unused intermediate message callback lists from two samples that are no longer used. <!-- Thank you for your contribution to the semantic-kernel repo! Please help reviewers and future users, providing the following information: 1. Why is this change required? 2. What problem does it solve? 3. What scenario does it contribute to? 4. If it fixes an open issue, please link to the issue here. --> ### Description Add samples to README. Clean up some samples. <!-- Describe your changes, the overall approach, the underlying design. These notes will help understanding how your code works. Thanks! --> ### Contribution Checklist <!-- Before submitting this PR, please make sure: --> - [X] The code builds clean without any errors or warnings - [X] The PR follows the [SK Contribution Guidelines](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md) and the [pre-submission formatting script](https://github.com/microsoft/semantic-kernel/blob/main/CONTRIBUTING.md#development-scripts) raises no violations - [X] All unit tests pass, and I have added new tests where possible - [X] I didn't break anyone 😄
1 parent d65f9b2 commit d7c2489

File tree

4 files changed

+16
-7
lines changed

4 files changed

+16
-7
lines changed

python/samples/concepts/agents/chat_completion_agent/chat_completion_agent_message_callback.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -40,9 +40,6 @@ def get_item_price(
4040
return "$9.99"
4141

4242

43-
intermediate_steps: list[ChatMessageContent] = []
44-
45-
4643
# This callback function will be called for each intermediate message
4744
# Which will allow one to handle FunctionCallContent and FunctionResultContent
4845
# If the callback is not provided, the agent will return the final response

python/samples/concepts/agents/chat_completion_agent/chat_completion_agent_message_callback_streaming.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,6 @@ def get_item_price(
3737
return "$9.99"
3838

3939

40-
intermediate_steps: list[ChatMessageContent] = []
41-
42-
4340
# This callback function will be called for each intermediate message
4441
# Which will allow one to handle FunctionCallContent and FunctionResultContent
4542
# If the callback is not provided, the agent will return the final response

python/samples/getting_started_with_agents/README.md

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -49,6 +49,21 @@ Example|Description
4949

5050
_Note: For details on configuring an Azure AI Agent, please see [here](../getting_started_with_agents/azure_ai_agent/README.md)._
5151

52+
## Multi Agent Orchestration
53+
54+
Example|Description
55+
---|---
56+
[step1_concurrent](../getting_started_with_agents/multi_agent_orchestration/step1_concurrent.py)|How to run multiple agents concurrently and manage their output.
57+
[step1a_concurrent_structure_output](../getting_started_with_agents/multi_agent_orchestration/step1a_concurrent_structure_output.py)|How to run concurrent agents that return structured outputs.
58+
[step2_sequential](../getting_started_with_agents/multi_agent_orchestration/step2_sequential.py)|How to run agents sequentially where each one depends on the previous.
59+
[step2a_sequential_cancellation_token](../getting_started_with_agents/multi_agent_orchestration/step2a_sequential_cancellation_token.py)|How to use cancellation tokens in a sequential agent flow.
60+
[step3_group_chat](../getting_started_with_agents/multi_agent_orchestration/step3_group_chat.py)|How to create a group chat with multiple agents interacting together.
61+
[step3a_group_chat_human_in_the_loop](../getting_started_with_agents/multi_agent_orchestration/step3a_group_chat_human_in_the_loop.py)|How to include a human participant in a group chat with agents.
62+
[step3b_group_chat_with_chat_completion_manager](../getting_started_with_agents/multi_agent_orchestration/step3b_group_chat_with_chat_completion_manager.py)|How to manage a group chat with agents using a chat completion manager.
63+
[step4_handoff](../getting_started_with_agents/multi_agent_orchestration/step4_handoff.py)|How to hand off conversation or tasks from one agent to another.
64+
[step4a_handoff_structured_inputs](../getting_started_with_agents/multi_agent_orchestration/step4a_handoff_structured_inputs.py)|How to perform structured inputs handoffs between agents.
65+
66+
5267
## OpenAI Assistant Agent
5368

5469
Example|Description
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@
1616
specialized in a different area.
1717
1818
The input to the orchestration is not longer a string or a chat message, but a Pydantic
19-
model (i.e. structure input). The model will get transformed into a chat message before
19+
model (i.e. structured inputs). The model will get transformed into a chat message before
2020
being passed to the agents. This allows the orchestration to become more flexible and
2121
easier reusable.
2222

0 commit comments

Comments
 (0)