跳到正文
DEV Community· MLH Team·· 3 小時前AI 評分47

Prompt Pad:在提示詞中設定角色,提升 AI 回答品質

Prompt Pad: Frame Your Persona for Better AI Answers

AI 導讀

Prompt Pad 示範如何在系統提示詞中設定模型角色,以提升回答品質。角色設定可界定模型運用的專業知識、語氣和理想答案形式;為常用提示詞加上一行角色描述,再比較回答。

正文

Major League Hacking (MLH) profile image MLH Team

Want better answers from AI? Start by telling it who to be.

In this episode of Prompt Pad, @rosendo_pili shows how setting your model's persona in the system prompt immediately improves the quality of its answers.

The tip in a nutshell

Before you ask the question, give the model a role. "You are a senior backend engineer reviewing a pull request" gets you a very different answer than a bare "review this code." A persona tells the model what expertise to draw on, what tone to use, and what a good answer looks like.

Try it yourself

Pick a prompt you use often and add a one-line persona to the top. Compare the two answers side by side. Then share your best persona in the comments 👇


📣 Help us spread the word

Know someone whose AI answers could use an upgrade? Send them this video. And subscribe so you don't miss the next Prompt Pad tip:

來源:DEV Community · dev.to