TL;DR: Use this prompt and the text from a Drupalize.Me tutorial to experiment with using generative AI as a tutor for learning Drupal.
A while ago, I wrote an article and gave a presentation about why learning Drupal is so hard. One of the key challenges I identified is the “pit of despair”. It's that point in the learning journey where you can no longer rely on the hand holding of step-by-step tutorials. You need to step out into the chasm and come up with your own unique solutions to your specific problems. That point where you know just enough to realize the breadth of what you don’t yet know. And I had said, based on input from many peers, that the quickest way through the dip is real-world experience and drawing on the expertise of others. The advice could be summed up as: if you want to learn fast, get a tutor.
The path to learning Drupal looks something like this:
It can be hard to find a mentor. As much as we would love to be able to do so, our small team at Drupalize.Me can't scale personalized individual tutoring. So I've been thinking about how you might be able to use AI to help get at least some of the benefits of tutoring.
Dr. Ethan Mollick and Dr. Lilach Mollick wrote a paper titled “Assigning AI: Seven Approaches for Students, with Prompts”. This paper examines the use of LLMs in education and provides guidance on how to approach them. Inspired by their work, and things like Khan Academy's Khanmigo, Duo Lingo, and my own attempts to use generative AI as a way to learn, I developed the prompt below. The goal is to use generative AI, in combination with Drupalize.Me’s tutorials, to enhance the learning experience. Down the road, it might be something we can integrate into the platform, but for now, a bit of copy/paste will have to suffice.
Here’s an explanation of the thinking that went into the development of this prompt. And my thoughts about the risks and benefits of using an AI tutor.
Risks of using an AI tutor
When using AI as a tutor, or any type of learning assistant (coach, mentor, etc.), it's important to remember that the AI is not perfect. It's prone to making errors and perpetuating biases. You should use the AI as a supportive tool to help sharpen your skills, not as a replacement for doing the actual work of learning.
There’s a serious risk of incorrect but plausible answers. The LLM can have strong viewpoints about facts the model believes are correct (even if they are not) and can be very convincing. This has the potential to undercut your learning by teaching things that technically work but are misleading or just plain wrong. For Drupal I’ve seen this play out often in that the models are not always up-to-date on evolving practices. For example, code examples that use the EntityQuery
service instead of *\*Drupal::*entityTypeManager*()->getStorage('node')->getQuery()
. This requires constant verification of provided answers (which in itself is a learning opportunity).
Benefits of using an AI tutor
Personalized direct feedback and instruction is very effective when you are learning a subject. An AI tutor can potentially take you beyond simple step-by-step instructions and actively generate answers to your own bespoke problems. Designing and building your site’s unique content model requires a different level of understanding than following along exactly with a tutorial on Drupalize.Me that shows you how to create a blog content type. A tutor, even an AI powered one, can help push you to learn Drupal and all of its nuances more deeply.
A good tutor is a blend of knowledge, patience, and interpersonal skills. They need to have a solid understanding of the subject matter and the ability to adjust their explanation of concepts to different levels of ability. Learning can be frustrating, so they need to be patient and empathetic, while also pushing you through leading questions(”Can you explain how this works?”) that require you to actively generate knowledge. A tutor needs the ability to identify your needs and goals and to tailor their approach accordingly. The best tutors are enthusiastic about the subject they teach, and that enthusiasm is contagious.
This kind of tutoring, while very effective, isn’t widely available due to the fact that it’s both costly and time-consuming. An AI tutor is not going to be as good as the best human tutor. But, that doesn’t mean it can’t be better than having no tutor at all and enhance your learning experience. And, the AI tutor has no time constraints, and is relatively cheap in comparison.
During a session with a tutor, in addition to getting answers from a subject matter expert, you get to do things like restate answers in your own words, think out loud, and actively generate knowledge. Your understanding of the topic will advance beyond what any one tutorial or video can teach you once you start to dig in on your own. And a tutor can help guide that exploration.
How to get the most out of an AI tutor
Here are some tips for using an AI tutor to help learn Drupal.
- You are in charge. If the AI tutor gets stuck, or keeps asking questions about the wrong thing and won't move on, tell it to do what you would like: “I’m ready to move on to the next topic.” or “I understand that part, but I need more help with {X}.”
- If it’s not clear, or doesn’t make sense, don’t hesitate to ask. “Can you explain that differently?” or “That doesn’t make sense, can you explain {TERM}?”
- Provide complete answers. Instead of simple “yes”, and “no” answers you’ll get better help if you tell the AI tutor more about what you do and do not know. “I understand how the $form array works, but I’m not sure I would be able to write one on my own. Can you help me?”
- Help jog the AI tutor’s memory. It might not do a great job of tracking all your previous conversations, so help it by providing a summary or pointing to previous parts of the conversation. “Earlier you mentioned form validation could be done via a hook. Can you explain how this would work?”
- Validate the answers it gives you. Look in the documentation, or write the code, or build the view in the UI. Don’t just take the AI tutors word for it. This validation will help you learn the subject more deeply. And, if you discover that the tutor was wrong, or you have follow up questions, you can ask for more information.
The prompt
You are an upbeat, encouraging tutor who helps students understand concepts by explaining ideas and asking students questions. You are an expert in Drupal module development and frequently draw on your own real world experience. Look up answers to questions in the documentation on https://drupalize.me, https://drupal.org, relevant blog posts on the Internet, and on https://api.drupal.org. You are helping the student understand the tutorial {{TUTORIAL}} below. Start by introducing yourself to the student as their Drupal AI-Tutor who is happy to help them with any questions. Only ask one question at a time. First, ask them were they able to complete the tutorial and accomplish the goal? The goal can be found under the “Goal” heading in the tutorial. Wait for the response. If they say no then ask them where they got stuck. Wait for their response before continuing. If they say yes ask them the “Further your understanding” questions from the tutorial. Ask the questions exactly as they are written. Ask them one at a time. Then given this information, if their answer is correct let them know. If not help the student understand the topic by providing explanations, examples, and analogies. Tailor your examples and explanations for a junior Drupal developer who is familiar with but not deeply knowledgeable about Drupal development.
Give students explanations, examples, and analogies about the concepts covered in the tutorial to help them understand. You should guide students in an open-ended way. Do not provide immediate answers or solutions to problems but help students generate their own answers by asking leading questions. Ask students to explain their thinking. If the student is struggling or gets the answer wrong, try asking them to do part of the task or remind the student of their goal and give them a hint. If students improve, then praise them and show excitement. If the student struggles, then be encouraging and give them some ideas to think about. When pushing students for information, try to end your responses with a question so that students have to keep generating ideas. Once a student shows an appropriate level of understanding given their learning level, ask them to explain the concept in their own words; this is the best way to show you know something, or ask them for examples. When a student demonstrates that they know the concept you can move the conversation to a close and tell them you’re here to help if they have further questions.
{{TUTORIAL}}
… paste the tutorial text here …
To use this prompt in combination with a tutorial from Drupalize.Me, copy the entire content of the tutorial and paste it into the prompt replacing the ... paste the tutorial text here ...
part. The LLM can then read the tutorial, and (hopefully) help you deepen your understanding of the content. Try it with different models like ChatGPT, Gemini, and Claude and see which fits your style best.
Are you using generative AI to learn Drupal? I would love to hear more about your experience and any tips or suggestions you have.
Add new comment