Skip to content

Commit

Permalink
Cache Tiktoken files
Browse files Browse the repository at this point in the history
  • Loading branch information
thekid committed Oct 13, 2024
1 parent 279053c commit abbe911
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,20 @@ jobs:
- name: Run test suite
run: sh xp-run xp.test.Runner -r Dots src/test/php

- name: Run integration tests
- name: Cache Tiktoken files
id: cache-tiktoken
uses: actions/cache@v3
with:
path: tiktoken
key: ${{ runner.os }}-tiktoken

- name: Download Tiktoken files
if: steps.cache-tiktoken.outputs.cache-hit != 'true'
run: >
mkdir -p tiktoken &&
cd tiktoken &&
curl -O 'https://openaipublic.blob.core.windows.net/encodings/cl100k_base.tiktoken' &&
curl -O 'https://openaipublic.blob.core.windows.net/encodings/o200k_base.tiktoken' &&
sh xp-run xp.test.Runner src/it/php --folder=.
curl -O 'https://openaipublic.blob.core.windows.net/encodings/o200k_base.tiktoken'
- name: Run integration tests
run: sh xp-run xp.test.Runner src/it/php --folder=tiktoken

0 comments on commit abbe911

Please sign in to comment.