Downloads · 30 days
23
5% of all-time downloads
Adriana213/gpt2-xl-text-generation
gpt2-xl-text-generation is a text generation model from Adriana213. Use it when you need the model to write or continue text. It is set up for transformers. The card lists the license as mit.
Model Description: This model card presents details for the gpt2-xl model, a large autoregressive language model optimized for text generation tasks. The model uses the GPT-2 architecture developed by OpenAI.
Downloads · 30 days
23
5% of all-time downloads
All-time downloads
428
Public
Parameters
1.6B
6.2 GB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors6.2 GB · 100%
From the Hugging Face model README
Model Description: This model card presents details for the gpt2-xl model, a large autoregressive language model optimized for text generation tasks. The model uses the GPT-2 architecture developed by OpenAI.
The model can be used for text generation tasks, such as completing sentences or generating coherent paragraphs.
The model may exhibit biases present in the training data and could generate inappropriate or sensitive content. Users should exercise caution when deploying the model in production.
Users should be aware of potential biases and limitations of the model, particularly when used in applications that involve sensitive or high-stakes content.
Use the code below to get started with the model.
import torch from transformers import AutoTokenizer, AutoModelForCausalLM
model_name = "gpt2-xl" tokenizer = AutoTokenizer.from_pretrained(model_name) model = AutoModelForCausalLM.from_pretrained(model_name)
input_txt = "Bananas are a great" input_ids = tokenizer(input_txt, return_tensors="pt")["input_ids"]
output = model.generate(input_ids, max_length=200, do_sample=False) print(tokenizer.decode(output[0]))
The model was trained on a diverse range of internet text, including news articles, books, and websites.
Training regime: Autoregressive training with large-scale language modeling objectives Compute infrastructure: GPUs (specific details not disclosed)
The model was evaluated on standard language modeling benchmarks, including perplexity scores on held-out data.