Instructions to use v000000/L3.1-Niitorm-8B-DPO-t0.0001 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use v000000/L3.1-Niitorm-8B-DPO-t0.0001 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="v000000/L3.1-Niitorm-8B-DPO-t0.0001") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("v000000/L3.1-Niitorm-8B-DPO-t0.0001") model = AutoModelForCausalLM.from_pretrained("v000000/L3.1-Niitorm-8B-DPO-t0.0001") 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]:])) - Inference
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use v000000/L3.1-Niitorm-8B-DPO-t0.0001 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "v000000/L3.1-Niitorm-8B-DPO-t0.0001" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "v000000/L3.1-Niitorm-8B-DPO-t0.0001", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/v000000/L3.1-Niitorm-8B-DPO-t0.0001
- SGLang
How to use v000000/L3.1-Niitorm-8B-DPO-t0.0001 with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "v000000/L3.1-Niitorm-8B-DPO-t0.0001" \ --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": "v000000/L3.1-Niitorm-8B-DPO-t0.0001", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
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 "v000000/L3.1-Niitorm-8B-DPO-t0.0001" \ --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": "v000000/L3.1-Niitorm-8B-DPO-t0.0001", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use v000000/L3.1-Niitorm-8B-DPO-t0.0001 with Docker Model Runner:
docker model run hf.co/v000000/L3.1-Niitorm-8B-DPO-t0.0001
Llama-3.1-Niitorm-8B-DPO
- DPO Trained, Llama3.1-8B.
New: DPO'd Gutenberg Version (full epoch training).
RP model, Niitama 1.1 as a base, nearswapped with one of the smartest 3.1 models "Storm", then DPO'd, mostly abliterated.
Essentially, it's an improved Niitama 1.1
Gutenberg DPO creates more human-like prose/story writing and greately lessen synthetic feeling outputs.
llama.cpp:
thank you, mradermacher (GGUF)
thank you, QuantFactory (GGUF)
v0 (GGUF)
- GGUF Imatrix -only q8, q6 k, q5 k s, q4 k s, iq4 x s
Finetune and merge
This is a merge and finetune of pre-trained language models.
Resultant merge finetuned on jondurbin/gutenberg-dpo-v0.1 for 1 epoch, 1.5e-5 learning rate, on Nvidia A100.
Merge Details
Merge Method
This model was merged using the NEARSWAP t0.0001 merge algorithm.
Models Merged
The following models were included in the merge:
- Base Model: Sao10K/L3.1-8B-Niitama-v1.1 + grimjim/Llama-3-Instruct-abliteration-LoRA-8B
- akjindal53244/Llama-3.1-Storm-8B
Configuration
The following YAML configuration was used to produce this model:
slices:
- sources:
- model: Sao10K/L3.1-8B-Niitama-v1.1+grimjim/Llama-3-Instruct-abliteration-LoRA-8B
layer_range: [0, 32]
- model: akjindal53244/Llama-3.1-Storm-8B
layer_range: [0, 32]
merge_method: nearswap
base_model: Sao10K/L3.1-8B-Niitama-v1.1+grimjim/Llama-3-Instruct-abliteration-LoRA-8B
parameters:
t:
- value: 0.0001
dtype: float16
# Then, DPO Finetune
# [jondurbin/gutenberg-dpo-v0.1](https://huggingface.co/datasets/jondurbin/gutenberg-dpo-v0.1)
DPO Notes
I used a higher learning rate and full dataset when training compared to my "L3.1-Celestial-Stone-2x8B-DPO". This caused lower loss and better adaption to the chosen style.
Prompt Template:
<|begin_of_text|><|start_header_id|>system<|end_header_id|>
{system_prompt}<|eot_id|><|start_header_id|>user<|end_header_id|>
{input}<|eot_id|><|start_header_id|>assistant<|end_header_id|>
{output}<|eot_id|>
Credit to Alchemonaut.
Credit to Sao10K.
Credit to Grimjim.
Credit to mlabonne.
Credit to jondurbin.
Credit to woofwolfy.
Open LLM Leaderboard Evaluation Results
Detailed results can be found here
| Metric | Value |
|---|---|
| Avg. | 27.89 |
| IFEval (0-Shot) | 76.89 |
| BBH (3-Shot) | 30.51 |
| MATH Lvl 5 (4-Shot) | 14.88 |
| GPQA (0-shot) | 5.93 |
| MuSR (0-shot) | 7.26 |
| MMLU-PRO (5-shot) | 31.85 |
- Downloads last month
- 31
Model tree for v000000/L3.1-Niitorm-8B-DPO-t0.0001
Dataset used to train v000000/L3.1-Niitorm-8B-DPO-t0.0001
Spaces using v000000/L3.1-Niitorm-8B-DPO-t0.0001 7
Collection including v000000/L3.1-Niitorm-8B-DPO-t0.0001
Evaluation results
- strict accuracy on IFEval (0-Shot)Open LLM Leaderboard76.890
- normalized accuracy on BBH (3-Shot)Open LLM Leaderboard30.510
- exact match on MATH Lvl 5 (4-Shot)Open LLM Leaderboard14.880
- acc_norm on GPQA (0-shot)Open LLM Leaderboard5.930
- acc_norm on MuSR (0-shot)Open LLM Leaderboard7.260
- accuracy on MMLU-PRO (5-shot)test set Open LLM Leaderboard31.850
