← back to Exo
cache isolation per workflow job
052ee1c7e99b77074007afc120d5202447d755cc · 2024-07-20 17:55:42 -0700 · Alex Cheema
Files touched
M .github/workflows/test.yml
Diff
commit 052ee1c7e99b77074007afc120d5202447d755cc
Author: Alex Cheema <alexcheema123@gmail.com>
Date: Sat Jul 20 17:55:42 2024 -0700
cache isolation per workflow job
---
.github/workflows/test.yml | 14 ++++++++++----
1 file changed, 10 insertions(+), 4 deletions(-)
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 5193fb90..cc2337f1 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -17,6 +17,12 @@ jobs:
with:
python-version: '3.12'
+ - name: Cache huggingface hub models
+ uses: actions/cache@v3
+ with:
+ path: ~/.cache/huggingface/hub
+ key: ${{ runner.os }}-huggingface-hub-${{ hashFiles('~/.cache/huggingface/hub/**/*') }}-${{ github.job }}
+
- name: Install dependencies
run: |
python3 -m pip install --upgrade pip
@@ -25,7 +31,7 @@ jobs:
- name: Run tests
run: |
# Check if cached files are present
- ls ~/.cache/huggingface/hub/models--mlx-community--Meta-Llama-3-8B-Instruct-4bit/**/*
+ ls ~/.cache/huggingface/hub/models--mlx-community--Meta-Llama-3-8B-Instruct-4bit/**/* || true
# Run unit tests
METAL_XCODE=1 python3 -m exo.inference.test_inference_engine
@@ -88,7 +94,7 @@ jobs:
uses: actions/cache@v3
with:
path: ~/.cache/huggingface/hub
- key: ${{ runner.os }}-huggingface-hub-${{ hashFiles('~/.cache/huggingface/hub/**/*') }}
+ key: ${{ runner.os }}-huggingface-hub-${{ hashFiles('~/.cache/huggingface/hub/**/*') }}-${{ github.job }}
restore-keys: |
${{ runner.os }}-huggingface-hub-
@@ -96,7 +102,7 @@ jobs:
uses: actions/cache@v3
with:
path: ~/Library/Caches/tinygrad/downloads
- key: ${{ runner.os }}-tinygrad-downloads-${{ hashFiles('~/Library/Caches/tinygrad/downloads/**/*') }}
+ key: ${{ runner.os }}-tinygrad-downloads-${{ hashFiles('~/Library/Caches/tinygrad/downloads/**/*') }}-${{ github.job }}
restore-keys: |
${{ runner.os }}-tinygrad-downloads-
@@ -108,7 +114,7 @@ jobs:
- name: Run chatgpt api integration test
run: |
# Check if cached files are present
- ls ~/.cache/huggingface/hub/models--mlx-community--Meta-Llama-3-8B-Instruct-4bit/**/*
+ ls ~/.cache/huggingface/hub/models--mlx-community--Meta-Llama-3-8B-Instruct-4bit/**/* || true
# Start first instance
DEBUG_DISCOVERY=9 DEBUG=9 python3 main.py --listen-port 5678 --broadcast-port 5679 --chatgpt-api-port 8000 --chatgpt-api-response-timeout-secs 1200 > output1.log 2>&1 &
← ce41e653 check cached files in workflow
·
back to Exo
·
tell the mofo in the workflow to keep responses concise 8850187b →