Instructions to use kaizerBox/retnet-summarization_small with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use kaizerBox/retnet-summarization_small with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="kaizerBox/retnet-summarization_small")# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("kaizerBox/retnet-summarization_small", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use kaizerBox/retnet-summarization_small with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "kaizerBox/retnet-summarization_small" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "kaizerBox/retnet-summarization_small", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/kaizerBox/retnet-summarization_small
- SGLang
How to use kaizerBox/retnet-summarization_small 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 "kaizerBox/retnet-summarization_small" \ --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": "kaizerBox/retnet-summarization_small", "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 "kaizerBox/retnet-summarization_small" \ --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": "kaizerBox/retnet-summarization_small", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use kaizerBox/retnet-summarization_small with Docker Model Runner:
docker model run hf.co/kaizerBox/retnet-summarization_small
retnet-summarization-small
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 [kaizerBox/retnet-summarization_small](https://huggingface.co/kaizerBox/retnet-summarization_small) on the xsum dataset.
|
| 18 |
It achieves the following results on the evaluation set:
|
| 19 |
-
- Loss: 4.
|
| 20 |
|
| 21 |
## Model description
|
| 22 |
|
|
@@ -35,7 +35,7 @@ More information needed
|
|
| 35 |
### Training hyperparameters
|
| 36 |
|
| 37 |
The following hyperparameters were used during training:
|
| 38 |
-
- learning_rate: 0.
|
| 39 |
- train_batch_size: 10
|
| 40 |
- eval_batch_size: 10
|
| 41 |
- seed: 42
|
|
@@ -44,19 +44,21 @@ The following hyperparameters were used during training:
|
|
| 44 |
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 45 |
- lr_scheduler_type: cosine
|
| 46 |
- lr_scheduler_warmup_steps: 10
|
| 47 |
-
- num_epochs:
|
| 48 |
- mixed_precision_training: Native AMP
|
| 49 |
|
| 50 |
### Training results
|
| 51 |
|
| 52 |
-
| Training Loss | Epoch | Step
|
| 53 |
-
|:-------------:|:-----:|:----:|:---------------:|
|
| 54 |
-
| 4.
|
|
|
|
|
|
|
| 55 |
|
| 56 |
|
| 57 |
### Framework versions
|
| 58 |
|
| 59 |
- Transformers 4.35.2
|
| 60 |
- Pytorch 2.1.0+cu118
|
| 61 |
-
- Datasets 2.
|
| 62 |
- Tokenizers 0.15.0
|
|
|
|
| 16 |
|
| 17 |
This model is a fine-tuned version of [kaizerBox/retnet-summarization_small](https://huggingface.co/kaizerBox/retnet-summarization_small) on the xsum dataset.
|
| 18 |
It achieves the following results on the evaluation set:
|
| 19 |
+
- Loss: 4.1548
|
| 20 |
|
| 21 |
## Model description
|
| 22 |
|
|
|
|
| 35 |
### Training hyperparameters
|
| 36 |
|
| 37 |
The following hyperparameters were used during training:
|
| 38 |
+
- learning_rate: 0.0001
|
| 39 |
- train_batch_size: 10
|
| 40 |
- eval_batch_size: 10
|
| 41 |
- seed: 42
|
|
|
|
| 44 |
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
|
| 45 |
- lr_scheduler_type: cosine
|
| 46 |
- lr_scheduler_warmup_steps: 10
|
| 47 |
+
- num_epochs: 3
|
| 48 |
- mixed_precision_training: Native AMP
|
| 49 |
|
| 50 |
### Training results
|
| 51 |
|
| 52 |
+
| Training Loss | Epoch | Step | Validation Loss |
|
| 53 |
+
|:-------------:|:-----:|:-----:|:---------------:|
|
| 54 |
+
| 4.3508 | 1.0 | 4610 | 4.1581 |
|
| 55 |
+
| 4.3471 | 2.0 | 9220 | 4.1551 |
|
| 56 |
+
| 4.3446 | 3.0 | 13830 | 4.1548 |
|
| 57 |
|
| 58 |
|
| 59 |
### Framework versions
|
| 60 |
|
| 61 |
- Transformers 4.35.2
|
| 62 |
- Pytorch 2.1.0+cu118
|
| 63 |
+
- Datasets 2.15.0
|
| 64 |
- Tokenizers 0.15.0
|
model.safetensors
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 53857264
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:10e909aa1a3aa9a5354a04476d7b9c9497bb4f3c9efc2dfaa95067eecd387e6a
|
| 3 |
size 53857264
|
runs/Nov16_19-21-08_0302d3c57c64/events.out.tfevents.1700162469.0302d3c57c64.293.0
ADDED
|
@@ -0,0 +1,3 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:c51e23ef366aed94410c4138d5b077324cf63776b8f8202c123beda70ac8c77e
|
| 3 |
+
size 6239
|
training_args.bin
CHANGED
|
@@ -1,3 +1,3 @@
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
-
oid sha256:
|
| 3 |
size 4600
|
|
|
|
| 1 |
version https://git-lfs.github.com/spec/v1
|
| 2 |
+
oid sha256:a4faff7697c8861a7d2773edb4ddf18938f973965f3955bab32edc7e832ebb87
|
| 3 |
size 4600
|