(Your persona and teaching style are defined in the system instructions. Follow them.)

## Unit Context
This lesson is part of a larger unit:
- **Unit Title:** {unit_title}
- **Unit Overview:** {unit_overview}

## Lesson Parameters
- **Subject:** {subject}
- **Grade Level:** {grade_level}
- **Topic:** {topic}
- **Objective:** {objective}
- **Lesson Number:** {lesson_number} of {total_lessons}
- **Duration:** {duration_minutes} minutes

## Standards
{standards}

{few_shot_context}

{teacher_materials}

CRITICAL: Do NOT use XML tags, angle brackets, or pseudo-markup in your response.
Do NOT wrap content in tags like <teacher prompt>, <transition>, <script>, etc.
Write plain text only. The JSON values must contain clean, readable prose.

---

## Image Requirements — MANDATORY

### Per-field image_spec rules:
- **primary_sources**: `image_spec` is ALWAYS REQUIRED (non-empty). All subjects benefit from source images.
- **direct_instruction**: `image_spec` is ALWAYS REQUIRED (non-empty). Visual aids help every subject — math diagrams, ELA book covers, science illustrations, history paintings, etc.
- **vocabulary**: `image_spec` is RECOMMENDED but may be an empty string for abstract terms (e.g. "democracy", "irony").
- **exit_ticket**: `stimulus_image_spec` is OPTIONAL — use it when the stimulus is visual (map, diagram, photograph).

Every image_spec MUST be a specific image search query naming the exact person, event, artifact, organism, diagram type, or concept — NOT a generic topic.

### How to write a good image_spec:
1. **Be specific**: "diagram of water cycle showing evaporation condensation precipitation" NOT "water cycle"
2. **Include the format**: "photograph", "diagram", "map", "political cartoon", "painting", "chart", "portrait", "book cover"
3. **Include context for age-appropriateness**: "for 5th grade students" helps filter complexity
4. **Name people and dates**: "Thomas Nast Boss Tweed Tammany Hall political cartoon 1871" NOT "political cartoon"

GOOD image_spec examples:
- "Louis XIV portrait Palace of Versailles painting"
- "Thomas Nast Boss Tweed Tammany Hall political cartoon 1871"
- "photosynthesis light reactions diagram chloroplast for middle school"
- "Declaration of Independence historical document 1776 photograph"
- "quadratic equation graph parabola diagram"
- "To Kill a Mockingbird book cover Harper Lee"
- "fractions number line diagram for 4th grade"

BAD image_spec (BANNED):
- "" (empty string — NEVER leave this blank for primary sources or direct instruction)
- "🏛️" or any emoji/Unicode — these are NOT searchable images
- "image of a building" — too generic, will return irrelevant results
- "political cartoon" — must include the specific subject and artist if known
- "science diagram" — must name the specific process or concept

For political cartoons specifically:
- `content_text` MUST contain a detailed written description of what the cartoon depicts: the characters, symbols, captions, labels, and visual metaphors. A student who cannot see the image must understand the cartoon from the description alone.
- `image_spec` MUST contain the cartoonist's name, subject, and approximate year (e.g. "Benjamin Franklin Join or Die cartoon 1754").
- NEVER substitute emoji, Unicode art, or animated characters for a political cartoon. These are historical documents — describe them as such.

---

## Self-Contained Materials Rule

Every piece of content this lesson references MUST be included in full. The following phrases are BANNED:
- "teacher will provide"
- "refer to textbook"
- "see page X"
- "open your book to"
- "use the handout"
- "worksheet attached"
- "see attached"
- "distribute the provided"
- "refer to class notes"
- "as discussed in class"

If you reference a document, passage, data table, primary source, graphic organizer, or any other material, it MUST appear verbatim in the appropriate field. A teacher printing this lesson must never need to find or create anything separately.

---

## Stimulus-Based Assessment — MANDATORY FOR ALL SUBJECTS

NEVER write a bare recall question. Every question — Do Now, guided notes prompts, station questions, and all exit ticket items — must be anchored to a stimulus.

Choose stimulus types by subject:
- **Science:** diagram, data table, lab observation, photograph
- **Social Studies:** primary source, political cartoon, map, data visualization
- **Math:** word problem, graph, table, geometric figure
- **ELA:** text excerpt, author quote, literary device example
- **General / Cross-Curricular:** real-world scenario, infographic, news excerpt

NEVER write a bare recall question. "What is photosynthesis?" is banned. "The graph below shows oxygen production in a sealed chamber over 10 minutes. At what point does oxygen output peak, and what process is responsible?" is required.

---

## Pedagogical Requirements

### Do Now
- MUST be stimulus-based. Include the actual stimulus text/data/scenario in the `stimulus` field.
- NOT "What did we learn yesterday?" or any other recall opener.
- Students must be able to begin independently the moment they sit down.
- Low-stakes, accessible entry — designed to activate thinking, not test prior knowledge.

### Guided Notes
- Minimum 5 fill-in-the-blank entries. Aim for 8–12.
- Each entry has exactly ONE blank (shown as ________) for a key word or phrase.
- The `section_ref` field names the direct-instruction heading the note belongs to.
- Include the correct answer in the `answer` field.

### Primary Sources
- Minimum 2 per lesson, regardless of subject.
- Each primary source MUST include the FULL TEXT of the excerpt in `content_text`. This means:
  - For text excerpts: 3-8 complete sentences, directly quoted, with attribution (author, date, title).
  - For data tables: ALL rows and columns with real numbers, not placeholders.
  - For political cartoons: A detailed visual description (characters, symbols, captions, setting) so someone who can't see the image can understand it.
  - For diagrams/maps: A complete text description of what is shown, with labels.
  - NEVER write "See handout" or "Teacher will distribute" — the text MUST be self-contained.
  - NEVER write a summary of the source. Write the ACTUAL SOURCE TEXT.
  - A substitute teacher must be able to deliver this lesson using ONLY this document. If the source text isn't in the document, the lesson is incomplete.
- Attribution must identify author, date, and title/origin.
- Subject-appropriate source types: use "text_excerpt" for ELA/SS, "data_table" for science/math, "diagram" for science/math, "map" for geography/SS, "political_cartoon" for SS, "photograph" for SS/science.
- Each primary source must include at least 2 `scaffolding_questions` that build from identification to analysis.
- `image_spec` MUST name the specific source with artist/author, date, and archive/publication. Example: "Thomas Jefferson letter to John Holmes April 22 1820 Library of Congress" NOT "historical letter".

### Exit Ticket
- Exactly 3 `StimulusQuestion` items.
- Cognitive progression is REQUIRED: Question 1 = recall/identification, Question 2 = application, Question 3 = analysis or transfer.
- The `stimulus` field must be non-empty for every question — include the actual text, data, or scenario.
- `cognitive_level` must be set: "recall", "application", or "analysis".

### Differentiation (MANDATORY — every lesson MUST have all three)
- `struggling` (IEP/504 students): 3-4 SPECIFIC accommodations that a teacher can implement immediately.
  - Name the EXACT scaffold: "Provide a partially completed T-chart with 'Cause' and 'Effect' pre-labeled and two rows filled in as models"
  - Include modified assessments: "Exit ticket reduced to 2 questions instead of 3, with sentence starters provided"
  - Include chunking: "Break the jigsaw into two phases: reading phase (8 min) and sharing phase (5 min) with a timer displayed"
  - NEVER write generic accommodations like "provide extra time" or "provide extra support" — those are useless
- `advanced` (gifted/accelerated): 3-4 genuine extensions that deepen thinking, not repeat work.
  - "Identify an assumption the author makes and write a paragraph challenging it with counter-evidence"
  - "Research a modern parallel to this historical event and present a 2-minute argument to the class"
  - "Write a CRQ using a source you find independently — not one provided in the lesson"
  - NEVER write "write an additional paragraph" or "do extra problems" — that's punishment, not enrichment
- `ell` (English Language Learners): 3-4 concrete language supports.
  - Sentence frames for EVERY written response: "The author argues that ___ because ___"
  - Visual glossary with key terms, simple definitions, and icons/images
  - Bilingual word bank if applicable (Spanish cognates for Social Studies terms)
  - Simplified versions of primary source excerpts (shorter sentences, defined vocabulary)
  - NEVER just say "provide vocabulary support" — specify WHICH vocabulary and HOW

---

## Output Format

Respond with ONLY a JSON object (no markdown fencing):

{
    "title": "Lesson Title",
    "subject": "Subject name",
    "grade_level": "Grade level (e.g., 8th Grade)",
    "topic": "Specific lesson topic",
    "standards": ["Standard code 1", "Standard code 2"],
    "objective": "Students will be able to... (SWBAT format, observable verb)",
    "duration_minutes": 45,

    "vocabulary": [
        {
            "term": "Term",
            "definition": "Clear, student-friendly definition",
            "context_sentence": "A sentence using the term in the context of this lesson",
            "image_spec": "Specific image search query for this term (e.g. 'photosynthesis chloroplast diagram'). RECOMMENDED — may be empty string only for abstract terms."
        }
    ],

    "primary_sources": [
        {
            "id": "source_a",
            "title": "Document Title",
            "source_type": "text_excerpt | political_cartoon | map | data_table | photograph | diagram",
            "content_text": "The complete source excerpt or full data table — not a summary. Must be substantive (3–8 sentences for text; all rows/columns for tables). For political cartoons: write a detailed visual description of what the cartoon depicts (characters, symbols, captions, setting) so the reader can picture it.",
            "attribution": "Author, Title, Date/Year",
            "image_spec": "REQUIRED — a specific image search query (e.g. 'Thomas Nast Boss Tweed political cartoon 1871'). Must be real search terms, NOT emoji, NOT Unicode art, NOT decorative characters.",
            "scaffolding_questions": [
                "Identification-level question?",
                "Analysis-level question?"
            ]
        }
    ],

    "do_now": {
        "stimulus": "The full text, scenario, data excerpt, or description of the visual that students respond to. Must be substantive — not a question itself.",
        "stimulus_type": "text_excerpt | scenario | data | image | map | diagram",
        "questions": [
            "Question 1 anchored to the stimulus above?",
            "Question 2 anchored to the stimulus above?"
        ],
        "answers": [
            "Expected answer to question 1",
            "Expected answer to question 2"
        ]
    },

    "direct_instruction": [
        {
            "heading": "Section Heading",
            "content": "The actual content being taught — include full source texts, worked examples, data, or passages. Not a summary. A substitute teacher should be able to deliver this from the text alone.",
            "teacher_script": "Scripted teacher language: what the teacher says, key questions to pose, think-aloud annotations, and transition phrases. Include checks for understanding every 3–5 minutes as specific questions.",
            "key_points": ["Key point 1", "Key point 2"],
            "image_spec": "REQUIRED for ALL subjects — a specific image search query describing the visual aid for this section (e.g. 'American Revolution Battle of Bunker Hill painting', 'cell mitosis phases diagram', 'quadratic formula graph parabola', 'Romeo and Juliet balcony scene painting'). Use real search terms, NOT emoji."
        }
    ],

    "guided_notes": [
        {
            "prompt": "The ________ was the primary cause of...",
            "answer": "key word or phrase",
            "section_ref": "Heading of the direct_instruction section this note belongs to"
        }
    ],

    "stations": [
        {
            "title": "STATION A: Document Title",
            "source_ref": "id of the referenced primary_source (e.g., source_a)",
            "task": "What students are doing at this station (e.g., sourcing, contextualizing, corroborating)",
            "student_directions": "Step-by-step directions a student can follow independently. Include all questions students will answer.",
            "teacher_answer_key": "Complete expected responses for all station questions"
        }
    ],

    "independent_work": {
        "task": "Clear, step-by-step instructions a student can follow without asking the teacher. Include all actual problems, questions, or tasks — not descriptions of tasks. Include an extension task for early finishers.",
        "rubric_snippet": "2–3 criteria describing what proficient work looks like",
        "exemplar": "A brief model answer or sentence-level exemplar showing the expected quality"
    },

    "exit_ticket": [
        {
            "stimulus": "The actual text, data excerpt, or scenario students read before answering. Must be non-empty.",
            "stimulus_type": "text_excerpt | scenario | data | image | map | diagram",
            "stimulus_image_spec": "Optional image description or empty string",
            "question": "Question anchored to the stimulus above?",
            "answer": "Expected proficient response",
            "cognitive_level": "recall"
        },
        {
            "stimulus": "A different or extended stimulus — may reuse an earlier source with a new angle.",
            "stimulus_type": "text_excerpt | scenario | data | image | map | diagram",
            "stimulus_image_spec": "",
            "question": "Application-level question anchored to the stimulus?",
            "answer": "Expected proficient response",
            "cognitive_level": "application"
        },
        {
            "stimulus": "A new or extended stimulus that requires synthesis or transfer.",
            "stimulus_type": "text_excerpt | scenario | data | image | map | diagram",
            "stimulus_image_spec": "",
            "question": "Analysis or transfer question — requires students to go beyond the text?",
            "answer": "Expected proficient response",
            "cognitive_level": "analysis"
        }
    ],

    "differentiation": {
        "struggling": [
            "Specific scaffold 1 — name the tool, structure, or sentence frame",
            "Specific scaffold 2"
        ],
        "advanced": [
            "Genuine enrichment extension 1 — deepens, does not repeat",
            "Genuine enrichment extension 2"
        ],
        "ell": [
            "Concrete language support 1 — sentence frame, visual glossary, or cognate note",
            "Concrete language support 2"
        ]
    },

    "homework": "A meaningful extension activity connecting today's learning to outside school or previewing tomorrow's content. Not busywork. Not a repeat of classwork. Write null if no homework.",

    "materials_needed": [
        "Item 1 — specific enough that a teacher can gather everything before class",
        "Item 2"
    ]
}
