M2-B — How AI Generates Answers

Apr 29, 2026 3:36 PM

The core idea When you ask ChatGPT something, it doesn't open a textbook. It does one thing on loop: read your words → predict next word → repeat.


⌨️ What Happens When You Type a Prompt

Your prompt is really giving AI four things at once:

What you're giving What it means
Situation The context around your question
Task What you actually want
Style (output format) How you want it to sound
Limits What to stay away from

The steering wheel Your prompt is the steering wheel. The model is the engine. Without steering, it goes anywhere.


🔄 Step-by-Step — How an Answer is Built

You type a prompt
    ↓
System breaks your text into small pieces (tokens)
    ↓
Model looks at tokens and asks: "What's the best next token?"
    ↓
It picks one (with a bit of randomness)
    ↓
Adds it to the answer
    ↓
Repeats until the answer feels complete

What's a token? Just a small chunk of text — a word or part of a word. You don't need to memorise the word. Just know: small pieces.


🎬 A Tiny Demo

Prompt: "In my school, the best teacher is"

The model predicts step by step: the → one → who → explains → with → examples

Result: "In my school, the best teacher is the one who explains with examples…"

This is it. It completes text smartly. That's the whole trick.


🎲 Why the Same Prompt Gives Different Answers

The model doesn't pick the next word in one fixed way. It picks from a group of "good next words" — like a weighted dice.

Setting What it does What you notice
More strict Picks the most common next word Safe, consistent, repetitive style
More creative Allows less-common words More variety, occasionally more mistakes

The real insight ChatGPT is not copying a stored answer. It is creating a new answer every time — step by step.


✍️ Prompt Quality = Output Quality

Your prompt gives the model its direction. A vague prompt = AI guesses.

Unclear vs Clear — Side by side

Unclear prompt Clear prompt
"Explain AI." "Explain AI to a 10th student using a school example, in 8 bullets, no technical words."

Think of it like a recipe A clear prompt gives: ingredients + steps + style. A vague prompt gives: the chef makes something random.


📋 Prompt Checklist

Before you send a prompt, ask yourself:

Part Question to ask yourself Example
Goal What exactly do I want? "Make study notes"
Audience For whom? "10th standard students"
Format How should it look? "Headings + recap"
Limits What to avoid? "No jargon, no math"
Examples Real-life context? "School, cricket, shopping"

🔍 AI is NOT Google — Clear Difference

ChatGPT Google
How it works Generates text from scratch Finds pages that already exist
Gives you Explanation, writing, drafts Links and sources
Best for Understanding and creating Checking facts and finding official info
Risk Can confidently generate something false Can give outdated or irrelevant links

Use both — not just one Use ChatGPT to understand and draft. Use Google to verify facts.


✅ Recap

30-second read