Merged
Conversation
…trations for protocol-only partial executors
Contributor
There was a problem hiding this comment.
Pull request overview
Updates .NET workflow samples to work with polymorphic routing changes by explicitly declaring message/output types for executors.
Changes:
- Add
[SendsMessage]annotations to executors that dispatch messages so routing can resolve the intended message types. - Add
[YieldsOutput]annotations to executors that emit final workflow outputs. - Minor formatting fix in the Loop sample (statement terminator).
Reviewed changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated no comments.
Show a summary per file
| File | Description |
|---|---|
| dotnet/samples/03-workflows/_StartHere/06_MixedWorkflowAgentsAndExecutors/Program.cs | Declares sent message types (ChatMessage, TurnToken) for executors involved in mixed agent/executor routing. |
| dotnet/samples/03-workflows/SharedStates/Program.cs | Declares the aggregation executor’s yielded output type. |
| dotnet/samples/03-workflows/Loop/Program.cs | Declares executor send/yield types and fixes a formatting issue in YieldOutputAsync call. |
| dotnet/samples/03-workflows/HumanInTheLoop/HumanInTheLoopBasic/WorkflowFactory.cs | Declares judge executor send/yield types for correct routing/output behavior. |
| dotnet/samples/03-workflows/ConditionalEdges/03_MultiSelection/Program.cs | Declares output yielding for terminal executors in multi-selection flow. |
| dotnet/samples/03-workflows/ConditionalEdges/02_SwitchCase/Program.cs | Declares output yielding for terminal executors in switch-case flow. |
| dotnet/samples/03-workflows/ConditionalEdges/01_EdgeCondition/Program.cs | Declares output yielding for terminal executors in edge-condition flow. |
| dotnet/samples/03-workflows/Concurrent/MapReduce/Program.cs | Declares sent message types for each stage and the final yielded output type for completion. |
| dotnet/samples/03-workflows/Concurrent/Concurrent/Program.cs | Declares sent message/output types for concurrent start/aggregation executors. |
| dotnet/samples/03-workflows/Checkpoint/CheckpointWithHumanInTheLoop/WorkflowFactory.cs | Declares judge executor send/yield types for checkpoint + HITL scenario. |
| dotnet/samples/03-workflows/Checkpoint/CheckpointAndResume/WorkflowFactory.cs | Declares guess/judge executor send/yield types for checkpoint-and-resume scenario. |
| dotnet/samples/03-workflows/Checkpoint/CheckpointAndRehydrate/WorkflowFactory.cs | Declares guess/judge executor send/yield types for checkpoint-and-rehydrate scenario. |
| dotnet/samples/03-workflows/Agents/WorkflowAsAnAgent/WorkflowFactory.cs | Declares yielded output type for workflow-as-agent aggregation executor. |
SergeyMenshykh
approved these changes
Mar 20, 2026
westey-m
approved these changes
Mar 20, 2026
This was referenced Mar 23, 2026
This was referenced Apr 3, 2026
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Fixing some workflow samples that were missed during polymorphic routing changes.
Fixes #4144
Contribution Checklist