Skip to content

Guide · Open source

How to use Prompt-Engineering-Guide: read, learn and apply prompting techniques

Updated · written with AI from the project's own documentation and checked against our catalogue data

Prompt-Engineering-Guide is an open-source collection of guides, papers, lectures, notebooks and reference links on prompt engineering, the practice of writing and structuring inputs to get better results from large language models. It also touches on context engineering, retrieval augmented generation (RAG) and AI agents. This tutorial shows you how to read it, which parts to start with, and how to get a local copy of the source files.

Prompt Engineering Guidedair-ai/Prompt-Engineering-Guide · ★ 79.8k · MIT

Quick start

  1. 1Open the web guide. Go to promptingguide.ai and start with the Introduction section.
  2. 2Learn the basics. Read LLM Settings, Basics of Prompting and Prompt Elements before moving on.
  3. 3Work through techniques. Read zero-shot, few-shot and chain-of-thought pages, then try their examples on a model you already have access to.
  4. 4Explore advanced topics. Move to self-consistency, ReAct and RAG when you are ready for agents and retrieval.
  5. 5Clone the repo if you want local files. Run git clone https://github.com/dair-ai/Prompt-Engineering-Guide to read the source files offline.
  6. 6Use the papers list. Browse the Papers section by Overviews, Approaches, Applications or Collections for further reading.

What Prompt-Engineering-Guide is (and is not)

Prompt-Engineering-Guide is mainly a reading resource. The project is published as a website at promptingguide.ai, and the repository holds the source files behind it. It is not a software program you install and run.

The README describes it as a set of guides and a curated resource collection, so the way to use it is to read it, follow its examples and look up the papers it links to.

Read the guide online

The simplest way to use the project is the web version at promptingguide.ai. The README points to this site as the place where the most up-to-date guides live.

Start with the Introduction section, which is split into LLM Settings, Basics of Prompting, Prompt Elements, General Tips for Designing Prompts and Examples of Prompts.

  • Introduction: settings, basics, prompt elements, tips and examples
  • Techniques: zero-shot, few-shot, chain-of-thought, self-consistency, ReAct and others
  • Applications: function calling, generating data, generating code
  • Prompt Hub, Models, Risks and Misuses, Papers, Tools, Notebooks, Datasets and Additional Readings

Clone the repository to read the source files locally

If you want the Markdown-style source files on your own machine, the README gives one command. The project is written in MDX.

Run the clone command below. Once it finishes, the source files are in a local folder you can open in any editor.

git clone https://github.com/dair-ai/Prompt-Engineering-Guide

Learn the core techniques in a sensible order

The Techniques section covers the methods most people meet first. Zero-shot and few-shot prompting come before chain-of-thought, which asks the model to reason step by step. Self-consistency and Tree of Thoughts build on that idea.

ReAct prompting is listed among the techniques and is useful if you are interested in agents that combine reasoning with actions. Retrieval Augmented Generation has its own page under Techniques.

  • Zero-Shot Prompting, then Few-Shot Prompting
  • Chain-of-Thought Prompting, then Self-Consistency
  • ReAct Prompting and Retrieval Augmented Generation for agent and retrieval topics

Use the papers and notebooks as a reference

The Papers section is organised into Overviews, Approaches, Applications and Collections. It is a curated list, so it is a good starting point for research reading.

The Notebooks section links to runnable examples. The README does not describe what each notebook requires, so check the notebook itself before running it.

  • Papers: Overviews, Approaches, Applications, Collections
  • Notebooks and Datasets for hands-on material

What people use it for

  • Learning prompting from scratch with structured lessons and examples
  • Getting an overview of techniques such as chain-of-thought and ReAct before building an app
  • Finding a curated list of prompt engineering papers for a literature review
  • Building a course outline for a class on language model basics

Frequently asked questions

Do I need to install anything to use Prompt-Engineering-Guide?

No. The project is a guide and resource collection published as a website. You can read it at promptingguide.ai without installing anything. The only command in the README is git clone, which is optional and copies the source files to your computer.

Is Prompt-Engineering-Guide free and what is its licence?

The repository is licensed under MIT. The README does not list any prices for the guide itself. It also promotes DAIR.AI Academy courses, which are separate from this repository and may be paid.

What are the system requirements for Prompt-Engineering-Guide?

The README lists no prerequisites. Reading the website needs only a web browser. Cloning the repository needs git.

Is Prompt-Engineering-Guide up to date?

The README points to the web version at promptingguide.ai as the most up-to-date source. It does not say how often content is reviewed, and model-specific pages may age quickly, so check dates on those pages.

What are alternatives to Prompt-Engineering-Guide?

Comparable projects named for this item are LearnPrompting, the OpenAI Cookbook and the Anthropic Prompt Engineering Tutorial. Pick one based on whether you want general prompting lessons, OpenAI-focused examples or Anthropic-focused examples.

Does Prompt-Engineering-Guide include hands-on courses?

The README promotes DAIR.AI Academy courses on prompt engineering, RAG and AI agents. These are separate from the repository. The README says the courses are meant to complement the guide and offer a more hands-on approach.

New agent skills, repos and AI tools — every week

The best new skills and open-source projects, the fastest-growing repos, and one free prompt. Five minutes to read. Unsubscribe anytime.

Our verdict

Prompt-Engineering-Guide suits beginners who want structured reading on prompting, developers who want an overview of techniques like chain-of-thought and ReAct, and teachers building a basic course. It is not a software tool, and if you need a hands-on paid course or current model-specific details, look at the DAIR.AI Academy offering or check the model pages' dates yourself.

Install options & downloads