Text Generation
Transformers
TensorBoard
Safetensors
gpt2
Generated from Trainer
text-generation-inference
Run this model with HF Jobs
Run ninagroot/GPT2-705-RUN1 on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/ninagroot/GPT2-705-RUN1. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/ninagroot/GPT2-705-RUN1 on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/ninagroot/GPT2-705-RUN1. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/ninagroot/GPT2-705-RUN1. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use ninagroot/GPT2-705-RUN1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ninagroot/GPT2-705-RUN1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="ninagroot/GPT2-705-RUN1")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("ninagroot/GPT2-705-RUN1") model = AutoModelForCausalLM.from_pretrained("ninagroot/GPT2-705-RUN1", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use ninagroot/GPT2-705-RUN1 with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ninagroot/GPT2-705-RUN1" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ninagroot/GPT2-705-RUN1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/ninagroot/GPT2-705-RUN1
- SGLang
How to use ninagroot/GPT2-705-RUN1 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 "ninagroot/GPT2-705-RUN1" \ --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": "ninagroot/GPT2-705-RUN1", "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 "ninagroot/GPT2-705-RUN1" \ --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": "ninagroot/GPT2-705-RUN1", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use ninagroot/GPT2-705-RUN1 with Docker Model Runner:
docker model run hf.co/ninagroot/GPT2-705-RUN1
ninagroot/GPT2-705Mtest
Browse filesFiles changed (4)
12 unmodified lines131415161617181921 unmodified lines41424344444546474849505152535451525354555657585960616212 unmodified lines
This model is a fine-tuned version of [](https://huggingface.co/) on an unknown dataset.It achieves the following results on the evaluation set:- Loss: 8.4040- Loss: 7.2081
## Model description
21 unmodified lines- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08- lr_scheduler_type: cosine- lr_scheduler_warmup_steps: 50- num_epochs: 7- num_epochs: 15- mixed_precision_training: Native AMP
### Training results
| Training Loss | Epoch | Step | Validation Loss ||:-------------:|:-----:|:----:|:---------------:|| 9.6206 | 0.57 | 1 | 9.6212 || 8.0141 | 1.71 | 3 | 9.3085 || 7.7709 | 2.86 | 5 | 7.8544 || 8.4543 | 4.0 | 7 | 8.4040 || 9.6439 | 0.57 | 1 | 9.6409 || 8.0775 | 1.71 | 3 | 9.6248 || 8.2418 | 2.86 | 5 | 8.7251 || 7.6995 | 4.0 | 7 | 8.0438 || 7.4715 | 4.57 | 8 | 8.1243 || 7.7918 | 5.71 | 10 | 7.7544 || 7.1086 | 6.86 | 12 | 7.4231 || 6.7919 | 8.0 | 14 | 7.1621 || 6.4626 | 8.57 | 15 | 7.2081 |
### Framework versions1223version https://git-lfs.github.com/spec/v1oid sha256:ae326a3dc782a1b33f60121c45c61ba8fa074d8a378a01954a6e1d53ff55672aoid sha256:2f1f9203db249777c29b82b484e27c1fc2e664be0559a016f326bdee7f55265fsize 2796386080123version https://git-lfs.github.com/spec/v1oid sha256:d54eed2efdc1a4c909bf0b368fe34cf7950dc21f6a0eb01564e2796e9f70a3f6size 105251223version https://git-lfs.github.com/spec/v1oid sha256:e18c8cd30fb93d9c4f2a922f1bb0b1c9bdec0d0f9e9d607e3614a92357eb1850oid sha256:6e54f97170740d4086e8930b99a3fa778220e4cb0c9979b0c991f4a96c4a2129size 4984README.md+11-6
model.safetensors+1-1
runs/Apr16_14-32-37_gcn33.local.snellius.surf.nl/events.out.tfevents.1713270766.gcn33.local.snellius.surf.nl.184936.0Added+3
training_args.bin+1-1