Downloads · 30 days
33
1% of all-time downloads
kmkrworks/LiteGPT-Instruct
LiteGPT-Instruct is a text generation model from kmkrworks. Use it when you need the model to write or continue text. The card lists the license as apache-2.0.
This is a 124M parameter Language Model (GPT-2 Small architecture) fine-tuned on the Alpaca dataset for instruction following.
Downloads · 30 days
33
1% of all-time downloads
All-time downloads
4.5K
Public
Parameters
124M
498 MB on disk
Likes
2
Public
Click a slice to open those files.
.safetensors498 MB · 100%
From the Hugging Face model README
This is a 124M parameter Language Model (GPT-2 Small architecture) fine-tuned on the Alpaca dataset for instruction following.
It is part of the "Small Language Model (SLM)" project, trained from scratch on educational data (FineWeb-Edu) and then fine-tuned on instructions.
This model requires a specific prompt format to function correctly.
Below is an instruction that describes a task. Write a response that appropriately completes the request.
### Instruction:
{your_instruction}
### Response:
from transformers import GPT2LMHeadModel, GPT2Tokenizer
model = GPT2LMHeadModel.from_pretrained("koganrath/LiteGPT-Instruct")
tokenizer = GPT2Tokenizer.from_pretrained("gpt2")
instruction = "List three primary colors."
prompt = f"""Below is an instruction that describes a task. Write a response that appropriately completes the request.
### Instruction:
{instruction}
### Response:
"""
inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=50)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
Trained by koganrath as part of the LiteGPT Project.