Skip to content

Windows ML: ABI Execution Provider enumeration sample - #544

Merged
Nick Eubanks (nieubank) merged 2 commits into
mainfrom
user/nieubank/winml_abi
Oct 7, 2025
Merged

Windows ML: ABI Execution Provider enumeration sample#544
Nick Eubanks (nieubank) merged 2 commits into
mainfrom
user/nieubank/winml_abi

Conversation

@nieubank

Copy link
Copy Markdown
Contributor

Description

Add Windows ML sample demonstrating execution provider discovery and management using direct ABI/COM interfaces with Microsoft.WindowsAppSDK.ML package.

Key features:

  • Automatic ABI header generation via Microsoft.Windows.AbiWinRT
  • Complete provider lifecycle management (discovery → preparation → registration)
  • Event-driven async operations with progress reporting
  • Modular architecture with reusable components

Technical implementation:

  • Direct COM interface programming with Microsoft::WRL
  • HANDLE-based async synchronization patterns
  • Self-contained Windows App SDK deployment, but nothing here precludes framework-based deployments.
  • Filtered metadata processing for Windows ML APIs

Components added:

  • AbiUtils.h: HSTRING utilities and common helpers
  • AsyncHandlers: Progress and completion event handlers
  • ExecutionProvider: IExecutionProvider wrapper with state management
  • ExecutionProviderCatalog: Provider discovery and enumeration
  • ConsoleUI: Interactive user interface utilities
  • Application: Lifecycle management and orchestration

This sample provides developers with
production-ready patterns for direct ABI access to Windows ML capabilities, complementing existing C++/WinRT samples with a lower-level programming approach.

Target Release

1.8.1

Checklist

Note that /azp run currently isn't working for this repo.

Add Windows ML sample demonstrating execution provider discovery and management
using direct ABI/COM interfaces with Microsoft.WindowsAppSDK.ML package.

Key features:
- Automatic ABI header generation via Microsoft.Windows.AbiWinRT
- Complete provider lifecycle management (discovery → preparation → registration)
- Event-driven async operations with progress reporting
- Modular architecture with reusable components

Technical implementation:
- Direct COM interface programming with Microsoft::WRL
- HANDLE-based async synchronization patterns
- Self-contained Windows App SDK deployment, but nothing here precludes framework-based deployments.
- Filtered metadata processing for Windows ML APIs

Components added:
- AbiUtils.h: HSTRING utilities and common helpers
- AsyncHandlers: Progress and completion event handlers
- ExecutionProvider: IExecutionProvider wrapper with state management
- ExecutionProviderCatalog: Provider discovery and enumeration
- ConsoleUI: Interactive user interface utilities
- Application: Lifecycle management and orchestration

This sample provides developers with
production-ready patterns for direct ABI access to Windows ML capabilities,
complementing existing C++/WinRT samples with a lower-level programming approach.
Comment thread Samples/WindowsML/cpp-abi/CppAbiEPEnumerationSample.vcxproj Outdated
Comment thread Samples/WindowsML/cpp-abi/ExecutionProviderCatalog.cpp Outdated

@adrastogi adrastogi left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks great!

@nieubank
Nick Eubanks (nieubank) merged commit 8336385 into main Oct 7, 2025
4 checks passed
@nieubank
Nick Eubanks (nieubank) deleted the user/nieubank/winml_abi branch October 7, 2025 18:04
Nick Eubanks (nieubank) added a commit that referenced this pull request Oct 8, 2025
* Windows ML: ABI Execution Provider enumeration sample

Add Windows ML sample demonstrating execution provider discovery and management
using direct ABI/COM interfaces with Microsoft.WindowsAppSDK.ML package.

Key features:
- Automatic ABI header generation via Microsoft.Windows.AbiWinRT
- Complete provider lifecycle management (discovery → preparation → registration)
- Event-driven async operations with progress reporting
- Modular architecture with reusable components

Technical implementation:
- Direct COM interface programming with Microsoft::WRL
- HANDLE-based async synchronization patterns
- Self-contained Windows App SDK deployment, but nothing here precludes framework-based deployments.
- Filtered metadata processing for Windows ML APIs

Components added:
- AbiUtils.h: HSTRING utilities and common helpers
- AsyncHandlers: Progress and completion event handlers
- ExecutionProvider: IExecutionProvider wrapper with state management
- ExecutionProviderCatalog: Provider discovery and enumeration
- ConsoleUI: Interactive user interface utilities
- Application: Lifecycle management and orchestration

This sample provides developers with
production-ready patterns for direct ABI access to Windows ML capabilities,
complementing existing C++/WinRT samples with a lower-level programming approach.

* Update Nuget package directory path and enhance error reporting in ExecutionProviderCatalog
Nick Eubanks (nieubank) added a commit that referenced this pull request Oct 8, 2025
* Windows ML: ABI Execution Provider enumeration sample

Add Windows ML sample demonstrating execution provider discovery and management
using direct ABI/COM interfaces with Microsoft.WindowsAppSDK.ML package.

Key features:
- Automatic ABI header generation via Microsoft.Windows.AbiWinRT
- Complete provider lifecycle management (discovery → preparation → registration)
- Event-driven async operations with progress reporting
- Modular architecture with reusable components

Technical implementation:
- Direct COM interface programming with Microsoft::WRL
- HANDLE-based async synchronization patterns
- Self-contained Windows App SDK deployment, but nothing here precludes framework-based deployments.
- Filtered metadata processing for Windows ML APIs

Components added:
- AbiUtils.h: HSTRING utilities and common helpers
- AsyncHandlers: Progress and completion event handlers
- ExecutionProvider: IExecutionProvider wrapper with state management
- ExecutionProviderCatalog: Provider discovery and enumeration
- ConsoleUI: Interactive user interface utilities
- Application: Lifecycle management and orchestration

This sample provides developers with
production-ready patterns for direct ABI access to Windows ML capabilities,
complementing existing C++/WinRT samples with a lower-level programming approach.

* Update Nuget package directory path and enhance error reporting in ExecutionProviderCatalog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants