Large language model (LLM)
A large language model is a neural network trained on very large amounts of text to predict the next piece of text in a sequence. This ability lets it answer questions, summarise, translate and write code. It is the most common kind of generative AI, and a typical example of a general-purpose AI model.
What it is
A large language model (LLM) is a neural network that has learned the patterns of language from very large collections of text, and that generates text by predicting what comes next. Given an instruction, it produces an answer one piece at a time. The same ability supports question answering, summarising, translation, drafting and writing code.
The main parts are:
- Tokens: the pieces of text, such as words or word fragments, that the model reads and writes.
- Parameters: the numbers inside the network, adjusted during training, that hold what the model has learned.
- Training data: the text used to learn, followed by further training on examples of desired behaviour.
- Context window: the maximum amount of text, instruction and answer together, that the model can take into account at once.
- Inference: the use of the trained model to answer a request.
An LLM does not look up facts in a database. It produces the most plausible continuation of its input, which is usually accurate on well-covered topics and can be wrong on others. The EU AI Act treats models of this kind as general-purpose AI models, meaning models that perform a wide range of distinct tasks.
Why it matters
LLMs turn text work into something that software can do: reading long documents, extracting facts, drafting messages and answering questions on policies. Finance produces large volumes of text in contracts, filings, reports and client messages.
The same properties create risks. Output can be fluent and wrong, which is called hallucination. The reasoning behind an answer is hard to explain, which complicates model validation and governance. Supervisors and standard setters study these limits in work on artificial intelligence in finance.
Worked example
Illustrative numbers. A model has a context window of 8,000 tokens. One token is about three quarters of a word.
- A report of 3,000 words is about 3,000 / 0.75 = 4,000 tokens.
- The instruction “Summarise the main risks” adds about 100 tokens, so the request is 4,100 tokens and fits.
- A second report of the same length would bring the request to about 8,100 tokens, which exceeds the window.
- The analyst therefore splits the task, summarising each report separately and then combining the two summaries.
Retrieval-augmented generation avoids the limit by searching documents first and passing only the relevant passages to the model.
Who uses it
- AI business analysts identify tasks suited to an LLM and define how outputs are checked before use.
- AI transformation analysts in banking assess use cases against risk, data and control requirements.
- Data scientists adapt models to a task, design tests of answer quality and measure error rates.
- Quantitative developers build the software that sends requests to the model and handles its answers.
- Data scientists in banking test models on internal text and document how outputs are monitored.
Common confusions
- An LLM is not a search engine or database. It generates text from learned patterns, and an answer without a cited source cannot be treated as a retrieved fact.
- Generative AI is wider than LLMs. It also covers models that produce images, audio and other content.
- A larger model is not automatically a better one for a task. Quality depends on training, the task and the checks around it.
- A fluent answer is not a correct answer. Hallucinations read as confidently as accurate text.
- Training a model and using it are separate stages. Using a model in a request does not by itself change what it has learned.