Skip to content

Conversation

@dargilco
Copy link
Member

@dargilco dargilco commented Dec 23, 2025

  • Use extra_body={"agent": {"name": agent.name, "type": "agent_reference"}} in Responses call, as per all other samples.
  • Use a more readable Agent name (and unique between sync and async) in Agent Workflow samples
  • Simplify printout of events, such that all events are printed, with additional event info when present
  • Run 'black' tool for fix fomatting

The Agent workflow samples run fine, but it's not clear to me how I get the input and output messages of the student and teacher Agents after the run is complete (or during the run). The events printout correctly shows the status of the workflow (which workflow item it is being processed), but there is no printout related to what is actually happening with regards to messages, including the expected [COMPLETE] message from the teacher Agent when it thinks it's done. I will need to update the samples again once I understand how to get this information.

@dargilco dargilco self-assigned this Dec 23, 2025
Copilot AI review requested due to automatic review settings December 23, 2025 18:23
@dargilco dargilco changed the title Sample updates Agent workflow sample updates and other minor updates Dec 23, 2025
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates sample code to use more idiomatic patterns and improve consistency across async and sync implementations.

  • Replaces AgentReference model usage with direct dictionary literals for better simplicity
  • Enhances workflow samples with improved event handling and agent naming conventions
  • Uses type-safe enum values instead of string literals for item type comparisons

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated no comments.

Show a summary per file
File Description
sdk/ai/azure-ai-projects/samples/agents/tools/sample_agent_computer_use_async.py Removes AgentReference import and replaces model instantiation with dict literal in extra_body parameter
sdk/ai/azure-ai-projects/samples/agents/tools/sample_agent_computer_use.py Removes AgentReference import and replaces model instantiation with dict literal in extra_body parameter
sdk/ai/azure-ai-projects/samples/agents/telemetry/sample_agent_basic_with_console_tracing.py Removes AgentReference import and replaces model instantiation with dict literal in extra_body parameter
sdk/ai/azure-ai-projects/samples/agents/sample_workflow_multi_agent_async.py Updates agent names with "-async" suffix for clarity, imports ItemType enum, improves event stream handling with better logging and uses enum for type checking
sdk/ai/azure-ai-projects/samples/agents/sample_workflow_multi_agent.py Updates workflow agent name for consistency, imports ItemType enum, improves event stream handling with better logging and uses enum for type checking

@dargilco dargilco enabled auto-merge (squash) December 23, 2025 23:11
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants