Seed: grade 7 rebuilt (every lesson 5+ questions computed in code), lost-exponent questions fixed

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-17 01:47:11 +03:30
parent 9eae99340d
commit f8a93a37c9
5 changed files with 23172 additions and 214 deletions

View File

@@ -300,7 +300,7 @@ has been done before.
### Content
- `content/seed/` is the whole curriculum and question bank as committed JSON: 10 grades (3–12), 5 subjects,
89 units, 1,145 islands, 5,406 lessons (every one has at least one question), 22,602 questions. `deploy.sh` runs `seed_content` on every release.
89 units, 1,145 islands, 5,406 lessons (every one has at least one question), 23,964 questions. `deploy.sh` runs `seed_content` on every release.
- `seed_content` is idempotent, never deletes, and does not undo admin work: the `SeedRecord` ledger remembers
what it delivered, so anything the admin deleted or renamed is not recreated; lesson text, `example`,
`steps` and `figures` are only filled when empty. Questions bind to lessons **by title path**

View File

@@ -13,7 +13,7 @@
| **سرویسِ زنده** | `https://mathapi.tadrisino2.ir` · اپ: `https://math.tadrisino2.ir` |
| **فناوری** | Python 3.11 · Django 5.2 · Django REST Framework · PostgreSQL 14 · Redis · Qdrant · gunicorn پشتِ nginx و ArvanCloud |
| **API** | ۶۱ عملیات روی ۵۹ مسیر، مستند با OpenAPI (`/api/docs/`) |
| **محتوا** | ۱۰ پایه · ۵ کتاب · ۸۹ فصل · ۱٬۱۴۵ جزیره · ۵٬۴۰۶ درس · ۲۲٬۶۰۲ سوال |
| **محتوا** | ۱۰ پایه · ۵ کتاب · ۸۹ فصل · ۱٬۱۴۵ جزیره · ۵٬۴۰۶ درس · ۲۳٬۹۶۴ سوال |
| **تست** | ۹۷۳ تستِ خودکار، همه سبز |
| **سرویس‌های بیرونی** | GapGPT (مدلِ زبانی) · Qdrant (جستجوی کتاب) · کاوه‌نگار (پیامک) · زرین‌پال و کافه‌بازار (پرداخت) |

View File

@@ -67170,71 +67170,7 @@
"برای پیدا کردن عدد بعدی، به آخرین عدد دنباله (۱۲) ۳ را اضافه می‌کنیم: ۱۲ + ۳ = ۱۵.",
"✅ جواب: ۱۵"
],
"figures": [
{
"where": "example",
"diagram": {
"kind": "plane",
"title": "۳n",
"axes": true,
"points": {},
"items": [
{
"type": "function",
"expr": "3*x",
"from": 0.0,
"to": 5.5,
"color": "gray",
"dashed": true
},
{
"type": "point",
"point": [
1.0,
3.0
]
},
{
"type": "point",
"point": [
2.0,
6.0
]
},
{
"type": "point",
"point": [
3.0,
9.0
]
},
{
"type": "point",
"point": [
4.0,
12.0
]
},
{
"type": "point",
"point": [
5.0,
15.0
]
}
],
"grid": true,
"xRange": [
0.0,
6.0
],
"yRange": [
0.0,
18.0
]
}
}
]
"figures": []
},
{
"title": "تشخیص الگوهای هندسی",
@@ -67276,45 +67212,7 @@
"محاسبه می‌کنیم: x = ۵",
"✅ جواب: ۵"
],
"figures": [
{
"where": "example",
"diagram": {
"kind": "plane",
"title": "۵x − ۷ = ۱۸",
"axes": true,
"points": {},
"items": [
{
"type": "function",
"expr": "5*x-7",
"from": 1.0,
"to": 9.0,
"color": "blue"
},
{
"type": "hline",
"y": 18.0,
"color": "red",
"dashed": true,
"label": "y = ۱۸"
},
{
"type": "point",
"point": [
5.0,
18.0
]
}
],
"grid": true,
"yRange": [
-5.0,
41.0
]
}
}
]
"figures": []
},
{
"title": "حذف حالت‌های نامطلوب",
@@ -68068,44 +67966,7 @@
"۱۰ ÷ ۲.",
"✅ جواب: ۵ پرش"
],
"figures": [
{
"where": "example",
"diagram": {
"kind": "plane",
"title": "پرش قورباغه",
"axes": false,
"points": {},
"items": [
{
"type": "text",
"at": [
1.0,
8.0
],
"text": "ارتفاع دیوار: ۱۰ متر"
},
{
"type": "text",
"at": [
1.0,
6.0
],
"text": "ارتفاع هر پرش: ۲ متر"
},
{
"type": "text",
"at": [
1.0,
4.0
],
"text": "تعداد پرش‌ها: ۵"
}
],
"grid": false
}
}
]
"figures": []
},
{
"title": "کاهش مقدار عددی",
@@ -68268,64 +68129,7 @@
"بنابراین اعداد بعدی به ترتیب عبارتند از: -۳، -۶، -۹.",
"✅ جواب: −۳ ، −۶ ، −۹"
],
"figures": [
{
"where": "example",
"diagram": {
"kind": "plane",
"title": "۱۲ − ۳n",
"axes": true,
"points": {},
"items": [
{
"type": "function",
"expr": "12-3*x",
"from": 0.0,
"to": 4.5,
"color": "gray",
"dashed": true
},
{
"type": "point",
"point": [
1.0,
9.0
]
},
{
"type": "point",
"point": [
2.0,
6.0
]
},
{
"type": "point",
"point": [
3.0,
3.0
]
},
{
"type": "point",
"point": [
4.0,
0.0
]
}
],
"grid": true,
"xRange": [
0.0,
5.0
],
"yRange": [
0.0,
12.0
]
}
}
]
"figures": []
},
{
"title": "تبدیل تفریق به جمع",

File diff suppressed because it is too large Load Diff

View File

@@ -11,7 +11,7 @@
| فایل | محتوا |
|---|---|
| `curriculum.json` | ۱۰ پایه (سوم تا دوازدهم)، ۵ کتاب، ۸۹ فصل، ۱٬۱۴۵ جزیره، ۵٬۴۰۶ درس؛ با `subject`، متنِ درس، مثال، قدم‌ها و شکلِ درس (`figures`) |
| `questions.json` | ۲۲٬۶۰۲ سوالِ چهارگزینه‌ای، بعضی با شکل (`figure`) |
| `questions.json` | ۲۳٬۹۶۴ سوالِ چهارگزینه‌ای، بعضی با شکل (`figure`) |
هر فصل باید `subject` داشته باشد (ریاضی، حسابان، هندسه، آمار و احتمال، گسسته)؛ فایلِ بی‌آن رد می‌شود. شکل‌ها
(`Lesson.figures`، `Question.figure`) با `rag.services.diagram.validate` در ورود اعتبارسنجی می‌شوند و شکلِ نامعتبر کلِ