Constructing Effective ChatGPT Prompts

Jan 15, 2024 · 8 min read

Have you seen all those ready-to-use ChatGPT prompt templates online? There are so many of them! But here’s a big question: do they really work well? In this article, we’re going to talk about how to make ChatGPT answer your questions in the best way possible.

We’ll look at what makes a prompt really good. The best prompts are the ones that fit exactly what you need. They should be easy for ChatGPT to understand so it can give you the kind of answer you’re looking for.

So, if you’re curious about how to ask ChatGPT questions in the best way, keep reading.

What is a Prompt and Prompt Engineering?

A prompt is like a set of instructions or questions that you give to an AI model like ChatGPT. It’s like telling the AI what you want to know or talk about. The AI then uses your prompt to come up with an answer. Your prompt can be just one sentence or even a whole paragraph.

The way you create these instructions is called prompt engineering. It’s all about how you ask your question or set up your prompt. This is really important because ChatGPT, which is a Large Language Model (LLM), gives answers based on how likely (statistically) certain words are to come next in a sentence. If your question is not clear or can be understood in many ways, the AI might not give the best answer. So, learning how to make good prompts helps you get better answers from ChatGPT.

Key Elements of an Effective Prompt

Creating an effective ChatGPT prompt involves several key elements. These elements ensure that the responses you get are focused, clear, and match your expectations. Let’s explore these elements:

  • Specificity and Clarity: Be clear and specific in your prompts, like asking “Describe the Apollo 11 moon landing mission of 1969” instead of just “Tell me about space missions.” Think of it like giving directions; the more specific you are, the more likely you are to get where you want to go. However, be aware that being too specific can backfire if you don’t fully understand what you’re asking about. It’s advised to do some exploratory prompting to gain knowledge of the topic as mentioned in the last section of this article.

  • Avoiding Ambiguity: Stay away from vague words like “it” or “that” in long conversations, as they can lead to confusion. Instead, use specific names or titles. For example, instead of saying, “Tell me more about it,” clarify with, “Tell me more about the Apollo 11 mission.”. Also, if a question seems unclear, instruct ChatGPT to ask for more information before answering.

  • Breaking Down Complex Questions: For intricate queries, dividing them into simpler, more manageable parts can yield more detailed and comprehensive answers. For example, instead of asking, “How does a rocket work?” break it down to, “What are the main parts of a rocket, and how does each contribute to its launch?”

  • Contextual Information: Include necessary background details in your prompt. Adding time, place, or relevant specifics can significantly enhance the accuracy of the response. For example, “Explain the causes of the French Revolution in the context of 18th-century European politics.”

  • Step-by-Step Explanations (Chain of Thought Prompting): For complex topics, request organized, process-based answers. Encourage ChatGPT to demonstrate its reasoning through a Chain of Thought approach, where it logically breaks down the steps of its thinking process.

  • Setting Expectations: Clearly state the desired format or depth of the response. For instance, “Provide an overview of Shakespeare’s ‘Hamlet’ in a bulleted list format.”. Usually, it helps to give ChatGPT a few examples of the desired response (aka Few-Shot Prompting).

  • Limiting Response Length: If a concise answer is needed, set specific constraints. You can request responses within a certain word count or paragraph limit, or instruct ChatGPT to respond in a succinct manner, akin to a character known for brevity (for example “Answer like Spock from Star Trek”).

  • Continuation Prompts: For ongoing discussions, use prompts that smoothly continue from the previous responses. Phrases like, “Continuing from your last point…” or “Expand further on…” help maintain the flow of conversation.

  • Defining Personas: Give ChatGPT specific characteristics, like a profession or style, to tailor the response. For example, “Answer as a climate scientist would” for expert-level insights in that field.

  • Specifying Language and Tone: Direct ChatGPT to adopt a certain style or tone, whether formal, casual, technical, or simplified, to match the intended audience or purpose of the conversation.

Categorizing ChatGPT Responses: What to Expect

When interacting with ChatGPT, the way you frame your question or prompt (prompt engineering) greatly influences the type of response you receive. Here’s a breakdown of various response categories you can expect from ChatGPT:

  • Q&A Format: This is a common conversation style where you ask a question, and ChatGPT provides an answer. It’s straightforward and effective for quick information.

  • Short and Concise Responses: These focus on clarity and depth but are brief. You might request bulleted lists of key points or learnings from a text. This style ensures unique, non-repetitive responses.

  • Long and Comprehensive Responses: Ideal for creative writing or getting multiple perspectives. In these prompts, you might hint at asking ChatGPT to confirm before proceeding if the response reaches a token limit. This allows for expansive answers.

  • Interactive Roleplay: This includes role-playing or simulating dialogues between characters. It’s useful for creating dynamic and engaging scenarios. For instance, you could simulate a conversation between historical figures to explore history or philosophy, enhancing the learning experience through active participation and critical thinking.

  • Step-by-Step Instructions: Useful for technical issues or detailed guidance. The Chain of Thought (CoT) method is often used here, where ChatGPT explains its reasoning process.

  • Topics with Brief Explanations: This style involves ChatGPT presenting topics along with concise explanations. These can be later used as flashcards to aid in learning the subject.

  • Self-Reflective Prompts: In this unique approach, you ask ChatGPT to suggest prompts that would lead to a specific type of response. It’s a form of reverse engineering, helping ChatGPT to backtrack from a desired outcome to formulate an appropriate prompt.

  • Multi-Step and Meta-Prompting: Advanced prompting for tasks requiring a deeper understanding, like creating diverse prompts or generating complex code. See following GitHub repositories for possible implementations: Mr. Ranedeer AI Tutor and Meta-Prompting.

Additional Tips and Tricks to Get the Most Out of ChatGPT

Here are additional tips to enhance your interactions:

  • Chunk Long Contextual Information: When providing context for your question, avoid overly long texts. ChatGPT tends to remember only the beginning and end of lengthy inputs, potentially missing key details in the middle. Instead, break down the information into smaller chunks and prompt ChatGPT to ask for more details if needed.

  • Use Exploratory Prompting, Then Restart: If unsure about how to ask something specific, start with open-ended questions to explore the topic. After gaining some initial understanding, begin a new chat session with more focused questions. Restarting the conversation can also be helpful when it becomes lengthy, as ChatGPT might start forgetting earlier parts of the conversation.

  • Prompt in Proper English: ChatGPT performs best when prompted in grammatically correct English, as most of its training data is in English. Proper punctuation is also crucial, as ChatGPT is a statistical model that relies on these details to understand and respond accurately.

  • Be Polite and Express Emotions: The model has been trained on real human conversations, which includes a wide range of tones and manners. Being polite and expressing emotions like urgency can sometimes lead to more effective responses. For more insights, refer to the research paper at arXiv:2307.11760.

  • Edit Instead of Sending New Messages to Correct Mistakes: If you realize you’ve asked the wrong question, it’s better to edit your prompt instead of sending a new one. ChatGPT, as a stateless model, doesn’t remember previous interactions unless the conversation history is included in the current prompt. So, if you send a new message with corrections, the wrong prompt will still be in ChatGPT’s memory, and it might give you a wrong answer.

  • Save Favorite Conversations for Future Reference: ChatGPT assigns an autogenerated title to each conversation. You can edit this title for easier reference later and save the conversation URL, perhaps in a Google Sheet, for quick access in the future.

  • Remember, ChatGPT Can’t Replace You: It’s important to understand that ChatGPT is a tool to assist you, not to do the work for you. Utilize it as an assistant or a learning tool to deepen your understanding of topics and boost your productivity, but remember the final interpretation and application of information rests with you.

Conclusion

ChatGPT is a really useful tool that can help answer your questions. But it’s not perfect, and it works best when you know how to use it right. Most of the tips we’ve talked about in this article are for the GPT-3.5 model, which is the standard version of ChatGPT that you can use for free. This model does a good job if you give it clear and well-thought-out prompts.

On the other hand, GPT-4, which is used in the paid Plus version of ChatGPT, is even better at understanding what you mean, even if your questions are not perfectly written. ChatGPT is really good for coming up with new ideas and helping with creative thinking. But if you’re using it for serious research or to analyze something important, you need to be careful. Sometimes it can make mistakes or give answers that aren’t completely accurate. So, it’s good to double-check the information you get from it.

Chatize leverages the power of ChatGPT to help you interact with documents in a conversational manner. It does this by using a combination of ChatGPT API and a RAG (Retrieval-Augmented Generation) which we will cover in a future post. So all the tips and tricks discussed in this article are applicable to Chatize as well. Chatize is a great tool for learning, research, and productivity. We hope this article helps you get the most out of ChatGPT and Chatize. Happy Chatizing!