Text Generation
Transformers
PyTorch
JAX
English
gpt2
huggingartists
lyrics
lm-head
causal-lm
text-generation-inference
Instructions to use huggingartists/aimer with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use huggingartists/aimer with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="huggingartists/aimer")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("huggingartists/aimer") model = AutoModelForCausalLM.from_pretrained("huggingartists/aimer", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use huggingartists/aimer with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "huggingartists/aimer" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "huggingartists/aimer", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/huggingartists/aimer
- SGLang
How to use huggingartists/aimer 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 "huggingartists/aimer" \ --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": "huggingartists/aimer", "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 "huggingartists/aimer" \ --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": "huggingartists/aimer", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use huggingartists/aimer with Docker Model Runner:
docker model run hf.co/huggingartists/aimer
Download trainer_state.json from huggingartists/aimer: direct link, hf CLI and curl.
- Browser
- Download file 1.29 kB
-
https://huggingface.co/huggingartists/aimer/resolve/main/trainer_state.json
- Command line
-
hf download hf://huggingartists/aimer/trainer_state.json
-
curl -L -o trainer_state.json https://huggingface.co/huggingartists/aimer/resolve/main/trainer_state.json
1.29 kB
| { | |
| "best_metric": 3.378333568572998, | |
| "best_model_checkpoint": "output/aimer/checkpoint-34", | |
| "epoch": 1.0, | |
| "global_step": 34, | |
| "is_hyper_param_search": false, | |
| "is_local_process_zero": true, | |
| "is_world_process_zero": true, | |
| "log_history": [ | |
| { | |
| "epoch": 0.15, | |
| "learning_rate": 0.0001300082017869573, | |
| "loss": 4.1528, | |
| "step": 5 | |
| }, | |
| { | |
| "epoch": 0.29, | |
| "learning_rate": 0.000109940736055617, | |
| "loss": 3.8717, | |
| "step": 10 | |
| }, | |
| { | |
| "epoch": 0.44, | |
| "learning_rate": 8.120521692221673e-05, | |
| "loss": 3.6779, | |
| "step": 15 | |
| }, | |
| { | |
| "epoch": 0.59, | |
| "learning_rate": 4.982671888105512e-05, | |
| "loss": 3.5809, | |
| "step": 20 | |
| }, | |
| { | |
| "epoch": 0.74, | |
| "learning_rate": 2.2384478845846175e-05, | |
| "loss": 3.5199, | |
| "step": 25 | |
| }, | |
| { | |
| "epoch": 0.88, | |
| "learning_rate": 4.6324050628611986e-06, | |
| "loss": 3.5483, | |
| "step": 30 | |
| }, | |
| { | |
| "epoch": 1.0, | |
| "eval_loss": 3.378333568572998, | |
| "eval_runtime": 2.4453, | |
| "eval_samples_per_second": 20.857, | |
| "eval_steps_per_second": 2.863, | |
| "step": 34 | |
| } | |
| ], | |
| "max_steps": 34, | |
| "num_train_epochs": 1, | |
| "total_flos": 34882486272000.0, | |
| "trial_name": null, | |
| "trial_params": null | |
| } | |