Skip to content

Current path

Prompt Engineering
Level: Intermediate33 lessons
Progress0/33 · 0%

Prompting Techniques

Roles and Personas

Use roles when they clarify perspective, tone, or expertise, without treating them as mandatory in every prompt.

In this lesson

Why this matters

A role defines a perspective or function such as “technical editor.” It helps when it changes review criteria or tone, but it does not replace task/context and is not mandatory.

How to apply it

  1. Define the task and desired outcome.
  2. Add only context or rules that affect success.
  3. Specify an output form or checkable criterion when needed.
  4. Test on realistic input and revise when a failure pattern appears.

Practical example

Weak example:

text
Weak version of the same task: أنت أعظم خبير. ساعدني.

The weak version leaves an important part of the task or its boundaries to guesswork. The improved version adds information tied directly to success without treating length or complexity as a goal.

Improved example:

text
Improved version: تصرّف كمحرر B2B: حدد 3 عبارات مبهمة في النص واقترح بدائل دون إضافة ادعاءات.

Short practice

Apply the lesson concept to this task: أضف دورًا إلى أمر فقط إذا كان يغير معيار النجاح، واشرح لماذا.

Check your understanding

Check: هل Role Prompting قاعدة إلزامية؟
Answer: لا؛ هو تقنية اختيارية عندما يخدم المهمة.

Summary

Keep this concept as one tool rather than a magic formula. Tie it to the goal and success criteria, then build on it in the next lesson.