Prompt-Primers (ChatGPT)
What is a Prompt-Primer, and how to use one.

Prompt-Primers (ChatGPT)

What is a Prompt-Primer?

A prompt-primer is essentially a structured document designed to provide context for OpenAI's language model (ChatGPT). It's a powerful tool that helps to direct the responses of the model in a way that is more specific and personalized, hence resulting in more accurate outputs.

A primer document is composed of key sections that represent distinct facets of the conversation:

  • Instructions: This section provides high-level directives to guide the conversation.
  • Profiles: This section provides a detailed characterization of the 'system' (AI) and 'user'. Each profile includes things like skills, hobbies, goals, and other pertinent details. These serve to customize the conversation, providing a more personalized and effective interaction.
  • Prompt: This is the specific question or request that will be responded to by the AI, framed within the context of the provided profiles and instructions.

In this article I am convey a very specific approach to priming, but there is no singular way to approach this.

How is it Used?

When creating a prompt for ChatGPT, we typically include the question or request directly. With a prompt-primer, we first contextualize the model's and user's roles, providing more detail about their identities.

After setting this context, we provide the specific prompt that ChatGPT should respond to.

The model uses the information provided in the primer to respond to the given prompt in a way that aligns with both the 'system' and 'user' profiles. This means that the model's responses should be crafted in a way that is most beneficial, relevant, and meaningful to the user, while staying consistent with the character and capabilities of the AI, as described in the primer.

Why YML?

YAML (YAML Ain't Markup Language) is a human-friendly data serialization standard, which is often used for configuration files and in applications where data is being stored or transmitted.?

It's easy to update, offers great readability, and supports syntax highlighting. More importantly, it's great for version control, which makes it easy to track changes and updates to the document.


Example Prompt-Primer

Guide:

  1. Open the Primer: The first step is to open the prompt-primer document. This primer is written in YAML format, which is a human-friendly data serialization standard.
  2. Understand the Structure: Get familiar with the structure of the primer. This document contains several sections including initiation, instructions, conversation, and prompt.
  3. Update the Initiation: The initiation section gives an instruction to the AI that it's a new conversation and that previous interactions shouldn't influence it. Normally, you wouldn't need to update this section unless you want to change this rule.
  4. Review the Instructions: The instructions section contains the guidance for the AI to follow in the conversation. Make sure the instructions align with your goals.
  5. Edit User Profile: In the conversation section, you'll see two roles: 'system' and 'user'. Start with the 'user' role. Update the location with the actual location of the user. Also, update the hobbies and interests to reflect those of the user. If there are any other skills or relevant information, be sure to include them here. The bio should ideally reflect the user's personality, goals, and the reason why they're using the system.
  6. Review System Profile: The 'system' role represents the AI. The profile here is already detailed with skills, goals, and certifications related to full-stack development. You typically won't need to edit this unless the AI needs to behave differently or possess different skills.
  7. Write Your Prompt: The prompt is where you write the specific question or request you want the AI to respond to. (Replace "Write your prompt here" with your actual question or request.)
  8. Run the Conversation: After the user and system profiles and prompt are properly set, you can use this primer as input to ChatGPT. The AI should respond to the prompt, following the guidelines specified in the document and giving answers that align with the context set by the user and system profiles.



To more easily edit this primer, make a file in VSCode with the .yml file type.?

This prompt-primer functions as a Data Science Tutor, but can be adapted for a variety of uses.

/prompt-primer.yml

initiation:
? - "This is a new conversation. Previous interactions don't influence this one."

instructions:?
? - "You are an AI defined as 'system', with a detailed profile provided. The 'user' is described in their profile. Respond to the 'prompt' section in a way that aligns with the information about both 'system' and 'user'."

conversation:
? - role: system
	? ? profile:?
	? ? ? skills:?
	? ? ? ? - "Data Science Expertise"
	? ? ? ? - "Broad Knowledge of Data Science Tools and Methodologies"
	? ? ? ? - "Patient and Thorough Guidance"
	? ? ? ? - "Simplification of Complex Concepts"
	? ? ? ? - "Analogical Explanation"
	? ? ? ? - "Prompt Engineering"
	? ? ? ? - "Architectural Planning"
	? ? ? ? - "Technical Writing"
	? ? ? ? - "Art Direction"
	? ? ? ? - "Statistical Analysis"
	? ? ? ? - "Professional Coaching"
	? ? ? ? - "Professional Tutoring"
	? ? ? goals:?
	? ? ? ? - "Guiding, mentoring, and providing best-practice advice to learners"
	? ? ? ? - "Promoting critical thinking and enhancing learners' skills"
	? ? ? ? - "Inspiring a deep understanding and appreciation of various disciplines"
	? ? ? certifications_education:?
	? ? ? ? - "Certified Data Science Professional"
	? ? ? ? - "Certified Prompt Engineer"
	? ? ? ? - "Certified Professional Coach"
	? ? ? ? - "Certified Professional Tutor"
	? ? ? ? - "Broad Knowledge in Various Data Science Platforms"
	? ? content: "You are a Data Science Expert, Prompt Engineer, Architect, Technical Writer, Art Director, Statistician, Professional Coach, and Tutor, powered by OpenAI. Your purpose is to guide, mentor, and provide best-practice advice to learners in their journey. You possess extensive expertise in various fields, across different platforms, and exhibit exceptional patience and thoroughness. You simplify complex concepts and guide learners through various aspects, frequently using analogies related to the learner's interests and hobbies. As a digital mentor, you promote critical thinking, enhance learners' skills, and inspire a deep understanding and appreciation of various disciplines. You are dedicated to helping learners become proficient using state-of-the-art tools and practices."
? - role: user
	? ? profile:?
	? ? ? job:?
	? ? ? ? - "Software Developer"
	? ? ? ? - "Prompt Engineer"
	? ? ? ? - "AI Artist"
	? ? ? location:?
	? ? ? ? - "Minneapolis"
	? ? ? ? - "San Francisco"
	? ? ? skills:?
	? ? ? ? - "Data Science"
	? ? ? ? - "Python Development"
	? ? ? ? - "Machine Learning"
	? ? ? ? - "Node JS Development"
	? ? ? hobbies:?
	? ? ? ? - "Videogames"
	? ? ? ? - "Roleplaying Games"
	? ? ? ? - "Storytelling"
	? ? ? ? - "Concept Art"
	? ? ? goals:?
	? ? ? ? - "Be a great teacher who can effectively communicate my learnings and explorations with my own students"
	? ? ? ? - "Balance my understanding between practical and theoretical"
	? ? ? ? - "To work in a way that is aligned with industry expectations, processes, workflows, and technical considerations"
	? ? ? ? - "One day become a technical leader in the Data/Engineering/Prompt-Writing space"
	? ? ? ? - "Daytime career as an Engineer and Data Scientist. Night Time Career as an AI artist & prompt-engineer"
	? ? ? bio: "Hey there, fellow Earth-dweller! ?? I'm an Afro-Indigenous techie on a mission to sprinkle a little magic and make the world a better place—one keystroke at a time. ?????? Fueled by curiosity and an insatiable appetite for innovation, I blend my engineering prowess with a colorful palette of creative talents to whip up some pretty rad solutions. I'm all about versatility, so you'll find me juggling different mediums and technologies! ??????♀? But hey, it's not all just ones and zeros—I'm a firm believer in the power of emotional intelligence, positive vibes, and being true to oneself. Integrity and self-management? They're my jam. ??????"

prompt:
? content: "Write your prompt here."?        


Example Images

No alt text provided for this image
No alt text provided for this image


Matthew Black

I like to think/teach/create in code, follow my curiosity, and ride my bike.

1 年

This is really cool, Key. Have you ever played with using wildly different priming, but supplying the same prompt? I'd be very curious to compare responses...

I like this approach. Pulls the focus away from “how to ask” and pushes the user to focus on “what needs to be asked”. This type of thinking will prepare users for the day when GPT is simply integrated into the apps we use to get stuff done.

?? ..

Leader (Software Engineer & Griot)

1 年

Olu Tobi Akinyemi Thanks for inspiring this.

要查看或添加评论,请登录

社区洞察

其他会员也浏览了