Update max_tokens default from 4096 to 65535 (#108) #43
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Python Publish | |
on: | |
push: | |
paths: | |
- "vlmrun/version.py" | |
branches: | |
- main | |
env: | |
CACHE_NUMBER: 1 # increase to reset cache manually | |
jobs: | |
test: | |
name: Test | |
runs-on: ubuntu-latest | |
timeout-minutes: 20 | |
environment: dev | |
steps: | |
- name: Checkout git repo | |
uses: actions/checkout@v3 | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.10" | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cache/uv | |
~/.cache/pip | |
key: uv-py310-${{ hashFiles('requirements/requirements*.txt') }}-${{ hashFiles('pyproject.toml') }}-${{ hashFiles('MANIFEST.in') }}-${{ env.CACHE_NUMBER }} | |
restore-keys: | | |
uv-py310- | |
- name: Install dependencies | |
run: | | |
pip install uv | |
uv pip install --system -e '.[test,all]' | |
- name: Quality Check | |
uses: pre-commit/[email protected] | |
continue-on-error: true | |
- name: Run tests | |
run: | | |
make test | |
publish: | |
name: Publish | |
runs-on: ubuntu-latest | |
timeout-minutes: 20 | |
environment: prod | |
needs: test | |
steps: | |
- name: Checkout git repo | |
uses: actions/checkout@v3 | |
with: | |
fetch-depth: 0 | |
token: ${{ secrets.GH_TOKEN }} | |
- uses: actions/setup-python@v5 | |
with: | |
python-version: "3.10" | |
- uses: actions/cache@v4 | |
with: | |
path: | | |
~/.cache/uv | |
~/.cache/pip | |
key: uv-${{ hashFiles('requirements/requirements*.txt') }}-${{ hashFiles('pyproject.toml') }}-${{ hashFiles('MANIFEST.in') }}-${{ env.CACHE_NUMBER }} | |
restore-keys: | | |
uv- | |
- name: Install dependencies | |
run: | | |
pip install uv | |
uv pip install --system -e '.[test,build,all]' | |
- name: Bump version | |
if: success() | |
run: | | |
version=$(grep -oP '__version__ = "\K[^"]+' vlmrun/version.py) | |
echo "Current version: ${version}" | |
git config --local user.email "github-actions[bot]@users.noreply.github.com" | |
git config --local user.name "github-actions[bot]" | |
git tag -a "v${version}" -m "Version ${version}" | |
git push origin main | |
git push origin "v${version}" | |
- name: Build package | |
run: | | |
python -m build | |
- name: Publish to PyPI | |
uses: pypa/gh-action-pypi-publish@release/v1 | |
with: | |
password: ${{ secrets.PYPI_TOKEN }} |