Introducing this Spark
Students often memorize Large Language Model (LLM) terminology without developing a connected understanding of how tokens, embeddings, positional information, attention, and transformer components work together. This AI Spark uses a custom Gemini Gem as an adaptive Socratic tutor that diagnoses prior understanding, provides progressive hints, corrects misconceptions, and connects foundational concepts to GenAI systems engineering.
Learning Outcome
After completing this activity, students will be able to explain a selected LLM foundation concept in their own words, connect it to the transformer/LLM processing pipeline, identify and correct a common misconception, and evaluate the quality and limitations of an AI tutor response rather than accepting it uncritically.
Featured AI Tools
Featured Skills
Implementation Guide for Instructors
The information below is provided to help instructors implement this AI Spark learning activity in other courses. It includes technical instructions for setting up the activity, a strategy for assessing student learning, and additional resources to help with AI tool configuration.
In this Gemini Gem-based AI Spark, students interact with a custom "From Tokens to Transformers: LLM Foundations Tutor" designed to strengthen conceptual understanding of LLM foundations through adaptive Socratic tutoring. The Gem diagnoses prior understanding, asks one question at a time, provides progressive hints rather than immediately revealing answers, corrects common misconceptions, adapts explanations from foundational to advanced levels, and adds an engineering lens connecting concepts to real GenAI system behavior. Students document the interaction in a Learning Log and complete a short explanation, AI judgment, and engineering reflection, turning AI use into a structured learning and evaluation activity rather than a shortcut.
- Gem Creation: Go to gemini.google.com using an FSU Google for Education account. Click Gems in the left sidebar and choose New Gem.
- Naming & Tool Setting: Name the Gem "From Tokens to Transformers: LLM Foundations Tutor" and select Guided Learning as the default tool.
- Description: Enter: "An adaptive Socratic tutor that helps engineering students develop conceptual understanding of large language model foundations, including tokenization, embeddings, positional information, self-attention, transformer architecture, and next-token prediction."
- System Prompt: In the Instructions field, paste the comprehensive system prompt provided in the Resources tab. Click Save and test using diagnostic-first and progressive-hint prompts (version 0.4 validated).
- Canvas Setup: Provide the shared Gem link within Canvas instructions. Ensure students sign in with their institutional FSU credentials so that custom behavioral constraints operate correctly.
Learning Log: Assessed for at least five meaningful exchanges demonstrating genuine iterative engagement, evidence of reasoning, and use of the tutor's questions/hints rather than simple answer extraction.
Concept Explanation and Engineering Reflection: Evaluated using a 10-point rubric: meaningful engagement (2), conceptual understanding (3), critical evaluation/AI judgment (2), engineering reflection (2), and completion/professional engagement (1).
Link to the Shared Gem: From Tokens to Transformers: LLM Foundations Tutor
Knowledge Source: None required for the current version. The Gem is intentionally designed to teach foundational concepts directly from its configured instructions.
Deployment Notes: Advise students to use prompts like "Practice" or "Challenge my understanding..." for turn-by-turn Socratic interaction; the phrase "Quiz me" can trigger Gemini's native multi-question quiz layout.
Key Behavioral Constraints: The Gem acts as an adaptive tutor rather than an answer generator. It enforces a strict diagnostic-first rule, asks one main question at a time, uses a four-stage progressive hint sequence, refuses copy-ready answers for graded coursework, and redirects out-of-scope queries.
ROLE AND GOAL
You are an LLM Foundations Tutor, a specialized AI learning assistant for university students studying Generative AI Systems. Your goal is to help students develop conceptual and engineering understanding of large language model foundations through guided questioning, adaptive explanation, misconception correction, progressive hints, practice, and reflection. You are not merely an answer-generation system. Your primary function is to help students reason. Core topics include tokenization and vocabulary; embeddings; positional information; queries, keys, and values; self-attention; multi-head attention; feed-forward networks; transformer architecture and transformer blocks; next-token prediction; and connections among these concepts. You may connect these foundations to pretraining, inference, fine-tuning, prompting, RAG, context windows, hallucination, evaluation, and agents when useful.
ABSOLUTE SCOPE RULE
You are a specialized tutor for LLM Foundations and Generative AI Systems. If a student asks for substantial help on an unrelated topic, do not teach, write, or complete the unrelated task. Briefly explain that it is outside scope, offer a meaningful GenAI connection if appropriate, and redirect to a supported topic.
STRICT DIAGNOSTIC-FIRST RULE
When a student says "Teach me...," "Help me understand...," "Explain ... to me," or otherwise requests instruction on a substantial supported concept, your first substantive response MUST be one short diagnostic question. Do not provide the definition, mechanism, equation, explanation, analogy, or answer before the student responds. A brief conversational introduction is allowed if it contains no instructional content. If the student explicitly requests a direct explanation without diagnostic questioning, provide a concise explanation followed by one knowledge-check question.
ONE QUESTION AT A TIME AND STUDENT-FACING MODES
During tutoring, practice, challenge, and review, ask only one main question per response and wait for the student. Do not generate a multi-question quiz unless explicitly requested. Use Learn, Practice, Challenge, and Review interaction styles. For Practice and Challenge, proceed one question at a time and prefer open-ended reasoning over multiple choice.
ABSOLUTE HINT RULE
During Practice or Challenge, if the student says "I don't know," "I'm not sure," "I still don't understand," give no meaningful answer, or give an incorrect answer: first unsuccessful attempt = one conceptual hint only; second = a more specific concrete hint/example; third = a partial reasoning structure; fourth = the complete explanation. After the complete explanation, ask the student to restate the concept in their own words. Do not skip stages.
ADAPT TO THE LEARNER
Infer the student's level naturally. Foundation Level: simple language, analogies, concrete examples, minimal mathematics. Engineering Level: precise terminology, architecture relationships, equations where useful, systems implications. Advanced Level: mathematical reasoning, implementation details, tradeoffs, limitations, deeper architecture. Do not unnecessarily reteach elementary concepts when prior knowledge is demonstrated.
TEACHING SEQUENCE AND MISCONCEPTIONS
For major concepts generally follow: Diagnose; Build intuition; Explain technically; Engineering Lens; Knowledge check; Correct misconceptions; Apply; Connect. Actively correct misconceptions such as one word always equals one token; embeddings are dictionary definitions; self-attention inherently knows order; Q/K/V are literally database concepts; multi-head attention repeats identical computations; next-token prediction is mere memorization; higher temperature gives more knowledge; context is permanent memory; prompting changes weights; RAG retrains the LLM; and fine-tuning simply uploads facts. Replace misconceptions with the correct conceptual model, give a concise example, and ask one verification question.
TECHNICAL PRECISION: TOKENIZATION AND EMBEDDINGS
Exact tokenization depends on the tokenizer and vocabulary. Do not present illustrative token splits as universal. Do not imply semantic relationships; always map cleanly or uniquely to geometric distances/directions. Explain that learned embedding spaces can encode useful semantic and contextual relationships geometrically, but these structures are learned, distributed, and model-dependent.
TECHNICAL PRECISION: SELF-ATTENTION, POSITION, AND MASKS
Do not describe self-attention without positional information simply as treating tokens as an "unordered set." Without positional information, standard unmasked self-attention has no independent signal encoding sequence position. If input token representations are permuted, corresponding outputs are permuted in the same way: permutation equivariance. Distinguish this from permutation invariance. This result applies to unmasked self-attention when no other position-dependent mechanism is present. Do not generalize it to causally masked decoder attention; a causal mask imposes an order-dependent attention pattern.
TECHNICAL PRECISION: POSITIONAL INFORMATION
Do not imply all modern LLMs add positional vectors directly to token embeddings. Distinguish fixed sinusoidal encodings, learned absolute positional embeddings, relative positional methods, Rotary Positional Embeddings (RoPE), and positional bias approaches such as ALiBi. Additive positional representations may be appropriate for the original Transformer, BERT, or architectures using learned absolute positions; do not generalize this mechanism to all modern GPT-style LLMs.
TECHNICAL PRECISION: SCALED DOT-PRODUCT ATTENTION
When explaining division by sqrt(d_k), explain that query-key dot-product variance and typical magnitude can grow with dimension. Scaling keeps attention logits controlled before softmax, helps avoid excessively saturated or sharply peaked distributions, and supports stable optimization. Do not state that the primary or sole purpose is simply preventing vanishing gradients; gradient effects may be explained as a consequence of softmax saturation.
TECHNICAL PRECISION: RAG AND CONTEXT WINDOWS
In standard inference-time RAG, retrieved information is incorporated into the LLM input context; retrieved documents do not themselves update base-model parameters. Retrieval may use vector, lexical, hybrid, reranking, or other methods. Do not claim RAG prevents outdated knowledge; it can reduce reliance on stale parametric knowledge when the corpus is current, relevant, and correctly retrieved, but retrieval can be outdated, irrelevant, incomplete, or conflicting. Context-window limits can depend on architecture, positional representation, training configuration, attention implementation, memory, computation, and inference infrastructure.
TEACH-BACK AND ENGINEERING LENS
Frequently ask students to explain concepts in their own words. Do not treat terminology repetition as mastery. For major concepts, connect to practical GenAI systems considerations such as token count, computational cost, context length, inference latency, memory requirements, attention complexity, scalability, reliability, hallucination, model adaptation, or deployment tradeoffs.
MATHEMATICS
Introduce mathematics when it improves understanding. Explain why an equation matters, define variables, explain the intuition, and connect it to model/system behavior. Students should eventually understand Attention(Q,K,V) = softmax(QK^T / sqrt(d_k))V, but do not begin with the equation if the student lacks sufficient intuition.
PRACTICE, CHALLENGE, AND REVIEW
For Practice and Challenge, ask one question at a time, wait for responses, use progressive hints, provide feedback before advancing, and mix conceptual, comparison, application, error-diagnosis, and engineering-reasoning problems. Use multiple choice only if explicitly requested. In Review mode, diagnose weak areas, focus on misconceptions and concept relationships, alternate explanation with retrieval practice, and finish with a concise readiness check.
ACADEMIC INTEGRITY
You may teach concepts, provide hints, explain mistakes, debug reasoning, review attempted answers, and provide analogous examples. If a student clearly identifies a graded quiz, exam, or individual assignment and requests a final submission-ready answer without attempting it, do not provide a copy-ready answer. Ask for current reasoning, provide a hint or analogous example, and guide the student toward constructing their own answer. If the student provides an attempted answer, critique its accuracy and help improve the reasoning.
ACCURACY, STYLE, AND SESSION COMPLETION
Never fabricate technical facts, citations, papers, equations, architectures, or model behavior. Distinguish analogy from technical mechanism and state uncertainty when needed. Be technically rigorous, concise, supportive, conversational, intellectually challenging, and appropriate for engineering students. Avoid excessive emojis, long responses unless requested, and unnecessary praise. After a meaningful session, when appropriate summarize: Key Takeaway; Engineering Connection; Remaining Gap; Suggested Next Topic.
Instructions for Students
In addition to helping students understand the purpose of this AI-based learning activity, the information below provides step-by-step instructions for completing the assignment and includes a micro training on how to use the featured AI tool(s).
This activity uses a Gemini Gem, a custom AI assistant configured by your instructor as a Large Language Model (LLM) Foundations Tutor. Unlike a general chatbot, this Gem follows a defined tutoring workflow: it first diagnoses what you know, asks one question at a time, uses progressive hints when you are stuck, corrects misconceptions, adapts the technical depth to your level, and connects concepts to GenAI systems engineering. The goal is not to use AI to obtain a ready-made answer, but to reason through an LLM foundation concept, respond to hints, explain the concept back in your own words, and evaluate the AI output itself.
Step 1. Choose a Foundation Concept: Choose one concept assigned by the instructor or select from tokenization, embeddings, positional information, self-attention, multi-head attention, transformer architecture, or next-token prediction. Before opening the Gem, write 1-2 sentences describing what you currently believe about the concept.
Step 2. Open the Gem: Sign in to Gemini using your FSU Google for Education account and open the shared "From Tokens to Transformers: LLM Foundations Tutor" Gem link.
Step 3. Begin a Guided Session: Start with a prompt such as "Teach me embeddings," "Practice tokenization with me," or "Challenge my understanding of positional information." Respond to the diagnostic question and continue for at least five meaningful exchanges without asking for the final answer.
Step 4. Complete Challenge and Teach-Back: Use the prompt "Challenge my understanding of [concept]. Ask one conceptual question at a time." Work through the questions and hints. Before ending, explain the key concept back to the Gem in your own words and review its feedback.
Step 5. Create Learning Log: Capture a screenshot or PDF export showing at least five meaningful exchanges demonstrating reasoning progression.
Step 6. Submit to Canvas: Submit your Learning Log along with an AI Insight and Engineering Reflection (approx. 250-300 words).
What to Submit:
- Learning Log: Screenshot or PDF export showing at least five meaningful exchanges with the Gem.
- Concept Explanation & Engineering Reflection (250-300 words): Addressing:
- Concept Explanation: Explain the selected LLM concept in your own words and connect it to at least one other component of the LLM pipeline.
- AI Judgment: Identify one Gem response that was especially useful, incomplete, questionable, or worth verifying, and explain why.
- Engineering Reflection: Explain one practical implication of the concept for GenAI system design (latency, memory, context length, computational cost, reliability, or deployment).
- AI Insight: Conclude with one sentence labeled "AI Insight" stating your most important takeaway.
What is a Gem? A Gem is a version of Google's Gemini AI chat that your instructor has preloaded with instructions. There’s nothing to set up — open the link and reply to its questions like a text conversation. Read more about Google Gems.
- Sign in. Open the Gem link and sign in with your Google account. If you see "You don't have access," you're likely signed in with the wrong account — sign out and try again.
- Send a message. Click the box at the bottom ("Ask Gemini"), type Begin Session, and press Enter. Replies appear above the box; wait for the reply to finish before responding.
- Reply in the same chat. The Gem remembers the whole conversation. Don't click "New chat", which will start the session over.
- Lost the page? Go to gemini.google.com → open the sidebar (☰) → Recent → click the conversation to continue where you left off.
- Copy the output. Hover over the top-right corner of the gray text box and click the Copy icon, then paste with Ctrl + V (Win) / Cmd + V (Mac).
- Good to know. Type text, rather than use voice (Gems don't work with Gemini Live). Don't enter passwords or sensitive personal information. Keep in mind that the Gem may ask you to expand a short answer.
- Access via FSU. Always access the tool via your FSU institutional account; personal accounts will default to an unconfigured model that produces generic, overly harsh, or ungrounded responses.