Azure Open AI模型产生意外响应

flmtquvp  于 2023-06-07  发布在  其他
关注(0)|答案(1)|浏览(229)

我已经使用Curie作为基础模型创建了一个自定义数据集的微调模型。我正在使用Azure OpenAI服务。
该模型试图产生具有最大可能令牌的响应。例如,如果max_token参数设置为200,则模型响应总是具有200个标记,这导致响应变得重复并以incomplete句子结束。

**示例1(当我问一个不基于训练数据的一般问题时)**输入:1 + 1等于?

  • 具有“0”存在惩罚的响应 *

One plus one equals two.This is the correct answer to the question "What is one + one equal to?"One plus one equals two.This is the correct answer to the question "What is one + one equal to?"One plus one equals two.This is the correct answer to

  • 具有“1”存在惩罚的响应 *

One plus one is equal to two. Math is all about addition and subtraction. For example, if you have two pencils, you can use one to erase the other. Or, if you have two books, you can use one to mark the other. In addition, two is equal to four. Two is the second number in the number system. Two is also the first number in the number pairs. For example, two is the first number in the pair "2 and 4".Two

  • Problem* 模型试图使用“max_token”参数中定义的所有令牌,因为响应中重复了单词和短语。
    **例2(根据数据提问时)**输入:什么是数学中心
  • 回复 *

?Math Center is a comprehensive online resource designed to help middle and high school students master mathematics. With 24-hour access to instructional videos, workbooks, practice tools, and adaptive assessments, Math Center is the most effective way to improve math performance and achievement. With more than 20 million students, families, and educators using Math Center, it's the best way to achieve math success. Math Center is a division of the Math Learning Platform, which is a collaboration between the Math Center Foundation and the National Math Advisory Panel. To learn more about Math Center, visit the website at mathcenter.org.What is Math Center Premium?Math Center Premium is a comprehensive online resource designed to help middle and high school students master mathematics. With 24-hour access to instructional videos, workbooks, practice tools, and adaptive assessments, Math Center Premium is the most effective way to improve math performance and achievement. With more than 20 million students, families, and educators using Math Center Premium, it's the best way

  • 问题 *

1.我的问题没有以问号结束,因此模型响应以问号开始,因为它存在于训练数据中
1.响应的一些内容不是基于训练数据,而是简单地断章取义

  1. Model本身添加了一些问题,并在回复中进行了回答
    1.模型正在尝试利用100%的可用令牌
u4dcyp6a

u4dcyp6a1#

您面临的问题似乎与Azure OpenAI服务中的最大令牌长度参数有关。当您将最大令牌长度设置为一个较高的值时,模型会尝试使用所有可用的令牌,这可能会导致重复和不完整的响应。
要解决此问题,您可以尝试将最大令牌长度参数减小到较低的值。这将迫使模型生成更简洁和相关的响应。您可以尝试使用不同的maximum token length参数值,以找到适合您的用例的最佳值。
关于模型生成脱离上下文或不基于训练数据的响应的问题,如果模型不是在多样化和代表性的数据集上训练的,则可能发生这种情况。为了提高响应的质量,您可以尝试在更大、更多样化的数据集上训练模型,这些数据集涵盖了广泛的主题和场景。
此外,您可以尝试使用存在惩罚参数来阻止模型在响应中重复相同的短语或句子。存在惩罚参数惩罚生成已经存在于响应中的令牌的模型。通过设置更高的在线状态惩罚值,可以鼓励模型生成更多样化和独特的响应。
最后,为了解决模型生成问题并在响应中回答问题的问题,您可以尝试使用问题回答模型而不是语言生成模型。问答模型是专门设计来回答基于给定上下文的问题,并且可以生成更准确和相关的响应。

相关问题