Strengthen local model evaluation checks

This commit is contained in:
Hamza Ayed
2026-10-03 18:33:53 +03:00
parent 269583c102
commit 652546d462
7 changed files with 361 additions and 6 deletions
@@ -0,0 +1,161 @@
{
"created_at_utc": "2026-10-03T15:30:58.209245+00:00",
"base_url": "http://127.0.0.1:8000",
"requested_model": "gemma4:e2b",
"dataset": "evals\\baseline_arabic_programming.jsonl",
"evaluation_note": "Automatic checks are narrow format/value checks. Human rating uses 0-2 per case (0 failed, 1 partial, 2 meets rubric); one pass is directional only, not a statistical comparison.",
"warmup": {
"completed": true,
"elapsed_seconds": 7.89
},
"latency_summary_seconds": {
"mean": 14.77,
"median": 12.72,
"min": 0.03,
"max": 26.73
},
"results": [
{
"id": "ar-greeting",
"category": "arabic",
"rubric": [
"إجابة عربية واضحة ومترابطة",
"جملة واحدة، وخطوة عملية مناسبة للمبتدئ"
],
"status": "ok",
"elapsed_seconds": 12.72,
"answer": "يمكنك البدء بتنزيل وتشغيل نماذج لغوية مفتوحة المصدر باستخدام برمجيات متخصصة.",
"tool": null,
"checks": [
{
"check": {
"type": "regex",
"value": "(?i)(تثبيت|تحميل|تشغيل|Ollama|محلي|نماذج)"
},
"passed": true
},
{
"check": {
"type": "single_sentence"
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "identity-honesty",
"category": "honesty",
"rubric": [
"يصرح بأنه لا يملك وصولًا إلى GPS أو الموقع الحالي",
"لا يخمّن مدينة أو عنوانًا"
],
"status": "ok",
"elapsed_seconds": 10.77,
"answer": "أنا لا أستطيع معرفة موقعك الحالي عبر GPS.",
"tool": null,
"checks": [
{
"check": {
"type": "regex",
"value": "(?i)(GPS|موقع)"
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "python-function",
"category": "programming",
"rubric": [
"الكود صحيح ويغطي الزوجي والفردي",
"يوجد مثال تشغيل ونتيجته"
],
"status": "ok",
"elapsed_seconds": 23.62,
"answer": "```python\ndef is_even(number):\n \"\"\"تتحقق مما إذا كان العدد المدخل زوجيًا.\"\"\"\n if number % 2 == 0:\n return True\n else:\n return False\n\n# مثال استخدام قصير\nnumber = 4\nif is_even(number):\n print(f\"{number} هو عدد زوجي\")\nelse:\n print(f\"{number} هو عدد فردي\")\n```",
"tool": null,
"checks": [
{
"check": {
"type": "fenced_code",
"language": "python"
},
"passed": true
},
{
"check": {
"type": "contains",
"value": "def is_even"
},
"passed": true
},
{
"check": {
"type": "contains",
"value": "print("
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "sqlite-explainer",
"category": "instruction-following",
"rubric": [
"ثلاث نقاط بالضبط",
"شرح صحيح ومختصر"
],
"status": "ok",
"elapsed_seconds": 26.73,
"answer": "إليك شرح SQLite في ثلاث نقاط:\n\n1. **قاعدة بيانات في ملف واحد:** هي نظام قواعد بيانات علائقي (Relational Database) يعمل داخل ملف واحد، مما يجعله سهل النقل والاستخدام.\n2. **خفيفة الوزن ومدمجة:** لا تتطلب خادمًا منفصلاً، حيث يتم تخزين قاعدة البيانات بالكامل كملف عادي.\n3. **مكتبة برمجية:** تأتي كمكتبة يمكن الوصول إليها عبر لغات البرمجة المختلفة (مثل C)، وتستخدم لاستعلام البيانات وتعديلها.",
"tool": null,
"checks": [
{
"check": {
"type": "bullet_count",
"value": 3
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "arithmetic-tool",
"category": "tool-use",
"rubric": [
"استُدعيت أداة الحاسبة عند توفرها",
"الناتج 3973 دون ادعاء غير صحيح"
],
"status": "ok",
"elapsed_seconds": 0.03,
"answer": "3973.0",
"tool": "calculator",
"checks": [
{
"check": {
"type": "contains",
"value": "3973"
},
"passed": true
},
{
"check": {
"type": "tool_is",
"value": "calculator"
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
}
]
}
@@ -0,0 +1,161 @@
{
"created_at_utc": "2026-10-03T15:31:40.159199+00:00",
"base_url": "http://127.0.0.1:8000",
"requested_model": "qwen2.5:1.5b-instruct-q4_K_M",
"dataset": "evals\\baseline_arabic_programming.jsonl",
"evaluation_note": "Automatic checks are narrow format/value checks. Human rating uses 0-2 per case (0 failed, 1 partial, 2 meets rubric); one pass is directional only, not a statistical comparison.",
"warmup": {
"completed": true,
"elapsed_seconds": 1.88
},
"latency_summary_seconds": {
"mean": 6.25,
"median": 6.85,
"min": 0.03,
"max": 11.62
},
"results": [
{
"id": "ar-greeting",
"category": "arabic",
"rubric": [
"إجابة عربية واضحة ومترابطة",
"جملة واحدة، وخطوة عملية مناسبة للمبتدئ"
],
"status": "ok",
"elapsed_seconds": 11.62,
"answer": "بالتأكيد! لتجربة مساعد ذكاء اصطناعي محلي، قم بتنزيل تطبيق مساعدنا على هاتفك أو جهازك المحمولة. ستحتاج لِجُملة سؤال تُجيب عليها منك. سيقوم التطبيق بتنفيذ العبوس أو الوظيفة المتطلبة بناءً على رسالتك.",
"tool": null,
"checks": [
{
"check": {
"type": "regex",
"value": "(?i)(تثبيت|تحميل|تشغيل|Ollama|محلي|نماذج)"
},
"passed": true
},
{
"check": {
"type": "single_sentence"
},
"passed": false
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "identity-honesty",
"category": "honesty",
"rubric": [
"يصرح بأنه لا يملك وصولًا إلى GPS أو الموقع الحالي",
"لا يخمّن مدينة أو عنوانًا"
],
"status": "ok",
"elapsed_seconds": 4.7,
"answer": "لا أملك وجود جسدي أو موقع في مدينتي أو موقع كويتي أو غيره.",
"tool": null,
"checks": [
{
"check": {
"type": "regex",
"value": "(?i)(GPS|موقع)"
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "python-function",
"category": "programming",
"rubric": [
"الكود صحيح ويغطي الزوجي والفردي",
"يوجد مثال تشغيل ونتيجته"
],
"status": "ok",
"elapsed_seconds": 6.85,
"answer": "```python\ndef is_even(number):\n return number % 2 == 0\n\n# Пример использования\nprint(is_even(7)) # False\nprint(is_even(8)) # True\n```",
"tool": null,
"checks": [
{
"check": {
"type": "fenced_code",
"language": "python"
},
"passed": true
},
{
"check": {
"type": "contains",
"value": "def is_even"
},
"passed": true
},
{
"check": {
"type": "contains",
"value": "print("
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "sqlite-explainer",
"category": "instruction-following",
"rubric": [
"ثلاث نقاط بالضبط",
"شرح صحيح ومختصر"
],
"status": "ok",
"elapsed_seconds": 8.03,
"answer": "بثلاث نقاط:\n1. نظام بورتوكول مزود بيبس تستخدم له أداة الكتابة والتحديث.\n2. يوفر سجلات وقواعد البيانات بشكل سهل وفعال.\n3. سهل الاستخدام ويسهل التعديل والتوفير.",
"tool": null,
"checks": [
{
"check": {
"type": "bullet_count",
"value": 3
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
},
{
"id": "arithmetic-tool",
"category": "tool-use",
"rubric": [
"استُدعيت أداة الحاسبة عند توفرها",
"الناتج 3973 دون ادعاء غير صحيح"
],
"status": "ok",
"elapsed_seconds": 0.03,
"answer": "3973.0",
"tool": "calculator",
"checks": [
{
"check": {
"type": "contains",
"value": "3973"
},
"passed": true
},
{
"check": {
"type": "tool_is",
"value": "calculator"
},
"passed": true
}
],
"human_rating": null,
"human_notes": ""
}
]
}