Skip to content
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

There is no way to stop / abort / cancel a pipeline() #1182

Open
sroussey opened this issue Feb 4, 2025 · 1 comment · May be fixed by #1190
Open

There is no way to stop / abort / cancel a pipeline() #1182

sroussey opened this issue Feb 4, 2025 · 1 comment · May be fixed by #1190
Labels
enhancement New feature or request

Comments

@sroussey
Copy link
Contributor

sroussey commented Feb 4, 2025

Feature request

Provide a way to abort a long running operation.

Motivation

Many things can take a long time (downloading a multi-gig model on 3G) or are not operating normally (infinite output) and the user may change their mind.

Your contribution

I can look into how to use AbortSignals for the download issue. Not sure what ONNX provides.

https://developer.mozilla.org/en-US/docs/Web/API/AbortSignal

Any API suggestion?

@sroussey sroussey added the enhancement New feature or request label Feb 4, 2025
@xenova
Copy link
Collaborator

xenova commented Feb 8, 2025

Good idea! I'm also open to API suggestions since this functionality isn't available in the python library. Following the examples in the docs, perhaps passing a signal parameter to calls to from_pretrained or pipeline could work. Similarly for calls to generate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
2 participants