Text Generation
Transformers
Safetensors
gemma2
alignment-handbook
trl
simpo
Generated from Trainer
conversational
text-generation-inference
Instructions to use jz666/simpo-train-small-wrong with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use jz666/simpo-train-small-wrong with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="jz666/simpo-train-small-wrong") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("jz666/simpo-train-small-wrong") model = AutoModelForCausalLM.from_pretrained("jz666/simpo-train-small-wrong", device_map="auto") 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]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use jz666/simpo-train-small-wrong with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "jz666/simpo-train-small-wrong" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jz666/simpo-train-small-wrong", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/jz666/simpo-train-small-wrong
- SGLang
How to use jz666/simpo-train-small-wrong 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 "jz666/simpo-train-small-wrong" \ --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": "jz666/simpo-train-small-wrong", "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 "jz666/simpo-train-small-wrong" \ --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": "jz666/simpo-train-small-wrong", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use jz666/simpo-train-small-wrong with Docker Model Runner:
docker model run hf.co/jz666/simpo-train-small-wrong
| { | |
| "epoch": 0.995910949568378, | |
| "eval_logits/chosen": -10.091446876525879, | |
| "eval_logits/rejected": -9.818441390991211, | |
| "eval_logps/chosen": -0.8267378211021423, | |
| "eval_logps/rejected": -0.9961459040641785, | |
| "eval_loss": 3.9708292484283447, | |
| "eval_rewards/accuracies": 0.7049180269241333, | |
| "eval_rewards/chosen": -8.267377853393555, | |
| "eval_rewards/margins": 1.6940813064575195, | |
| "eval_rewards/rejected": -9.96146011352539, | |
| "eval_runtime": 86.365, | |
| "eval_samples": 1941, | |
| "eval_samples_per_second": 22.474, | |
| "eval_steps_per_second": 1.413, | |
| "total_flos": 0.0, | |
| "train_loss": 4.865393144370866, | |
| "train_runtime": 3024.5765, | |
| "train_samples": 17605, | |
| "train_samples_per_second": 5.821, | |
| "train_steps_per_second": 0.045 | |
| } |