π An innovative programming textbook that embraces AI as a learning partner. Master Python by learning how to think computationally and direct AI to help you build solutions.
This book represents a fundamental shift in how we teach programming in the age of AI. Instead of treating AI as something to avoid, we embrace it as a powerful learning partner. Students learn to think computationally, design solutions, and direct AI to help implement their ideas.
- Concept First: Understand patterns before syntax
- AI as Explorer: Use AI to discover and understand
- Mental Models: Build deep understanding, not just working code
- Progressive Partnership: Evolve from AI explaining concepts to AI implementing your designs
- Chapter 0: Understanding Your AI Partner β
- Chapter 1: Input, Process, Output β
- Chapter 2: Remembering Things (Variables) β
- Chapter 3: Asking Questions (Input) β
- Chapter 4: Making Decisions (If Statements) π§
- Chapter 5: Doing Things Over and Over (Loops) π
- Weekly Projects: Fortune Teller, Mad Libs, Number Game, Rock Paper Scissors
- Chapter 6: Creating Your Own Commands (Functions)
- Chapter 7: Organizing Information (Dictionaries)
- Chapter 8: Saving Your Work (Files)
- Chapter 9: When Things Go Wrong (Debugging)
- Weekly Projects: Temperature Converter, Contact List, Journal App, Quiz Game
- Chapter 10: Planning Before Coding
- Chapter 11: Working with Data
- Chapter 12: Connecting to the Internet (APIs)
- Chapter 13: Making Things Look Nice (GUI Basics)
- Weekly Projects: To-Do List, Weather Checker, Budget Tracker, Drawing App
- Chapter 14: You're Ready for Projects!
- No programming experience required
- Access to an AI assistant (ChatGPT, Claude, etc.)
- Python installed on your computer
- Enthusiasm to learn!
This book is built using Quarto. To build locally:
# Install Quarto first (see https://quarto.org/docs/get-started/)
# Clone the repository
git clone https://github.com/yourusername/python-step-by-step-ai.git
cd python-step-by-step-ai
# Preview with live reload
quarto preview
# Build all formats
quarto render
# Build specific format
quarto render --to html
quarto render --to pdf
quarto render --to epub- π± HTML (interactive web version with dark mode)
- π PDF (professional typography for printing)
- π EPUB (optimized for e-readers)
This book is designed for a 12-week introductory programming course. Each week includes:
- Conceptual learning with AI exploration
- Hands-on exercises with 5-level progression
- Weekly projects that reinforce concepts
- Reflection and journaling prompts
- Concept Recognition - Identify patterns without coding
- Prompt Engineering - Learn to communicate with AI effectively
- Pattern Matching - Find concepts in complex code
- Model Building - Create mental models and visualizations
- Architect First - Design solutions before implementation
- Weeks 1-4: AI as Concept Explorer
- Weeks 5-8: AI as Implementation Assistant
- Weeks 9-12: AI as Code Producer (following student designs)
We welcome contributions! Please see CONTRIBUTING.md for guidelines.
- Additional exercises and projects
- Translations
- Accessibility improvements
- Teaching resources
- Bug fixes and improvements
- Tone: Conversational, encouraging, reality-based
- Code: Simple, clear, extensively commented for beginners
- Exercises: Follow the 5-level system
- AI Examples: Show overcomplicated AI code first, then simplify
python-step-by-step-ai/
βββ _quarto.yml # Main Quarto configuration
βββ index.qmd # Book preface
βββ intro.qmd # Introduction
βββ chapter-*.qmd # Chapter files
βββ projects/ # Weekly project files
βββ assets/ # CSS, JavaScript, images
βββ templates/ # Chapter and exercise templates
βββ _extensions/ # Quarto extensions
βββ notes/ # Development notes
βββ tasks/ # Task management
βββ references.bib # Bibliography
This book is part of a comprehensive series for mastering modern software development in the AI era:
- Converse Python, Partner AI: The Python Edition
- Think Python, Direct AI (this book): Computational Thinking for Beginners
- Code Python, Consult AI: Python Fundamentals for the AI Era
- Ship Python, Orchestrate AI: Professional Python in the AI Era
- Build Web, Guide AI: Business Web Development with AI
This project is licensed under the MIT License - see the LICENSE file for details.
- Built with Quarto
- Inspired by educators embracing AI in the classroom
- Based on research in AI-assisted learning and constructionist pedagogy
- Special thanks to all contributors and early adopters
- Issues: Bug reports and feature requests
- Discussions: Teaching experiences and ideas
- Website: https://pythonstepbystep.ai (coming soon)
"In the age of AI, we're not teaching students to write code. We're teaching them to think computationally and direct AI to bring their ideas to life."
This book is part of the books.borck.education series. Publishing (PDF, EPUB, llm.txt, chatbot, cover generation) is handled by the book-publisher repo.
| Path | Purpose |
|---|---|
index.qmd |
Preface (landing page) |
_quarto.yml |
HTML-only Quarto config |
cover.png |
Cover image |
copyright-page.tex |
Copyright page for PDF |
pdf-header.tex |
LaTeX header for PDF |
epub-styles.css |
EPUB styles |
scripts/ |
Build scripts (preprocess.py = print preprocessing hook) |
appendices/ |
Appendix content |
notes/ |
Working notes, outlines, planning docs (not published) |
rag-documents/ |
Generated RAG chunks for chatbot |
_book/ |
Rendered output (gitignored) |
_print_source/ |
Generated print source (gitignored) |