def generate_flashcards(text): """تحويل المحتوى إلى كروت دراسية""" sentences = text.split('. ') flashcards = [{"السؤال": f"ما هو معنى: {sent.strip()}؟", "الإجابة": sent.strip()} for sent in sentences if len(sent) > 10] return flashcards