Beginner — Day 5
AI Day
Day Schedule
Online
| Time | Activity |
|---|---|
| 10:00 | AI Introduction AI as a coding partner; demo precise vs. vague prompts side by side |
| 10:20 | Live Demo Extend Boredom Buster Bot with AI; walk through every generated line |
| 10:50 | Break |
| 11:00 | Breakout Groups Students extend their bot using AI |
| 11:30 | Post-Assessment Link provided separately |
| 11:50 | Show & Tell |
| 12:10 | Meetup Advanced group joins |
| 12:20 | Closeout Closing remarks, photos |
In-Person
| Time | Activity |
|---|---|
| 8:00 | AI Introduction AI as a coding partner; demo precise vs. vague prompts side by side |
| 8:30 | Live Demo Extend Boredom Buster Bot with AI; walk through every generated line |
| 9:00 | Breakout Groups Students extend their bot using AI |
| 9:40 | Break |
| 9:50 | Breakout Groups Continue; help students pick a second project to extend |
| 11:00 | Post-Assessment Link provided separately |
| 11:20 | Show & Tell |
| 11:50 | Open Coding / Overflow Catch up or continue extending with AI |
| 12:10 | Meetup Advanced group joins |
| 12:20 | Closeout Closing remarks, photos |
Learning Objectives
- Write a precise AI prompt that describes existing code and a specific new feature
- Read and explain every line of AI-generated code before using it
- Add at least one new feature to the Boredom Buster Bot using AI
- Demo the extended program in show & tell
Main Topic
# INSTRUCTOR — Day 5: Introduction to AI (Beginner)
# -----------------------------------------------
# TEACH: No new Python concepts today. The focus is on AI as a tool.
# Key messages to reinforce all day:
# 1. AI is a coding partner, not a replacement for thinking.
# 2. Understand every line before you use it.
# 3. A bad prompt gives a bad result — precision matters.
#
# DEMO: Live demonstration of prompting an AI tool.
# Recommended sequence:
# a. Show a vague prompt ("make my bot better") and show a mediocre result.
# b. Show a precise prompt (below) and show a much better result.
# c. Show how to ask the AI to EXPLAIN a line you don't understand.
#
# DEMO PROMPT (use with Boredom Buster Bot):
# "I have a Python program that asks the user how they're feeling and gives a suggestion.
# Here is my code: [paste]. Add a mood called 'stressed'. It should ask one follow-up
# question: 'Is it school or something else?' Each answer gets a different response."
#
# TEACH: how to evaluate AI output
# - Run it. Does it work?
# - Read every line. Can you explain it?
# - If there's a line you don't understand, ask: "Explain line X of this code to me."
#
# TEACH: AI makes mistakes. Show a known error if time allows.
# Ask AI for something slightly wrong on purpose, then debug together.
Project — Extend Your Bot
# INSTRUCTOR — Day 5: Activity: Extend your Bot with AI (Beginner)
# -----------------------------------------------
# TEACH: Students open their Boredom Buster Bot from Day 2 and use AI to add one feature.
# Circulate and check two things:
# 1. Does their prompt describe the existing code clearly?
# 2. Can they explain every line of the generated code?
#
# Sample good prompts to share with the class:
# "Add a mood called 'stressed' to my Boredom Buster Bot.
# It should ask one follow-up question."
#
# "Add a 'surprise me' option that picks a random activity from a list."
#
# "Ask the player their name at the start and use it in the responses."
#
# REFERENCE: a complete Boredom Buster Bot with AI-added 'stressed' mood
print("Hey! I'm your Boredom Buster Bot.")
name = input("What's your name? ") # AI-added: personalization
print("Nice to meet you, " + name + "!")
mood = input("How are you feeling? (bored / tired / hungry / stressed): ")
if mood == "bored":
activity = input("Do you want something active or chill? ")
if activity == "active":
print("Go outside and challenge someone to a race!")
else:
print("Watch a funny YouTube video.")
elif mood == "tired":
print("Take a 20-minute nap. You'll feel better!")
elif mood == "hungry":
print("Go make a snack. You've earned it!")
elif mood == "stressed": # AI-added mood
cause = input("Is it school or something else? ")
if cause == "school":
print("Take a 5-minute break, then tackle one small task at a time.")
else:
print("Write down what's on your mind. Getting it out helps a lot.")
else:
print("I'm not sure what to do with that. Try again!")
Extra — Build Something New
# INSTRUCTOR — Day 5: Extra Activity: Build Something New (Beginner)
# -----------------------------------------------
# TEACH: Students who finish the Bot extension pick any project from the week
# and use AI to add one feature they thought of themselves.
# Your role: verify they understand the generated code before they paste it in.
#
# Ask them: "Explain this line to me." If they can't, send them back to the AI.
#
# REFERENCE: sample AI-extended Snowflake project (color randomization)
import turtle
import random
def draw_snowflake(size, color): # AI-added: color parameter
turtle.color(color) # set color before drawing
for i in range(6):
turtle.forward(size)
turtle.backward(size)
turtle.right(60)
colors = ["white", "light blue", "cyan", "powder blue", "alice blue"]
turtle.speed(0)
turtle.bgcolor("midnight blue")
for i in range(12):
x = random.randint(-300, 300)
y = random.randint(-200, 200)
turtle.penup()
turtle.goto(x, y)
turtle.pendown()
chosen_color = random.choice(colors) # AI-added: pick random color
draw_snowflake(random.randint(30, 100), chosen_color)
turtle.hideturtle()
turtle.done()