Llama 3.1 8B Creative Writing
Published by @wordsmith_ai · Community adapter
Trains on 40 k excerpts from Project Gutenberg fiction. Improves narrative flow, dialogue naturalness, and scene-setting density. Include genre in the system prompt for best results.
Usage
from peft import PeftModel
from transformers import AutoModelForCausalLM, AutoTokenizer
tokenizer = AutoTokenizer.from_pretrained("meta-llama/Meta-Llama-3.1-8B-Instruct")
base = AutoModelForCausalLM.from_pretrained("meta-llama/Meta-Llama-3.1-8B-Instruct")
model = PeftModel.from_pretrained(base, "modelforgelab/llama31-8b-creative-writing-lora")
inputs = tokenizer("Your prompt here", return_tensors="pt")
outputs = model.generate(**inputs, max_new_tokens=256)
print(tokenizer.decode(outputs[0], skip_special_tokens=True))
Compatibility
- transformers>=4.43
- vLLM
You might also like
text-generation
public
Llama 3.1 8B Travel Planner
meta-llama/Meta-Llama-3.1-8B-Instruct
text-generation
public
Llama 3.1 8B Crypto Market Analyst
meta-llama/Meta-Llama-3.1-8B-Instruct
text-generation
public
Llama 3.1 8B Changelog Writer v2
meta-llama/Meta-Llama-3.1-8B-Instruct
text-generation
members
Llama 3.1 8B HR Writing
meta-llama/Meta-Llama-3.1-8B-Instruct