Opening soon
The Nonsense Filter: Generative AI for Grownups
Learn what generative AI is, how language models produce text, and where they fall short.
5 chapters · 20 lessons
Want a note when it opens?
Join the waitlist and we'll email you when the course is ready.
Free first lesson
What Generative AI Is and Why It Can Be Fluent and Wrong
Chapter 1, lesson 1. Read it now, no account needed.
Generative AI produces new text, images or code from patterns learned in training data. A language model writes by predicting the next token, one step at a time, which is why its output can be fluent and still wrong. This lesson walks through that mechanism with a worked example, shows where the tools fit and where they do not, and gives you a plain way to explain them to a colleague.
What generative AI is
Generative AI is software that produces new content. It can write text, create images, write code or produce audio. It does this from patterns it learned in its training data. You give it an instruction, called a prompt, and it returns content that fits the prompt.
Many AI systems already in business use do a different job. A spam filter sorts each email into "spam" or "not spam." A fraud model scores each payment as risky or safe. These are called discriminative models: they choose from a fixed set of labels. A generative model has no fixed list of answers. It builds a new output each time, piece by piece.
This course covers what generative AI is, how it grew out of earlier AI, how language models produce text, the transformer design behind them, and the main model families. This first lesson gives you the core idea that the rest of chapter 1 builds on. It focuses on language models, the kind behind chat assistants, because they are the tools you are likely to use first.
Tokens: the pieces a language model works with
A large language model, or LLM, is a generative model for text. It does not read words the way you do. It reads tokens. A token is a chunk of text. It can be a whole word, part of a word, a number or a punctuation mark. A short, common word like "report" may be one token. A long word like "reconciliation" may be split into several.
Each model has a fixed vocabulary of tokens. Before the model sees your prompt, a tool called a tokenizer cuts the text into tokens from that vocabulary. The model's reply comes out as tokens too, which are then joined back into text.
Tokens matter in practice for two reasons. Providers measure usage and set limits in tokens. And each model can take in a set number of tokens at once, called its context window. Text beyond that limit is cut off or has to be handled another way.
How a model learns from training data
A language model starts as a very large set of numbers, called parameters or weights. At first those numbers are random, so its predictions are useless.
Training changes that. The model is shown a huge amount of text, such as books, web pages and code. Again and again, it sees part of a passage and must predict the token that comes next. It compares its guess with the real next token. Then its weights are nudged so the right token becomes a little more likely next time. This first stage is called pre-training. Repeated across vast amounts of text, this produces a model that has absorbed grammar, style, common facts and the shape of many kinds of documents.
Chat assistants get extra training on top of this. They learn from examples of instructions paired with good answers. Human reviewers also rate answers, and the model is tuned toward the answers people preferred. Both steps are kinds of fine-tuning. One well-known method for this step is reinforcement learning from human feedback. This extra training is why an assistant answers your question instead of just continuing your text.
Two more terms help here. Training is the long, costly process of setting the weights. Inference is what happens when you use the finished model: the weights stay fixed and the model produces output. Training data also stops at a date, called the training cutoff. Unless search or your prompt supplies it, the model knows nothing about events after that date.
Predicting the next token, one step at a time
Here is what happens when you send a prompt. The model reads all the tokens so far. For every token in its vocabulary, it computes a probability: how likely that token is to come next. A setting called temperature controls how it picks. A low temperature favours the most probable token. A higher temperature lets less probable tokens through, so the output varies more. The chosen token is added to the text, and the whole process runs again. A reply of 300 words takes hundreds of these steps in a row.
Here is a worked example. An employee types: "Draft a reminder that the quarterly budget report is due on". The model might weigh options like these. The numbers are illustrative, not taken from a real model.
| Possible next token | Probability |
|---|---|
| Friday | 0.22 |
| the | 0.19 |
| March | 0.11 |
| Monday | 0.09 |
Say it picks "Friday." The reminder now states that the report is due on Friday. But the model has no access to your calendar. "Friday" won because it fit the pattern of reminders the model learned from. The sentence is fluent and the grammar is right, yet the date may be wrong. That is the core of generation in one example.
One analogy can help, as long as you see where it stops. The word suggestions on a phone keyboard also predict the next word. A language model does the same basic job at far greater scale, with your whole prompt as context. That is why it can stay on a topic for pages. The analogy stops at choice: a keyboard suggests and you pick, while the model picks every token itself.
Why fluent output can be wrong
Pre-training rewards one thing: predicting text that fits the patterns in the data. Nothing in that step checks whether a claim is true. Later tuning on human ratings reduces errors, but it cannot add facts the model never saw. So fluency and accuracy come from different places. Fluency comes from the patterns of language, which the model has seen across vast amounts of text. Accuracy depends on whether the right fact was in the training data, how many times it appeared, and whether the prompt draws it out.
When the model lacks the fact, it can still produce a likely-sounding continuation instead of saying it does not know. The result is called a hallucination, or confabulation: confident, fluent output that no source supports. Fake citations are a well-known case. A model asked for sources can produce titles, authors and journals that look real but do not exist. It has learned what a citation looks like, not which ones are real.
The risk is higher in these conditions:
- The fact is rare or niche, so it appeared few times in the training data.
- The question is about events after the training cutoff.
- The task needs an exact figure, name, date, quote or reference.
- The prompt assumes something false, and the model goes along with it.
Hallucinations follow from how generation works. They are not a bug that one update will remove. Some tools reduce them, for example by giving the model your documents to work from. That still leaves you with the job of checking.
A common misconception: "it looks the answer up"
It is easy to picture a chat assistant as a search engine or a database. In that picture, you ask a question, it finds the stored answer and shows it to you. That picture is wrong for the model itself.
A language model does not keep a library of documents to fetch from. What it learned is spread across its weights as patterns. When it answers, it generates text token by token, as in the example above. It can repeat well-known facts because those patterns are strong. It cannot reliably tell you where a fact came from, because it keeps no record of its sources.
Some products do add a lookup step. They run a web search or pull passages from your files, then place that text in the prompt. This is called retrieval-augmented generation, or RAG. It helps, because the model now has the source in front of it. But the model still writes the answer by prediction, so it can still misread or misquote the source. Check the quoted passage, not just the fact that a citation is there.
What it is good at and what it is poor at
The mechanism tells you where the tool fits. It is strong where a good answer is a plausible, well-formed pattern and you can judge the result. It is weak where one wrong detail matters and you cannot easily check.
Good fits:
- Drafting a first version of an email, report section or job post.
- Rewriting text for a different reader, length or tone.
- Summarising a document that you paste in and can check against.
- Brainstorming options, questions or headlines.
- Writing or explaining short pieces of code for common tasks, which you then test.
Poor fits, unless you add a source and a check:
- Exact facts, figures and dates, and legal or medical details.
- Citations and references.
- Recent events after the training cutoff.
- Long chains of arithmetic done without a calculator tool.
- Decisions about people, money or safety, where a person must be accountable.
The line between the two lists is whether you can check the output. If you can check it faster than you could write it, the tool can save effort. If you cannot check it, a fluent answer gives you false confidence.
Using it well this week
You can start with six habits:
- Put the source in the prompt. Paste the policy, the notes or the data, and ask the model to work only from that text.
- Ask for quotes. Ask it to quote the line that supports each claim, then check that the line exists.
- Check every name, number, date and reference against the source before the text leaves your hands.
- Treat the output as a draft that you edit, not a final answer.
- Follow your organisation's rules on data. Keep client and personal data out of any tool your organisation has not approved.
- Send questions the source does not answer to a person. If the policy is silent on a case, the model's answer is a guess, so pass the question to whoever owns the policy.
Illustrative example: an HR coordinator asks an assistant to "summarise our remote-work policy" without pasting it. The reply says staff may work from abroad for up to 30 days a year. The company's policy contains no such rule. It is a plausible rule built from patterns, not from the document. Next, she pastes the policy and asks for a quote behind each point. Then she searches the policy for each quote. If a quote for the work-abroad rule does not appear in the policy, she has found the error. If a quote does appear but does not say what the summary claims, that is an error too.
Explaining it to a colleague without hype
When a colleague asks what these tools are, a short, accurate answer helps more than excitement or dismissal. Here is one you can adapt:
"It's a model trained on a huge amount of text to predict the next piece of text. It writes by making that prediction over and over, one token at a time. That makes it good at drafting and rewording. It also means it can state false things fluently, so anything factual needs checking against a source."
Notice what this leaves out. It avoids words like "understands," "knows" or "thinks," which suggest a mind behind the text. It also avoids "just autocomplete," which undersells how useful the tool can be. Overclaiming leads people to trust the output too much; underclaiming leads them to dismiss it.
The other lessons in chapter 1 build on this. They define "generative" more fully, look closely at the gap between fluency and understanding, and show how generative AI relates to machine learning and deep learning.
Key takeaways
- Generative AI: Software that produces new text, images, code or audio from patterns learned in training data, instead of choosing from a fixed set of labels.
- Token: A chunk of text, such as a word, part of a word or a punctuation mark, that a language model reads and writes.
- Next-token prediction: The core loop of a language model: score how likely each possible next token is, pick one, add it, and repeat.
- Hallucination: Fluent, confident output that no source supports; it follows from how generation works, so factual claims need checking.
- Training cutoff: The date the training data ends; the model knows nothing later unless search or your prompt supplies it.
- Grounding: Putting the source text in the prompt and asking the model to quote it, so you can check each claim against that source.
What you'll cover
The chapters
The plan for the full course. Lessons open when the course does.
- 01What generative AI is and is not4 lessons
- 02From expert systems to foundation models4 lessons
- 03How language models generate text4 lessons
- 04Attention, transformers and embeddings4 lessons
- 05Major model families and open versus closed models4 lessons
Self-check
How much do you already know?
5 quick questions. Pick an answer to see why it's right or wrong. Nothing is saved.
Question 1 of 5
What does 'generative AI' fundamentally do, in the simplest terms?
Question 2 of 5
What is a 'diffusion model' primarily used for?
Question 3 of 5
How does traditional (discriminative) AI differ from generative AI?
Question 4 of 5
What year was the transformer architecture introduced, and what was its key innovation?
Question 5 of 5
What does a 'loss function' do in machine learning?
In the news
Recent stories on this topic
From NewsPals, our sister newsroom.
- Open weight AI is not API lite, Nathan Lambert’s access map (opens in new tab)
Inspectable weights turn model access into strategy, especially in U.S. China competition.
- OpenAI's chip claim is about compute control, not beating Nvidia (opens in new tab)
Jalapeño may or may not win every test, but the launch shows why AI product margins now start in the compute stack.
- DeepSeek V4 Pro makes a fourfold API hike a peak and off peak pricing test (opens in new tab)
The V4 Pro move shows how cheap AI access can graduate into resource aware pricing once usage meets scarce compute.
- Writer’s new AI model and upgraded harness turn token budgets into enterprise AI strategy (opens in new tab)
The Palmyra X6 launch shows why scaling agents now depends on orchestration, governance, and ruthless prompt accounting.
- Ad Age’s AI Token Cost Story Is Really About Agency Pricing Design (opens in new tab)
Generative AI is moving from creative upgrade to metered business system, and agencies are learning that the pricing model matters as much as the prompt.
- Runaway AI token costs are now agency operations work (opens in new tab)
The API bill is only the receipt. The real job is designing workflows that know when to spend.
Key terms
Words you'll meet in this course
- Transformer architecture
- A neural network design built around attention, which lets a model weigh every part of its input at once. Most current language models use it.
- Embeddings
- Lists of numbers that represent words or other items so that items with related meanings sit close together in a shared space.
- Temperature
- A setting that controls how much randomness goes into choosing each next token; higher values give more varied output, lower values more predictable output.
- In-context learning
- A model's ability to pick up a task from instructions or examples in the prompt, without any change to its weights.
- Fine-tuning
- Further training of an already trained model on a smaller, focused dataset so it performs better on a particular task or style.
- Confabulation
- Fluent, confident output that is not supported by facts or sources; in AI it is often called hallucination.
- Closed models
- Models whose weights are not released; you can use them only through the provider's app or API, on the provider's terms.
- Scaling laws
- Observed relationships in which model performance tends to improve predictably as model size, training data and compute increase.
Help us choose
Which course should open next?
Pick the one you'd take first. Your vote helps us decide what to finish next.