26条提示词工程策略

#原则中文原则
1No need to be polite with LLM so there is no need to add phrases like “please”, “if you don’t mind”, “thank you”, “I would like to”, etc., and get straight to the point.不需要对 LLM 使用礼貌用语,因此无需添加诸如“请”、“如果您不介意”、“谢谢”、“我想”之类的短语,直接开门见山即可。
2Break down complex tasks into a sequence of simpler prompts in an interactive conversation.在交互式对话中,将复杂的任务分解成一系列简单的提示。
3Integrate the intended audience in the prompt, e.g., the audience is an expert in the field.在提示中整合目标受众,例如,受众是该领域的专家。
4Employ affirmative directives such as “do”, while steering clear of negative language like “don’t”.使用肯定的指示词,例如“做”,同时避免使用否定语言,例如“不要”。
5When you need clarity or a deeper understanding of a topic, idea, or any piece of information, utilize the following prompts: o Explain [insert specific topic] in simple terms. o Explain to me like I’m 11 years old. o Explain to me as if I’m a beginner in [field]. o Write the [essay/text/paragraph] using simple English like you’re explaining something to a 5-year-old.当您需要清晰或更深入地理解某个主题、想法或任何信息时,请使用以下提示: o 用简单的术语解释 [插入特定主题]。 o 像给我 11 岁的孩子解释一样解释给我听。 o 像给我这个领域的初学者解释一样解释给我听。 o 使用简单的英语写 [文章/文本/段落],就像你在向一个 5 岁的孩子解释一样。
6Add “I’m going to tip $xxx for a better solution!”添加“如果能得到更好的解决方案,我将支付 xxx 美元的小费!”
7Implement example-driven prompting (Use few-shot prompting).实施示例驱动的提示(使用少量样本提示)。
8When formatting your prompt, start with ###Instruction###, followed by either ###Example### or ###Question### if relevant. Subsequently, present your content. Use one or more line breaks to separate instructions, examples, questions, context, and input data.在格式化提示时,以 ###Instruction### 开头,然后根据需要后跟 ###Example### 或 ###Question###。随后,呈现您的内容。使用一个或多个换行符来分隔指令、示例、问题、上下文和输入数据。
9Incorporate the following phrases: “Your task is” and “You MUST”.合并以下短语:“您的任务是”和“您必须”。
10Incorporate the following phrases: “You will be penalized”.合并以下短语:“您将受到惩罚”。
11Use the phrase “Answer a question given in a natural, human-like manner” in your prompts.在您的提示中使用短语“以自然、类似人类的方式回答问题”。
12Use leading words like writing “think step by step”.使用引导词,例如写“逐步思考”。
13Add to your prompt the following phrase “Ensure that your answer is unbiased and does not rely on stereotypes”.在您的提示中添加以下短语“确保您的答案没有偏见,并且不依赖于刻板印象”。
14Allow the model to elicit precise details and requirements from you by asking you questions until he has enough information to provide the needed output (for example, “From now on, I would like you to ask me questions to…”).允许模型通过向您提出问题来获取精确的细节和要求,直到它有足够的信息来提供所需的输出(例如,“从现在开始,我希望您问我问题以……”)。
15To inquire about a specific topic or idea or any information and you want to test your understanding, you can use the following phrase: “Teach me the [Any theorem/topic/rule name] and include a test at the end, but don’t give me the answers and then tell me if I got the answer right when I respond”.要询问特定主题或想法或任何信息,并且您想测试您的理解,可以使用以下短语:“教我 [任何定理/主题/规则名称] 并在最后包含测试,但不要给出答案,然后告诉我当我回答时是否答对了”。
16Assign a role to the large language models.为大型语言模型分配角色。
17Use Delimiters.使用分隔符。
18Repeat a specific word or phrase multiple times within a prompt.在提示中多次重复特定单词或短语。
19Combine Chain-of-thought (CoT) with few-Shot prompts.将思维链 (CoT) 与少量样本提示相结合。
20Use output primers, which involve concluding your prompt with the beginning of the desired output. Utilize output primers by ending your prompt with the start of the anticipated response.使用输出启动器,这涉及用所需输出的开头结束您的提示。通过以预期响应的开头结束您的提示来利用输出启动器。
21To write an essay/text/paragraph/article or any type of text that should be detailed: “Write a detailed [essay/text /paragraph] for me on [topic] in detail by adding all the information necessary”.要撰写应详细说明的文章/文本/段落/文章或任何类型的文本:“详细地为我撰写关于 [主题] 的详细 [文章/文本/段落],添加所有必要的信息”。
22To correct/change specific text without changing its style: “Try to revise every paragraph sent by users. You should only improve the user’s grammar and vocabulary and make sure it sounds natural. You should not change the writing style, such as making a formal paragraph casual”.要在不改变其风格的情况下纠正/更改特定文本:“尝试修改用户发送的每个段落。您应该只改进用户的语法和词汇,并确保它听起来自然。您不应该改变写作风格,例如使正式的段落变得随意”。
23When you have a complex coding prompt that may be in different files: “From now and on whenever you generate code that spans more than one file, generate a [programming language ] script that can be run to automatically create the specified files or make changes to existing files to insert the generated code. [your question]”当您有一个可能位于不同文件中的复杂编码提示时:“从现在开始,每当您生成跨越多个文件的代码时,生成一个 [编程语言] 脚本,该脚本可以运行以自动创建指定的文件或对现有文件进行更改以插入生成的代码。 [你的问题]”
24When you want to initiate or continue a text using specific words, phrases, or sentences, utilize the following prompt: o I’m providing you with the beginning [song lyrics/story/paragraph/essay…]: [Insert lyrics/words/sentence]… Finish it based on the words provided. Keep the flow consistent.当您想使用特定的单词、短语或句子来开始或继续文本时,请使用以下提示: o 我将为您提供开头 [歌词/故事/段落/文章……]: [插入歌词/单词/句子]……根据提供的单词完成它。保持流程一致。
25Clearly state the requirements that the model must follow in order to produce content, in the form of the keywords, regulations, hint, or instructions清楚地说明模型为了生成内容而必须遵循的要求,以关键词、规定、提示或说明的形式
26To write any text, such as an essay or paragraph, that is intended to be similar to a provided sample, include the following instructions: o Please use the same language based on the provided paragraph/[title/text/essay/answer].要撰写任何文本(例如文章或段落),使其与提供的示例相似,请包含以下说明: o 请使用与提供的段落/[标题/文本/文章/答案] 相同的语言。

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.mzph.cn/pingmian/14613.shtml

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈email:809451989@qq.com,一经查实,立即删除!

相关文章

springboot集成达梦数据库8

springboot集成达梦数据库8 官方文档&#xff1a;[https://eco.dameng.com/document/dm/zh-cn/start/java-development.html](https://eco.dameng.com/document/dm/zh-cn/start/java-development.html) 引入maven依赖 <!--添加数据库驱动安装包--> <dependency> …

Threejs路径规划_基于A*算法案例完整版

上节利用了A*实现了基础的路径规划&#xff0c;这节把整个功能完善好&#xff0c;A*算法一方面是基于当前点找到可以到达的点&#xff0c;计算从出发点到此点&#xff0c;以及此点到目的地的总成本&#xff0c;比较出最小的那个&#xff0c;再用最小成本的点继续找到它可以到达…

明天(周六)下午!武汉Linux爱好者线下沙龙,我们在华中科技大学等你!

2024 年 5月 25 日&#xff08;周六&#xff09;下午&#xff0c;我们将在「武汉市洪山区」 珞喻路 1037 号华中科技大学南五楼 613 室举办武汉 Linux 爱好者线下沙龙&#xff08;WHLUG&#xff09;&#xff0c;欢迎广大 Linux 爱好者来到现场&#xff0c;与我们一同交流技术&a…

git分支开发主干合并流程

文章目录 一、分支开发二、主干合并三、删除合并过的分支 一、分支开发 创建分支git branch <分支名> # git branch my_new_branch开发后提交代码git commit -m 本次开发内容 # git commit -m 增加登录保持功能同步远端仓库git push origin <分支名> # git push o…

Kubernetes——资源调度与Pod探针

目录 前言 一、资源调度策略 1.默认调度器&#xff08;Default Scheduler&#xff09; 2.自定义调度器&#xff08;Custom Scheduler&#xff09; 3.亲和性与反亲和性&#xff08;Affinity and Anti-Affinity&#xff09; 4.污点与容忍&#xff08;Taints and Toleration…

单体应用与微服务的优缺点

单体应用与微服务的优缺点 单体应用&#xff08;monolith application&#xff09;就是将应用程序的所有功能都打包成一个独立的单元&#xff0c;可以是 JAR、WAR、EAR 或其它归档格式。 随着业务需求的快速发展变化&#xff0c;敏捷性、灵活性和可扩展性需求不断增长&#x…

Window GDI+ API有BUG?GetBounds测不准?

文章目录 GraphicsPath的GetBounds测不准&#xff1f;方法一&#xff1a;GetBounds ()实战 方法二&#xff1a;GetBounds(Matrix)实战 GraphicsPath的GetBounds测不准?实战 .NET 版本的问题&#xff1f;C也一样&#xff0c;不是.NET的问题怀疑人生MiterLimit惹得祸完美结果结束…

MyBatis-Plus介绍及Spring Boot 3集成指南

我们每个Java开发者都在使用springbootmybatis开发时&#xff0c;我们经常发现自己需要为每张数据库表单独编写XML文件&#xff0c;并且为每个表都需要编写一套增删改查的方法&#xff0c;较为繁琐。为了解决这一问题&#xff0c;MyBatis-Plus应运而生。在本文中&#xff0c;我…

第七节:带你全面理解vue3: 其他响应式进阶API

前言: 针对vue3官网中, 响应式:进阶API 中, 我们在上一章中给大家讲解了shallowRef, shallowReactive, shallowReadonly几个API的使用. 本章主要对剩下的API 进行讲解, 我们先看一下官网中进阶API 都有那些 对于剩下这些API, 你需要了解他们创建目的, 是为了解决之前的API存在…

查看cpu进程数

import multiprocessing from multiprocessing import Pool# 导入 Pool 允许你创建一个进程池 # 进程池是一组工作进程&#xff0c;它们可以并行地执行多个任务# multiprocessing.cpu_count(): 返回当前机器上的CPU核心数 sum_cpu multiprocessing.cpu_count()use_cpu max(1,…

LLM多模态——GPT-4o改变人机交互的多模式 AI 模型应用

1. 概述 OpenAI 发布了迄今为止最新、最先进的语言模型 – GPT-4o也称为“全“ 模型。这一革命性的人工智能系统代表了一次巨大的飞跃&#xff0c;其能力模糊了人类和人工智能之间的界限。 GPT-4o 的核心在于其原生的多模式特性&#xff0c;使其能够无缝处理和生成文本、音频…

AWPortrait1.4更新,人物的生成更加趋近真实感,将SD1.5人像的真实感提升到了一个新的高度

AWPortrait1.4更新&#xff0c;人物的生成更加趋近真实感&#xff0c;将SD1.5人像的真实感提升到了一个新的高度 经过5个月&#xff0c;AWPortrait终于迎来了1.4。 本次更新基于1.3训练&#xff0c;使得人物的生成更加趋近真实感&#xff0c;将SD1.5人像的真实感提升到了一个新…

SpringBoot(七)之监控

SpringBoot&#xff08;七&#xff09;之监控 Spring Boot 提供了丰富的监控和管理功能&#xff0c;可以通过 Spring Boot Actuator 组件实现。Actuator 使你能够监控和管理 Spring Boot 应用程序的各个方面&#xff0c;比如健康检查、指标、环境信息等。以下是如何在 Spring …

EUT上电时,测试LISN拾取的脉冲电压对接收机的影响

背景&#xff1a;在2024年4月25日发现G220 IP20 FSF1测试结果不一致&#xff0c;有5dB差异&#xff0c;经排查&#xff0c;是两台接收机测试出的结果不一致&#xff0c;经过进一步确认&#xff0c;使用信号发生器直接灌入接收机DI-111内&#xff0c;测试出的结果会少4dB.使用梳…

linux-ftp服务器搭建简介

安装ftp服务器&#xff1a; vsftpd全称为“very secure FTP daemon”&#xff0c;是一个在UNIX类操作系统上运行的服务&#xff0c;可以提供高安全性的FTP服务。 vsftpd是一个免费和开放源代码的FTP服务器软件&#xff0c;它提供了许多其他FTP服务器不支持的特性&#xff0c;例…

基于python+Django大数据的电影市场预测分析系统设计与实现

博主介绍&#xff1a; 大家好&#xff0c;本人精通Java、Python、C#、C、C编程语言&#xff0c;同时也熟练掌握微信小程序、Php和Android等技术&#xff0c;能够为大家提供全方位的技术支持和交流。 我有丰富的成品Java、Python、C#毕设项目经验&#xff0c;能够为学生提供各类…

uview1.0 u-form表单回显校验不通过

提交到后端的数据&#xff0c;回显后不做任何修改无法通过表单校验 原因&#xff0c;u-form表单校验的类型默认为string&#xff0c;但是后端返回的是integer类型&#xff0c;导致无法通过校验 解决&#xff0c;既然后端返回的是整数形&#xff0c;那么我们就将校验规则的type…

html 根字号 以及 设置根元素font-size:calc(100vw/18.75)、元素rem实现自适应

rem 单位介绍&#xff1a;rem 是相对文档根元素(html)字体大小的尺寸单位&#xff0c;当元素的尺寸或文字字号等使用 rem 单位时&#xff0c;会随着根元素的 font-size变化而变化。 得出结论&#xff1a;在不同分辨率的设备下动态设置根元素的字体大小就可以实现页面自适应。 …

【企业动态】东胜物联成为AWS硬件合作伙伴,助力实现边缘智能

近日&#xff0c;AIoT硬件设备供应商东胜物联与全球领先的云计算服务提供商亚马逊云&#xff08;AWS&#xff09;达成合作关系&#xff0c;共同致力于推动物联网技术的发展&#xff0c;为企业客户提供更智能、灵活的硬件解决方案&#xff0c;助力智能化升级和数字化转型。 作为…

Android studio关闭自动更新

Windows下&#xff1a; 左上角file - setting - Appearance & Behavier - system setting - update - 取消勾选