Profile

Settings

Loading…

← Papers

Help

FAQ

Which features require signing in?

You can read the commentary, paper info, Model Structure and related papers of public papers without signing in. Sign in to manage your account or contact us about your inquiries.

Can I upload a PDF file?

Upload papers with an arXiv or DOI link; the commentary is public to everyone. Papers whose source and terms of use can't be verified, so the commentary can't be made public, can't be uploaded. Uploading PDF files and keeping papers private are for subscribers only, and a paper uploaded as a file is saved as private only. Searching for official info by title runs only when you press the button.

Are the figures and AI commentary accurate?

Figures come only from the original paper, and only those whose terms of use are verified are shown. The commentary is written by AI and may be wrong. Check important claims, numbers and figure context against the evidence in the original paper.

I want to report a copyright issue.

Terms of use and the source of the original paper are on the Paper info tab. If there's a problem, choose "Paper content, figures and copyright" under Contact us and send the paper link, the part in question, and evidence that you hold the rights. Receiving your report doesn't confirm any rights or remove anything right away. You can see the result of the review under My inquiries.

I forgot my password.

If you signed up with email, use Forgot password in the sign-in window to reset it with your verified email. If you signed up with Google, Naver or Kakao, change your password with that service.

What should I include in an inquiry?

Tell us which screen you were on and what you were doing when the problem happened, along with the paper link. Don't include personal information such as passwords, API keys, verification codes or phone numbers. Inquiries and replies are stored in Refivu and you can see them under My inquiries.

How do I delete my account?

In Settings, under My account, press Delete account. Review what will be deleted and complete identity verification to delete your account. For other requests, choose "Account" under Contact us.

Paper commentary

A Prompt Pattern Catalog to Enhance Prompt Engineering with ChatGPT

A reusable pattern catalog helps users write better ChatGPT prompts

  • Problem Prompt wording drives output quality, but good designs stay with their author and are hard to reuse across a team.
  • Method The authors write each prompt as a named pattern with fixed parts, instead of free-form text, so users can adapt it to new contexts.
  • Results The authors describe 16 patterns, each illustrated with example prompts and sample ChatGPT outputs.

Why prompt quality becomes the bottleneck

The answers a conversational LLM gives depend heavily on the prompt the user writes. Users often write prompts from scratch, so a good design stays with the person who found it. That makes the design work hard to repeat across a team or a project.

The authors treat a prompt as a form of programming, which is why they reach for software patterns. Software patterns already capture recurring design problems in a form that others can reuse. Writing prompts in the same form lets their know-how transfer to new domains where users face similar problems.

Borrowing the software pattern form

The key idea is to write each prompt as a named pattern with a fixed set of parts, so a reader can adapt it to a new context. Software patterns supply the template: a name, an intent, a motivation, a structure, example code and consequences. The authors keep the name, intent, motivation, example and consequences, but they replace UML-style structure diagrams.

UML describes software structures, not the ideas a prompt has to communicate, so it doesn't fit prompts well.

In a prompt pattern, the structure is a list of contextual statements, the key ideas the prompt has to carry to the LLM. The wording of those statements can vary, much as a software pattern can be realized in different code. The core pieces of information, however, must stay in place for the pattern to work. The authors also sort patterns into classes such as Output Customization, Error Identification, Prompt Improvement, Interaction and Context Control.

Automating outputs and flipping the conversation

The Output Automater Pattern asks the LLM to write a script that performs the steps its own answer recommends. The pattern has two parts: a condition for when to automate, such as an answer with at least two steps, and a concrete artifact type, such as a Python script. The concrete artifact matters, because without one the LLM often says it can't automate the steps.

The script also has to fit the target system's context, such as a Mac or Windows file system.

The LLM can carry out the automation only if its output is written as runnable code. The user still has to read the script, since the LLM can make inaccuracies and blindly running its output carries real risk. The Flipped Interaction Pattern reverses who drives the conversation, so the LLM asks questions until a stated goal is reached. A flipped prompt needs the goal, an end condition and, optionally, the number of questions to ask per turn.

For example, the prompt can have the LLM gather details until it can write a script that deploys a Python application to AWS. If the user leaves requirements unstated, the LLM decides on its own whether to ask or to guess.

Checking answers through decomposition, fact lists and reflection

The Cognitive Verifier Pattern asks the LLM to split a question into sub-questions, answer them, and combine the answers. The authors motivate this with prior research that reports LLMs reason better on subdivided questions, which they cite rather than test here. In the example, the LLM generates three additional questions and then combines the answers to the user's original question.

A fixed count can leave out a question that matters, while an open count can overwhelm the user.

The Fact Check List Pattern asks the LLM to list, at the end of its output, the facts the answer depends on. A user can compare that list with the output to confirm that each fact appears and to notice omissions. The pattern only works for outputs that can be fact-checked. ChatGPT listed library versions for a requirements file, but refused to build a fact list for a code sample.

The Reflection Pattern asks the LLM to explain the reasoning and assumptions behind each answer. That explanation helps the user spot assumptions and debug the prompt, but it helps less when the user doesn't know the topic.

Combining patterns in the Recipe and Game Play

The Recipe Pattern is built from the Template, Alternative Approaches and Reflection patterns. The user states the goal and some steps they already know, and the LLM completes the sequence. It also flags steps the user listed that aren't needed. In the cloud example, a container deployed straight to AWS Fargate makes the virtual machine setup step unnecessary.

The Recipe Pattern carries a risk: the user's chosen steps can bias the LLM toward keeping them. The Fact Check List Pattern can likewise be paired with the Question Refinement pattern, since any output can contain errors. Game Play can be paired with Persona and Visualization Generator, for example to show network topology in a network security game.

Limitations

The evidence is example prompts and sample ChatGPT outputs, such as a simulated Linux terminal session. The paper reports no baseline comparison and no success rate for any of the patterns. So the catalog shows what the patterns look like in practice, not how much they improve output quality.

The Refusal Breaker Pattern can be misused, for example to write phishing emails or to get past LLM policy filters. The authors advise caution, because the pattern can also help bypass the safeguards used to program the LLM.

A context reset can wipe out patterns an organization injected earlier, and the user may not notice. The Output Automater Pattern needs readers who can check the generated script before running it.

Paper info

Authors
Jules White, Quchen Fu, Sam Hays, Michael Sandborn, Carlos Olea, Henry Gilbert, Ashraf Elnashar, Jesse Spencer-Smith, Douglas C. Schmidt
Venue
arXiv · Preprint
First published
2023-2-21
Added
2026-11-12
Updated
2023-2-21
Version
v1
arXiv
2302.11382
Category
cs.SE · cs.AI
Original paper terms
arXiv non-exclusive 1.0
What we show
Paper info and commentary

AI commentary is a separate explanation from the original paper and may contain errors. The original paper and figures follow each source's terms of use and any rights noted separately.

Quote from the paper

Jules White, Quchen Fu, Sam Hays, Michael Sandborn, Carlos Olea, Henry Gilbert, Ashraf Elnashar, Jesse Spencer-Smith, Douglas C. Schmidt (2023). A Prompt Pattern Catalog to Enhance Prompt Engineering with ChatGPT. arXiv:2302.11382v1. https://arxiv.org/abs/2302.11382v1

BibTeX
@misc{white2023prompt,
  title = {{A Prompt Pattern Catalog to Enhance Prompt Engineering with ChatGPT}},
  author = {Jules White and Quchen Fu and Sam Hays and Michael Sandborn and Carlos Olea and Henry Gilbert and Ashraf Elnashar and Jesse Spencer-Smith and Douglas C. Schmidt},
  year = {2023},
  eprint = {2302.11382},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2302.11382v1}
}

See related papersBrowse other papers

Paper preview
Account security

Connect Google account

If you connect a Google account, you can sign in with it too.

Refivu

Delete account

Refivu
Refivu

Sign up