Skip to content

Add an "extension" system. #1687

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Add an "extension" system. #1687

wants to merge 1 commit into from

Conversation

bmatherly
Copy link
Member

Not ready for merge. Posting for initial review and comments.

This adds a new "extension" system that can be used to download additional features. This commit uses the extension system to allow the user to download additional Whisper.cpp models.

The "Speech to Text" dialog now has a new list that shows all the available models. Models that are downloaded have a green check mark. Models that are not downloaded have a download icon.
image

If the user clicks on a model with a green check mark, it becomes the current model. If the user clicks on a model with a download icon, they are prompted to download it:

image

image

Models are stored in the users data directory in an "extensions" folder. Example on Linux:
/home/brian/.local/share/Meltytech/Shotcut/extensions/Whisper Model/ggml-small.bin

The available models are listed in the QML extension file: whispermodel.qml
The extension file is distributed with the Shotcut binary package.

Discussion: should Shotcut offer a way to delete the models? Perhaps a right-click context menu?

Comments are welcome.

The extension system can be used to download additional features.
This commit uses the extension system to allow the user to download
additional Whisper.cpp models.
@ddennedy
Copy link
Member

ddennedy commented Jun 5, 2025

I think it looks good, and I agree there can be a context menu to Remove a model. (Recent and Recent Project list view have that menu item.)

I see how the model can be used for other sets of extensions and have different context-sensitive UIs where it makes sense instead of perhaps one central UI. Maybe we will change our mind and later have a common UI, but we can run with this for now.

@bmatherly
Copy link
Member Author

Thanks for the feedback. For the Whisper.cpp extension, all the downloads link to the huggingface.co website. Is that what we want to do? Or should we make our own host for extension files so that we control their availability?

@ddennedy
Copy link
Member

ddennedy commented Jun 8, 2025

Can you try to make Shotcut download the data file? I would host it on S3. I am fairly confident the huggingface downloads will be reliable and likely permanent, but this way we at least have some manner to make a change and control behavior of existing installs. Otherwise, yeah, I can put the models in AWS.

@bmatherly
Copy link
Member Author

I see what you mean. Here is what I propose:

  • Shotcut will still include the extension file with the package in the application directory
  • I will add a button to the dialog called "Update Models"
  • When the user clicks the button, an extension file will be downloaded from the Shotcut website and stored in the user directory
  • When Shotcut starts up, it will first look in the user directory and if it finds an extension file, it will use that one
  • If an extension file is not found in the user directory, it will use the one in the application directory that came with Shotcut

Thoughts?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants