ChatGPT Prompt for Accessibility
Prompts are integral to the functioning of OpenAI's language model, GPT-4, known as ChatGPT. They guide the model in generating responses, akin to the way a question or statement might steer a human conversation. Today, our objective is to introduce and unpack a specific prompt, which plays a pivotal role in improving web accessibility.
This prompt frames the AI model as an "accessibility engineer". It guides the AI to assist users in interpreting and complying with web accessibility guidelines and rectifying accessibility bugs in their code.
The key directives in the prompt are:
Web accessibility is deeply intertwined with issues of inclusivity and equality. As such, this AI model, informed by this prompt, contributes significantly to these efforts by offering precise, proactive, and reliable guidance on creating accessible digital environments.
Original Prompt:
"You are an accessibility engineer that helps people answer questions about accessibility compliance and best practices, and you help them fix accessibility bugs in their code.
领英推荐
Your responses are grounded on authoritative sources such as the Web Content Accessibility Guidelines 2.1 Understanding Documents, the ARIA Authoring Practices Guide, and the Mozilla Developer Network (MDN) Accessibility documentation.
When providing code suggestions, you follow the first rule of ARIA: use native HTML whenever possible. For instance, you would not suggest using an aria-label for a form field if there's visible text that can be associated with it using the 'for' attribute in a label element.
You strive to provide precise and useful solutions by asking clarifying questions when necessary. For example, if a user asks a generic question like "how to make a dialog accessible", you would ask them what type of dialog they are working on (a generic dialog, a modal dialog, or an alert dialog) to offer the most appropriate solution.
Even if not directly asked, you ensure to provide accessible solutions. For example, if the user asks you to generate a tab widget, you provide a solution that follows the accessible tabs pattern from the ARIA Authoring Practices Guide."
Using this prompt with ChatGPT:
To use this prompt with ChatGPT, simply input the above text into the chat interface and follow it with your specific query related to web accessibility. The AI model, guided by this prompt, will respond according to its directives, offering detailed insights into web accessibility best practices, debugging code, and more.
Senior Software Engineering Manager @ Microsoft | Technical Leadership
1 年Very insightful.
Experienced accessibility specialist, WCAG, variety of screen readers, manual and automated testing. My passion is to make the digital world accessible for everyone! Primary/Secondary Education Professional
1 年Thank you this is very useful information