LLMs & Models

What Are Large Language Models (LLMs)? How AI Actually Works (2026)

What a large language model is, how it turns a prompt into an answer, what tokens and context windows are, what LLMs do well and where their answers need checking, from vendor documentation and NIST.

By Published Updated

A large language model (LLM) is an AI model trained on large amounts of text to predict the next token, and it uses that training to write text, answer questions and summarize. Claude, GPT and Gemini are LLMs. Each one works within a context window measured in tokens and can state false information confidently, so check facts that matter.

A large language model (LLM) is an AI model with many parameters, trained on very large amounts of text, that can generate text, answer questions and summarize information. That is close to the definition in Anthropic's glossary. Anthropic's Claude models, OpenAI's GPT models and Google's Gemini models are all LLMs.

How an LLM turns a prompt into an answer

The model reads and writes text as tokens. A token can be a word, part of a word, a single character or a punctuation mark. OpenAI's rule of thumb for English is that one token is about four characters, or about three quarters of a word, so 100 tokens come to roughly 75 words. The ratio depends on the model. According to Anthropic's glossary, its newer Claude models use a tokenizer that produces about 30 percent more tokens for the same text than earlier ones.

Training happens in stages. In pretraining, the model learns from a large body of unlabeled text to predict the next word, given the words before it. A model at that stage is not good at following instructions, so its developers fine-tune it on more data and use reinforcement learning from human feedback (RLHF), where people rank example answers and the model is trained to prefer the higher-ranked kind. Anthropic's glossary describes all three steps.

When you send a prompt, the model writes its answer one token at a time, each one predicted from the text before it. The NIST Generative AI Profile puts it this way: these models "generate outputs that approximate the statistical distribution of their training data."

The network design these models are built on is the Transformer, introduced in the June 2017 paper Attention Is All You Need. Its authors described it as "based solely on attention mechanisms, dispensing with recurrence and convolutions entirely."

The context window

The context window is all the text a model can refer to while it writes a response, including the response itself. Anthropic's context window documentation calls it the model's working memory, separate from the data it was trained on. Everything in a request counts toward it: your instructions, the conversation so far, any documents you attach and the answer.

The current flagship models from Anthropic, OpenAI and Google list windows of about a million tokens. Anthropic's models overview shows 1M tokens for its current Claude models, OpenAI's model page shows 1.05M for its flagship GPT models, and Google's Gemini model page shows 1M for its Gemini 4 models. On Claude's current tokenizer, Anthropic puts 1M tokens at roughly 555,000 words.

A bigger window gives you room, and you still have to choose what goes in it. According to Anthropic's documentation, accuracy and recall degrade as the token count grows, a problem Anthropic calls context rot. So put in the documents that answer the question and leave out the rest.

Knowledge cutoff

A model's knowledge comes from its training data, which stops at a cutoff date. Anthropic lists two dates for each Claude model: a training data cutoff and a reliable knowledge cutoff, the date through which the model's knowledge is "most extensive and reliable." For anything newer, the model needs a tool that brings current information into the context window, such as web search. Claude's free plan includes web search, according to its pricing page.

What LLMs do well

Anthropic's glossary names generating text, answering questions and summarizing information. Every current Claude model accepts text and image input, writes text, works in multiple languages and can use tools, according to the models overview, and Google lists text, image, audio, video and PDF input for its Gemini 4 models.

In day-to-day work that means drafting emails and documents, summarizing long reports, pulling fields out of text, translating, writing and explaining code, and answering questions about material you supply. Anthropic's glossary describes passing documents into the context window as a way to ground an answer in evidence, so give the model the document instead of asking it to recall one.

Where answers need checking

The NIST profile (NIST AI 600-1, July 2024) calls the main accuracy problem confabulation: "the production of confidently stated but erroneous or false content," usually called hallucination. NIST describes it as a natural result of how generative models work, since they predict likely text. In the same profile, NIST notes that a model can produce invented citations or reasoning steps that read like a justification for a wrong answer. So check numbers, dates, quotes and citations against the source before you rely on them.

Answers can also change between runs. Temperature is the setting that controls how random the output is. Lower values give more conservative, predictable wording, and higher values give more varied output. Anthropic's glossary adds that even at a temperature of 0, results are not fully deterministic, so the same prompt can return different answers.

Privacy is the third check. NIST lists data privacy among the twelve generative AI risks in its profile, including leakage of personal or sensitive information. Before you paste client or company data into a tool, find out whether your plan uses your data for training. See What Is Safe to Put Into ChatGPT for how to check.

Terms you will see

Fine-tuning

Fine-tuning is further training of a pretrained model on additional data, so it picks up the patterns of that data for a domain, a task or a writing style. According to Anthropic's glossary, the Claude API does not currently offer fine-tuning.

Retrieval-augmented generation (RAG)

RAG retrieves relevant documents when a question comes in and passes them into the context window with the prompt, so the model can answer from material beyond its training data. According to Anthropic's glossary, RAG helps with current or domain-specific information and with citing sources, and the results depend on the quality of the documents retrieved.

Open-weight models

Most people use LLMs through hosted apps and APIs. Some developers also publish open-weight models that you can download and run on your own hardware. Meta's developer site, for example, lists an open-weight model alongside its hosted ones.

Choosing a model

Compare models on the work you actually need done. Check the context window, the data terms of the plan, the price if you use an API, and how each model handles a sample of your own documents. For a side-by-side, see the model selection guide and Claude vs ChatGPT vs Gemini.

Sources

  1. Vaswani et al., Attention Is All You Need (arXiv 1706.03762, June 2017) (checked 2026-12-01)
  2. Glossary: LLM, tokens, pretraining, fine-tuning, RLHF, RAG, temperature (Anthropic documentation) (checked 2026-12-01)
  3. Context windows (Anthropic documentation) (checked 2026-12-01)
  4. Models overview: context windows and knowledge cutoffs (Anthropic documentation) (checked 2026-12-01)
  5. What are tokens and how to count them (OpenAI Help Center) (checked 2026-12-01)
  6. Models (OpenAI API documentation) (checked 2026-12-01)
  7. Gemini models (Google AI Studio documentation) (checked 2026-12-01)
  8. NIST AI 600-1, Artificial Intelligence Risk Management Framework: Generative Artificial Intelligence Profile (July 2024) (checked 2026-12-01)
  9. Meta AI developer platform: hosted and open-weight models (Meta) (checked 2026-12-01)
  10. Claude plans and pricing (Anthropic) (checked 2026-12-01)
the list

Get the next one.

Field notes from real deployments, written the way this one was. No schedule promised and nothing sold to you. Unsubscribe whenever.

Frequently asked questions

What is an LLM?

A large language model is an AI model with many parameters, trained on very large amounts of text, that can generate text, answer questions and summarize information. Anthropic's Claude models, OpenAI's GPT models and Google's Gemini models are all LLMs.

How do LLMs work?

An LLM splits text into tokens and predicts the next token from the ones before it, one token at a time. It learns that in pretraining on large amounts of text. Its developers then fine-tune it and use reinforcement learning from human feedback so it follows instructions. Everything it reads and writes in one request has to fit in its context window.

Which LLM is the best?

There is no single best model for every task. The current flagship models from Anthropic, OpenAI and Google all list context windows of about a million tokens, so compare them on your own documents, the data terms of the plan you would buy, and the price. Run the same sample task through each before you decide.

Can LLMs make mistakes?

Yes. NIST calls it confabulation: confidently stated but false content, often called hallucination. It can include invented citations. Check numbers, dates, quotes and citations against the source, and give the model the source document in the prompt when accuracy matters.

What is a token?

A token is the unit a model reads and writes: a word, part of a word, a character or punctuation. OpenAI's rule of thumb for English is about four characters, or three quarters of a word, per token. Counts vary by model, and Anthropic's newer Claude tokenizer produces about 30 percent more tokens for the same text than earlier ones.

Need help implementing this?

Prometheus does AI consulting and implementation, remote, with onsite days available in Milwaukee. We set it up, train your team, and make sure it works.

let's talk