Skip to content

feat(ollama-cloud): wire reasoning_effort (xhigh→max) [salvage #29221] - #51494

Merged
teknium1 merged 2 commits into
mainfrom
hermes/hermes-0c1c66e0
Jun 23, 2026
Merged

feat(ollama-cloud): wire reasoning_effort (xhigh→max) [salvage #29221]#51494
teknium1 merged 2 commits into
mainfrom
hermes/hermes-0c1c66e0

Conversation

@teknium1

Copy link
Copy Markdown
Contributor

Summary

Ollama Cloud now honors agent.reasoning_effort — previously it was dead config there.

The ollama-cloud profile was a bare 14-line ProviderProfile whose build_api_kwargs_extras() returned ({}, {}), so reasoning_config was silently dropped and the model always ran at the server default (high for DeepSeek). This adds the same build_api_kwargs_extras override Kimi/DeepSeek already have.

Changes

  • plugins/model-providers/ollama-cloud/__init__.py: OllamaCloudProfile subclass emits top-level reasoning_effort. xhigh/maxmax (DeepSeek V4 "Max thinking"), low/medium/high pass through, none/enabled: false omit it.
  • tests/plugins/model_providers/test_ollama_cloud_profile.py (new): 17 tests — mapping, pass-through, disabled/none suppression, full transport integration.
  • scripts/release.py: AUTHOR_MAP entry for @s010mn (CI strict-mode gate).

Validation

effort wire reasoning_effort
xhigh / max max
low / medium / high unchanged
none / disabled omitted

Cherry-picked clean onto current main; 61 tests pass (new + existing ollama-cloud suite); E2E through the real ChatCompletionsTransport.build_kwargs path confirms each mapping. Contributor's live curl test: high → 642 chars reasoning, max → 1576 chars (2.45×).

Salvage of #29221 by @s010mn — authorship preserved via rebase-merge.

Infographic

ollama-cloud reasoning_effort wired

s010mn and others added 2 commits June 23, 2026 11:30
Map Hermes xhigh→max to unlock DeepSeek V4's 'Max thinking' tier
through Ollama Cloud's OpenAI-compatible /v1/chat/completions endpoint.
low/medium/high pass through unchanged; disabled/none suppress
reasoning entirely.

Empirically confirmed: reasoning_effort:max produces ~2.5× more
thinking tokens than high on deepseek-v4-pro:cloud (1576 vs 642).
@github-actions

Copy link
Copy Markdown
Contributor

🔎 Lint report: hermes/hermes-0c1c66e0 vs origin/main

ruff

Total: 0 on HEAD, 0 on base (➖ 0)

🆕 New issues: none

✅ Fixed issues: none

Unchanged: 0 pre-existing issues carried over.

ty (type checker)

Total: 11118 on HEAD, 11115 on base (🆕 +3)

🆕 New issues (3):

Rule Count
unresolved-attribute 2
unresolved-import 1
First entries
tests/run_agent/test_credits_notices_toggle.py:76: [unresolved-attribute] unresolved-attribute: Unresolved attribute `_credits_session_start_micros` on type `AIAgent`
run_agent.py:2984: [unresolved-attribute] unresolved-attribute: Object of type `Self@get_credits_spent_micros` has no attribute `_credits_session_start_micros`
tests/plugins/model_providers/test_ollama_cloud_profile.py:15: [unresolved-import] unresolved-import: Cannot resolve imported module `pytest`

✅ Fixed issues (1):

Rule Count
invalid-assignment 1
First entries
tests/run_agent/test_credits_notices_toggle.py:76: [invalid-assignment] invalid-assignment: Object of type `None` is not assignable to attribute `_credits_session_start_micros` of type `int`

Unchanged: 5858 pre-existing issues carried over.

Diagnostics are surfaced as warnings — this check never fails the build.

@alt-glitch alt-glitch added type/feature New feature or request comp/plugins Plugin system and bundled plugins provider/ollama Ollama / local models P3 Low — cosmetic, nice to have labels Jun 23, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

This was generated by AI during triage.

Related (salvage, not duplicate): salvages #29221 (@s010mn) onto current main with authorship preserved. This is the core-maintainer version of the ollama-cloud reasoning_effort cluster alongside competing OPEN community salvage #51482 (same scope, filed ~25min earlier) and the superset #30262 (adds DeepSeek thinking-mode). One of these should be picked; the others closed.

@teknium1
teknium1 merged commit 64131bf into main Jun 23, 2026
48 of 50 checks passed
@teknium1
teknium1 deleted the hermes/hermes-0c1c66e0 branch June 23, 2026 18:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp/plugins Plugin system and bundled plugins P3 Low — cosmetic, nice to have provider/ollama Ollama / local models type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants