Run this model with HF Jobs
Run progs2002/star-trek-tng-script-generator 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/progs2002/star-trek-tng-script-generator. 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/progs2002/star-trek-tng-script-generator 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/progs2002/star-trek-tng-script-generator. 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/progs2002/star-trek-tng-script-generator. 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 progs2002/star-trek-tng-script-generator with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use progs2002/star-trek-tng-script-generator with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="progs2002/star-trek-tng-script-generator")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("progs2002/star-trek-tng-script-generator") model = AutoModelForCausalLM.from_pretrained("progs2002/star-trek-tng-script-generator", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use progs2002/star-trek-tng-script-generator with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "progs2002/star-trek-tng-script-generator" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "progs2002/star-trek-tng-script-generator", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/progs2002/star-trek-tng-script-generator
- SGLang
How to use progs2002/star-trek-tng-script-generator 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 "progs2002/star-trek-tng-script-generator" \ --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": "progs2002/star-trek-tng-script-generator", "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 "progs2002/star-trek-tng-script-generator" \ --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": "progs2002/star-trek-tng-script-generator", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use progs2002/star-trek-tng-script-generator with Docker Model Runner:
docker model run hf.co/progs2002/star-trek-tng-script-generator
data cleaning and training code
https://github.com/progs2002/StarTrekTNG-ScriptGenerator
star-trek-tng-script-generator
This model is a fine-tuned version of gpt2 on an unknown dataset. It achieves the following results on the evaluation set:
- Loss: 2.8459
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.0002
- train_batch_size: 1
- eval_batch_size: 1
- seed: 42
- optimizer: Adam with betas=(0.9,0.999) and epsilon=1e-08
- lr_scheduler_type: cosine
- lr_scheduler_warmup_steps: 50
- num_epochs: 3
Training results
| Training Loss | Epoch | Step | Validation Loss |
|---|---|---|---|
| 3.1502 | 0.13 | 500 | 3.0233 |
| 3.0538 | 0.26 | 1000 | 2.9728 |
| 2.9951 | 0.38 | 1500 | 2.9437 |
| 2.9891 | 0.51 | 2000 | 2.9125 |
| 2.9289 | 0.64 | 2500 | 2.9159 |
| 2.9091 | 0.77 | 3000 | 2.9008 |
| 2.8916 | 0.89 | 3500 | 2.8752 |
| 2.8122 | 1.02 | 4000 | 2.8881 |
| 2.5224 | 1.15 | 4500 | 2.8896 |
| 2.5284 | 1.28 | 5000 | 2.8667 |
| 2.5191 | 1.4 | 5500 | 2.8599 |
| 2.5119 | 1.53 | 6000 | 2.8488 |
| 2.4808 | 1.66 | 6500 | 2.8296 |
| 2.4601 | 1.79 | 7000 | 2.8081 |
| 2.4331 | 1.91 | 7500 | 2.7993 |
| 2.3716 | 2.04 | 8000 | 2.8518 |
| 2.1528 | 2.17 | 8500 | 2.8634 |
| 2.1276 | 2.3 | 9000 | 2.8617 |
| 2.1329 | 2.43 | 9500 | 2.8489 |
| 2.1135 | 2.55 | 10000 | 2.8446 |
| 2.1259 | 2.68 | 10500 | 2.8461 |
| 2.1142 | 2.81 | 11000 | 2.8472 |
| 2.1071 | 2.94 | 11500 | 2.8459 |
Framework versions
- Transformers 4.35.2
- Pytorch 2.1.0+cu121
- Datasets 2.16.1
- Tokenizers 0.15.0
- Downloads last month
- 40
Model tree for progs2002/star-trek-tng-script-generator
Base model
openai-community/gpt2