"docs/source/reference/api_reference.md" did not exist on "0595bf3e9a15807d038e41f09c0f7e1c595d2417"
Unverified Commit 9946165e authored by OlivierDehaene's avatar OlivierDehaene Committed by GitHub
Browse files

chore: add pre-commit (#1569)

parent 142cdabe
...@@ -71,12 +71,11 @@ jobs: ...@@ -71,12 +71,11 @@ jobs:
pip install pytest pip install pytest
export HUGGING_FACE_HUB_TOKEN=${{ secrets.HUGGING_FACE_HUB_TOKEN }} export HUGGING_FACE_HUB_TOKEN=${{ secrets.HUGGING_FACE_HUB_TOKEN }}
pytest -s -vv server/tests pytest -s -vv server/tests
- name: Run Rust fmt - name: Pre-commit checks
run: | run: |
cargo fmt --check pip install pre-commit
- name: Run Rust clippy pre-commit install
run: | pre-commit run --all-files
cargo clippy
- name: Run Rust tests - name: Run Rust tests
run: | run: |
cargo test cargo test
......
...@@ -11,4 +11,3 @@ server/exllama_kernels/exllama_kernels/hip_func/ ...@@ -11,4 +11,3 @@ server/exllama_kernels/exllama_kernels/hip_func/
*_hip.cuh *_hip.cuh
server/exllama_kernels/exllama_kernels/hip_buffers.cuh server/exllama_kernels/exllama_kernels/hip_buffers.cuh
server/exllama_kernels/exllama_kernels/exllama_ext_hip.cpp server/exllama_kernels/exllama_kernels/exllama_ext_hip.cpp
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v4.5.0
hooks:
- id: check-yaml
- id: end-of-file-fixer
- id: trailing-whitespace
exclude: docs/source/basic_tutorials/launcher.md
- repo: https://github.com/psf/black
rev: 24.2.0
hooks:
- id: black
- repo: https://github.com/doublify/pre-commit-rust
rev: v1.0
hooks:
- id: fmt
- id: cargo-check
- id: clippy
...@@ -29,4 +29,3 @@ tui = {package = "ratatui", version = "0.23", default-features = false, features ...@@ -29,4 +29,3 @@ tui = {package = "ratatui", version = "0.23", default-features = false, features
tracing = "0.1.37" tracing = "0.1.37"
tracing-subscriber = { version = "0.3.17", features = ["json", "env-filter"] } tracing-subscriber = { version = "0.3.17", features = ["json", "env-filter"] }
hf-hub = "0.3.1" hf-hub = "0.3.1"
...@@ -134,6 +134,7 @@ class Parameters(BaseModel): ...@@ -134,6 +134,7 @@ class Parameters(BaseModel):
raise ValidationError("`value` cannot be empty for `json` grammar") raise ValidationError("`value` cannot be empty for `json` grammar")
return v return v
class Request(BaseModel): class Request(BaseModel):
# Prompt # Prompt
inputs: str inputs: str
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment