feat: add ModelScope backend support with modelscope:// protocol#1673
Open
pmady wants to merge 1 commit intodragonflyoss:mainfrom
Open
feat: add ModelScope backend support with modelscope:// protocol#1673pmady wants to merge 1 commit intodragonflyoss:mainfrom
pmady wants to merge 1 commit intodragonflyoss:mainfrom
Conversation
Add a new backend for downloading models and datasets from ModelScope Hub (modelscope.cn) using the modelscope:// URL scheme. URL format: modelscope://[<repo_type>/]<owner>/<repo>[/<path>][@<revision>] Features: - Support for models and datasets repository types - File listing via ModelScope API for recursive downloads - Authentication via --ms-token CLI flag - Range download support - Default revision is 'master' (matching ModelScope convention) Closes dragonflyoss/dragonfly#4420 Signed-off-by: Pradumna Saraf <pradumnasaraf@gmail.com> Signed-off-by: pmady <pmady@users.noreply.github.com>
Author
|
Hi maintainers, could you please add the enhancement label to this PR? The PR Label check requires one of: bug, enhancement, documentation, or dependencies. Thank you! |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #1673 +/- ##
==========================================
- Coverage 50.83% 50.52% -0.32%
==========================================
Files 83 84 +1
Lines 20029 20631 +602
==========================================
+ Hits 10182 10424 +242
- Misses 9847 10207 +360
🚀 New features to boost your workflow:
|
Member
|
@pmady Thanks, I'll finish the review by this week. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does / why we need it:
Adds a new backend for downloading models and datasets from ModelScope Hub using the
modelscope://URL scheme, similar to the existing Hugging Face backend.URL Format
Examples
Features
modelsanddatasetsrepository types/api/v1/models/{id}/repo/files) for recursive downloads/api/v1/models/{id}/repo?FilePath=...)--ms-tokenCLI flag (injected asAuthorization: Bearerheader)master(matching ModelScope convention)Which issue(s) this PR fixes:
Closes dragonflyoss/dragonfly#4420
Does this PR introduce a user-facing change?
Yes. Users can now download files and repositories from ModelScope Hub using
dfget modelscope://...with P2P acceleration.