Understanding Generative AI: Breaking Down the Technology Behind the Hype
by Dulcie Vousden, Head of Data Science, DataKind UK
Since ChatGPT was released at the end of 2022, it feels like everyone’s talking about AI. And for the third sector, already focused on delivering essential services, supporting communities, and just staying afloat, this can feel incredibly overwhelming. Resources are already constrained, capacity is already limited, and now there is a whole new technology to learn?!
Building an understanding of how technologies like AI, and tools like ChatGPT, work is key to deciding whether to use them. With this grounding, you can understand the technologies’ strengths and limitations, as well as the risks underlying different use cases. The good news is that this knowledge is available to anyone!
If you’ve ever wondered how ChatGPT or Copilot are generating responses, or the difference between ‘AI’, ‘generative AI’, ‘machine learning’, and ‘data science’, this guide will walk you through the basics.
Starting at the beginning: what is AI?
At its core, AI is the effort to get computers to perform tasks that typically require human intelligence – things like reasoning, learning, understanding language, and recognising patterns.
AI has been around since the 1950s, evolving through various boom and bust cycles (known as ‘AI winters’). Early AI systems were rule-based – essentially very sophisticated ‘if this, then that’ programmes. This is apparent in older chatbots that give predetermined answers to common questions.
The limitation with these rule-based systems is that they can’t do tasks outside their predefined scope. So here's the key shift: modern AI doesn't just follow preprogrammed rules. Instead, it learns from data.
Machine Learning: Teaching computers to learn
Machine Learning (ML) is a subset of AI that focuses on building systems that can learn from data without being explicitly programmed for every possible scenario. Instead of writing rules for every situation, we show the computer lots of examples and let it figure out the patterns.
There are two main types of machine learning:
Supervised Learning
This is like having a teacher with labelled examples. Imagine showing a computer thousands of pictures of biscuits, labelled ‘custard cream’, ‘hobnob’, or ‘bourbon’. Eventually, it learns to identify the features that distinguish custard creams (rectangular, filled) from hobnobs (round, not-filled), and can classify new images it's never seen before.
Unsupervised Learning
Here, the computer finds patterns in unlabeled data on its own. It's like giving someone a mixed tin of biscuits without labels and asking them to sort them into groups. The system might group them by shape, texture, or filling – discovering categories without being told what to look for.
How machines learn
Let's stick with the biscuit analogy to understand how this works. Say you're training a computer to identify different types of biscuits:
Initial guess: You show it a custard cream. Having never seen one before, it makes a random guess: "This is a hobnob."
Learning from mistakes: The system calculates how wrong it was (called the ‘error’ or ‘loss’). Since it predicted hobnob, but the answer was custard cream, the error is quite high.
Adjustment: The model tweaks its internal settings to make better predictions next time. Maybe the next guess is ‘bourbon’, which is arguably closer (rectangular and filled, but chocolatey instead of creamy), but still wrong.
Repetition: This process repeats thousands of times with different biscuits until the model gets good at distinguishing custard creams from digestives, hobnobs from jammy dodgers, and so on.
Eventually, the model can correctly identify biscuits it's never seen before (even a partially eaten biscuit) by recognising the patterns it learned.
Enter Generative AI
Generative AI is a specific type of machine learning that goes beyond classifying or predicting – it creates or generates new content. Instead of only identifying whether something is a custard cream or jammy dodger, generative AI can create entirely new images of biscuits, write stories about biscuits, or even compose songs about your favourite biscuit.
Large Language Models (LLMs) are a type of generative AI that can process and generate new content. Often they take text as input, and create text as output. These models underpin Generative AI chatbots like ChatGPT (which currently uses an LLM called GPT-4) and Claude (which currently uses one of the Claude 4 models like Sonnet). There are many different types of LLMs - you might have heard of DeepSeek, Llama, or Mistral.
How LLMs actually work
So, how does this work? LLMs are trained on massive amounts of text - books, websites, or articles - which enables them to predict what word is likely to come next in a given context. Intuitively, the training process is something like:
Show the model the beginning of a sentence: "The boy went to the..."
Ask it to predict the next word (or token if you want to be technically correct).
Compare its guess to the actual next word.
Adjust the model based on how wrong it was.
Repeat billions of times.
The magic of context
To predict the next word accurately, the model needs to understand context. For "The boy went to the..." it might predict ‘school,’ ‘park,’ or ‘store’ based on what it's learned about where boys typically go. But this requires building an understanding of grammar, common patterns, relationships between concepts, and even cultural context.
From prediction to conversation
Once trained, when you ask ChatGPT a question, it generates an answer by predicting what a likely response would look like, word by word. It uses everything it learned during training to generate text that follows the patterns of the text it has been exposed to.
What this means in practice
Understanding how LLMs work helps explain both their capabilities and limitations.
They're good at:
Maintaining conversational context.
Following complex writing styles.
Translating between languages.
Explaining concepts in different ways.
They struggle with:
Hallucinations - hallucinations are plausible-sounding responses that are wrong or irrelevant. LLMs are optimised for creating well-fitted responses, not factual ones.
Bias - LLMs are trained on vast amounts of text data, but these sources can contain embedded bias (as can other sources like images). For example, if a dataset that genders certain professions is used as training data, this is likely to be reflected in the LLM’s output.
Mathematical calculations - LLMs predict what looks right. They don’t inherently understand mathematical rules and so can make errors with calculations, particularly outside the scope of what they’ve been trained on.
Real-time information - as they're trained on existing data, answers may not be up to date, although recent updates to tools like ChatGPT have added robust web search capabilities, blurring the lines between a traditional search engine and an AI assistant.
The bottom line
Generative AI might seem like magic, but really, it’s just sophisticated pattern recognition and prediction. LLMs have learned incredibly complex patterns about how humans communicate by analysing vast amounts of text, then use these patterns to generate responses that sound natural and helpful.
Understanding this helps set realistic expectations. These tools are incredibly powerful for many tasks, but they're essentially very sophisticated guessing machines. They don't ‘understand’ in the human sense – they're just extremely good at predicting what a useful response should look like, based on patterns.
This is why human oversight remains crucial, especially for important decisions. AI is a powerful tool, but like any tool, its effectiveness depends on understanding what it can and can't do, and using it accordingly.
Learn more from our AI webinar series
AI Transparency statement
Some of the content of this blog was generated using Claude Sonnet 4 and our recent webinars as input. All content was human-reviewed and edited prior to publication.