FastGPT icon indicating copy to clipboard operation
FastGPT copied to clipboard

AI 模型的参数配置的回复上限没有用

Open hugefrog opened this issue 10 months ago • 11 comments

例行检查

  • [x] 我已确认目前没有类似 issue
  • [x ] 我已完整查看过项目 README,以及项目文档
  • [x] 我使用了自己的 key,并确认我的 key 是可正常使用的
  • [x] 我理解并愿意跟进此 issue,协助测试和提供反馈
  • [x] 我理解并认可上述内容,并理解项目维护者精力有限,不遵循规则的 issue 可能会被无视或直接关闭

你的版本 4.6.9 和4.7.1

  • [ ] 公有云版本
  • [ ] 私有部署版本, 具体版本号:

问题描述 AI 模型的参数配置的“”回复上限”设置没有用,在大模型的API服务端收到的request中没有看到这个数值。 复现步骤

预期结果

相关截图 1

hugefrog avatar Apr 25 '24 09:04 hugefrog

你自己过滤了把。设置100 max token,回答截断,说明生效了(都不需要测)

image

c121914yu avatar Apr 25 '24 10:04 c121914yu

没有啊,都是默认设置。在哪里可以过滤?

---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 18:13 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) |

你自己过滤了把

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

hugefrog avatar Apr 25 '24 11:04 hugefrog

100

这就得问你的接口怎么写的了

c121914yu avatar Apr 25 '24 12:04 c121914yu

接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。

---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) |

100

这就得问你的接口怎么写的了

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

hugefrog avatar Apr 25 '24 13:04 hugefrog

接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢?

c121914yu avatar Apr 25 '24 13:04 c121914yu

我没表达清楚吗?那个request是我在fastgpt输入问题问大模型以后,fastgpt生成并由oneapi转到我的大模型api的。我的大模型的http 接口收到的就是那个request,我动都没动,我怎么改。fastgpt和oneapi的代码我也没动过。

---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:14 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) |

接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢?

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

hugefrog avatar Apr 25 '24 13:04 hugefrog

我没表达清楚吗?那个request是我在fastgpt输入问题问大模型以后,fastgpt生成并由oneapi转到我的大模型api的。我的大模型的http 接口收到的就是那个request,我动都没动,我怎么改。fastgpt和oneapi的代码我也没动过。 ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:14 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢? — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.>

我感觉表达清楚了。 就是指oneapi已经给你发maxtoken了,是你自己过滤掉了。可能是你,可能是你的框架,但是无所谓,重要是oneapi已经发出去了。

c121914yu avatar Apr 25 '24 13:04 c121914yu

框架我是用qwen的open_ai.py基础上改的。

---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:36 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) |

我没表达清楚吗?那个request是我在fastgpt输入问题问大模型以后,fastgpt生成并由oneapi转到我的大模型api的。我的大模型的http 接口收到的就是那个request,我动都没动,我怎么改。fastgpt和oneapi的代码我也没动过。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:14 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢? — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.>

我感觉表达清楚了。 就是指oneapi已经给你发maxtoken了,是你自己过滤掉了。可能是你,可能是你的框架,但是无所谓,重要是oneapi已经发出去了。

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

hugefrog avatar Apr 25 '24 13:04 hugefrog

他这个request这么写的

---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:36 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) |

我没表达清楚吗?那个request是我在fastgpt输入问题问大模型以后,fastgpt生成并由oneapi转到我的大模型api的。我的大模型的http 接口收到的就是那个request,我动都没动,我怎么改。fastgpt和oneapi的代码我也没动过。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:14 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢? — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.>

我感觉表达清楚了。 就是指oneapi已经给你发maxtoken了,是你自己过滤掉了。可能是你,可能是你的框架,但是无所谓,重要是oneapi已经发出去了。

— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

hugefrog avatar Apr 25 '24 13:04 hugefrog

他这个request这么写的 ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:36 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 我没表达清楚吗?那个request是我在fastgpt输入问题问大模型以后,fastgpt生成并由oneapi转到我的大模型api的。我的大模型的http 接口收到的就是那个request,我动都没动,我怎么改。fastgpt和oneapi的代码我也没动过。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:14 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢? — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 我感觉表达清楚了。 就是指oneapi已经给你发maxtoken了,是你自己过滤掉了。可能是你,可能是你的框架,但是无所谓,重要是oneapi已经发出去了。 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>

那就是了,它不是openai接口规范~ 他叫max length,不叫max token

c121914yu avatar Apr 25 '24 13:04 c121914yu

他这个request这么写的 ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:36 | | 收件人 | _@**._> | | 抄送至 | _@.>@._> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 我没表达清楚吗?那个request是我在fastgpt输入问题问大模型以后,fastgpt生成并由oneapi转到我的大模型api的。我的大模型的http 接口收到的就是那个request,我动都没动,我怎么改。fastgpt和oneapi的代码我也没动过。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 21:14 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 接口是fastgpt和oneapi的啊我没改,我的大模型收到的http request就是那个样子,就只有温度参数。 … ---- 回复的原邮件 ---- | 发件人 | @.> | | 日期 | 2024年04月25日 20:34 | | 收件人 | @.> | | 抄送至 | @.>@.> | | 主题 | Re: [labring/FastGPT] AI 模型的参数配置的回复上限没有用 (Issue #1289) | 100 这就得问你的接口怎么写的了 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 谁知道你模型接口咋写的。topK也没传,你不也显示None了,如果max token没传,你为啥不显示None呢? — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.> 我感觉表达清楚了。 就是指oneapi已经给你发maxtoken了,是你自己过滤掉了。可能是你,可能是你的框架,但是无所谓,重要是oneapi已经发出去了。 — Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: _@_.*>

那就是了,它不是openai接口规范~ 他叫max length,不叫max token

把qwen定义ChatCompletionRequest用的max_length改成max_tokens,然后数值就传到max_tokens里面了。谢谢!!

hugefrog avatar Apr 26 '24 01:04 hugefrog