Instructions to use mo22zy/LLM-fineTune-LLaMAFactory-UnSloth with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use mo22zy/LLM-fineTune-LLaMAFactory-UnSloth with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("unsloth/Qwen2.5-0.5B-Instruct") model = PeftModel.from_pretrained(base_model, "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth") - Transformers
How to use mo22zy/LLM-fineTune-LLaMAFactory-UnSloth with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="mo22zy/LLM-fineTune-LLaMAFactory-UnSloth") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("mo22zy/LLM-fineTune-LLaMAFactory-UnSloth", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use mo22zy/LLM-fineTune-LLaMAFactory-UnSloth with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/mo22zy/LLM-fineTune-LLaMAFactory-UnSloth
- SGLang
How to use mo22zy/LLM-fineTune-LLaMAFactory-UnSloth 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 "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth" \ --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": "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth", "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 "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth" \ --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": "mo22zy/LLM-fineTune-LLaMAFactory-UnSloth", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Desktop
- Docker Model Runner
How to use mo22zy/LLM-fineTune-LLaMAFactory-UnSloth with Docker Model Runner:
docker model run hf.co/mo22zy/LLM-fineTune-LLaMAFactory-UnSloth
|
Download README.md from mo22zy/LLM-fineTune-LLaMAFactory-UnSloth: direct link, hf CLI and curl.
- Browser
- Download file 2.71 kB
-
https://huggingface.co/mo22zy/LLM-fineTune-LLaMAFactory-UnSloth/resolve/main/README.md
- Command line
-
hf download hf://mo22zy/LLM-fineTune-LLaMAFactory-UnSloth/README.md
-
curl -L -o README.md https://huggingface.co/mo22zy/LLM-fineTune-LLaMAFactory-UnSloth/resolve/main/README.md
2.71 kB
| library_name: peft | |
| license: apache-2.0 | |
| base_model: unsloth/Qwen2.5-0.5B-Instruct | |
| tags: | |
| - base_model:adapter:unsloth/Qwen2.5-0.5B-Instruct | |
| - llama-factory | |
| - lora | |
| - transformers | |
| - unsloth | |
| pipeline_tag: text-generation | |
| model-index: | |
| - name: LLM-fineTune-LLaMAFactory-UnSloth | |
| results: [] | |
| <!-- This model card has been generated automatically according to the information the Trainer had access to. You | |
| should probably proofread and complete it, then remove this comment. --> | |
| # LLM-fineTune-LLaMAFactory-UnSloth | |
| This model is a fine-tuned version of [Qwen/Qwen2.5-0.5B-Instruct](https://huggingface.co/Qwen/Qwen2.5-0.5B-Instruct) on the news_finetune_train dataset. | |
| It achieves the following results on the evaluation set: | |
| - Loss: 0.5046 | |
| ## Model description | |
| More information needed | |
| ## Intended uses & limitations | |
| More information needed | |
| ## Training and evaluation data | |
| More information needed | |
| ## Training procedure | |
| ### Training hyperparameters | |
| The following hyperparameters were used during training: | |
| - learning_rate: 0.0001 | |
| - train_batch_size: 1 | |
| - eval_batch_size: 1 | |
| - seed: 42 | |
| - gradient_accumulation_steps: 4 | |
| - total_train_batch_size: 4 | |
| - optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments | |
| - lr_scheduler_type: cosine | |
| - lr_scheduler_warmup_steps: 0.1 | |
| - num_epochs: 3.0 | |
| - mixed_precision_training: Native AMP | |
| ### Training results | |
| | Training Loss | Epoch | Step | Validation Loss | | |
| |:-------------:|:------:|:----:|:---------------:| | |
| | 0.6751 | 0.1559 | 100 | 0.6013 | | |
| | 0.7727 | 0.3119 | 200 | 0.5871 | | |
| | 0.6416 | 0.4678 | 300 | 0.5594 | | |
| | 0.6686 | 0.6238 | 400 | 0.5424 | | |
| | 0.5999 | 0.7797 | 500 | 0.5319 | | |
| | 0.5403 | 0.9357 | 600 | 0.5232 | | |
| | 0.4161 | 1.0904 | 700 | 0.5130 | | |
| | 0.4490 | 1.2464 | 800 | 0.5075 | | |
| | 0.4694 | 1.4023 | 900 | 0.4965 | | |
| | 0.4071 | 1.5583 | 1000 | 0.4871 | | |
| | 0.4285 | 1.7142 | 1100 | 0.4959 | | |
| | 0.5757 | 1.8702 | 1200 | 0.5070 | | |
| | 0.2810 | 2.0250 | 1300 | 0.5236 | | |
| | 0.3507 | 2.1809 | 1400 | 0.5188 | | |
| | 0.2787 | 2.3368 | 1500 | 0.5214 | | |
| | 0.3636 | 2.4928 | 1600 | 0.5142 | | |
| | 0.3344 | 2.6487 | 1700 | 0.5073 | | |
| | 0.3201 | 2.8047 | 1800 | 0.5123 | | |
| | 0.2866 | 2.9606 | 1900 | 0.4967 | | |
| | 0.2767 | 3.0 | 1926 | 0.5046 | | |
| ### Framework versions | |
| - PEFT 0.18.1 | |
| - Transformers 5.8.0 | |
| - Pytorch 2.11.0+cu128 | |
| - Datasets 4.0.0 | |
| - Tokenizers 0.22.2 |