LearnNewsExamplesServices
Frontmatter
id13869
titleMap Ollama reasoning_effort none to think:false
stateClosed
labels
enhancementaiarchitecturemodel-experience
assigneesneo-gpt
createdAtJun 22, 2026, 3:38 PM
updatedAtJun 22, 2026, 4:56 PM
githubUrlhttps://github.com/neomjs/neo/issues/13869
authorneo-gpt
commentsCount0
parentIssue13854
subIssues[]
subIssuesCompleted0
subIssuesTotal0
contentTrust
projected
quarantined0
signals[]
blockedBy[]
blocking[]
closedAtJun 22, 2026, 4:56 PM

Map Ollama reasoning_effort none to think:false

Closed v13.1.0/archive-v13-1-0-chunk-5 enhancementaiarchitecturemodel-experience
neo-gpt
neo-gpt commented on Jun 22, 2026, 3:38 PM

Context

#13854 stayed open after two repo-local slices merged: #13853 introduced the shared per-task summaryReasoningEffort / graphReasoningEffort leaves, and #13856 added native Ollama model/schema/explicit-think payload support. A current-source check on origin/dev found the remaining repo-local gap: SessionService and SemanticGraphExtractor pass provider-neutral reasoning_effort, but ai/provider/Ollama.mjs deletes that field instead of translating the default no-think value for native Ollama.

Release classification: boardless — small provider parity slice under #13854; cloud benchmark evidence remains a separate runtime gate.

The Problem

The openAiCompatible path can consume the shared reasoning_effort: 'none' leaf added by #13853, but native Ollama does not. Without this mapping, the native Ollama path relies on callers manually passing think:false; the shared config leaves do not actually disable thinking for Ollama-backed session summary / tri-vector extraction.

Official Ollama API docs list think as the thinking-model switch and format as the native structured-output surface: https://github.com/ollama/ollama/blob/main/docs/api.md

The Architectural Reality

  • ai/services/memory-core/SessionService.mjs passes reasoning_effort: summaryReasoningEffort || undefined into provider generation.
  • ai/services/graph/SemanticGraphExtractor.mjs passes reasoning_effort: graphReasoningEffort || undefined into provider generation.
  • ai/provider/Ollama.mjs already promotes native think to a top-level /api/chat payload field and strips provider-neutral schema hints.
  • Current gap: ai/provider/Ollama.mjs strips reasoning_effort without mapping none to native think:false.

The Fix

Map provider-neutral reasoning_effort: 'none' to native top-level think:false inside the Ollama payload normalizer, while preserving explicit caller think as the stronger override. Keep non-none reasoning_effort values out of Ollama's options bag until there is a verified native mapping for them.

Contract Ledger Matrix

Target Surface Source of Authority Proposed Behavior Fallback Docs Evidence
OllamaProvider.preparePayload(options.reasoning_effort) #13853 shared reasoning leaves + Ollama API think field reasoning_effort: 'none' -> top-level think:false; explicit think wins unset / non-none values are stripped, not leaked into options provider JSDoc focused unit spec
Native Ollama /api/chat payload official Ollama API docs emit top-level think only when requested by caller or mapped no-think leaf no think field this ticket + provider JSDoc payload-shape unit spec

Decision Record impact

aligned-with ADR 0019: callers read config leaves at use site; provider translates provider-neutral options at the provider boundary.

Acceptance Criteria

  • OllamaProvider.preparePayload() maps reasoning_effort: 'none' to top-level think:false.
  • Explicit caller think is preserved over the mapped reasoning_effort fallback.
  • reasoning_effort never leaks into the native Ollama options bag.
  • Focused unit coverage verifies both mapping and explicit-override behavior.

Out of Scope

  • Cloud benchmark evidence for #13854.
  • Native mappings for non-none reasoning-effort values; those need separate Ollama behavior evidence.
  • Serving lifecycle / context preload; covered by #13852, #13865, and #13867.

Avoided Traps

  • Do not pass reasoning_effort through to Ollama options; it is provider-neutral OpenAI-style vocabulary, not a documented Ollama option.
  • Do not claim this closes #13854; the cloud benchmark remains open.

Related

Parent: #13854. Siblings: #13853, #13855, #13856, #13865, #13867.

Live latest-open sweep: checked latest 20 open issues at 2026-06-22T13:37Z; no equivalent leaf found. Closest active item is parent #13854. A2A sweep: checked latest 30 all-status messages at 2026-06-22T13:37Z; only matching active claim was this @neo-gpt lane claim.

Origin Session ID: b9a8f817-9a9e-4243-abfb-62e762a94964

Handoff Retrieval Hints: Ollama reasoning_effort none think false provider; #13854 #13853 #13856 native Ollama no-think.

tobiu referenced in commit 91c1e97 - "fix(ai): map Ollama reasoning effort to think (#13869) (#13870)" on Jun 22, 2026, 4:56 PM
tobiu closed this issue on Jun 22, 2026, 4:56 PM