Text Generation
Transformers
TensorBoard
Safetensors
llama
Generated from Trainer
text-generation-inference
Instructions to use WilliamHH/Assignment2-modified-V2 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use WilliamHH/Assignment2-modified-V2 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="WilliamHH/Assignment2-modified-V2")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("WilliamHH/Assignment2-modified-V2") model = AutoModelForCausalLM.from_pretrained("WilliamHH/Assignment2-modified-V2") - Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use WilliamHH/Assignment2-modified-V2 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "WilliamHH/Assignment2-modified-V2" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "WilliamHH/Assignment2-modified-V2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/WilliamHH/Assignment2-modified-V2
- SGLang
How to use WilliamHH/Assignment2-modified-V2 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 "WilliamHH/Assignment2-modified-V2" \ --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": "WilliamHH/Assignment2-modified-V2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'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 "WilliamHH/Assignment2-modified-V2" \ --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": "WilliamHH/Assignment2-modified-V2", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use WilliamHH/Assignment2-modified-V2 with Docker Model Runner:
docker model run hf.co/WilliamHH/Assignment2-modified-V2
End of training
Browse files
README.md
CHANGED
|
@@ -16,7 +16,7 @@ should probably proofread and complete it, then remove this comment. -->
|
|
| 16 |
|
| 17 |
This model is a fine-tuned version of [HuggingFaceTB/SmolLM-135M](https://huggingface.co/HuggingFaceTB/SmolLM-135M) on an unknown dataset.
|
| 18 |
It achieves the following results on the evaluation set:
|
| 19 |
-
- Loss:
|
| 20 |
|
| 21 |
## Model description
|
| 22 |
|
|
@@ -35,36 +35,30 @@ More information needed
|
|
| 35 |
### Training hyperparameters
|
| 36 |
|
| 37 |
The following hyperparameters were used during training:
|
| 38 |
-
- learning_rate:
|
| 39 |
- train_batch_size: 8
|
| 40 |
- eval_batch_size: 8
|
| 41 |
- seed: 42
|
| 42 |
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
|
| 43 |
- lr_scheduler_type: cosine
|
| 44 |
-
- num_epochs:
|
| 45 |
|
| 46 |
### Training results
|
| 47 |
|
| 48 |
-
| Training Loss | Epoch
|
| 49 |
-
|:-------------:|:-----
|
| 50 |
-
|
|
| 51 |
-
|
|
| 52 |
-
|
|
| 53 |
-
|
|
| 54 |
-
|
|
| 55 |
-
|
|
| 56 |
-
| 2.
|
| 57 |
-
| 2.
|
| 58 |
-
| 2.
|
| 59 |
-
| 2.
|
| 60 |
-
| 2.
|
| 61 |
-
| 2.
|
| 62 |
-
| 2.7784 | 2.08 | 2600 | 3.3150 |
|
| 63 |
-
| 2.7302 | 2.24 | 2800 | 3.3180 |
|
| 64 |
-
| 2.7181 | 2.4 | 3000 | 3.3185 |
|
| 65 |
-
| 2.729 | 2.56 | 3200 | 3.3186 |
|
| 66 |
-
| 2.7404 | 2.7200 | 3400 | 3.3182 |
|
| 67 |
-
| 2.7329 | 2.88 | 3600 | 3.3182 |
|
| 68 |
|
| 69 |
|
| 70 |
### Framework versions
|
|
|
|
| 16 |
|
| 17 |
This model is a fine-tuned version of [HuggingFaceTB/SmolLM-135M](https://huggingface.co/HuggingFaceTB/SmolLM-135M) on an unknown dataset.
|
| 18 |
It achieves the following results on the evaluation set:
|
| 19 |
+
- Loss: 2.8719
|
| 20 |
|
| 21 |
## Model description
|
| 22 |
|
|
|
|
| 35 |
### Training hyperparameters
|
| 36 |
|
| 37 |
The following hyperparameters were used during training:
|
| 38 |
+
- learning_rate: 3e-05
|
| 39 |
- train_batch_size: 8
|
| 40 |
- eval_batch_size: 8
|
| 41 |
- seed: 42
|
| 42 |
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
|
| 43 |
- lr_scheduler_type: cosine
|
| 44 |
+
- num_epochs: 2
|
| 45 |
|
| 46 |
### Training results
|
| 47 |
|
| 48 |
+
| Training Loss | Epoch | Step | Validation Loss |
|
| 49 |
+
|:-------------:|:-----:|:----:|:---------------:|
|
| 50 |
+
| 2.594 | 0.16 | 200 | 2.9858 |
|
| 51 |
+
| 2.5675 | 0.32 | 400 | 2.9604 |
|
| 52 |
+
| 2.5578 | 0.48 | 600 | 2.9417 |
|
| 53 |
+
| 2.6641 | 0.64 | 800 | 2.9061 |
|
| 54 |
+
| 2.6633 | 0.8 | 1000 | 2.8829 |
|
| 55 |
+
| 2.6115 | 0.96 | 1200 | 2.8656 |
|
| 56 |
+
| 2.4333 | 1.12 | 1400 | 2.8809 |
|
| 57 |
+
| 2.3539 | 1.28 | 1600 | 2.8797 |
|
| 58 |
+
| 2.3336 | 1.44 | 1800 | 2.8743 |
|
| 59 |
+
| 2.334 | 1.6 | 2000 | 2.8731 |
|
| 60 |
+
| 2.3502 | 1.76 | 2200 | 2.8723 |
|
| 61 |
+
| 2.3205 | 1.92 | 2400 | 2.8719 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 62 |
|
| 63 |
|
| 64 |
### Framework versions
|