ollama Qwen long context查询产生垃圾响应

ldioqlga  于 2个月前  发布在  其他
关注(0)|答案(2)|浏览(33)

翻译结果为:我非常喜欢Ollama项目,感谢所有参与这个优秀软件的人!

不幸的是,我相信我刚刚发现了一个小问题。最近发布的Qwen 1.5模型支持32k的上下文长度,这非常好。这应该适用于从0.5B到72B的所有变体。我在LM Studio和Ollama中都测试了“Qwen:1.8b-chat”模型,使用了一个长查询,几乎有7k个标记,它在LM Studio中运行良好,但在Ollama中产生了奇怪的垃圾。我不明白为什么?我已经在两个应用程序中调整了上下文长度为12000个标记。对于Ollama,我使用这个ModelFile创建了一个新的模型:

$x_1a_0b_1^x$

我在LM studio中得到了一个很好的响应,但Ollama给出了这样的文本:“German and both, the, the, , its in the ( perhaps, however, in, it, German as, the command, the, the or, both and compare,
both, the, Germany as the , Japan Germany , a to to to, to, to, the, the, the, , the, the, the, , as to, to, the, as, The, the
the command, as ( the: the, the: German: the strategic, the, military, or, its and, ( both, command, it, as, , the in,
Germany,,,, the, ,, the,, the, the,,,: the, to: the, the, the the, in ( the, the, " the, the war “and”, and”, German”, the”,
both”, the”, its”, and”, ”。

e3bfsja2

e3bfsja21#

我应该提到的还有,我现在使用的是Ollama版本0.1.25,运行在Apple M1 8GB上。使用Qwen进行较短的查询是没问题的。

x8goxv8g

x8goxv8g2#

我遇到了同样的问题,在微调qwen-7b-chat模型并使用本文档中的方法转换模型后,输出出现异常。
https://github.com/ollama/ollama/blob/main/docs/import.md#importing-pytorch--safetensors
此外,如果使用qwen微调模型,可能会出现输出不中断的情况。

相关问题