Generative AI
- In Turkish
- Üretken Yapay Zekâ
In short
Generative AI is artificial intelligence that creates new content, such as text, images, code, or audio, based on patterns learned from existing data.
What is generative AI?
Generative AI refers to models that produce new content instead of only classifying or scoring existing data. Given a prompt, such as a question or a description, a generative model can write an answer, draft code, create an image, compose music, or synthesize a voice. The best-known examples are large language models for text and code, along with image and video generators.
These models are trained on huge datasets to learn the statistical patterns of their domain. A large language model generates text one token at a time, each time choosing a likely next token based on everything before it, while most image generators use diffusion models that start from random noise and gradually refine it into a picture that matches the prompt. Settings like temperature control how predictable or varied the output is.
A helpful analogy is an extremely well-read improviser: it has absorbed countless examples and can produce something new in a similar style on request, but it doesn't look facts up unless it is connected to a source. That is why generative AI can hallucinate, confidently producing plausible but false statements, and why techniques like retrieval-augmented generation (RAG) and human review matter in real products such as coding assistants, chatbots, and document drafting tools.
Generative AI is often confused with AI in general. Traditional, or discriminative, machine learning models classify or score existing inputs, such as flagging a transaction as fraud, while generative models create new outputs. Generative AI is also not the same as an AI agent: an agent uses a generative model to plan and take actions with tools, while the model on its own only produces content.
Key takeaways
- Generative AI creates new text, images, code, audio, or video from a prompt.
- LLMs generate text token by token; many image models use diffusion.
- Outputs are based on learned patterns, not verified facts, so hallucinations happen.
- Grounding answers with RAG and adding human review improve reliability.
- Discriminative models classify existing data; generative models produce new data.
Example
// Send a prompt to a text-generation API (endpoint and fields are illustrative)
const response = await fetch("https://api.example.com/v1/generate", {
method: "POST",
headers: {
"Content-Type": "application/json",
Authorization: `Bearer ${process.env.AI_API_KEY}`,
},
body: JSON.stringify({
prompt: "Write a haiku about code reviews.",
maxTokens: 60,
temperature: 0.8, // higher values give more varied output
}),
});
const { text } = await response.json();
console.log(text);Readers ask
What is the difference between generative AI and traditional AI?
Traditional machine learning systems mostly analyze existing data, for example classifying an image or predicting a price. Generative AI creates new content, such as writing text or generating an image, though both are built on machine learning.
Are large language models generative AI?
Yes. Large language models are the most widely used kind of generative AI; they generate text and code by predicting one token after another. Generative AI also includes models that create images, audio, and video.
Can generative AI output be trusted?
Not blindly. Generative models can produce convincing but incorrect statements, outdated information, or insecure code, so important outputs should be checked against reliable sources, tested, or reviewed by a person.
See also
- LLMAI & Machine Learning, p. 25An LLM is a machine learning model trained on huge amounts of text that generates language by repeatedly predicting the next most likely piece of text.
- TransformerAI & Machine Learning, p. 49A transformer is a neural network architecture that uses attention to weigh how each token in a sequence relates to the others, and it powers most modern LLMs.
- HallucinationAI & Machine Learning, p. 23A hallucination is when an AI model, such as an LLM, confidently produces information that sounds plausible but is false, invented, or unsupported by sources.
- PromptAI & Machine Learning, p. 35A prompt is the input text or instructions you give an AI model, such as an LLM, to tell it what task to perform and what kind of answer you want.
- TemperatureAI & Machine Learning, p. 45Temperature is a setting that controls how random an LLM's output is, from focused and predictable at low values to more varied and creative at high values.
- Multimodal AIAI & Machine Learning, p. 31Multimodal AI is artificial intelligence that can understand or generate several types of data, such as text, images, audio, and video, in a single model.
- Artificial IntelligenceAI & Machine Learning, p. 4Artificial intelligence (AI) is the field of computer science that builds systems able to do tasks that normally require human intelligence.
- GPTAI & Machine Learning, p. 21GPT (Generative Pre-trained Transformer) is OpenAI's family of large language models that generate text by predicting the next token.
- Vibe CodingAI & Machine Learning, p. 52Vibe coding is building software by describing what you want to an AI and accepting the code it writes, mostly judging the result by whether it seems to work.
- Diffusion ModelAI & Machine Learning, p. 15A diffusion model is a generative AI model that makes images, audio, or video by starting from random noise and removing it step by step until content appears.
Spotted a mistake or something missing on this page?Suggest an edit