9 7 months ago

TashriAI-DZ is a specialized Algerian AI model designed to assist with legislative and regulatory texts related to the national education system. It focuses on accurate retrieval, analysis, and understanding of official educational documents such as laws,

tools
ollama run nacerzouaizia/TashriAI-DZ

Applications

Claude Code
Claude Code ollama launch claude --model nacerzouaizia/TashriAI-DZ
OpenCode
OpenCode ollama launch opencode --model nacerzouaizia/TashriAI-DZ
Hermes Agent
Hermes Agent ollama launch hermes --model nacerzouaizia/TashriAI-DZ
OpenClaw
OpenClaw ollama launch openclaw --model nacerzouaizia/TashriAI-DZ

Models

View all →

Readme

🇩🇿 TashriAI DZ

الذكاء الاصطناعي في خدمة التشريع المدرسي الجزائري

Intelligence artificielle au service de la législation scolaire algérienne

AI for Algerian Educational Legislation

Ollama Size Context Arabic French


🇩🇿 العربية

لماذا TashriAI DZ؟

في قطاع التربية، قد تكون الإجابة التي نبحث عنها موجودة داخل قانون، مرسوم، قرار أو منشور رسمي…

لكن الوصول إلى النص الصحيح، وربطه بالسؤال المطروح، والتحقق من مرجعه قد يستغرق وقتًا.

من هنا بدأت فكرة TashriAI DZ.

هو مشروع جزائري أعمل على تطويره لتسهيل البحث، الاسترجاع وفهم النصوص التشريعية والتنظيمية المرتبطة بالمنظومة التربوية الجزائرية باستخدام تقنيات الذكاء الاصطناعي ونماذج اللغة.

الهدف ليس بناء نموذج “يجيب عن كل شيء”.

الهدف هو بناء أداة تحاول أن:

  • 🔎 تبحث قبل أن تجيب
  • 📚 تعتمد على النصوص والمصادر
  • 🧾 تحافظ على المرجعية القانونية
  • 🛡️ تتجنب اختلاق المواد والمراجع
  • 🤝 تصرّح بعدم المعرفة عندما لا يكون النص المتوفر كافيًا

في المجال القانوني، الإجابة غير الموثقة قد تكون أسوأ من عدم الإجابة.


🎯 ما هو TashriAI DZ؟

TashriAI DZ هو نموذج ذكاء اصطناعي موجه للتعامل مع النصوص القانونية والتنظيمية المرتبطة بقطاع التربية الوطنية في الجزائر.

يمكن استخدامه للمساعدة في:

  • البحث في التشريع المدرسي
  • فهم النصوص التنظيمية
  • تحليل القوانين والمراسيم
  • التعامل مع المناشير والتعليمات
  • استخراج المعلومات من النصوص الطويلة
  • صياغة إجابات واضحة انطلاقًا من سياق قانوني
  • التعامل مع المصطلحات الإدارية والقانونية العربية والفرنسية

🧠 فلسفة المشروع

Retrieval first. Generation second.

في النسخة الكاملة من المشروع، لا يُفترض أن تعتمد المعرفة القانونية على ذاكرة النموذج وحدها.

بدلًا من ذلك:

السؤال ↓
البحث في الوثائق ↓
استرجاع المقاطع الأكثر صلة ↓
إرسال السياق إلى النموذج ↓
توليد الإجابة ↓
عرض المرجع متى كان متاحًا

وهذه الفكرة هي أساس بنية RAG — Retrieval-Augmented Generation المستخدمة في المشروع.


⚠️ النموذج والمنظومة الكاملة ليسا الشيء نفسه

النموذج الموجود على Ollama:

nacerzouaizia/TashriAI-DZ

يمثل طبقة الذكاء اللغوي في المشروع.

أما منظومة TashriAI DZ الكاملة فتضيف مكونات أخرى مثل:

Official Documents
       │
       ▼
Document Processing
       │
       ▼
Embeddings
       │
       ▼
ChromaDB
       │
       ▼
RAG Retrieval
       │
       ▼
TashriAI-DZ
       │
       ▼
FastAPI
       │
       ▼
Next.js Arabic RTL Interface

وبالتالي يمكن تحديث قاعدة المعرفة القانونية دون الحاجة إلى إعادة تدريب النموذج في كل مرة.


🏗️ البنية التقنية

الطبقة التقنية
🧠 Language Model TashriAI-DZ
🦙 Local Inference Ollama
🔎 Retrieval RAG
🗄️ Vector Database ChromaDB
🧬 Embeddings Multilingual Embeddings
⚡ Backend FastAPI
🌐 Frontend Next.js
🇩🇿 Interface Arabic RTL
🐳 Deployment Docker / Docker Compose
🎓 Training Colab / Unsloth
📊 Evaluation Dedicated evaluation set

🔑 المبادئ الأساسية

1. 📚 المصدر أولًا

المعلومة القانونية يجب، قدر الإمكان، أن تأتي من النصوص والوثائق المرجعية وليس من ذاكرة النموذج وحدها.

2. 🧠 التدريب للأسلوب وليس لتخزين كل التشريع

يستخدم الـDataset لتعليم النموذج كيف يجيب، بينما يمكن توفير المعرفة المتغيرة من خلال RAG.

3. 🛡️ عدم اختلاق المراجع

لا ينبغي إنشاء رقم مادة أو قانون أو منشور دون وجود سند كافٍ.

4. 🤝 الصدق في عدم المعرفة

عندما لا توجد معلومات كافية، من الأفضل أن تكون الإجابة:

لا أستطيع تأكيد ذلك من النصوص المتاحة.

بدل إعطاء إجابة غير موثقة.

5. 🧾 المرجعية

عند توفر المصدر، يجب أن يكون من الممكن ربط الإجابة بالوثيقة أو المادة ذات الصلة.


🚀 تشغيل النموذج

بعد تثبيت Ollama:

ollama run nacerzouaizia/TashriAI-DZ

ثم ابدأ بطرح الأسئلة مباشرة.


📝 أمثلة بالعربية

ما هي صلاحيات مجلس التأديب في المؤسسة التربوية؟
ما هي النصوص التنظيمية المتعلقة بغيابات التلاميذ؟
ما هي حقوق التلميذ داخل المؤسسة التعليمية؟
ما هو المرجع القانوني المنظم لهذا الإجراء؟
إذا لم يوجد نص صريح حول هذه المسألة، أخبرني بذلك ولا تفترض مادة قانونية.

🇫🇷 Français

Pourquoi TashriAI DZ ?

Dans le secteur de l’éducation, l’information recherchée se trouve souvent dans une loi, un décret, un arrêté, une instruction ou une circulaire.

Le véritable défi n’est pas toujours l’existence de l’information, mais plutôt la capacité à retrouver rapidement le bon texte, comprendre son contexte et identifier sa référence.

C’est à partir de ce besoin qu’est né TashriAI DZ.

TashriAI DZ est un projet algérien d’intelligence artificielle consacré aux textes législatifs et réglementaires liés au système éducatif algérien.

L’objectif n’est pas de construire un modèle qui prétend tout savoir.

L’objectif est de développer un outil capable de :

  • 🔎 rechercher avant de répondre ;
  • 📚 s’appuyer sur les documents de référence ;
  • 🧾 préserver la traçabilité juridique ;
  • 🛡️ éviter d’inventer des articles ou des références ;
  • 🤝 reconnaître lorsqu’une information ne peut pas être confirmée.

Dans le domaine juridique, une réponse non vérifiée peut être plus problématique qu’une absence de réponse.


🎯 Cas d’utilisation

TashriAI DZ peut contribuer à :

  • rechercher des textes relatifs à la législation scolaire ;
  • analyser des lois et décrets ;
  • comprendre des circulaires administratives ;
  • rechercher une disposition réglementaire ;
  • traiter des documents juridiques longs ;
  • reformuler un texte réglementaire de manière plus accessible ;
  • travailler avec la terminologie administrative arabe et française.

🧠 Approche

Retrieval first. Generation second.

Dans l’architecture complète de TashriAI DZ, la connaissance juridique peut être fournie au modèle grâce à une couche RAG — Retrieval-Augmented Generation.

Documents officiels
        ↓
Traitement
        ↓
Embeddings
        ↓
ChromaDB
        ↓
Recherche RAG
        ↓
TashriAI-DZ
        ↓
FastAPI
        ↓
Interface Next.js

Cette architecture permet notamment de mettre à jour la base documentaire sans devoir réentraîner entièrement le modèle.


📝 Exemples en français

Quelles sont les attributions du conseil de discipline ?
Quels textes réglementent les absences des élèves ?
Quelle est la référence juridique de cette disposition ?
Explique-moi cette disposition réglementaire en termes simples.
Si aucun texte disponible ne permet de confirmer la réponse, indique-le clairement.

🇬🇧 English

About the project

TashriAI DZ is an Algerian AI project focused on legislative and regulatory texts related to the national education system.

The project explores how language models and retrieval systems can make official educational regulations easier to search, retrieve, understand and reference.

The goal is not to create a model that claims to know everything.

Instead, TashriAI DZ is designed around a simple principle:

Retrieve first. Generate second.

When used with the complete RAG pipeline, relevant passages can be retrieved from a document database before an answer is generated.


Key principles

  • 📚 Source-first approach
  • 🔎 Retrieval-Augmented Generation
  • 🧾 Source traceability
  • 🛡️ Reduced unsupported legal references
  • 🤝 Explicit uncertainty when evidence is insufficient
  • 🇩🇿 Focus on Algerian educational legislation
  • 🌍 Arabic and French-oriented use cases
  • 💻 Local execution through Ollama

📊 Model Card

Attribute Value
Model TashriAI-DZ
Ollama ID nacerzouaizia/TashriAI-DZ
Base Model Qwen2.5 7B Instruct
Size 2.0 GB
Context Window 128K
Input Text
Main Language Arabic
Additional Language French
Domain Algerian Educational Legislation
Runtime Ollama

📚 Document Scope

The broader TashriAI project is designed to work with sources such as:

  • Algerian educational laws
  • Executive decrees
  • Ministerial decisions
  • Ministerial instructions
  • Administrative circulars
  • Official educational regulations

The long-term objective is to gradually expand the verified document corpus.


🧪 Evaluation

Model evaluation is an important part of the project.

The current project includes a dedicated evaluation set covering questions related to topics such as:

  • disciplinary procedures;
  • student rights;
  • administrative organization;
  • legal principles;
  • unavailable information;
  • out-of-scope questions.

The evaluation process is intended to measure not only whether an answer sounds correct, but also whether it is:

  • supported by the available source;
  • appropriately referenced;
  • relevant to the question;
  • explicit about uncertainty;
  • free from unsupported legal citations.

Future versions will publish more quantitative evaluation results.


🛡️ Limitations

TashriAI DZ is an experimental and evolving project.

Important limitations include:

  • AI-generated answers can contain errors.
  • The standalone model should not be considered a complete legal database.
  • The quality of a RAG-based answer depends on the quality and coverage of the indexed documents.
  • Some laws or regulations may be missing, outdated or superseded.
  • A retrieved passage can still require legal or administrative interpretation.

For important administrative or legal decisions, always verify the answer against the official source currently in force.


⚖️ Disclaimer

TashriAI DZ is intended for:

  • research;
  • education;
  • experimentation;
  • information retrieval;
  • AI-assisted document exploration.

It does not replace official legal publications, competent administrations, or professional legal advice.


💻 Developer Integration

CLI

ollama run nacerzouaizia/TashriAI-DZ

cURL

curl http://localhost:11434/api/chat \
  -d '{
    "model": "nacerzouaizia/TashriAI-DZ",
    "messages": [
      {
        "role": "user",
        "content": "ما هي صلاحيات مجلس التأديب؟"
      }
    ]
  }'

Python

from ollama import chat

response = chat(
    model="nacerzouaizia/TashriAI-DZ",
    messages=[
        {
            "role": "user",
            "content": "ما هي صلاحيات مجلس التأديب؟"
        }
    ],
)

print(response.message.content)

JavaScript

import ollama from "ollama";

const response = await ollama.chat({
  model: "nacerzouaizia/TashriAI-DZ",
  messages: [
    {
      role: "user",
      content: "ما هي صلاحيات مجلس التأديب؟"
    }
  ]
});

console.log(response.message.content);

🗺️ Roadmap

TashriAI DZ is still evolving.

Planned improvements include:

  • 📚 expanding the corpus of official documents;
  • 🔎 improving retrieval quality;
  • 🧠 adding stronger multilingual embeddings;
  • 🎯 introducing reranking;
  • 🧾 improving legal citation extraction;
  • 📊 extending the evaluation benchmark;
  • 🇫🇷 improving French-language capabilities;
  • 🇩🇿 improving Algerian administrative terminology;
  • 🖥️ improving the Arabic RTL interface;
  • 🗃️ creating easier document-ingestion tools.

🤝 Contributing

TashriAI DZ is also a learning and research project.

Feedback is welcome from:

  • educators;
  • school administrators;
  • researchers;
  • developers;
  • legal professionals;
  • AI enthusiasts.

If you find an incorrect answer, a missing legal source, an issue with retrieval, or have an idea for improving the project, your feedback is welcome.


👨‍💻 Developer

Nacer Zouaizia

Ollama:

nacerzouaizia/TashriAI-DZ

🇩🇿 رؤية المشروع

لا أهدف من خلال TashriAI DZ إلى استبدال الإنسان أو النص القانوني الرسمي.

الهدف أبسط من ذلك:

استخدام الذكاء الاصطناعي لتقريب المعلومة، تسريع الوصول إليها، وجعل التعامل مع التشريع المدرسي أكثر سهولة ووضوحًا.

المشروع لا يزال يتطور، وكل نسخة هي خطوة نحو نظام أكثر دقة، أكثر شفافية وأكثر ارتباطًا بالمصدر.

معًا من أجل توظيف أفضل للذكاء الاصطناعي في خدمة التربية والمعرفة في الجزائر. 🇩🇿


Thank you for your interest in TashriAI DZ.

Merci pour votre intérêt pour TashriAI DZ.

شكرًا لاهتمامكم بمشروع TashriAI DZ.