diff --git a/.github/workflows/build_push_image.yml b/.github/workflows/build_push_image.yml index 95d7e77..feb6cc0 100644 --- a/.github/workflows/build_push_image.yml +++ b/.github/workflows/build_push_image.yml @@ -5,6 +5,7 @@ on: branches: - build-push-llama3-image - build-push-phi3-image + - build-push-mock-image workflow_dispatch: env: @@ -39,6 +40,8 @@ jobs: echo "MODEL_NAME=llama3" >> $GITHUB_ENV elif [[ "${{ github.ref }}" == "refs/heads/build-push-phi3-image" ]]; then echo "MODEL_NAME=phi3" >> $GITHUB_ENV + elif [[ "${{ github.ref }}" == "refs/heads/build-push-mock-image" ]]; then + echo "MODEL_NAME=mock" >> $GITHUB_ENV fi - name: Docker build and push diff --git a/src/compute_horde_prompt_gen/download_model.py b/src/compute_horde_prompt_gen/download_model.py index 8e062b5..f18d0d4 100644 --- a/src/compute_horde_prompt_gen/download_model.py +++ b/src/compute_horde_prompt_gen/download_model.py @@ -1,5 +1,6 @@ import os import argparse +import sys from transformers import ( AutoTokenizer, AutoModelForCausalLM, @@ -39,6 +40,10 @@ ) args = parser.parse_args() + + if args.model_name == "mock": + sys.exit(0) + save_path = os.path.join(args.save_path, args.model_name) model_name = MODEL_PATHS[args.model_name] print(f"Saving {model_name} model to {save_path}")