Availit World How AI really works, in your language

Lesson 1 of 4615 minFacts checked October 20, 2026

What AI actually is

Not magic and not a brain in a box: a very large set of numbers that has learned, from examples, to predict what comes next.

In this lesson you will

  • Say what the letters AI stand for, and what people mean by them today
  • Tell the difference between a program someone wrote by hand and one that learned from examples
  • Describe, in one sentence, what a language model like ChatGPT, DeepSeek or Qwen does
  • Know the two words you will meet in every lesson: training and inference
On this page
  1. Three letters
  2. Rules written by hand, or rules learned
  3. What a language model does
  4. A model is a file of numbers
  5. Where this course goes
  6. Remember
  7. Check yourself

Three letters

AI stands for artificial intelligence: getting computers to do things that need intelligence when a person does them. Understanding a sentence, recognising a face, translating, writing code, planning the steps of a task.

The name is older than most people think. It was coined in 1955, in a proposal for a summer workshop at Dartmouth College in the United States. Its authors guessed that “every aspect of learning” could in principle be described so precisely that a machine could do it. It took about seventy years, and much faster computers, for that guess to start paying off.

Today, when people say “AI”, they almost always mean one particular kind: machine learning, and inside that, large language models (LLMs), the programs behind ChatGPT, Claude, Gemini, DeepSeek, Qwen, Kimi and many others. This course is mostly about them, because they are where the action is, but it also covers the models that see, draw, listen and move.

Rules written by hand, or rules learned

There are two ways to make a computer do something clever.

The old way: write the rules

  • A programmer thinks of every rule and types it in: “if the email contains free money, it is spam”.
  • Works well when the rules are clear, like a calculator or a tax form.
  • Breaks on messy things. Nobody can write down the rules for recognising a cat or understanding a joke.

The new way: learn from examples

  • You show the program many examples: thousands of emails, each marked spam or not spam.
  • The program adjusts itself, little by little, until its answers match the examples.
  • The “rules” it ends up with are millions or billions of numbers that nobody wrote by hand.

That second way is machine learning. The thing that learns is called a model, and the numbers inside it are called its weights or parameters. Learning means changing those numbers so the model gets better at its task.

Which way would you build each of these?

0 of 6 sorted
  • Adding up the prices in a shopping basket

    Answer: Write the rules

  • Turning speech into text

    Answer: Learn from examples

  • Checking that a password has at least 12 characters

    Answer: Write the rules

  • Translating Urdu into English

    Answer: Learn from examples

  • Spotting tumours in X-ray images

    Answer: Learn from examples

  • Converting kilometres to miles

    Answer: Write the rules

What a language model does

A large language model does one thing, over and over: given some text, it works out how likely every possible next piece of text is, then one piece is picked. The pieces are called tokens (often a whole word, sometimes part of a word). The new token is added to the text, and the model goes again.

Try itBe the model for a moment

The model has read “The sky is” and given every possible next token a score. Here are the top six, turned into chances. Press the button to pick one at random, weighted by those chances. Then change the temperature and pick again.

This interactive part needs JavaScript.

That is the whole trick. A reply of 300 words is this loop run about 400 times. A model that predicts the next token really well has to pick up grammar, facts, reasoning patterns and style along the way, because all of those help it predict.

One answer, step by step
  1. Your messagePlain text
  2. TokensThe text cut into pieces, each with a number
  3. The modelBillions of weights turn the tokens into a score for every possible next token
  4. Pick oneUsually at random, weighted by the scores
  5. RepeatAdd it to the text and go again until the answer is done

Quick check

A model writes a 100-token reply. Roughly how many times did it predict a next token?

Show the answer

Answer: About 100 times, one per token Language models generate one token at a time. Each new token is predicted from all the text so far, including the tokens it has just written.

A model is a file of numbers

Strip away the app and the chat window, and a model is a file. Inside are its weights: a long list of numbers. A model called Llama 3.1 8B has about 8 billion of them (the “8B” in the name). Stored at 16 bits each, that is about 16 GB. Squeezed down to about 5 bits each, it is about 4.9 GB, small enough for a normal laptop.

You need two things to use a model: the file of weights, and a program that knows how to run it. On your own computer that program might be llama.cpp or Ollama. In a data centre it might be vLLM or SGLang. You will use some of these yourself later in the course.

The two lives of a model
TrainingInference
What happensThe weights are adjusted, again and again, so the model predicts its training text betterThe weights stay fixed; the model is used to answer
How oftenOnce (plus some later fine-tuning)Every time anyone uses it, millions of times a day
CostHuge: thousands of GPUs for weeks or monthsSmall per answer, but it adds up
Who does itThe lab that makes the modelAnyone with the file and a program to run it

Where this course goes

Everything you will learn builds on this one picture: text goes in, numbers do the work, a next token comes out. The course takes it apart piece by piece.

  1. The basics and the maths: what vectors, matrices and probabilities are, and how computers store numbers. Gently, and only what is needed.
  2. How machines learn: neural networks, and the method that adjusts billions of weights at once.
  3. Inside a language model: tokens, embeddings, attention, the transformer, mixture of experts.
  4. Training: how a model reads trillions of tokens, becomes an assistant, and learns to reason.
  5. Inference: what happens when you press Enter, and how to run models on your own machine.
  6. Agents: models that use tools, and the harnesses that run them.
  7. Beyond text, and the frontier: images, sound, robots, how models are measured, and how to read the papers.

Remember

  • AI means getting computers to do things that need intelligence. Today it mostly means machine learning: programs that learn from examples instead of following hand-written rules.
  • A model is a file of numbers called weights. Learning means adjusting them.
  • A language model predicts the next token, again and again. That loop is how every reply is written.
  • Training makes the weights (rare, very expensive). Inference uses them (every time you ask something).
  • The weights do not change while you chat. The conversation so far, the context, is sent again with every message.

Words to know

Artificial intelligence (AI)
Computers doing tasks that need intelligence when people do them.
Machine learning
Making a program learn its own rules from examples, instead of writing the rules by hand.
Model
The thing that learns: a structure plus a large set of numbers.
Weights (parameters)
The numbers inside a model. “8B” means about 8 billion of them.
Large language model (LLM)
A very large model trained on text to predict the next token.
Token
A piece of text, often a word or part of a word. Models read and write tokens.
Training
Adjusting the weights so the model gets better at its task.
Inference
Using a trained model to produce an answer. The weights stay fixed.
Context
All the text a model is given at once: instructions, the conversation so far, documents.
Open-weight model
A model whose weight files are published, so anyone can download and run it.

Go to the source

This lesson is built on these papers and documents. Paper links open arxiv.org, a separate site.

Check yourself

5 questions. Tap the answer you think is right.

0 of 5 answered

What is the main difference between machine learning and ordinary programming?

Show the answer

Answer: In machine learning the program finds its own rules from examples In ordinary programming a person writes the rules. In machine learning the program adjusts its own numbers until its answers match the examples.

What are a model’s weights?

Show the answer

Answer: The numbers inside it that are adjusted during training Weights, also called parameters, are the numbers that hold everything the model has learned. A “7B” model has about 7 billion of them.

What does a language model produce at each step?

Show the answer

Answer: A score for every possible next token, from which one is picked It scores every possible next token. One is picked, added to the text, and the model runs again.

You chat with a model for an hour. What happens to its weights?

Show the answer

Answer: Nothing: they stay fixed during inference Inference never changes the weights. The model only “remembers” what is in its context: the conversation sent to it with each message.

Which of these is inference?

Show the answer

Answer: You asking a model on your laptop to summarise a document Inference is using a finished model. The other two change the weights, which is training.

Lesson complete

Answer every question above to complete this lesson.

Your progress is saved on this device only.

Next lessonHow we got here: 75 years in 15 minutes
All lessons

Choose your language