-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into renovate/actions-upload-artifact-4.x
- Loading branch information
Showing
31 changed files
with
661 additions
and
225 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
{{- if .Capabilities.APIVersions.Has "security.istio.io/v1beta1" }} | ||
apiVersion: security.istio.io/v1beta1 | ||
kind: AuthorizationPolicy | ||
metadata: | ||
name: api-block-metrics-access-from-public-gateway | ||
namespace: {{ .Release.Namespace }} | ||
spec: | ||
selector: | ||
matchLabels: | ||
{{- include "chart.selectorLabels" . | nindent 6 }} | ||
action: DENY | ||
rules: | ||
- to: | ||
- operation: | ||
ports: | ||
- "8080" | ||
paths: | ||
- /metrics* | ||
from: | ||
- source: | ||
notNamespaces: | ||
- istio-admin-gateway | ||
- monitoring | ||
{{- end }} |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,13 +1,12 @@ | ||
export LAI_HF_HUB_ENABLE_HF_TRANSFER="1" | ||
export LAI_REPO_ID="TheBloke/Synthia-7B-v2.0-GPTQ" | ||
export LAI_REVISION="gptq-4bit-32g-actorder_True" | ||
export LAI_QUANTIZATION="gptq" | ||
export LAI_TENSOR_PARALLEL_SIZE=1 | ||
export LAI_MODEL_SOURCE=".model/" | ||
export LAI_MAX_CONTEXT_LENGTH=32768 | ||
export LAI_STOP_TOKENS='["</s>","<|endoftext|>","<|im_end|>"]' | ||
export LAI_PROMPT_FORMAT_CHAT_SYSTEM="SYSTEM: {}\n" | ||
export LAI_PROMPT_FORMAT_CHAT_ASSISTANT="ASSISTANT: {}\n" | ||
export LAI_PROMPT_FORMAT_CHAT_USER="USER: {}\n" | ||
export LAI_PROMPT_FORMAT_DEFAULTS_TOP_P=1.0 | ||
export LAI_PROMPT_FORMAT_DEFAULTS_TOP_K=0 | ||
LFAI_REPO_ID="TheBloke/SynthIA-7B-v2.0-GPTQ" | ||
LFAI_REVISION="gptq-4bit-32g-actorder_True" | ||
|
||
VLLM_TENSOR_PARALLEL_SIZE=1 | ||
VLLM_TRUST_REMOTE_CODE=True | ||
VLLM_MAX_CONTEXT_LENGTH=32768 | ||
VLLM_ENFORCE_EAGER=False | ||
VLLM_GPU_MEMORY_UTILIZATION=0.90 | ||
VLLM_WORKER_USE_RAY=True | ||
VLLM_ENGINE_USE_RAY=True | ||
VLLM_QUANTIZATION=None | ||
VLLM_LOAD_FORMAT=auto |
This file contains 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
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,27 @@ | ||
ARCH ?= amd64 | ||
LOCAL_VERSION ?= $(shell git rev-parse --short HEAD) | ||
DOCKER_FLAGS := | ||
|
||
install: | ||
python -m pip install ../../src/leapfrogai_sdk | ||
python -m pip install -e ".[dev]" | ||
|
||
dev: | ||
python -m leapfrogai_sdk.cli --app-dir=src/ main:Model | ||
download: | ||
@env $$(cat .env | xargs) python src/model_download.py | ||
|
||
dev: download | ||
@env $$(cat .env | xargs) python -m leapfrogai_sdk.cli --app-dir=src/ main:Model | ||
|
||
docker: download | ||
docker build ${DOCKER_FLAGS} \ | ||
--platform=linux/${ARCH} \ | ||
--build-arg LOCAL_VERSION=${LOCAL_VERSION} \ | ||
--build-arg COMPONENT_DIRECTORY="./" \ | ||
-t ghcr.io/defenseunicorns/leapfrogai/vllm:${LOCAL_VERSION} \ | ||
-f ./Dockerfile . | ||
|
||
docker run -it --rm \ | ||
--env-file ./.env \ | ||
-v $(PWD)/config.yaml:/home/leapfrogai/config.yaml \ | ||
-v $(PWD)/.model:/home/leapfrogai/.model \ | ||
ghcr.io/defenseunicorns/leapfrogai/vllm:${LOCAL_VERSION} |
Oops, something went wrong.