AI Engineering Tutorial · LLM Basics · Lesson 1 of 25
What Is AI Engineering?
What AI engineers build, how it differs from machine-learning research, and what this tutorial covers.
The short answer
AI engineering is building reliable software features on top of large language models (LLMs) and other foundation models, usually through an API. You don't train the model; you design what goes into it (prompts, context, tools), what comes out (validated, structured output) and everything around it (retrieval, evaluation, guardrails, cost and monitoring).
| Role | Main work |
|---|---|
| ML researcher / scientist | Train and improve models |
| ML engineer | Data pipelines, training and serving custom models |
| AI engineer | Build products with existing models: prompts, tools, retrieval, evals, guardrails |
What you build
- Assistants that answer questions from your company's documents (retrieval-augmented generation).
- Workflow steps: classify tickets, extract fields from invoices, draft replies for review.
- Agents that call tools (search, databases, APIs) in a loop to complete tasks.
feature = ["user request", "prompt + context", "model", "validate output", "tools / retrieval", "evaluate & monitor"]
for i, step in enumerate(feature, 1):
print(f"{i}. {step}")
print("Only one of these steps is the model; AI engineering is the rest.")
Output
1. user request 2. prompt + context 3. model 4. validate output 5. tools / retrieval 6. evaluate & monitor Only one of these steps is the model; AI engineering is the rest.
How this tutorial works
Every example is Python you can run in the browser. Where a real model would be called, a small stub model returns fixed replies, so the examples run instantly, for free, and always give the same output. Real API code is shown alongside where it helps.
Test yourself
What does an AI engineer usually NOT do?
Design prompts and contextValidate model outputTrain the foundation model from scratchBuild evaluations
Show answer
Answer: Train the foundation model from scratch
AI engineers build on existing models through APIs; training foundation models is research and ML engineering work.