PulseAugur
实时 00:42:11
English(EN) Ollama's Default Context Length, and Why It Is Not the Number You Read

Ollama 的上下文长度默认设置令人困惑,并且会默默地截断对话

Ollama 的默认上下文长度在不同配置中的文档记录和应用不一致。文档中至少显示了三个相互冲突的默认值:Modelfile 参考中的 2048,基于可用 VRAM 的可变长度(4k、32k、256k),以及嵌入在模型镜像本身中的值。最具体的设置,例如在模型 Modelfile 或单个请求的选项中定义的设置,会覆盖更广泛的默认设置,如环境变量或基于 VRAM 的分层。一个严重的问题是,当提示超过有效的上下文窗口时,Ollama 会默默地丢弃较早的消息,而没有任何用户可见的指示或错误,仅在调试级别记录截断。 AI

影响 由于上下文被默默截断,用户在使用长对话时可能会遇到意外行为,从而影响 Ollama 在复杂任务上的可靠性。

排序理由 文章讨论的是现有 AI 工具的配置和行为,而不是新发布或重要的行业事件。

在 dev.to — LLM tag 阅读 →

AI 生成摘要 · Google Gemini · 来自 1 个来源。 我们如何撰写摘要 →

Ollama 的上下文长度默认设置令人困惑,并且会默默地截断对话

报道来源 [1]

  1. dev.to — LLM tag TIER_1 English(EN) · Multigrid ·

    Ollama 的默认上下文长度,以及为什么它不是你读到的那个数字

    <p>People arrive at this question because a model with a 128K context window forgot the beginning of a 20,000-token document and said nothing about it. The context that applied was not the model’s. Ollama documents at least three different defaults in three different places, and …