Skip to content

.NET Workflows - Support fidelity when converting to and from ChatMessage in declarative workflows - #3021

Closed
Chris (crickman) wants to merge 10 commits into
crickman/dependency-update-declarative-objectmodelfrom
crickman/messaging-handling-fix-declarative-workflows
Closed

.NET Workflows - Support fidelity when converting to and from ChatMessage in declarative workflows#3021
Chris (crickman) wants to merge 10 commits into
crickman/dependency-update-declarative-objectmodelfrom
crickman/messaging-handling-fix-declarative-workflows

Conversation

@crickman

@crickmanChris (crickman) commented Dec 23, 2025

Copy link
Copy Markdown
Contributor

Motivation and Context

Ensures media-type and message id are persisted when converting between ChatMessage and the object model representation.

Fixes: #3020

Note: Relies on dependency update in PR #3017 (rebase this PR to main after merged)

Description

  • Makes use of update to Object Model update that supports MediaType
  • Tests added

Contribution Checklist

  • The code builds clean without any errors or warnings
  • The PR follows the Contribution Guidelines
  • All unit tests pass, and I have added new tests where possible
  • Is this a breaking change? If yes, add "[BREAKING]" prefix to the title of the PR.

@crickmanChris (crickman) self-assigned this Dec 23, 2025
@crickmanChris (crickman) added .NET Usage: [Issues, PRs], Target: .Net workflows Usage: [Issues, PRs], Target: Workflows labels Dec 23, 2025
private static string InferMediaType(string value)
{
// Base64 encoded content includes media type
if (value.StartsWith("data:", StringComparison.OrdinalIgnoreCase))

Copy link
Copy Markdown
ContributorAuthor

Choose a reason for hiding this comment

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

Note: ImageUrl is constrained to image types for public url, but allows for PDF for base64 encoded data: urls.

* Renamed Github to GitHub
* Small fix
* Updated package versions
)
* Builds locally and tests pass
* Fix typo
* Reverted nuget config change to remove internal feed and map to new public object model package with renames.
* Renaming Bot object model in additional sample.
---------
Co-authored-by: Peter Ibekwe <peibekwe@microsoft.com>
…onse for Response Format (#3305)
* added generic types to ChatOptions and ChatResponse/AgentResponse for response format
* fix typevar import
* fix for older python versions
* fix missing import
* fixed imports
* fixed mypy
* mypy fix
@peibekwe
Peter Ibekwe (peibekwe) requested a review from a team as a code ownerJanuary 29, 2026 18:05
@markwallace-microsoftMark Wallace (markwallace-microsoft) added documentation Usage: [Issues, PRs], Target: documentation in the code base and learn docs python Usage: [Issues, PRs], Target: Python lab labels Jan 29, 2026
@github-actionsgithub-actionsBot changed the title .NET Workflows - Support fidelity when converting to and from ChatMessage in declarative workflowsPython: .NET Workflows - Support fidelity when converting to and from ChatMessage in declarative workflowsJan 29, 2026
@peibekwe
Peter Ibekwe (peibekwe) removed the request for review from a teamJanuary 29, 2026 18:12
@github-project-automationgithub-project-automationBot moved this from In Review to Done in Agent FrameworkJan 30, 2026
@peibekwe

Copy link
Copy Markdown
Contributor

Closing this PR as it's been checked in as part of #3505

@crickman
Chris (crickman) deleted the crickman/messaging-handling-fix-declarative-workflows branch February 4, 2026 20:26
@crickmanChris (crickman) added declarative-workflow and removed python Usage: [Issues, PRs], Target: Python labels Feb 6, 2026
@crickmanChris (crickman) changed the title Python: .NET Workflows - Support fidelity when converting to and from ChatMessage in declarative workflows.NET Workflows - Support fidelity when converting to and from ChatMessage in declarative workflowsFeb 6, 2026
@moonbox3Evan Mattson (moonbox3) added declarative Usage: [Issues, PRs], Target: declarative agents and workflows and removed declarative-workflow labels Jun 17, 2026
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

declarativeUsage: [Issues, PRs], Target: declarative agents and workflowsdocumentationUsage: [Issues, PRs], Target: documentation in the code base and learn docs.NETUsage: [Issues, PRs], Target: .NetworkflowsUsage: [Issues, PRs], Target: Workflows

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

7 participants

@crickman@peibekwe@markwallace-microsoft@moonbox3@dmytrostruk@larohra@eavanvalkenburg