Subjects per grade (math, calculus, geometry, stats, discrete), 5 new textbooks, 202 new islands, long islands split, hand-written figures and lesson texts for the new books

- content.Subject + Unit.subject, /api/home?subject=, tutor grounded in the chosen book
- 5 new books ingested; ~1150 hand-written questions, islands named by hand
- node_split: islands over 7 lessons split into parts of <=6 (lesson ids and progress kept)
- Lesson.figures hand-authored and visually checked for 653 lessons of the new books;
  gen_lesson_figures got --subject and survives network errors
- seed files re-exported

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-10-12 05:35:18 +03:30
parent 3d51b3b83a
commit 8cb1ecb85e
32 changed files with 81218 additions and 4486 deletions

View File

@@ -1,7 +1,7 @@
from django.db.models.signals import post_delete, post_save
from django.dispatch import receiver
from .models import Grade, Lesson, Node, Question, Unit, UserAnswer, UserLessonCompletion
from .models import Grade, Lesson, Node, Question, Subject, Unit, UserAnswer, UserLessonCompletion
from .services import touch_node_progress_on_answer, update_node_progress_on_lesson_completion
@@ -25,6 +25,8 @@ def _on_lesson_completion_created(sender, instance, created, raw=False, **kwargs
# می‌رود و همه‌ی کلیدهای content:grades / content:tree را یک‌جا باطل می‌کند.
@receiver(post_save, sender=Grade, dispatch_uid='content_bump_curriculum_grade_save')
@receiver(post_delete, sender=Grade, dispatch_uid='content_bump_curriculum_grade_delete')
@receiver(post_save, sender=Subject, dispatch_uid='content_bump_curriculum_subject_save')
@receiver(post_delete, sender=Subject, dispatch_uid='content_bump_curriculum_subject_delete')
@receiver(post_save, sender=Unit, dispatch_uid='content_bump_curriculum_unit_save')
@receiver(post_delete, sender=Unit, dispatch_uid='content_bump_curriculum_unit_delete')
@receiver(post_save, sender=Node, dispatch_uid='content_bump_curriculum_node_save')