Welcome back, Recruits! Ready to start building your AI sidekick? Today we're breathing life into QuestBot - your personal AI assistant that'll grow smarter over the next 3 days.
What we're building today: A friendly AI that greets you by name and adapts its personality to your vibe.
Time needed: ~30 minutes
XP Reward: 100 XP + Code Summoner badge ๐๏ธ
๐ฏ Mission Overview
By the end of today, your QuestBot will:
- Greet users with a custom message
- Ask for their name and remember it
- Adapt its personality based on user preference
- Feel like a real conversation!
๐ Download the Files
Prefer to code along? Grab the starter files:
- questbot_day1_template.py - Empty template with TODO comments and hints
- questbot_day1_solution.py - Complete working code (check this if you get stuck)
- setup_guide.md - Detailed installation instructions
Choose your adventure:
- ๐ Follow the tutorial โ Read and code step-by-step below
- ๐ Use the template โ Download the template and fill in the TODOs
- โ Check solutions โ Compare your code with the working version
Files will be available in the comments or on my GitHub link !
Quest 1: Unlock the Code Vault (20 XP - 5 min)
First things first - let's make sure your setup is ready to roll!
Option A: Local Setup
- Install Python 3 from python.org if you haven't already
- Test it: Open your terminal/command prompt and type:
python --version
# or try
python3 --version
-
Create your workspace: Make a new folder called
questbot-project
- Choose your editor: VS Code, PyCharm, or even Notepad works!
Option B: Online Setup (Zero Install!)
- Go to replit.com and create a free account
- Click "Create Repl" โ Choose "Python"
- Name it "QuestBot-Assistant"
- You're ready to code!
โ Checkpoint: You can run Python and see the version number
Quest 2: Forge QuestBot's Voice (30 XP - 10 min)
Time to give your bot its first words! Create a new file called questbot.py
and let's start simple:
# QuestBot Day 1 - First Contact
print("Greetings, Recruit! I'm QuestBot, your AI sidekick!")
Run it:
-
Local:
python questbot.py
in your terminal - Replit: Hit that green "Run" button
You should see QuestBot's first message! ๐
Level Up: Add Some Personality
Let's make it more interesting:
print("๐ค SYSTEM INITIALIZING...")
print("โจ QuestBot v1.0 ONLINE")
print("")
print("Greetings, Recruit! I'm QuestBot, your AI sidekick!")
print("Ready to embark on your coding quest? ๐")
โ Checkpoint: Your bot has a personality and greets users
Quest 3: Personalize the Mission (50 XP - 15 min)
Here's where the magic happens - making it feel like a real conversation!
Step 1: Get to Know Your User
print("๐ค SYSTEM INITIALIZING...")
print("โจ QuestBot v1.0 ONLINE")
print("")
print("Greetings, Recruit! I'm QuestBot, your AI sidekick!")
# Get user's name
name = input("What's your Recruit name? ")
print(f"Excellent! Nice to meet you, {name}!")
Step 2: Adapt to Their Vibe
# Ask for their preferred vibe
print(f"\\nAlright {name}, let's set the mood...")
vibe = input("Pick a vibe (epic, chill, heroic): ")
# Respond with personalized greeting
print(f"\\nSalute, {name}! QuestBot is ready in {vibe} mode! ๐ฏ")
Step 3: Complete Day 1 Code
Here's your full questbot.py
for today:
# QuestBot Day 1 - First Contact
print("๐ค SYSTEM INITIALIZING...")
print("โจ QuestBot v1.0 ONLINE")
print("")
print("Greetings, Recruit! I'm QuestBot, your AI sidekick!")
# Get user's name
name = input("\\nWhat's your Recruit name? ")
print(f"Excellent! Nice to meet you, {name}!")
# Ask for their preferred vibe
print(f"\\nAlright {name}, let's set the mood...")
vibe = input("Pick a vibe (epic, chill, heroic): ")
# Personalized response
print(f"\\nSalute, {name}! QuestBot is ready in {vibe} mode! ๐ฏ")
print("Your AI sidekick is now online and ready for action!")
โ Checkpoint: QuestBot knows your name and adapts to your chosen vibe
๐ Bonus Challenge: Dynamic Responses (10 XP)
Want to earn extra XP? Make QuestBot respond differently based on the vibe:
# Add this after getting the vibe, before the final greeting
if vibe.lower() == "epic":
print("๐ Prepare for LEGENDARY adventures!")
elif vibe.lower() == "chill":
print("๐ Cool vibes activated. Let's take it easy.")
elif vibe.lower() == "heroic":
print("โ๏ธ Honor and glory await! Ready for battle!")
else:
print(f"๐ญ {vibe} mode activated! Let's make it happen!")
print(f"\\nSalute, {name}! QuestBot is ready and reporting for duty! ๐ฏ")
๐ฎ Test Your QuestBot
Run your code and try different inputs:
- Test 1: Use your real name + "epic" vibe
- Test 2: Try a fun nickname + "chill" vibe
- Test 3: Enter something random for vibe and see what happens
Example interaction:
๐ค SYSTEM INITIALIZING...
โจ QuestBot v1.0 ONLINE
Greetings, Recruit! I'm QuestBot, your AI sidekick!
What's your Recruit name? Alex
Excellent! Nice to meet you, Alex!
Alright Alex, let's set the mood...
Pick a vibe (epic, chill, heroic): epic
๐ Prepare for LEGENDARY adventures!
Salute, Alex! QuestBot is ready and reporting for duty! ๐ฏ
๐ธ Quest Log: Share Your Victory!
Got your QuestBot talking? Awesome! Share a screenshot of your personalized greeting on social media with #4IRQuestSaga - I'd love to see what names and vibes you chose!
๐๏ธ Badge Unlocked: Code Summoner
"Summoned your first AI companion from lines of code"
What's Next?
Tomorrow in Day 2, we'll teach QuestBot to:
- ๐ Remember and manage your tasks
- โป๏ธ Handle multiple commands in a loop
- ๐ฏ Display your mission log with style
Your homework: Play around with your QuestBot! Try different names, vibes, and see what happens. The more comfortable you get with input/output, the easier Day 2 will be.
Total XP Earned Today: 100 XP
Running Total: 100/300 XP
Progress: 33% complete ๐
See you tomorrow for Day 2: Task Mastery! ๐
Having trouble? Drop a comment below or find me on social @creator_x - happy to help debug! ๐จโ๐ป
Top comments (0)