LLaMA FLUTE
Collection
8 items • Updated • 1
How to use radi-cho/Meta-Llama-3-8B-FLUTE with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="radi-cho/Meta-Llama-3-8B-FLUTE") # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("radi-cho/Meta-Llama-3-8B-FLUTE")
model = AutoModelForCausalLM.from_pretrained("radi-cho/Meta-Llama-3-8B-FLUTE", device_map="auto")How to use radi-cho/Meta-Llama-3-8B-FLUTE with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "radi-cho/Meta-Llama-3-8B-FLUTE"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "radi-cho/Meta-Llama-3-8B-FLUTE",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker model run hf.co/radi-cho/Meta-Llama-3-8B-FLUTE
How to use radi-cho/Meta-Llama-3-8B-FLUTE with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "radi-cho/Meta-Llama-3-8B-FLUTE" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "radi-cho/Meta-Llama-3-8B-FLUTE",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'docker run --gpus all \
--shm-size 32g \
-p 30000:30000 \
-v ~/.cache/huggingface:/root/.cache/huggingface \
--env "HF_TOKEN=<secret>" \
--ipc=host \
lmsysorg/sglang:latest \
python3 -m sglang.launch_server \
--model-path "radi-cho/Meta-Llama-3-8B-FLUTE" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "radi-cho/Meta-Llama-3-8B-FLUTE",
"prompt": "Once upon a time,",
"max_tokens": 512,
"temperature": 0.5
}'How to use radi-cho/Meta-Llama-3-8B-FLUTE with Docker Model Runner:
docker model run hf.co/radi-cho/Meta-Llama-3-8B-FLUTE
| Wiki | C4 | PIQA | ARC-E | ARC-C | HellaSwag | Wino | Avg. | |
|---|---|---|---|---|---|---|---|---|
| Unquantized | 6.1 | 9.2 | 79.9 | 80.1 | 50.4 | 60.2 | 72.8 | 68.6 |
| W4G64 | 6.11 | 9.38 | 79.33 | 79.79 | 49.74 | 59.22 | 73.95 | 68.41 |
| W3G64 | 7.13 | 11.06 | 78.78 | 76.22 | 44.37 | 56.69 | 70.32 | 65.28 |
Revisions available in this repository:
main (W4G64, scales learned);nfl_w3g64 (W3G64, scales learned);nf_w4g64 (W4G64, scales not learned);nf_w3g64 (W3G64, scales not learned);Evaluations are provided for models with learned scales.
Benchmark scores (zero-shot) are computed with lm-evaluation-harness.