UbumuntuAPI / api /data /exercises.py
Macbook
Add comprehensive exercises with categories, images, and French translations
f9b1f70
"""
Comprehensive Speech Therapy Exercises Database
Categories: Fundamentals, Speech Practice, Visual Learning, Sound Imitation
Languages: English (en), French (fr)
"""
from typing import List, Dict, Optional
from pydantic import BaseModel
from enum import Enum
class ExerciseType(str, Enum):
# Fundamentals
BREATHING = "breathing"
ARTICULATION = "articulation"
PHONEME = "phoneme"
# Speech Practice
WORD_REPETITION = "word_repetition"
SENTENCE_READING = "sentence_reading"
TONGUE_TWISTER = "tongue_twister"
# Visual Learning
COLOR = "color"
OBJECT = "object"
ANIMAL = "animal"
ACTION = "action"
# Sound Imitation
ANIMAL_SOUND = "animal_sound"
ENVIRONMENTAL_SOUND = "environmental_sound"
class Difficulty(str, Enum):
EASY = "easy"
MEDIUM = "medium"
HARD = "hard"
class Category(BaseModel):
id: str
name: Dict[str, str] # {"en": "...", "fr": "..."}
description: Dict[str, str]
icon: str
subcategories: List[str]
class Exercise(BaseModel):
id: str
type: ExerciseType
category: str
subcategory: str
difficulty: Difficulty
title: Dict[str, str]
target_text: Dict[str, str]
instructions: Dict[str, str]
image_url: Optional[str] = None
audio_url: Optional[str] = None
phoneme_focus: Optional[List[str]] = None
# =============================================================================
# CATEGORIES
# =============================================================================
CATEGORIES: List[Dict] = [
{
"id": "fundamentals",
"name": {"en": "Fundamentals", "fr": "Fondamentaux"},
"description": {
"en": "Build your foundation with breathing and articulation exercises",
"fr": "Construisez votre base avec des exercices de respiration et d'articulation"
},
"icon": "🎯",
"subcategories": ["breathing", "articulation", "phoneme"]
},
{
"id": "speech_practice",
"name": {"en": "Speech Practice", "fr": "Pratique de la Parole"},
"description": {
"en": "Practice words, sentences, and tongue twisters",
"fr": "Pratiquez des mots, des phrases et des virelangues"
},
"icon": "📖",
"subcategories": ["word_repetition", "sentence_reading", "tongue_twister"]
},
{
"id": "visual_learning",
"name": {"en": "Visual Learning", "fr": "Apprentissage Visuel"},
"description": {
"en": "Learn by identifying colors, objects, animals, and actions",
"fr": "Apprenez en identifiant les couleurs, objets, animaux et actions"
},
"icon": "🖼️",
"subcategories": ["color", "object", "animal", "action"]
},
{
"id": "sound_imitation",
"name": {"en": "Sound Imitation", "fr": "Imitation de Sons"},
"description": {
"en": "Imitate animal and environmental sounds",
"fr": "Imitez les sons d'animaux et de l'environnement"
},
"icon": "🔊",
"subcategories": ["animal_sound", "environmental_sound"]
}
]
SUBCATEGORIES: Dict[str, Dict] = {
"breathing": {
"name": {"en": "Breathing Exercises", "fr": "Exercices de Respiration"},
"description": {"en": "Control your breath for better speech", "fr": "Contrôlez votre respiration pour mieux parler"}
},
"articulation": {
"name": {"en": "Articulation Drills", "fr": "Exercices d'Articulation"},
"description": {"en": "Improve mouth and tongue movements", "fr": "Améliorez les mouvements de la bouche et de la langue"}
},
"phoneme": {
"name": {"en": "Phoneme Practice", "fr": "Pratique des Phonèmes"},
"description": {"en": "Master specific sounds like R, S, TH", "fr": "Maîtrisez des sons spécifiques comme R, S, CH"}
},
"word_repetition": {
"name": {"en": "Word Repetition", "fr": "Répétition de Mots"},
"description": {"en": "Repeat words clearly", "fr": "Répétez les mots clairement"}
},
"sentence_reading": {
"name": {"en": "Sentence Reading", "fr": "Lecture de Phrases"},
"description": {"en": "Read complete sentences", "fr": "Lisez des phrases complètes"}
},
"tongue_twister": {
"name": {"en": "Tongue Twisters", "fr": "Virelangues"},
"description": {"en": "Challenge yourself with tricky phrases", "fr": "Défiez-vous avec des phrases difficiles"}
},
"color": {
"name": {"en": "Colors", "fr": "Couleurs"},
"description": {"en": "Identify and say color names", "fr": "Identifiez et dites les noms des couleurs"}
},
"object": {
"name": {"en": "Objects", "fr": "Objets"},
"description": {"en": "Name everyday objects", "fr": "Nommez des objets du quotidien"}
},
"animal": {
"name": {"en": "Animals", "fr": "Animaux"},
"description": {"en": "Identify animals by sight", "fr": "Identifiez les animaux à vue"}
},
"action": {
"name": {"en": "Actions", "fr": "Actions"},
"description": {"en": "Describe what people are doing", "fr": "Décrivez ce que font les gens"}
},
"animal_sound": {
"name": {"en": "Animal Sounds", "fr": "Sons d'Animaux"},
"description": {"en": "Imitate animal sounds", "fr": "Imitez les sons des animaux"}
},
"environmental_sound": {
"name": {"en": "Environmental Sounds", "fr": "Sons de l'Environnement"},
"description": {"en": "Imitate sounds around us", "fr": "Imitez les sons autour de nous"}
}
}
# =============================================================================
# EXERCISES DATABASE
# =============================================================================
EXERCISES: List[Dict] = [
# =========================================================================
# FUNDAMENTALS - Breathing
# =========================================================================
{
"id": "breath-001",
"type": "breathing",
"category": "fundamentals",
"subcategory": "breathing",
"difficulty": "easy",
"title": {"en": "Deep Belly Breathing", "fr": "Respiration Abdominale"},
"target_text": {"en": "Breathe in slowly through your nose, hold, breathe out through your mouth", "fr": "Inspirez lentement par le nez, retenez, expirez par la bouche"},
"instructions": {"en": "Place your hand on your belly. Breathe in for 4 seconds, hold for 2, breathe out for 4. Repeat 3 times.", "fr": "Placez votre main sur le ventre. Inspirez 4 secondes, retenez 2, expirez 4. Répétez 3 fois."},
},
{
"id": "breath-002",
"type": "breathing",
"category": "fundamentals",
"subcategory": "breathing",
"difficulty": "easy",
"title": {"en": "Candle Blow", "fr": "Souffler la Bougie"},
"target_text": {"en": "Take a deep breath and blow out slowly like blowing a candle", "fr": "Prenez une grande inspiration et soufflez doucement comme une bougie"},
"instructions": {"en": "Imagine a candle in front of you. Take a deep breath and blow slowly to make the flame flicker but not go out.", "fr": "Imaginez une bougie devant vous. Inspirez et soufflez doucement pour faire vaciller la flamme sans l'éteindre."},
},
{
"id": "breath-003",
"type": "breathing",
"category": "fundamentals",
"subcategory": "breathing",
"difficulty": "medium",
"title": {"en": "Sustained Breath", "fr": "Souffle Prolongé"},
"target_text": {"en": "Aaaaaaaaahhhhhh", "fr": "Aaaaaaaaahhhhhh"},
"instructions": {"en": "Take a deep breath and say 'Ahhh' for as long as you can. Try to reach 10 seconds!", "fr": "Inspirez profondément et dites 'Ahhh' aussi longtemps que possible. Essayez d'atteindre 10 secondes!"},
},
# =========================================================================
# FUNDAMENTALS - Articulation
# =========================================================================
{
"id": "artic-001",
"type": "articulation",
"category": "fundamentals",
"subcategory": "articulation",
"difficulty": "easy",
"title": {"en": "Lip Warm-up", "fr": "Échauffement des Lèvres"},
"target_text": {"en": "Ma ma ma, Pa pa pa, Ba ba ba", "fr": "Ma ma ma, Pa pa pa, Ba ba ba"},
"instructions": {"en": "Say each syllable clearly, focusing on your lip movements. Repeat 3 times.", "fr": "Prononcez chaque syllabe clairement en vous concentrant sur vos lèvres. Répétez 3 fois."},
},
{
"id": "artic-002",
"type": "articulation",
"category": "fundamentals",
"subcategory": "articulation",
"difficulty": "easy",
"title": {"en": "Tongue Stretch", "fr": "Étirement de la Langue"},
"target_text": {"en": "La la la, Ta ta ta, Da da da", "fr": "La la la, Ta ta ta, Da da da"},
"instructions": {"en": "Touch the roof of your mouth with your tongue for each syllable. Feel the movement!", "fr": "Touchez le palais avec votre langue pour chaque syllabe. Sentez le mouvement!"},
},
{
"id": "artic-003",
"type": "articulation",
"category": "fundamentals",
"subcategory": "articulation",
"difficulty": "medium",
"title": {"en": "Jaw Exercise", "fr": "Exercice de Mâchoire"},
"target_text": {"en": "Wa wa wa, Ya ya ya, Oo ee oo ee", "fr": "Oua oua oua, Ya ya ya, Ou i ou i"},
"instructions": {"en": "Open your mouth wide for each sound. Feel your jaw moving up and down.", "fr": "Ouvrez grand la bouche pour chaque son. Sentez votre mâchoire bouger."},
},
# =========================================================================
# FUNDAMENTALS - Phoneme Practice
# =========================================================================
{
"id": "phon-r-001",
"type": "phoneme",
"category": "fundamentals",
"subcategory": "phoneme",
"difficulty": "medium",
"title": {"en": "R Sound Practice", "fr": "Pratique du Son R"},
"target_text": {"en": "Run, red, rain, rabbit, river", "fr": "Rue, rouge, rire, rat, rivière"},
"instructions": {"en": "Focus on the 'R' sound at the beginning of each word. Let your tongue vibrate slightly.", "fr": "Concentrez-vous sur le son 'R' au début de chaque mot. Laissez votre langue vibrer légèrement."},
"phoneme_focus": ["R"]
},
{
"id": "phon-s-001",
"type": "phoneme",
"category": "fundamentals",
"subcategory": "phoneme",
"difficulty": "easy",
"title": {"en": "S Sound Practice", "fr": "Pratique du Son S"},
"target_text": {"en": "Sun, see, song, seven, smile", "fr": "Sol, sac, sept, soir, sourire"},
"instructions": {"en": "Make a hissing sound like a snake. Keep your tongue behind your teeth.", "fr": "Faites un son sifflant comme un serpent. Gardez la langue derrière les dents."},
"phoneme_focus": ["S"]
},
{
"id": "phon-th-001",
"type": "phoneme",
"category": "fundamentals",
"subcategory": "phoneme",
"difficulty": "hard",
"title": {"en": "TH Sound Practice", "fr": "Pratique du Son TH"},
"target_text": {"en": "Think, this, that, three, thank", "fr": "Think, this, that, three, thank"},
"instructions": {"en": "Put your tongue between your teeth and blow air. This sound doesn't exist in French!", "fr": "Mettez la langue entre les dents et soufflez. Ce son n'existe pas en français!"},
"phoneme_focus": ["TH"]
},
{
"id": "phon-l-001",
"type": "phoneme",
"category": "fundamentals",
"subcategory": "phoneme",
"difficulty": "easy",
"title": {"en": "L Sound Practice", "fr": "Pratique du Son L"},
"target_text": {"en": "Love, light, look, lion, lake", "fr": "Lune, livre, lac, lion, lait"},
"instructions": {"en": "Touch the roof of your mouth with the tip of your tongue.", "fr": "Touchez le palais avec le bout de la langue."},
"phoneme_focus": ["L"]
},
{
"id": "phon-ch-001",
"type": "phoneme",
"category": "fundamentals",
"subcategory": "phoneme",
"difficulty": "medium",
"title": {"en": "CH Sound Practice", "fr": "Pratique du Son CH"},
"target_text": {"en": "Chair, cheese, chicken, chocolate, church", "fr": "Chat, chien, chose, chou, chaud"},
"instructions": {"en": "Push air through your teeth with rounded lips.", "fr": "Poussez l'air entre vos dents avec les lèvres arrondies."},
"phoneme_focus": ["CH", "SH"]
},
# =========================================================================
# SPEECH PRACTICE - Word Repetition
# =========================================================================
{
"id": "word-001",
"type": "word_repetition",
"category": "speech_practice",
"subcategory": "word_repetition",
"difficulty": "easy",
"title": {"en": "Greetings", "fr": "Salutations"},
"target_text": {"en": "Hello, Goodbye, Please, Thank you", "fr": "Bonjour, Au revoir, S'il vous plaît, Merci"},
"instructions": {"en": "Say each word clearly with a pause between them.", "fr": "Dites chaque mot clairement avec une pause entre eux."},
},
{
"id": "word-002",
"type": "word_repetition",
"category": "speech_practice",
"subcategory": "word_repetition",
"difficulty": "easy",
"title": {"en": "Numbers 1-10", "fr": "Chiffres 1-10"},
"target_text": {"en": "One, two, three, four, five, six, seven, eight, nine, ten", "fr": "Un, deux, trois, quatre, cinq, six, sept, huit, neuf, dix"},
"instructions": {"en": "Count clearly and steadily. Don't rush!", "fr": "Comptez clairement et régulièrement. Ne vous précipitez pas!"},
},
{
"id": "word-003",
"type": "word_repetition",
"category": "speech_practice",
"subcategory": "word_repetition",
"difficulty": "medium",
"title": {"en": "Days of the Week", "fr": "Jours de la Semaine"},
"target_text": {"en": "Monday, Tuesday, Wednesday, Thursday, Friday, Saturday, Sunday", "fr": "Lundi, Mardi, Mercredi, Jeudi, Vendredi, Samedi, Dimanche"},
"instructions": {"en": "Say each day with emphasis on the first syllable.", "fr": "Dites chaque jour en accentuant la première syllabe."},
},
# =========================================================================
# SPEECH PRACTICE - Sentence Reading
# =========================================================================
{
"id": "sent-001",
"type": "sentence_reading",
"category": "speech_practice",
"subcategory": "sentence_reading",
"difficulty": "easy",
"title": {"en": "Simple Introduction", "fr": "Introduction Simple"},
"target_text": {"en": "Hello, my name is... Nice to meet you!", "fr": "Bonjour, je m'appelle... Enchanté!"},
"instructions": {"en": "Replace '...' with your name. Speak clearly and smile!", "fr": "Remplacez '...' par votre nom. Parlez clairement et souriez!"},
},
{
"id": "sent-002",
"type": "sentence_reading",
"category": "speech_practice",
"subcategory": "sentence_reading",
"difficulty": "easy",
"title": {"en": "How Are You?", "fr": "Comment Allez-Vous?"},
"target_text": {"en": "How are you today? I am fine, thank you.", "fr": "Comment allez-vous aujourd'hui? Je vais bien, merci."},
"instructions": {"en": "Practice this common conversation with natural intonation.", "fr": "Pratiquez cette conversation courante avec une intonation naturelle."},
},
{
"id": "sent-003",
"type": "sentence_reading",
"category": "speech_practice",
"subcategory": "sentence_reading",
"difficulty": "medium",
"title": {"en": "Weather Talk", "fr": "Parler de la Météo"},
"target_text": {"en": "The weather is beautiful today. The sun is shining brightly.", "fr": "Il fait beau aujourd'hui. Le soleil brille."},
"instructions": {"en": "Read the sentences with expression. Sound happy about the weather!", "fr": "Lisez avec expression. Montrez que vous êtes content du temps!"},
},
{
"id": "sent-004",
"type": "sentence_reading",
"category": "speech_practice",
"subcategory": "sentence_reading",
"difficulty": "hard",
"title": {"en": "At the Restaurant", "fr": "Au Restaurant"},
"target_text": {"en": "I would like to order the fish, please. Could I also have some water?", "fr": "Je voudrais commander le poisson, s'il vous plaît. Puis-je aussi avoir de l'eau?"},
"instructions": {"en": "Practice polite restaurant phrases. Speak clearly to be understood.", "fr": "Pratiquez les phrases polies au restaurant. Parlez clairement pour être compris."},
},
# =========================================================================
# SPEECH PRACTICE - Tongue Twisters
# =========================================================================
{
"id": "twist-001",
"type": "tongue_twister",
"category": "speech_practice",
"subcategory": "tongue_twister",
"difficulty": "medium",
"title": {"en": "She Sells Seashells", "fr": "Les Chaussettes de l'Archiduchesse"},
"target_text": {"en": "She sells seashells by the seashore", "fr": "Les chaussettes de l'archiduchesse sont-elles sèches ou archi-sèches"},
"instructions": {"en": "Start slowly, then try to speed up while staying clear.", "fr": "Commencez lentement, puis essayez d'accélérer tout en restant clair."},
"phoneme_focus": ["S", "SH"]
},
{
"id": "twist-002",
"type": "tongue_twister",
"category": "speech_practice",
"subcategory": "tongue_twister",
"difficulty": "hard",
"title": {"en": "Peter Piper", "fr": "Un Chasseur"},
"target_text": {"en": "Peter Piper picked a peck of pickled peppers", "fr": "Un chasseur sachant chasser sait chasser sans son chien"},
"instructions": {"en": "Focus on the 'P' sounds. Keep your lips tight.", "fr": "Concentrez-vous sur les sons 'CH'. Gardez la langue stable."},
"phoneme_focus": ["P"]
},
{
"id": "twist-003",
"type": "tongue_twister",
"category": "speech_practice",
"subcategory": "tongue_twister",
"difficulty": "hard",
"title": {"en": "Red Lorry Yellow Lorry", "fr": "Trois Tortues"},
"target_text": {"en": "Red lorry, yellow lorry, red lorry, yellow lorry", "fr": "Trois tortues trottaient sur trois toits très étroits"},
"instructions": {"en": "Practice the R and L sounds alternating. This is challenging!", "fr": "Pratiquez les sons T et R en alternance. C'est un défi!"},
"phoneme_focus": ["R", "L"]
},
{
"id": "twist-004",
"type": "tongue_twister",
"category": "speech_practice",
"subcategory": "tongue_twister",
"difficulty": "medium",
"title": {"en": "Unique New York", "fr": "Panier Piano"},
"target_text": {"en": "Unique New York, you know you need unique New York", "fr": "Piano panier, panier piano"},
"instructions": {"en": "Focus on the 'N' and 'Y' sounds.", "fr": "Concentrez-vous sur les sons 'P' et 'N'."},
"phoneme_focus": ["N", "Y"]
},
# =========================================================================
# VISUAL LEARNING - Colors
# =========================================================================
{
"id": "color-001",
"type": "color",
"category": "visual_learning",
"subcategory": "color",
"difficulty": "easy",
"title": {"en": "Red", "fr": "Rouge"},
"target_text": {"en": "Red", "fr": "Rouge"},
"instructions": {"en": "Look at the color and say its name.", "fr": "Regardez la couleur et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1562157873-818bc0726f68?w=400&h=400&fit=crop"
},
{
"id": "color-002",
"type": "color",
"category": "visual_learning",
"subcategory": "color",
"difficulty": "easy",
"title": {"en": "Blue", "fr": "Bleu"},
"target_text": {"en": "Blue", "fr": "Bleu"},
"instructions": {"en": "Look at the color and say its name.", "fr": "Regardez la couleur et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1579546929518-9e396f3cc809?w=400&h=400&fit=crop"
},
{
"id": "color-003",
"type": "color",
"category": "visual_learning",
"subcategory": "color",
"difficulty": "easy",
"title": {"en": "Yellow", "fr": "Jaune"},
"target_text": {"en": "Yellow", "fr": "Jaune"},
"instructions": {"en": "Look at the color and say its name.", "fr": "Regardez la couleur et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1495001258031-d1b407bc1776?w=400&h=400&fit=crop"
},
{
"id": "color-004",
"type": "color",
"category": "visual_learning",
"subcategory": "color",
"difficulty": "easy",
"title": {"en": "Green", "fr": "Vert"},
"target_text": {"en": "Green", "fr": "Vert"},
"instructions": {"en": "Look at the color and say its name.", "fr": "Regardez la couleur et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1464820453369-31d2c0b651af?w=400&h=400&fit=crop"
},
{
"id": "color-005",
"type": "color",
"category": "visual_learning",
"subcategory": "color",
"difficulty": "easy",
"title": {"en": "Orange", "fr": "Orange"},
"target_text": {"en": "Orange", "fr": "Orange"},
"instructions": {"en": "Look at the color and say its name.", "fr": "Regardez la couleur et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1557800636-894a64c1696f?w=400&h=400&fit=crop"
},
{
"id": "color-006",
"type": "color",
"category": "visual_learning",
"subcategory": "color",
"difficulty": "easy",
"title": {"en": "Purple", "fr": "Violet"},
"target_text": {"en": "Purple", "fr": "Violet"},
"instructions": {"en": "Look at the color and say its name.", "fr": "Regardez la couleur et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1528459801416-a9e53bbf4e17?w=400&h=400&fit=crop"
},
# =========================================================================
# VISUAL LEARNING - Objects
# =========================================================================
{
"id": "obj-001",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "easy",
"title": {"en": "Apple", "fr": "Pomme"},
"target_text": {"en": "Apple", "fr": "Pomme"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1584306670957-acf935f5033c?w=400&h=400&fit=crop"
},
{
"id": "obj-002",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "easy",
"title": {"en": "Book", "fr": "Livre"},
"target_text": {"en": "Book", "fr": "Livre"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1544947950-fa07a98d237f?w=400&h=400&fit=crop"
},
{
"id": "obj-003",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "easy",
"title": {"en": "Car", "fr": "Voiture"},
"target_text": {"en": "Car", "fr": "Voiture"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1502877338535-766e1452684a?w=400&h=400&fit=crop"
},
{
"id": "obj-004",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "easy",
"title": {"en": "Chair", "fr": "Chaise"},
"target_text": {"en": "Chair", "fr": "Chaise"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1503602642458-232111445657?w=400&h=400&fit=crop"
},
{
"id": "obj-005",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "easy",
"title": {"en": "House", "fr": "Maison"},
"target_text": {"en": "House", "fr": "Maison"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1518780664697-55e3ad937233?w=400&h=400&fit=crop"
},
{
"id": "obj-006",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "medium",
"title": {"en": "Telephone", "fr": "Téléphone"},
"target_text": {"en": "Telephone", "fr": "Téléphone"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1511707171634-5f897ff02aa9?w=400&h=400&fit=crop"
},
{
"id": "obj-007",
"type": "object",
"category": "visual_learning",
"subcategory": "object",
"difficulty": "medium",
"title": {"en": "Umbrella", "fr": "Parapluie"},
"target_text": {"en": "Umbrella", "fr": "Parapluie"},
"instructions": {"en": "Look at the picture and say what you see.", "fr": "Regardez l'image et dites ce que vous voyez."},
"image_url": "https://images.unsplash.com/photo-1534309466160-70b22cc6252c?w=400&h=400&fit=crop"
},
# =========================================================================
# VISUAL LEARNING - Animals
# =========================================================================
{
"id": "animal-001",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "easy",
"title": {"en": "Dog", "fr": "Chien"},
"target_text": {"en": "Dog", "fr": "Chien"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1587300003388-59208cc962cb?w=400&h=400&fit=crop"
},
{
"id": "animal-002",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "easy",
"title": {"en": "Cat", "fr": "Chat"},
"target_text": {"en": "Cat", "fr": "Chat"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1514888286974-6c03e2ca1dba?w=400&h=400&fit=crop"
},
{
"id": "animal-003",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "easy",
"title": {"en": "Bird", "fr": "Oiseau"},
"target_text": {"en": "Bird", "fr": "Oiseau"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1522926193341-e9ffd686c60f?w=400&h=400&fit=crop"
},
{
"id": "animal-004",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "easy",
"title": {"en": "Fish", "fr": "Poisson"},
"target_text": {"en": "Fish", "fr": "Poisson"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1524704654690-b56c05c78a00?w=400&h=400&fit=crop"
},
{
"id": "animal-005",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "medium",
"title": {"en": "Elephant", "fr": "Éléphant"},
"target_text": {"en": "Elephant", "fr": "Éléphant"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1557050543-4d5f4e07ef46?w=400&h=400&fit=crop"
},
{
"id": "animal-006",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "medium",
"title": {"en": "Lion", "fr": "Lion"},
"target_text": {"en": "Lion", "fr": "Lion"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1546182990-dffeafbe841d?w=400&h=400&fit=crop"
},
{
"id": "animal-007",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "medium",
"title": {"en": "Butterfly", "fr": "Papillon"},
"target_text": {"en": "Butterfly", "fr": "Papillon"},
"instructions": {"en": "Look at the animal and say its name.", "fr": "Regardez l'animal et dites son nom."},
"image_url": "https://images.unsplash.com/photo-1452570053594-1b985d6ea890?w=400&h=400&fit=crop"
},
{
"id": "animal-008",
"type": "animal",
"category": "visual_learning",
"subcategory": "animal",
"difficulty": "hard",
"title": {"en": "Hippopotamus", "fr": "Hippopotame"},
"target_text": {"en": "Hippopotamus", "fr": "Hippopotame"},
"instructions": {"en": "Look at the animal and say its name. This is a long word!", "fr": "Regardez l'animal et dites son nom. C'est un mot long!"},
"image_url": "https://images.unsplash.com/photo-1517840933437-c41356892b35?w=400&h=400&fit=crop"
},
# =========================================================================
# VISUAL LEARNING - Actions
# =========================================================================
{
"id": "action-001",
"type": "action",
"category": "visual_learning",
"subcategory": "action",
"difficulty": "easy",
"title": {"en": "Running", "fr": "Courir"},
"target_text": {"en": "Running", "fr": "Courir"},
"instructions": {"en": "Look at the action and say what the person is doing.", "fr": "Regardez l'action et dites ce que fait la personne."},
"image_url": "https://images.unsplash.com/photo-1552674605-db6ffd4facb5?w=400&h=400&fit=crop"
},
{
"id": "action-002",
"type": "action",
"category": "visual_learning",
"subcategory": "action",
"difficulty": "easy",
"title": {"en": "Eating", "fr": "Manger"},
"target_text": {"en": "Eating", "fr": "Manger"},
"instructions": {"en": "Look at the action and say what the person is doing.", "fr": "Regardez l'action et dites ce que fait la personne."},
"image_url": "https://images.unsplash.com/photo-1504674900247-0877df9cc836?w=400&h=400&fit=crop"
},
{
"id": "action-003",
"type": "action",
"category": "visual_learning",
"subcategory": "action",
"difficulty": "easy",
"title": {"en": "Sleeping", "fr": "Dormir"},
"target_text": {"en": "Sleeping", "fr": "Dormir"},
"instructions": {"en": "Look at the action and say what the person is doing.", "fr": "Regardez l'action et dites ce que fait la personne."},
"image_url": "https://images.unsplash.com/photo-1541781774459-bb2af2f05b55?w=400&h=400&fit=crop"
},
{
"id": "action-004",
"type": "action",
"category": "visual_learning",
"subcategory": "action",
"difficulty": "easy",
"title": {"en": "Reading", "fr": "Lire"},
"target_text": {"en": "Reading", "fr": "Lire"},
"instructions": {"en": "Look at the action and say what the person is doing.", "fr": "Regardez l'action et dites ce que fait la personne."},
"image_url": "https://images.unsplash.com/photo-1506880018603-83d5b814b5a6?w=400&h=400&fit=crop"
},
{
"id": "action-005",
"type": "action",
"category": "visual_learning",
"subcategory": "action",
"difficulty": "medium",
"title": {"en": "Swimming", "fr": "Nager"},
"target_text": {"en": "Swimming", "fr": "Nager"},
"instructions": {"en": "Look at the action and say what the person is doing.", "fr": "Regardez l'action et dites ce que fait la personne."},
"image_url": "https://images.unsplash.com/photo-1530549387789-4c1017266635?w=400&h=400&fit=crop"
},
# =========================================================================
# SOUND IMITATION - Animal Sounds
# =========================================================================
{
"id": "asound-001",
"type": "animal_sound",
"category": "sound_imitation",
"subcategory": "animal_sound",
"difficulty": "easy",
"title": {"en": "Dog Sound", "fr": "Son du Chien"},
"target_text": {"en": "Woof woof", "fr": "Ouaf ouaf"},
"instructions": {"en": "Imitate the sound a dog makes!", "fr": "Imitez le son que fait un chien!"},
"image_url": "https://images.unsplash.com/photo-1587300003388-59208cc962cb?w=400&h=400&fit=crop"
},
{
"id": "asound-002",
"type": "animal_sound",
"category": "sound_imitation",
"subcategory": "animal_sound",
"difficulty": "easy",
"title": {"en": "Cat Sound", "fr": "Son du Chat"},
"target_text": {"en": "Meow meow", "fr": "Miaou miaou"},
"instructions": {"en": "Imitate the sound a cat makes!", "fr": "Imitez le son que fait un chat!"},
"image_url": "https://images.unsplash.com/photo-1514888286974-6c03e2ca1dba?w=400&h=400&fit=crop"
},
{
"id": "asound-003",
"type": "animal_sound",
"category": "sound_imitation",
"subcategory": "animal_sound",
"difficulty": "easy",
"title": {"en": "Cow Sound", "fr": "Son de la Vache"},
"target_text": {"en": "Moo moo", "fr": "Meuh meuh"},
"instructions": {"en": "Imitate the sound a cow makes!", "fr": "Imitez le son que fait une vache!"},
"image_url": "https://images.unsplash.com/photo-1570042225831-d98fa7577f1e?w=400&h=400&fit=crop"
},
{
"id": "asound-004",
"type": "animal_sound",
"category": "sound_imitation",
"subcategory": "animal_sound",
"difficulty": "easy",
"title": {"en": "Duck Sound", "fr": "Son du Canard"},
"target_text": {"en": "Quack quack", "fr": "Coin coin"},
"instructions": {"en": "Imitate the sound a duck makes!", "fr": "Imitez le son que fait un canard!"},
"image_url": "https://images.unsplash.com/photo-1459682687441-7761439a709d?w=400&h=400&fit=crop"
},
{
"id": "asound-005",
"type": "animal_sound",
"category": "sound_imitation",
"subcategory": "animal_sound",
"difficulty": "medium",
"title": {"en": "Lion Sound", "fr": "Son du Lion"},
"target_text": {"en": "Roar!", "fr": "Grrrr!"},
"instructions": {"en": "Imitate the sound a lion makes! Be loud!", "fr": "Imitez le son que fait un lion! Soyez fort!"},
"image_url": "https://images.unsplash.com/photo-1546182990-dffeafbe841d?w=400&h=400&fit=crop"
},
{
"id": "asound-006",
"type": "animal_sound",
"category": "sound_imitation",
"subcategory": "animal_sound",
"difficulty": "medium",
"title": {"en": "Snake Sound", "fr": "Son du Serpent"},
"target_text": {"en": "Sssssss", "fr": "Sssssss"},
"instructions": {"en": "Imitate the hissing sound a snake makes!", "fr": "Imitez le sifflement que fait un serpent!"},
"image_url": "https://images.unsplash.com/photo-1531386151447-fd76ad50012f?w=400&h=400&fit=crop"
},
# =========================================================================
# SOUND IMITATION - Environmental Sounds
# =========================================================================
{
"id": "esound-001",
"type": "environmental_sound",
"category": "sound_imitation",
"subcategory": "environmental_sound",
"difficulty": "easy",
"title": {"en": "Car Horn", "fr": "Klaxon"},
"target_text": {"en": "Beep beep", "fr": "Pouet pouet"},
"instructions": {"en": "Imitate the sound of a car horn!", "fr": "Imitez le son d'un klaxon!"},
"image_url": "https://images.unsplash.com/photo-1502877338535-766e1452684a?w=400&h=400&fit=crop"
},
{
"id": "esound-002",
"type": "environmental_sound",
"category": "sound_imitation",
"subcategory": "environmental_sound",
"difficulty": "easy",
"title": {"en": "Train Sound", "fr": "Son du Train"},
"target_text": {"en": "Choo choo", "fr": "Tchou tchou"},
"instructions": {"en": "Imitate the sound of a train!", "fr": "Imitez le son d'un train!"},
"image_url": "https://images.unsplash.com/photo-1474487548417-781cb71495f3?w=400&h=400&fit=crop"
},
{
"id": "esound-003",
"type": "environmental_sound",
"category": "sound_imitation",
"subcategory": "environmental_sound",
"difficulty": "easy",
"title": {"en": "Clock Sound", "fr": "Son de l'Horloge"},
"target_text": {"en": "Tick tock tick tock", "fr": "Tic tac tic tac"},
"instructions": {"en": "Imitate the sound of a clock!", "fr": "Imitez le son d'une horloge!"},
"image_url": "https://images.unsplash.com/photo-1563861826100-9cb868fdbe1c?w=400&h=400&fit=crop"
},
{
"id": "esound-004",
"type": "environmental_sound",
"category": "sound_imitation",
"subcategory": "environmental_sound",
"difficulty": "medium",
"title": {"en": "Rain Sound", "fr": "Son de la Pluie"},
"target_text": {"en": "Pitter patter pitter patter", "fr": "Plic ploc plic ploc"},
"instructions": {"en": "Imitate the sound of rain falling!", "fr": "Imitez le son de la pluie qui tombe!"},
"image_url": "https://images.unsplash.com/photo-1519692933481-e162a57d6721?w=400&h=400&fit=crop"
},
{
"id": "esound-005",
"type": "environmental_sound",
"category": "sound_imitation",
"subcategory": "environmental_sound",
"difficulty": "medium",
"title": {"en": "Wind Sound", "fr": "Son du Vent"},
"target_text": {"en": "Whoooosh", "fr": "Woooosh"},
"instructions": {"en": "Imitate the sound of strong wind!", "fr": "Imitez le son du vent fort!"},
"image_url": "https://images.unsplash.com/photo-1534088568595-a066f410bcda?w=400&h=400&fit=crop"
},
]
def get_all_categories() -> List[Dict]:
"""Return all exercise categories."""
return CATEGORIES
def get_subcategory_info(subcategory_id: str) -> Optional[Dict]:
"""Return information about a specific subcategory."""
return SUBCATEGORIES.get(subcategory_id)
def get_all_exercises(language: str = "en") -> List[Dict]:
"""Return all exercises in the specified language."""
exercises = []
for ex in EXERCISES:
exercises.append({
"id": ex["id"],
"type": ex["type"],
"category": ex["category"],
"subcategory": ex["subcategory"],
"difficulty": ex["difficulty"],
"title": ex["title"].get(language, ex["title"]["en"]),
"target_text": ex["target_text"].get(language, ex["target_text"]["en"]),
"instructions": ex["instructions"].get(language, ex["instructions"]["en"]),
"image_url": ex.get("image_url"),
"audio_url": ex.get("audio_url"),
"phoneme_focus": ex.get("phoneme_focus", [])
})
return exercises
def get_exercises_by_category(category: str, language: str = "en") -> List[Dict]:
"""Return exercises filtered by category."""
all_exercises = get_all_exercises(language)
return [ex for ex in all_exercises if ex["category"] == category]
def get_exercises_by_subcategory(subcategory: str, language: str = "en") -> List[Dict]:
"""Return exercises filtered by subcategory."""
all_exercises = get_all_exercises(language)
return [ex for ex in all_exercises if ex["subcategory"] == subcategory]
def get_exercises_by_difficulty(difficulty: str, language: str = "en") -> List[Dict]:
"""Return exercises filtered by difficulty."""
all_exercises = get_all_exercises(language)
return [ex for ex in all_exercises if ex["difficulty"] == difficulty]
def get_exercise_by_id(exercise_id: str, language: str = "en") -> Optional[Dict]:
"""Return a specific exercise by ID."""
all_exercises = get_all_exercises(language)
for ex in all_exercises:
if ex["id"] == exercise_id:
return ex
return None