Files
esh-pfi-infrastructure/stacks/vllm/.env.example
T
vh 52612cbe96 feat(reward-seat): move Skywork reward seat from fv-ml1 to esh-ml1; audit finds nothing superseding it
- Audit: Skywork-Reward-V2-Llama-3.1-8B is still #1 of 188 on AllenAI's
  RewardBench 2 per-sample results; no Skywork V3; the -40M sibling is
  vendor-marked experimental. Our AWQ W4A16 quant: 0.847 vs published bf16
  0.860 on a 150-prompt sample (within +/-2.9 pt SE), 96.2% pairwise
  agreement. Double BOS from vLLM on pre-templated text costs a further
  ~2.7 pts; callers must send add_special_tokens=false.
- No working consumer: 0 requests since 2026-09-13; Worldtree Domari points
  at a dead IP with a non-vLLM schema (reported to worldtree-dev).
- Move: sha256-identical model copy; vLLM v0.24.0 on esh-ml1 :8003 at 0.55
  util (KV 1.30x of a 16k request). Parity vs fv-ml1: 149/150 verdicts,
  99.8% pairwise signs, raw |delta| median 0.049.
- Gateway /scalar-judge passthrough -> 10.0.50.80:8003; fv-ml1 vllm-reward
  removed (~10.2 GB freed on GPU 1). stacks/vllm now holds only vllm-coder.
2026-09-25 09:09:48 -07:00

99 lines
5.3 KiB
Bash

# vllm stack tunables. Copy this to `.env` on the server before deploying.
#
# cp .env.example .env
# # edit .env with real values
# docker compose up -d
# Image version — PINNED. Do not put `latest` here: every service in this file
# shares this one variable, so a bare `docker compose up -d` would silently
# upgrade the whole stack's vLLM at once. Pinned 2026-08-20 to the version all
# seats were already running (`latest` and `v0.24.0` were the same local image,
# 4091d5593f77, so the pin changed nothing at runtime). Bump deliberately.
VLLM_VERSION=v0.24.0
# Host ports (container always listens on 8000 internally)
# (EMBED_PORT 8001 / RERANK_PORT 8013 retired 2026-09-25 with their seats —
# embedding + reranking moved to TEI on esh-ml1, stacks/embed-rerank.)
# REWARD_PORT=8003 (retired here 2026-09-25 — the reward seat moved to esh-ml1, stacks/reward-seat)
# GPU assignment — all services share this GPU
# (ana-ml2 has 0 and 1; default 1 keeps 0 free for heavy LLM work in llama-swap)
GPU_ID=1
# Models
# Skywork is a local-path AWQ output, not from HF Hub. Bind-mounted into the
# reward container at /local-models — see compose.yaml. No env var here for
# the model path itself since it's hard-coded in the compose command.
# GPU memory split — fractions are of TOTAL GPU memory, not free memory.
# vLLM profiles each service independently, so each slice must be large enough
# to fit that service's model + KV cache with no awareness of the others.
# Setting any one too low causes that container to OOM on KV cache allocation
# with `Available KV cache memory: -X.XX GiB`.
#
# Layout on a 48 GB Ada, RIGHT-SIZED 2026-06-05 to free room for the granite
# summarizer's CUDA graphs + a LoRA hedge. The trio was wildly over-provisioned:
# embed ran a 5.89x KV pool, reward 3.90x — pure waste for utility models that
# need ~1.5x. Trimmed to free ~10 GB. (Utilization = fraction of TOTAL GPU mem;
# each service profiles independently. Too low → that container OOMs on KV with
# `Available KV cache memory: -X.XX GiB`.)
# EMBED 0.07 (~3.4 GB) — 0.6B Qwen3 embed @8k; 1.1GB weights + ~2GB KV (~3x)
# RERANK 0.07 (~3.4 GB) — 0.6B Qwen3 rerank @8k; comfortable
# REWARD 0.18 (~8.6 GB) — 8B Skywork AWQ @16k; 4.4GB weights + ~3.5GB KV (~1.5x)
#
# RETUNED 2026-06-12 for the Ada->Blackwell swap (cards are now 96 GB, so the
# Ada-era fractions reserved ~2x the bytes for the same models). Empirically
# re-floored: util climbed in 0.01 steps until each service was stable under
# 20x parallel inference.
# embed/rerank 0.05 (~4.8 GB ea) — the load-floor for the 0.6B models (0.04
# OOMs on engine init; their footprint is fixed weights+context, not KV).
# reward 0.10 (~9.6 GB) — the real over-provision was here (0.18 -> 0.10).
# Net: ~11 GB freed on GPU 1. (Fractions are of TOTAL card VRAM — re-floor if
# the cards change again.)
# 0.03 each — REBALANCED 2026-06-14 (was 0.05): the 0.6B models sat at ~5.5 GB
# each at 0.05 (mostly util-reservation waste); 0.03 (~3.6 GB) fits weights +
# CUDA context with room, freeing ~4 GB back to granite. Recreate them ONE AT A
# TIME — concurrent recreate races the memory-profiling assertion.
# REWARD_GPU_MEM_UTIL=0.10 (retired here 2026-09-25 — the reward seat moved to esh-ml1, stacks/reward-seat)
# Context length caps — lower these if VRAM is tight.
# Qwen3-Embedding supports up to 32k; reranker up to 32k.
# Skywork capped at 16k server-side as defense-in-depth; JudgeClient also
# enforces the cap at dispatch time per spec.
# REWARD_MAX_MODEL_LEN=16384 (retired here 2026-09-25 — the reward seat moved to esh-ml1, stacks/reward-seat)
# Optional API key — leave blank for no auth (fine on the internal network).
# If set, all three services require `Authorization: Bearer <key>`.
API_KEY=
# HuggingFace token — only needed for gated models in the HF-Hub-loaded
# services (embed/rerank). Reward is local-path, ignores this.
HF_TOKEN=
# === granite-4.1-8b — RETIRED 2026-08-12, vars removed 2026-08-20 ===
# Was the production summarizer. The `summarizer` / `classifier` gateway aliases
# were repointed at the gen seat and the container stopped; the service block and
# these tunables are now gone. See the tombstone in compose.yaml for the lesson
# this cost us (nevermore stayed pinned to the dead `granite-4.1-8b` alias and
# failed silently for 8 days).
# Qwen2.5-Coder-1.5B (BASE) — FIM code-completion seat for Zed editor inline
# edit-predictions (deep-research pick 2026-07-27, Apache-2.0). GPU-1, alongside the
# small-model trio + (phasing-out) granite. Reached via LiteLLM `coder-fast` alias
# and the keyless zed-fim-proxy (stacks/zed-fim-proxy). util 0.06 (~5.7 GB) holds
# the 1.5B fp16 + fp8 KV; 8192 ctx is ample for FIM (KV = 13.75x concurrency).
CODER_PORT=8020
CODER_GPU_ID=1
CODER_MODEL=Qwen/Qwen2.5-Coder-1.5B
CODER_SERVED_NAME=qwen2.5-coder-1.5b
CODER_MAX_MODEL_LEN=8192
CODER_KV_CACHE_DTYPE=fp8
CODER_GPU_MEM_UTIL=0.06
CODER_MAX_NUM_SEQS=32
# === LFM2.5-2.6B — RETIRED PERMANENTLY 2026-08-20 (operator directive) ===
# Eval-only bake-off seat vs granite-4.1-8b that never got its production ruling;
# its comparator was retired first, and it logged 0 calls in the 4 days before it
# came down. Container removed, service block and tunables deleted, gateway alias
# dropped. Weights remain in the shared HF cache.