当前位置:首页> AI教程> ChatGPT使用最佳实践系列第4篇 – 给GPT思考的时间

ChatGPT使用最佳实践系列第4篇 – 给GPT思考的时间

释放双眼,带上耳机,听听看~!
本文是ChatGPT使用最佳实践系列第4篇,介绍了如何给GPT思考时间,使大模型的回答效果更好。通过引导大模型给出自己的解和从第一性原理出发重新设计系统消息,可以提升大模型的回答效果。

背景

OpenAI官方详细介绍了ChatGPT使用的最佳实践,不仅适用于使用ChatGPT网站进行直接对话的用户,还适用于通过OpenAI API接入的开发者。

掌握了这些最佳实践,就能更好地利用GPT大模型。

本文是ChatGPT使用最佳实践系列第4篇 – 给GPT思考的时间。

假设你被问到 17乘以28 是多少,大概率没办法立马给出回答。但是经过几秒的心算你就可以得到正确的结果。

GPT在做推理的时候也是同理,如果能给大模型思考的时间,让大模型分步推理,往往回答效果会更好。

策略1:引导大模型给出自己的解

直接让大模型立马给出结论往往不能达到最佳效果,比如下面的例子:

system Determine if the student’s solution is correct or not.
user Problem Statement: I’m building a solar power installation and I need help working out the financials.
– Land costs 100/squarefoot<br>−Icanbuysolarpanelsfor100 / square foot <br>- I can buy solar panels for 250 / square foot
– I negotiated a contract for maintenance that will cost me a flat 100kperyear,andanadditional100k per year, and an additional 10 / square foot
What is the total cost for the first year of operations as a function of the number of square feet.
Student’s Solution: Let x be the size of the installation in square feet. 1. Land cost: 100x 2. Solar panel cost: 250x 3. Maintenance cost: 100,000 + 100x Total cost: 100x + 250x + 100,000 + 100x = 450x + 100,000
assistant The student’s solution is correct.

显然上面GPT给出的回答是错误的。

但是我们如果从第一性原理(第一性原理指的是,回归事物最基本的条件,将其拆分成各要素进行解构分析,从而找到实现目标最优路径的方法)出发,重新设计system消息,那大模型的回答效果可以更好,参考下面的例子:

system First work out your own solution to the problem. Then compare your solution to the student’s solution and evaluate if the student’s solution is correct or not. Don’t decide if the student’s solution is correct until you have done the problem yourself.
user Problem Statement: I’m building a solar power installation and I need help working out the financials.
– Land costs 100/squarefoot<br/>−Icanbuysolarpanelsfor100 / square foot <br/>- I can buy solar panels for 250 / square foot
– I negotiated a contract for maintenance that will cost me a flat 100kperyear,andanadditional100k per year, and an additional 10 / square foot
What is the total cost for the first year of operations as a function of the number of square feet.
Student’s Solution: Let x be the size of the installation in square feet. 1. Land cost: 100x 2. Solar panel cost: 250x 3. Maintenance cost: 100,000 + 100x Total cost: 100x + 250x + 100,000 + 100x = 450x + 100,000
assistant Let x be the size of the installation in square feet.
1. Land cost: 100x
2. Solar panel cost: 250x
3. Maintenance cost: 100,000 + 10x
Total cost: 100x + 250x + 100,000 + 10x = 360x + 100,000

The student’s solution is incorrect. They made an error in the maintenance cost calculation, using 100x instead of 10x. The correct total cost for the first year of operations is 360x + 100,000.

可以通过这个链接地址进行体验:platform.openai.com/docs/guides…

本网站的内容主要来自互联网上的各种资源,仅供参考和信息分享之用,不代表本网站拥有相关版权或知识产权。如您认为内容侵犯您的权益,请联系我们,我们将尽快采取行动,包括删除或更正。
AI教程

ES(ElasticSearch)语义搜索系统搭建教程

2023-11-23 10:26:14

AI教程

二次型及其标准型 - 了解配方法和正/负定二次型

2023-11-23 10:34:14

个人中心
购物车
优惠劵
今日签到
有新私信 私信列表
搜索