17-630 Context Engineering
12 units, Carnegie Mellon University
Prompt Engineering examines the science behind language model prompting and the strategies by which to design prompt-based systems. Students in this course will learn a brief history of large language models (LLM) as well as contemporary approaches to LLM design and development, such as instruction-tuning, alignment, and calibration. Under alignment, students will study hallucinations, bias, sycophancy, immorality and deception by LLMs. Students will learn about contemporary prompt engineering strategies and techniques, including chain-of-thought, retrieval augmented generation (RAG), tool usage, various ways to self-prompt for response verification and consistency and agent-based prompting, including the use of personas, and benefits of agent-based debate and collaboration. The course covers standard prompt engineering benchmarks and evaluation metrics to evaluate the efficacy of prompt designs. Finally, students will practice using cloud-based language models to complete coursework. Various options exist, including OpenAI's GPT, Google's Gemini, multiple models, including Anthropic's Claude, available on Amazon Bedrock. Class tutorials exist to guide students on how to setup and use one of these services.
Prerequisites: none listed
Offered: Spring 2027, Summer 2026, Spring 2026
Courseweave needs JavaScript to show sections, workloads and planning tools.