Downloads · 30 days
16
4% of all-time downloads
merileijona/mechanicus-prayer-gpt2
mechanicus-prayer-gpt2 is a text generation model from merileijona. Use it when you need the model to write or continue text. The card lists the license as cc-by-nc-sa-4.0.
A 124M parameter transformer model trained on Mechanicus-style prayers using the GPT-2 architecture.
Downloads · 30 days
16
4% of all-time downloads
All-time downloads
455
Public
Parameters
124M
496 MB on disk
Likes
1
Public
Click a slice to open those files.
.safetensors496 MB · 100%
From the Hugging Face model README
A 124M parameter transformer model trained on Mechanicus-style prayers using the GPT-2 architecture.
This model generates thematic prayers, blessings, and activation rites for various machines and equipment in the Mechanicus style. It produces natural prose with appropriate Mechanicus flavor (references to the Omnissiah, Machine Spirits, sacred oils, litanies, etc.).
Architecture: GPT-2 (124M parameters, trained from scratch)
Training Data: 3,972 Grok-generated examples (dataset)
Tokenization: Trained without bias terms, uses tiktoken encoding
pip install transformers torch tiktoken
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
# Load model and tokenizer
tokenizer = AutoTokenizer.from_pretrained(
"merileijona/mechanicus-prayer-gpt2",
trust_remote_code=True # Required for custom tiktoken tokenizer
)
model = AutoModelForCausalLM.from_pretrained("merileijona/mechanicus-prayer-gpt2")
model.eval()
# Format prompt
prompt = "<|user|>Prayer for activating a plasma reactor.<|end|>\n<|assistant|>"
# Generate
inputs = tokenizer(prompt, return_tensors="pt")
with torch.no_grad():
outputs = model.generate(
inputs["input_ids"],
max_new_tokens=256,
temperature=0.65, # Lower = more consistent
top_k=30,
do_sample=True,
)
# Decode
text = tokenizer.decode(outputs[0], skip_special_tokens=False)
prayer = text.split("<|assistant|>")[1].split("<|end|>")[0].strip()
print(prayer)
Input: "Prayer for activating a plasma reactor."
Generated:
Encircle the plasma reactor, intoning the Litany of Containment.
Beseech the plasma reactor's volatile Machine Spirit to accept charging.
Infuse plasma conduits with sanctified isotopes into the plasma reactor's core.
Chant the Incantation of Contained Fury during the charging ritual.
Seal the plasma reactor's charged plasma with a final benediction.
<|user|>[Your request]<|end|>
<|assistant|>
Example prompts:
"Prayer for activating a [device]""Blessing for a [weapon/tool]""Emergency prayer for a [system]""Litany for [action/sequence]""Rite of [operation] for a [component]"temperature: 0.65 (lower than default 1.0 for better consistency)top_k: 30 (lower than default 50)max_new_tokens: 256Higher temperatures may produce less coherent results.
This model uses a custom tiktoken-based tokenizer wrapped in HuggingFace's interface. This ensures compatibility with the original training process while maintaining standard HuggingFace APIs.
Why? The model was trained using tiktoken (standard for nanoGPT). HuggingFace's default GPT2Tokenizer has subtle encoding differences that break generation quality.
The custom tokenizer loads automatically with trust_remote_code=True.
<|user|> (50257), <|assistant|> (50258), <|end|> (50259)✅ Appropriate uses:
Code & Model: Licensed under CC BY-NC-SA 4.0
Warhammer 40,000 IP: All Warhammer 40,000 content, including the Adeptus Mechanicus, Cult Mechanicus, and associated lore, names, characters, and imagery are ©, ®, and/or ™ Games Workshop Limited.
This is an unofficial, non-commercial fan project for educational and entertainment purposes. Not affiliated with, endorsed by, or sponsored by Games Workshop Limited.
@misc{mechanicus-prayer-gpt2-2026,
author = {merileijona},
title = {Mechanicus Prayer Generator GPT-2},
year = {2026},
publisher = {HuggingFace},
howpublished = {\url{https://huggingface.co/merileijona/mechanicus-prayer-gpt2}}
}
From the weakness of the mind, Omnissiah save us.
From the lies of the Antipath, circuit preserve us.
From the rage of the Beast, iron protect us.
From the temptations of the Flesh, silica cleanse us.
From the ravages of the Destroyer, anima shield us.
From this rotting cage of biomatter, Machine God, set us free. ⚙️