Repository navigation
Export omnilingualASR v2 - #3140
Conversation
Summary of ChangesHello @csukuangfj, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request extends the functionality of the omnilingual ASR ONNX export script by incorporating support for the second version of the 300M and 1B CTC models. This update ensures that users can now generate ONNX models for these newer, potentially improved, ASR versions, enhancing the script's compatibility and utility for the latest model releases. Highlights
Changelog
Ignored Files
Activity
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for Github and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
|
Caution Review failedThe pull request is closed. 📝 WalkthroughWalkthroughThis PR extends omnilingual ASR export support by adding v2 model variants (300M and 1B) to the CI pipeline and export script. The workflow now includes conditional logic for mapping v2 variants to their respective directories and introduces a new ModelScope publishing step alongside HuggingFace publishing. The export script validates model-card input against the expanded list of supported models. Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~22 minutes Possibly related PRs
Poem
✨ Finishing touches
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Code Review
This pull request updates the export-onnx.py script to support v2 versions of the omnilingual ASR models. The change is straightforward, updating the help message for the --model-card argument. I've suggested an improvement to use argparse's choices feature to validate the model card input, which will make the script more robust.
| "--model-card", | ||
| type=str, | ||
| required=True, | ||
| help="omniASR_CTC_300M, or omniASR_CTC_1B", | ||
| help="omniASR_CTC_300M, omniASR_CTC_300M_v2, omniASR_CTC_1B, or omniASR_CTC_1B_v2", | ||
| ) |
There was a problem hiding this comment.
To improve robustness and provide better error messages to the user, consider using the choices parameter for the --model-card argument. This will validate the user's input against the list of supported models and automatically list the available options in the help message.
"--model-card",
type=str,
required=True,
choices=[
"omniASR_CTC_300M",
"omniASR_CTC_300M_v2",
"omniASR_CTC_1B",
"omniASR_CTC_1B_v2",
],
help="The model card to export.",
)
See also #3138
CC @Edison2ST
Summary by CodeRabbit
New Features
Chores