From d4391e566f36b05e5f0543c29578aaaf6244b0cf Mon Sep 17 00:00:00 2001 From: tooyosi Date: Wed, 27 May 2026 23:13:32 +0100 Subject: [PATCH] add huggingFace env vars to prediction batch env --- bajor/batch/predictions.py | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/bajor/batch/predictions.py b/bajor/batch/predictions.py index 1007a34..8f8c17b 100644 --- a/bajor/batch/predictions.py +++ b/bajor/batch/predictions.py @@ -74,6 +74,13 @@ def create_batch_job(job_id, manifest_url, pool_id, options: JobOptions=JobOptio batchmodels.EnvironmentSetting( name='PREDICTIONS_JOB_RESULTS_DIR', value=job_results_dir(job_id)), + # set the Hugging Face env vars + batchmodels.EnvironmentSetting( + name='HF_REPO_ID', + value=os.getenv('HF_REPO_ID', '')), + batchmodels.EnvironmentSetting( + name='HF_TOKEN', + value=os.getenv('HF_TOKEN', '')), # set the zoobot saved model checkpoint file path batchmodels.EnvironmentSetting( name='ZOOBOT_CHECKPOINT_TARGET',