Preserve revision pins in secondary artifact loaders (#51446)

Signed-off-by: Clinton Thomas <1033162+KernelClint@users.noreply.github.com>
Co-authored-by: Lucas Bourtoule <35483370+dhalf@users.noreply.github.com>
This commit is contained in:
Clinton Thomas
2026-08-11 04:33:10 +00:00
committed by GitHub
co-authored by Lucas Bourtoule
parent adc1200597
commit 90fd4a333f
11 changed files with 226 additions and 13 deletions
+7 -2
View File
@@ -519,12 +519,17 @@ class FunAudioChatProcessingInfo(BaseProcessingInfo):
@cached_property
def feature_extractor(self) -> WhisperFeatureExtractor:
return WhisperFeatureExtractor.from_pretrained(self.model_id)
return WhisperFeatureExtractor.from_pretrained(
self.model_id,
revision=self.ctx.model_config.revision,
)
@cached_property
def speech_tokenizer(self) -> TokenizersBackend:
return TokenizersBackend.from_pretrained(
self.model_id, subfolder="speech_tokenizer"
self.model_id,
subfolder="speech_tokenizer",
revision=self.ctx.model_config.tokenizer_revision,
)
def get_feature_extractor(self) -> WhisperFeatureExtractor: