Spaces:
Runtime error
Runtime error
Prashanth Ramakrishna commited on
Commit ·
40b044c
1
Parent(s): 0a09fc5
Switch to Mistral-7B-Instruct-v0.3 for faster inference
Browse files- Using single GPU (NUM_SHARD=1) for optimal 7B model performance
- No quantization needed with 24GB L4 VRAM
- Optimized batch settings for high throughput
- 10-20x faster than Qwen-72B configuration
- Dockerfile +8 -9
Dockerfile
CHANGED
|
@@ -33,20 +33,19 @@ ENV NUMBA_DISABLE_PERFORMANCE_WARNINGS=1
|
|
| 33 |
ENV NUMBA_DISABLE_INTEL_SVML=1
|
| 34 |
|
| 35 |
# Model configuration
|
| 36 |
-
# Using
|
| 37 |
-
ENV MODEL_ID=
|
| 38 |
|
| 39 |
-
# TGI Configuration for
|
| 40 |
ENV MAX_INPUT_LENGTH=4096
|
| 41 |
ENV MAX_TOTAL_TOKENS=8192
|
| 42 |
-
ENV MAX_BATCH_PREFILL_TOKENS=
|
| 43 |
-
ENV MAX_BATCH_TOTAL_TOKENS=
|
| 44 |
|
| 45 |
-
#
|
| 46 |
-
ENV NUM_SHARD=
|
| 47 |
|
| 48 |
-
#
|
| 49 |
-
ENV QUANTIZE=bitsandbytes-nf4
|
| 50 |
|
| 51 |
# Trust remote code (required for some models)
|
| 52 |
ENV TRUST_REMOTE_CODE=true
|
|
|
|
| 33 |
ENV NUMBA_DISABLE_INTEL_SVML=1
|
| 34 |
|
| 35 |
# Model configuration
|
| 36 |
+
# Using Mistral-7B v0.3 - Fast, ungated, high-quality model
|
| 37 |
+
ENV MODEL_ID=mistralai/Mistral-7B-Instruct-v0.3
|
| 38 |
|
| 39 |
+
# TGI Configuration optimized for speed
|
| 40 |
ENV MAX_INPUT_LENGTH=4096
|
| 41 |
ENV MAX_TOTAL_TOKENS=8192
|
| 42 |
+
ENV MAX_BATCH_PREFILL_TOKENS=8192
|
| 43 |
+
ENV MAX_BATCH_TOTAL_TOKENS=32768
|
| 44 |
|
| 45 |
+
# Single GPU is enough for 7B model (much faster than sharding)
|
| 46 |
+
ENV NUM_SHARD=1
|
| 47 |
|
| 48 |
+
# No quantization needed for 7B model on L4 (24GB VRAM)
|
|
|
|
| 49 |
|
| 50 |
# Trust remote code (required for some models)
|
| 51 |
ENV TRUST_REMOTE_CODE=true
|