Add hugging-face command support#1411
Open
vycius wants to merge 1 commit into
Open
Conversation
Introduce a thin CLI and pulp-glue layer for the pulp_hugging_face plugin, enabling pull-through caching of Hugging Face Hub content. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
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.
Summary
hugging-facecommand group backed by thepulp_hugging_faceplugin, for managing Hugging Face Hub pull-through caching via Pulp.PulpHuggingFaceRemoteContext,PulpHuggingFaceRepositoryContext,PulpHuggingFaceRepositoryVersionContext, andPulpHuggingFaceDistributionContext(all gated onhugging_face >= 0.1.0).pulp hugging-facewithremote,repository, anddistributionsubgroups (create/show/list/update/destroy, labels, repository versions).remoteadds a write-only--hf-token(never returned in API responses) and a--policyoption (immediate/on_demand/streamed) for pull-through caching.distributionsupports attaching/detaching a remote or repository via--remote/--repositoryresource options.pyproject.tomland adds a deferred-context help-page test case.Notes
PulpHuggingFaceDistributionContext.preprocess_entityonly defaultsrepository/remoteto null on create (partial=False), so partial updates no longer detach an attached remote/repository.updatecommand exposes--base-path, consistent with the other distribution plugins.Test plan
make lint typecheck testtests/scripts/pulp_hugging_face/test_remote.shtests/scripts/pulp_hugging_face/test_repository.shtests/scripts/pulp_hugging_face/test_distribution.shCo-Authored-By: Claude Opus 4.7 noreply@anthropic.com