A free, self-paced textbook in 6 chapters. Read a chapter, then drill it with the 201 companion flashcards using spaced repetition.
A prompt is the natural-language input—a question, instruction, or block of context—that a user provides to a language model to elicit a response. Prompts frame the task and guide...
Prompts can be designed with several reusable patterns. The role pattern assigns the model a persona or function, conditioning its tone, vocabulary, and reasoning style for a speci...
Several API-level parameters shape how the model converts probabilities into text. Temperature scales the logits before sampling: zero makes the model greedy and deterministic, pic...
Retrieval-augmented generation (RAG) pairs a retriever that fetches relevant external documents with a generator LLM that conditions its answer on those documents. RAG reduces hall...
Function calling lets a model output structured arguments matching a user-defined schema, which the application then executes against real APIs, databases, or code, returning resul...
A hallucination is a fluent, plausible-sounding model statement that is factually incorrect, fabricated, or unsupported. Intrinsic hallucinations contradict the source prompt or co...