Skip to content

Commit

Permalink
Merge pull request #477 from niwa2/hf_token_via_env
Browse files Browse the repository at this point in the history
add option to provide HuggingFace-token via environment variable
  • Loading branch information
jhj0517 authored Jan 24, 2025
2 parents 77b3814 + 6ab697e commit e44f57f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/whisper/base_transcription_pipeline.py
Original file line number Diff line number Diff line change
Expand Up @@ -179,7 +179,7 @@ def run(self,
if diarization_params.is_diarize:
result, elapsed_time_diarization = self.diarizer.run(
audio=origin_audio,
use_auth_token=diarization_params.hf_token,
use_auth_token=diarization_params.hf_token if diarization_params.hf_token else os.environ.get("HF_TOKEN"),
transcribed_result=result,
device=diarization_params.diarization_device
)
Expand Down

0 comments on commit e44f57f

Please sign in to comment.