[FEATURE] Windows Nuget Package should be build with direct-ml and cuda enabled

Author: KeinNiemandCreated Jul 2, 2026Updated Sep 8, 2026
Labelsenhancement

Describe the feature

Currently if you want to use sherpa-onnx in .net on windows, and want GPU support, you need to compile onnx yourself, with it enabled, Enabling Direct-ML in the package (it already works when enabled at compile time) would enable cross vendor GPU support on Windows. In addition CUDA would provide better performance on NVidia over Direct/ML.

I'm specfically talking about these nuget packages: org.k2fsa.sherpa.onnx, org.k2fsa.sherpa.onnx.runtime.win-x64 and org.k2fsa.sherpa.onnx.runtime.win-x86 (that last one being less important)

Motivation / Use Case

It would make it much easier to support GPUs in an application using sherpa-onnx (.net) on Windows since it would eliminate the need to compile onnx yourself.

Additional context

Any context, examples, or references that help understand the feature.