Prompt patterns, few-shot, chain of thought, embeddings, vector databases, chunking, retrieval augmented generation and agents.
40 cards · basic cards · AI-written, checked twice. Edit anything.
- What is a prompt pattern?
Show answer
A reusable template for formulating prompts to achieve consistent, specific types of responses
- What does the role prompt pattern do?
Show answer
It asks the LLM to adopt a specific persona or expertise level, such as 'You are a data scientist'
- What is the context prompt pattern?
Show answer
Providing background information or setting before the main task or question
- What is the constraint prompt pattern?
Show answer
Specifying limitations or rules that the model must follow in its response
- What is the output format prompt pattern?
Show answer
Explicitly specifying how the response should be structured, such as JSON, a list, or a paragraph
- What is the steps prompt pattern?
Show answer
Breaking a complex task into a numbered sequence of smaller, manageable steps
- What is the refinement prompt pattern?
Show answer
Asking the model to improve, expand, or critique its own previous response
- What is a meta-prompt?
Show answer
A prompt that instructs the model how to handle or interpret subsequent prompts
- What is few-shot learning?
Show answer
Providing a small number of input-output examples in a prompt to teach the model desired behavior without fine-tuning
- How does few-shot learning work?
Show answer
The model identifies patterns from the provided examples and applies those patterns to the new task
- What is the difference between zero-shot and few-shot prompting?
Show answer
Zero-shot has no examples; few-shot includes a small number of input-output examples to demonstrate desired behavior
- What is chain of thought (CoT) prompting?
Show answer
A technique where the model is asked to show its reasoning step-by-step before providing the final answer
- How does chain of thought improve accuracy?
Show answer
It forces systematic problem-solving, reducing errors and improving performance on complex reasoning tasks
- What is zero-shot chain of thought?
Show answer
Adding the phrase 'Let me think step by step' to a prompt, which encourages reasoning without explicit examples
- What is the tree of thought technique?
Show answer
An approach that explores multiple reasoning paths in parallel and selects the most promising one to continue