Instructions to use BLACK0X80/horus-egy-coder with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use BLACK0X80/horus-egy-coder with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="BLACK0X80/horus-egy-coder") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("BLACK0X80/horus-egy-coder") model = AutoModelForCausalLM.from_pretrained("BLACK0X80/horus-egy-coder") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use BLACK0X80/horus-egy-coder with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "BLACK0X80/horus-egy-coder" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BLACK0X80/horus-egy-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/BLACK0X80/horus-egy-coder
- SGLang
How to use BLACK0X80/horus-egy-coder with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "BLACK0X80/horus-egy-coder" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BLACK0X80/horus-egy-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "BLACK0X80/horus-egy-coder" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "BLACK0X80/horus-egy-coder", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Unsloth Studio
How to use BLACK0X80/horus-egy-coder with Unsloth Studio:
Install Unsloth Studio (macOS, Linux, WSL)
curl -fsSL https://unsloth.ai/install.sh | sh # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for BLACK0X80/horus-egy-coder to start chatting
Install Unsloth Studio (Windows)
irm https://unsloth.ai/install.ps1 | iex # Run unsloth studio unsloth studio -H 0.0.0.0 -p 8888 # Then open http://localhost:8888 in your browser # Search for BLACK0X80/horus-egy-coder to start chatting
Using HuggingFace Spaces for Unsloth
# No setup required # Open https://huggingface.co/spaces/unsloth/studio in your browser # Search for BLACK0X80/horus-egy-coder to start chatting
Load model with FastModel
pip install unsloth from unsloth import FastModel model, tokenizer = FastModel.from_pretrained( model_name="BLACK0X80/horus-egy-coder", max_seq_length=2048, ) - Docker Model Runner
How to use BLACK0X80/horus-egy-coder with Docker Model Runner:
docker model run hf.co/BLACK0X80/horus-egy-coder
Horus-Egy-Coder
Egyptian Arabic coding assistant — a fine-tuned Llama 3.1-8B model specialized in helping Arabic and Egyptian developers write, debug, and understand code.
Built in Egypt 🇪🇬 | Powered by Unsloth + TRL
Model Description
horus-egy-coder is a fine-tuned version of meta-llama/Llama-3.1-8B-Instruct trained to assist Arabic-speaking developers — with native understanding of Egyptian Arabic technical dialect. It can explain code in Arabic, help debug in conversational Egyptian, and write clean code with Arabic comments.
| Property | Value |
|---|---|
| Base model | meta-llama/Llama-3.1-8B-Instruct |
| Parameters | 1B (quantized BF16) |
| Training | Unsloth + HuggingFace TRL (2x faster) |
| License | Apache 2.0 |
| Language | Arabic 🇪🇬 / English |
| Task | Code generation, explanation, debugging |
Quick Start
from transformers import AutoTokenizer, AutoModelForCausalLM
import torch
model_name = "BLACK0X80/horus-egy-coder"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForCausalLM.from_pretrained(
model_name,
torch_dtype=torch.bfloat16,
device_map="auto"
)
messages = [
{
"role": "system",
"content": "أنت مساعد برمجة بيتكلم عربي مصري. بتشرح الكود بالعربي وبتساعد المطورين."
},
{
"role": "user",
"content": "اكتبلي function بـ Python بتحسب الـ factorial"
}
]
input_ids = tokenizer.apply_chat_template(
messages,
tokenize=True,
add_generation_prompt=True,
return_tensors="pt"
).to(model.device)
output = model.generate(
input_ids,
max_new_tokens=512,
temperature=0.7,
do_sample=True
)
print(tokenizer.decode(output[0][input_ids.shape[1]:], skip_special_tokens=True))
Example Interactions
Example 1 — Code explanation in Arabic:
User: فسرلي الكود ده
for i in range(len(arr)-1):
for j in range(len(arr)-i-1):
if arr[j] > arr[j+1]:
arr[j], arr[j+1] = arr[j+1], arr[j]
Model: ده Bubble Sort — خوارزمية ترتيب بسيطة.
بتعمل loop على الـ array وبتقارن كل عنصر بالي بعده،
لو العنصر الأكبر جه الأول بتبدلهم...
Example 2 — Debugging:
User: الكود ده بيطلع IndexError، مش عارف ليه
Model: المشكلة في السطر ده... جرب كذا...
🔢 GGUF Version (للأجهزة المحدودة)
لو جهازك مش عنده GPU كبير، استخدم النسخة المضغوطة:
BLACK0X80/horus-egy-coder-Q4_K_M-GGUF
# تشغيل بـ llama.cpp
./llama-cli -m horus-egy-coder-Q4_K_M.gguf \
-p "أنت مساعد برمجة عربي مصري." \
--chat-format llama-3
Training Details
- Framework: Unsloth (2x faster training, 60% less memory)
- Library: HuggingFace TRL (SFT Trainer)
- Base:
unsloth/Meta-Llama-3.1-8B-Instruct-bnb-4bit - Quantization: BF16
Intended Use
Good for:
- شرح الكود بالعربي المصري
- كتابة functions وscripts بـ Python
- Debugging مع تفسير الأخطاء بالعربي
- تعليم البرمجة للمبتدئين العرب
Limitations:
- النموذج fine-tuned على بيانات محدودة — ممكن يغلط في كود معقد جداً
- مش متخصص في لغات غير Python بنفس الكفاءة
- مش مناسب لـ production code بدون مراجعة بشرية
About HORUS-AI
HORUS-AI is an Egyptian AI initiative focused on building Arabic and Egyptian-dialect AI models. Named after the ancient Egyptian god of knowledge, we aim to make AI accessible to Arabic-speaking developers.
- GitHub: BLACK0X80
- Web: black0x80.vercel.app
Citation
@misc{horus-egy-coder-2025,
title={Horus-Egy-Coder: Egyptian Arabic Coding Assistant},
author={BLACK0X80 and HORUS-AI},
year={2025},
url={https://huggingface.co/BLACK0X80/horus-egy-coder},
note={Fine-tuned from meta-llama/Llama-3.1-8B-Instruct}
}
Made with ❤️ in Egypt 🇪🇬
- Downloads last month
- 88