Adds a vllm.io_processor_plugins entry point (bge_m3_sparse_plugin) that serves learned sparse vectors of BAAI/bge-m3 over POST /pooling, on top of the BgeM3EmbeddingModel architecture that already ships with vLLM. - plugin/: python package, sparse (token_classify) and dense (embed) modes, batch support, per-request weight threshold - entrypoint.sh: pip install the plugin from a read-only mount at container start - docker-compose.yml: stack ready for Portainer (git repository deployment) Verified against vLLM 0.30.0 on an RTX 5070: single/batch/parallel requests, validation errors, and weights matching the FlagEmbedding reference formula.
22 lines
545 B
Bash
22 lines
545 B
Bash
# Values used by docker-compose.yml. Every variable has a default,
|
|
# so the stack starts even without this file.
|
|
|
|
# port on the host
|
|
HOST_PORT=8083
|
|
|
|
# share of VRAM vLLM may use (raise it if the model does not fit)
|
|
GPU_MEMORY_UTILIZATION=0.15
|
|
|
|
MAX_MODEL_LEN=8192
|
|
MODEL=BAAI/bge-m3
|
|
|
|
# pin a version instead of latest, the plugin is tied to the vLLM API
|
|
VLLM_IMAGE=vllm/vllm-openai:latest
|
|
|
|
# model cache on the host
|
|
HF_CACHE=/root/.cache/huggingface
|
|
|
|
# defaults for the /pooling "data" object
|
|
BGE_M3_SPARSE_MODE=sparse
|
|
BGE_M3_SPARSE_THRESHOLD=0.0
|