💬 提示工程:把话说清楚💬 Prompt Engineering: Say What You Mean
上一片,通才机器人经过微调,成了能上岗的专才。可上岗以后,它要根据当前上下文工作。这一片学怎么跟它说话:同一个模型,问法不同,答案天差地别。Last leaf, fine-tuning turned our generalist robot into a job-ready specialist. On the job, it works from its current context. This leaf is about talking to it: same model, different wording, wildly different answers.
第 1 步:模型不会读心Step 1: The model can't read your mind
先看一个翻车现场:班长只打了四个字。First, a flop: the class monitor typed just three words.
提示词(Prompt)就是你发给模型的那段话。模型根据当前上下文回答,看不到你脑子里的计划。班长想的是周五去森林公园春游,它却只读到「写个通知」。于是它只能猜:开会?比赛?出游?最后交出一份放哪个班都行的空话。模糊的问题,只能换来模糊的答案。A prompt is the text you send to a model. The model uses its current context, not the plan in your head. The monitor means a spring trip to Forest Park this Friday, but the model reads only “Write a notice”. So it guesses: a meeting? a match? a trip? — and hands back empty words that would fit any class. A vague question gets a vague answer.
那要补哪些话,它才答得准?So what do you add to get a sharp answer?
第 2 步:四块积木:角色、任务、格式、示例Step 2: Four blocks: role, task, format, example
角色:告诉它扮演谁,比如「亲切、重视安全的班主任助手」,语气和重点就跟着变。具体任务:把事情说具体——周五 8 点、校门口集合、去森林公园、带午饭和水。格式:说清长什么样,比如「分 3 条,每条一句话」。示例:给一份以前的通知,让它照着那个样子写。这四块能减少歧义,并非每次都必需。具体任务最要紧,结果仍需核对。Role: tell it who to be — say, “a friendly class teacher's assistant who cares about safety” — and its tone and priorities follow. Specific task: spell out the job — Friday at 8, the school gate, Forest Park, bring lunch and water. Format: say what shape you want — “3 lines, one sentence each”. Example: show it an old notice and let it copy that style. These blocks can reduce ambiguity, though not every task needs all four. The specific task matters most, and outputs still need checking.
这只是写个通知。做 AI 产品的人,怎么用这一招?That's just a notice. How do people who build AI products use this?
第 3 步:工程师怎么写提示词Step 3: How engineers write prompts
做 AI 产品的人,会把好用的提示词写成模板:角色说明、输出格式固定写好,再留个空填进用户的问题。改一个词,就拿几十个问题试一遍,比比哪版答得更好。他们还会把复杂任务拆成可核验的小步骤。效果因模型和任务而异,要用测试比较。和微调不同,提示工程不改模型里任何参数,只改你说的话——又快又便宜。Teams building AI products turn good prompts into templates: the role and the output format are written once, with a blank slot for each user's question. Change one word, then rerun dozens of test questions to see which version answers better. They may break complex work into checkable steps. Effects depend on the model and task and should be measured in tests. Unlike fine-tuning, prompt engineering changes no parameters inside the model — only your words. Fast and cheap.
🎮 你来当提示词工程师(30 秒)🎮 Your turn: prompt engineer (30 seconds)
道理讲完了。先点亮四块积木,看回答怎么从含糊变精准;再诊断 4 份翻车回答,找出缺的是哪一块。Theory done. Switch on the four blocks and watch the answer go from vague to precise; then diagnose 4 flopped answers and find the missing block.
一句话记住它:提示工程 = 把需求说清楚。交代角色、具体任务、输出格式,按需给示例,减少歧义并检验结果。Remember it in one line: prompt engineering = saying clearly what you need. Give a role, a specific task, an output format and an example — then test whether the output meets the need.
模型根据可用上下文回答,不会读心:模糊的问题 → 模糊的答案The model uses available context and cannot read minds: vague question → vague answer四块积木:角色(扮演谁)、任务(具体做什么)、格式(长什么样)、示例(照着写)Four blocks: role (who to be), task (exactly what to do), format (what shape), example (what to copy)提示工程不改模型参数,只改说法;好提示词要反复试、反复改Prompt engineering changes no model parameters, only the wording — good prompts come from testing and tweaking
把握度:明确任务与测试的作用较高;具体提示效果依模型而异。互动回答为预先编写的示例,不调用模型,也不保证实际输出。AI 辅助制作与资料核对。Confidence: high for clear tasks and evaluation; prompt effects vary by model. Responses in the activity are authored examples, not live model calls or output guarantees. AI-assisted production and source checking.