data-is-better-together/10k_prompts_ranked
Viewer • Updated • 10.3k • 1.25k • 168
How to use argilla/zephyr-7b-spin-iter1-v0 with Transformers:
# Use a pipeline as a high-level helper
from transformers import pipeline
pipe = pipeline("text-generation", model="argilla/zephyr-7b-spin-iter1-v0")
messages = [
{"role": "user", "content": "Who are you?"},
]
pipe(messages) # Load model directly
from transformers import AutoTokenizer, AutoModelForCausalLM
tokenizer = AutoTokenizer.from_pretrained("argilla/zephyr-7b-spin-iter1-v0")
model = AutoModelForCausalLM.from_pretrained("argilla/zephyr-7b-spin-iter1-v0")
messages = [
{"role": "user", "content": "Who are you?"},
]
inputs = tokenizer.apply_chat_template(
messages,
add_generation_prompt=True,
tokenize=True,
return_dict=True,
return_tensors="pt",
).to(model.device)
outputs = model.generate(**inputs, max_new_tokens=40)
print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:]))How to use argilla/zephyr-7b-spin-iter1-v0 with vLLM:
# Install vLLM from pip:
pip install vllm
# Start the vLLM server:
vllm serve "argilla/zephyr-7b-spin-iter1-v0"
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:8000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "argilla/zephyr-7b-spin-iter1-v0",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'docker model run hf.co/argilla/zephyr-7b-spin-iter1-v0
How to use argilla/zephyr-7b-spin-iter1-v0 with SGLang:
# Install SGLang from pip:
pip install sglang
# Start the SGLang server:
python3 -m sglang.launch_server \
--model-path "argilla/zephyr-7b-spin-iter1-v0" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "argilla/zephyr-7b-spin-iter1-v0",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'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 "argilla/zephyr-7b-spin-iter1-v0" \
--host 0.0.0.0 \
--port 30000
# Call the server using curl (OpenAI-compatible API):
curl -X POST "http://localhost:30000/v1/chat/completions" \
-H "Content-Type: application/json" \
--data '{
"model": "argilla/zephyr-7b-spin-iter1-v0",
"messages": [
{
"role": "user",
"content": "What is the capital of France?"
}
]
}'How to use argilla/zephyr-7b-spin-iter1-v0 with Docker Model Runner:
docker model run hf.co/argilla/zephyr-7b-spin-iter1-v0
This model is a fine-tuned version of argilla/zephyr-7b-spin-iter0-v0 on the argilla/10k_prompts_SPIN_iter1_zephyr_top and argilla/10k_prompts_SPIN_iter0_zephyr_top dataset.
It achieves the following results on the evaluation set:
| Model | 1st Turn Score | 2nd Turn Score | Average Score |
|---|---|---|---|
| zephyr-7b-sft-full | 6.6625 | 6.0250 | 6.34375 |
| zephyr-7b-spin-iter0-v0 | 6.64375 | 6.1750 | 6.409375 |
| zephyr-7b-spin-iter1-v0 | 6.90625 | 6.3000 | 6.603125 |
| zephyr-7b-spin-iter2-v0 | 7.1375 | 6.3125 | 6.725000 |
| zephyr-7b-spin-iter3-v0 | 7.09375 | 6.4500 | 6.771875 |
More information needed
More information needed
More information needed
The following hyperparameters were used during training:
| Training Loss | Epoch | Step | Validation Loss | Rewards/real | Rewards/generated | Rewards/accuracies | Rewards/margins | Logps/generated | Logps/real | Logits/generated | Logits/real |
|---|---|---|---|---|---|---|---|---|---|---|---|
| 0.1827 | 0.49 | 25 | 0.1651 | 0.1714 | -3.3650 | 0.9688 | 3.5364 | -524.2469 | -283.6962 | -2.7482 | -2.7944 |
| 0.0462 | 0.97 | 50 | 0.0835 | 1.4823 | -4.4998 | 1.0 | 5.9821 | -535.5947 | -270.5871 | -2.6963 | -2.7356 |
| 0.0047 | 1.46 | 75 | 0.0837 | 1.3725 | -5.2500 | 0.9896 | 6.6225 | -543.0965 | -271.6846 | -2.6847 | -2.7211 |
| 0.0034 | 1.94 | 100 | 0.0831 | 1.3037 | -5.4434 | 0.9792 | 6.7471 | -545.0309 | -272.3726 | -2.6844 | -2.7197 |
Base model
mistralai/Mistral-7B-v0.1