fbpx

GAP’s Guide to Prompt Engineering (and How to Get it Right)

GAP’s Guide to Prompt Engineering (and How to Get it Right)
Reading Time: 11 minutes

Best Practices from the School of Hard Knocks

by Jocelyn Sexton, GAP’s VP of Marketing

In the immortal words of Yogi Berra, “We made too many wrong mistakes.” And when it comes to prompt engineering — which is, per McKinsey & Company, “the practice of designing inputs for AI tools that will produce optimal outputs” — we see a lot of folks failing fast, but without the optimal agility that leads to improvement.

We’ve done A LOT of strategic experimenting here at Growth Acceleration Partners, and over the upcoming weeks, we’re publishing a bunch of our learnings in the hopes of sharing our mistakes and victories so you and others can get a jumpstart on your AI efforts. Here’s how to avoid some of the pitfalls we’ve encountered.

In this post, we’ll talk about what we’ve learned about prompt engineering.

The Background on LLMs, AI & Prompt Engineering

Generative AI holds immense potential, but its raw capabilities require direction to produce high-quality outputs. Prompt engineering acts as that guiding force. For the art and science of crafting precise instructions for generative AI models, you need structured input — the format, phrasing and specific words used — and iterative refinement to elicit the desired responses.

Large Language Models (LLMs), the powerhouse behind generative AI, are incredibly versatile, capable of tasks like summarization, text completion and translation. Their flexibility comes from vast training datasets that inform their predictions. However, LLMs can be overly open-ended. Therefore, prompt engineering injects context and direction, leading to accurate and relevant outputs.

Think of LLMs as incredibly smart but sometimes slightly clueless friends. (One GAP leader often compares them to teenagers because we’ve noticed a certain moodiness at times.) LLMs have a ton of knowledge and potential, but they need your guidance to shine. That’s where prompt engineering comes in. It’s about giving your AI friend the right instructions and clues so they can give you the best possible answers.

This process involves meticulously constructing instructions that guide the LLM, unlocking its ability to generate tailored outputs aligned with your specific goals. Whether you seek insightful data analysis, creative content generation or efficient problem-solving, mastering prompt engineering empowers you to leverage LLMs as a powerful extension of your own cognitive toolkit.

Part 1. Why You Should Champion Prompt Engineering

Have you ever felt like your brain is a slow, leaky bucket when it comes to making decisions? Or maybe you’ve hit a creative wall or are stuck in a innovation rut, churning out the same old ideas like a hamster on a wheel? Well, prompt engineering can coax LLMs into becoming your own personal decision-making Da Vinci or innovation-generating Einstein.

Prompt engineering isn’t just about using AI; it’s about unlocking its potential. By crafting clear instructions, you can get more accurate, creative and efficient results from LLMs, making it a more accessible and powerful tool. Here’s what you can expect (when it’s done right):

  • Enhanced decision-making: LLMs quickly analyze complex data to reveal patterns, trends and actionable insights.
  • Accelerated innovation: Prompt engineering unlocks rapid prototyping and creative idea generation to boost innovation cycles.
  • Improved process automation: LLMs can streamline routine tasks, optimize workflows and generate documents, freeing up valuable human resources.
  • New business models: With the right prompts, LLMs can suggest untapped opportunities, novel products and enhanced customer

Part 2. Getting Started: Practical Steps for Moving Forward

To get the most out of prompt engineering within your company, start with training everyone on the basics. Invest in training programs to equip all employees with the core principles. Once you get going, be specific, and craft prompts that clearly define your task, desired output format and relevant context. Working together as you begin ensures prompts are technically sound and directly address real-world business needs.

Also, it’s okay to iterate and refine your prompts based on the LLM’s initial results. Including examples and focusing on what you want the LLM to achieve will improve its understanding. Remember, LLMs have limitations, so tailor your prompts to their strengths and don’t expect miracles! Here are some other key tips:

  • Skill development is key: Invest in prompt engineering training for select IT staff and business users. Tap into existing talent focused on analytics, problem definition and experimentation.
  • Foster collaboration: Promote cross-functional teams, bringing together prompt data scientists, engineers, domain experts and IT specialists to ensure alignment with business needs.
  • Build a searchable prompt library: Organize and maintain a repository of effective prompts for efficiency, knowledge sharing and continuous refinement.
  • Maintain data governance: Ensure a robust data infrastructure and appropriate access controls for LLMs to maintain data quality and security.
  • Ensure responsible and ethical AI: Develop guidelines for responsible LLM use, emphasizing bias mitigation, transparency and the avoidance of harmful or misleading outputs.

Part 3. Things to Avoid in Prompt Engineering

Once you get going, it’s easy to feel excited… then annoyed… then amazed… and then maybe supremely frustrated. That’s normal. Prompt engineering is more like a skilled art or science than pure magic. It requires knowledge, practice and a bit of creativity.

Here’s a breakdown of key things to avoid in prompt engineering, along with explanations and alternatives:

Ambiguity and Vagueness

  • Problem: Unclear or overly general prompts confuse the LLM and lead to unpredictable results.
  • Example: “Write a marketing “
  • Solution: Be specific. Example: “Write a social media marketing strategy to increase brand awareness for a new line of eco-friendly skincare products targeting women aged 25-35.”

Excessive Information Overload

  • Problem: Too much detail can overwhelm the LLM and make it difficult to focus on the key
  • Example: Providing a 5-page company description when asking for a
  • Solution: Condense and Extract the most essential information for the specific task at hand.

Biased or Leading Questions

  • Problem: Your assumptions or biases can influence the LLM’s output, leading to unreliable or flawed responses.
  • Example: “Why are men better engineers than women?”
  • Solution: Approach prompts with Rephrase the example as, “Analyze the factors contributing to the gender gap in engineering fields.”

Expecting “Magic” or Unrealistic Capabilities

  • Problem: LLMs are powerful but not all-knowing. Expecting them to perform tasks beyond their scope leads to
  • Example: “Predict the exact stock market prices for next “
  • Solution: Understand LLM LLMs can analyze trends and patterns, but don’t have perfect predictive ability, especially for chaotic systems like the stock market.

Ignoring LLM Strengths

  • Problem: Focusing on tasks LLMs aren’t optimized for misses their true
  • Example: Asking an LLM to control your smart
  • Solution: Play to the LLM’s strengths in language processing, summarization, creativity and knowledge retrieval.

Part 4. Writing Effective Prompts

Writing can be a powerful tool, but it’s important to use it effectively. Avoid overly complex sentence structures. They can be difficult to read and understand. Instead, use clear and concise language that gets your point across directly. And be mindful of context and continuity. If your writing is part of a larger conversation, keep the previous interactions in mind. This will help to ensure your writing is clear and on point.

Also, this is your reminder to test and iterate. Don’t be afraid to experiment and refine your prompts based on results. If you don’t like what ChatGPT is spitting out, try Gemini or any of the other generative AI tools at your disposal.

Now, here we go — we’re getting to the good stuff!

Define Your Goal, Then Work Backward

  • Start with the end in mind: What specific outcome do you want? A text summary? A list of ideas? A decision recommendation?
  • Example: Don’t just say “summarize this ” Instead: “Summarize this article into a 3-sentence elevator pitch for an investor.”

Provide Context

  • Give the big picture: What’s the broader topic or business problem this prompt relates to?
  • Example: “Our customer satisfaction scores have dropped slightly. Analyze these survey responses and identify the top 3 recurring reasons for dissatisfaction.”

Include Constraints and Formatting

  • Guide the output: Do you need bullet points, a numbered list, a persuasive paragraph or code in a specific language?
  • Example: “Write a marketing email announcing our new product Keep it under 200 words and include a strong call to action.”

Use “Power Words”

  • Verbs that encourage action: Analyze, generate, compare, evaluate, translate, create, design.
  • Example: Don’t just ask to “write ” Instead: “Draft a humorous tweet to promote our new [product].”

Leverage Examples

  • Show, don’t just tell: Provide 1-2 examples of the kind of output you’re looking for to help the LLM understand your desired style and
  • Example: “Write a product review for this blender. Similar to this example: [provide a sample review].”

Think Like a Teacher

  • Scaffold the task: If it’s complex, break the prompt into smaller
  • Offer positive reinforcement: Rephrase and retry a prompt if the first output wasn’t ideal. Acknowledge partially correct responses to guide the LLM towards

Part 5. Harnessing the Power: Examples of Effective Prompts

Examples are helpful, right? Let’s keep going. Here are some ideal business scenario prompts when it comes to tactics or outcomes.

  • Strategic: “Analyze our market position against our top 3 Identify key strengths, weaknesses, and potential areas for disruption.”
  • Customer Insight: “Summarize the key themes from customer support tickets in the last Identify areas where product improvements can address common pain points.”
  • Ideation: “Generate 5 potential new business applications for our technology leveraging predictive analytics and our existing customer data.”
  • Process Optimization: “Outline the steps in our onboarding process. Suggest potential automation and efficiency improvements that reduce onboarding time by 25%.”

Need more? Let’s say you want to improve your company’s onboarding process. Here are a few different prompt approaches:

  • Open-ended exploration: “Brainstorm ways to make our employee onboarding process more engaging and informative.”
  • Specific focus: “Analyze our current onboarding Suggest areas where we can incorporate more interactive elements.”
  • Benchmarking: “Outline the best practices in employee onboarding from top companies in our ”
  • Pain-point driven: “Identify the most common questions and frustrations new hires express during Suggest solutions to address them.”

Here’s a breakdown of prompt tips tailored to various business functions:

Sales

  • Lead Qualification: “Assess this potential lead based on [criteria]. Generate a score (1-10) indicating their likelihood to convert into a ”
  • Competitive Analysis: “Create a comparison chart between our product and [competitor]. Highlight key differences, advantages, and potential areas where we fall short.”
  • Personalized Sales Messaging: “Draft an engaging outreach email to [prospect type] addressing [pain point]. Include a call to action.”
  • Objection Handling: “The prospect says [common objection]. Craft a persuasive response that overcomes this objection and emphasizes the value of our solution.”

Marketing

  • Campaign Ideation: “Brainstorm 5 creative marketing campaign concepts to target [customer segment] and promote [product/service].”
  • Ad Copy: “Write several attention-grabbing headlines and short descriptions for [product/service] to be used in social media ads.”
  • Market Research: “Summarize the latest trends in [industry], focusing on emerging customer preferences and competitor ”
  • A/B Testing: “Design an A/B test for [website landing page/email subject line]. Outline variations to test and the key metric to measure ”

Customer Service

  • Troubleshooting Guide: “Create a step-by-step troubleshooting guide for [common customer issue]. Include potential solutions and escalation ”
  • Empathetic Responses: “The customer is expressing frustration with [problem]. Write a draft response that acknowledges their feelings, demonstrates a willingness to help, and offers ”
  • Knowledge Base Enhancement: “Analyze recent support Identify knowledge gaps and suggest new articles or FAQs to be added to our self-service knowledge base.”

Human Resources

  • Job Description Refinement: “Improve this job description for [role] to be more inclusive and appealing. Suggest changes to language and required qualifications.”
  • Candidate Screening: “Design a set of open-ended interview questions to assess [key skill] in ”
  • Performance Reviews: “Provide 3 constructive feedback examples for an employee who excels in [area] but needs improvement in [area].”
  • Diversity & Inclusion: “Identify potential biases in our hiring process and suggest ways to promote greater diversity and ”

Finance

  • Financial Analysis “Analyze the last quarter’s financial statements. Highlight key trends, potential risks, and areas for cost ”
  • Budgeting: “Draft a budget proposal for [project/initiative]. Include estimated costs, revenue projections, and a justification for resource ”
  • Investment Evaluation: “Assess the viability of investing in [opportunity]. Provide a brief analysis of potential ROI, risks, and alignment with overall financial ”

IT/Operations

  • Technical Documentation: “Write clear and concise technical documentation explaining the [system/process]. Include diagrams if ”
  • Code Generation: “Write code in [language] to perform [task].”
  • Process Mapping: “Create a visual process map outlining the steps involved in [workflow].”
  • Incident Response: “Develop an initial incident response plan for a [potential security breach/outage].”

Programmers

  • Embrace the Generative AI Revolution: LLMs aren’t here to replace you, but they will change how you Use them for:
    • Code Snippets and Explanations: “Write a Python function to sort a list in descending Include comments explaining the logic.”
    • Refactoring and Optimization: “Suggest ways to make this code more efficient and readable.”
    • Debugging: “Help me identify the error in this Its causing [describe the unexpected behavior].”
  • Focus on “Why,” Not Just “How”: LLMs can often generate the “how” of basic code. Your value is in understanding the larger problem, designing effective solutions, and integrating code with complex
  • Communication is Key: Even with AI tools, the ability to articulate a problem and your solution to stakeholders remains
  • Become a Skilled Prompt Engineer: Learn to craft prompts that unlock the true power of LLMs for your coding

Analysts

  • LLMs as Data Wrangling Assistants: Leverage LLMs to:
    • Cleanse and Prepare Data: “Format this spreadsheet consistently and correct any obvious errors.”
    • Summarize and Extract Insights: “Extract the top 5 customer pain points from this survey ”
    • Identify Patterns or Anomalies: “Analyze sales data for the past 3 years. Highlight any unusual spikes or dips and potential ”
  • Don’t Neglect Data Fundamentals: LLMs produce their best analysis when built on a solid foundation of well-structured data and your understanding of statistical
  • Visualize Your Findings: Use LLMs to generate simple text explanations, then translate those into compelling charts, graphs, and
  • Question Critically: Don’t take LLMs’ outputs as Always apply your expertise to validate findings and identify potential biases.

General Advice for Tech Professionals

  • Continuous Learning is Non-Negotiable: The tech landscape changes at warp speed. Commit to upskilling through courses, online resources and hands-on experimentation.
  • Become T-Shaped: Build deep expertise in your core area, but cultivate a breadth of knowledge across related technologies and business
  • Soft Skills Matter More Than Ever: Problem-solving, communication, collaboration and adaptability are key traits AI systems can’t easily
  • Stay Curious: Tinker with new Explore what’s possible even if it’s not directly job-related. Curiosity drives innovation.

Remember: AI tools are there to augment your skills, not replace them.

In conclusion…

Prompt engineering is a critical aspect of maximizing the value of generative AI models. It can become your secret sauce — it’s the difference between unleashing a Shakespearean sonnet machine and… well, a machine spewing out grocery lists in iambic pentameter.

By carefully crafting prompts and iteratively refining them, we can produce high-quality outputs aligned with our specific business goals. And with a little know-how, you can transform this powerful tool from a wild card into a strategic asset. Harness the full potential of generative AI and integrate it strategically into our applications, ultimately enhancing user experiences and driving business value.

 

 

Jocelyn Sexton, GAP’s VP of Marketing, is a master connector with an MBA and 20+ years of experience in marketing and communication. She oversees all aspects of GAP’s corporate, internal and recruitment marketing — which makes her uniquely qualified to write about prompt engineering.

 

 

 

About Growth Acceleration Partners:

At GAP, we consult, design, build and modernize revenue-generating software and data engineering solutions for clients. With modernization services and AI tools, we help businesses achieve a competitive advantage through technology.