Downloads · 30 days
0
thomasajai/llama-3.1-8b-egyptian-german
llama-3.1-8b-egyptian-german is a machine learning model from thomasajai. Use it for the machine learning task on the model card, and read the license before you ship it in a product.
This model translates Ancient Egyptian transliterations to German. It's a LoRA fine-tuned version of Llama-3.1-8B-Instruct.
Downloads · 30 days
0
Access
Public
Updated Nov 25, 2025
Repo size
672 MB
Likes
0
Public
Click a slice to open those files.
.pt437 MB · 56%
From the Hugging Face model README
This model translates Ancient Egyptian transliterations to German. It's a LoRA fine-tuned version of Llama-3.1-8B-Instruct.
See evaluation_metrics.json for detailed scores:
from transformers import AutoTokenizer, AutoModelForCausalLM
from peft import PeftModel
# Load base model
base_model = AutoModelForCausalLM.from_pretrained(
"meta-llama/Llama-3.1-8B-Instruct",
device_map="auto",
torch_dtype="auto"
)
# Load LoRA adapter
model = PeftModel.from_pretrained(base_model, "thomasajai/llama-3.1-8b-egyptian-german")
tokenizer = AutoTokenizer.from_pretrained("thomasajai/llama-3.1-8b-egyptian-german")
# Generate translation
def translate(text):
messages = [
{"role": "system", "content": "Translate Ancient Egyptian transliteration to German."},
{"role": "user", "content": text}
]
prompt = tokenizer.apply_chat_template(messages, tokenize=False, add_generation_prompt=True)
inputs = tokenizer(prompt, return_tensors="pt").to(model.device)
outputs = model.generate(**inputs, max_new_tokens=64, temperature=0.1)
return tokenizer.decode(outputs[0][inputs['input_ids'].shape[1]:], skip_special_tokens=True)
# Example
print(translate("ḥr.w n.ꜥ nṯr")) # Output: "Horus Ninetjer"
| Egyptian | German (Reference) | Model Output |
|---|---|---|
| ḥr.w n.ꜥ nṯr | Horus Ninetjer | [Add examples] |
| wsꜣr wnꜣs | Osiris Unas | [Add examples] |
The model was trained on cleaned data from the Thesaurus Linguae Aegyptiae corpus, focusing on Earlier Egyptian texts.
Data preprocessing included:
If you use this model, please cite:
@misc{egyptian-german-llama,
author = {Your Name},
title = {Egyptian-German Translation Model},
year = {2024},
publisher = {Hugging Face},
howpublished = {\url{https://huggingface.co/thomasajai/llama-3.1-8b-egyptian-german}}
}
This adapter is released under the same license as the base Llama-3.1 model. Please refer to Meta's license terms.