Model Builder: Add an API for listing and testing supported models #884
samuel100
started this conversation in
New features / APIs
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In the
create_model
function of Model Builder (MB), there is a test to check whether the model architecture is supported:onnxruntime-genai/src/python/py/models/builder.py
Lines 2654 to 2687 in dac90d5
Would it be possible to make this more formal by adding a method called
is_model_supported(str model_name)
wheremodel_name
is a HF model path e.g.microsoft/Phi-3-mini-4k-instruct-onnx
?This API would allow the Olive CLI to test whether a model input is supported by MB for graph capture. If it is Olive will use MB for graph capture, if the model is not supported by MB it will fall back to TorchDynamo.
Beta Was this translation helpful? Give feedback.
All reactions