Skip to content

feat(providers): add Mistral AI provider plugin - #76391

Closed
merouaneagar wants to merge 1 commit into
NousResearch:mainfrom
merouaneagar:feat/mistral-provider
Closed

feat(providers): add Mistral AI provider plugin#76391
merouaneagar wants to merge 1 commit into
NousResearch:mainfrom
merouaneagar:feat/mistral-provider

Conversation

@merouaneagar

Copy link
Copy Markdown

Summary

Production-grade Mistral AI provider profile (api.mistral.ai) as a
bundled model-provider plugin, addressing long-standing requests
(#42357, #20859, #61160).

Wire-format quirks handled

  • reasoning_effort accepts ONLY none/high; a global Hermes medium is
    rejected (HTTP 400 / code 3051). Positive efforts are OMITTED
    rather than clamped to high: with high, Mistral streams
    delta.content as a JSON list (thinking + text parts), which crashes
    the Hermes 0.19 stream parser ("".join(content_parts) ->
    TypeError: sequence item 0: expected str instance, list found) --
    the "Stream interrupted" symptom.
  • reasoning_effort is rejected entirely on models without the
    reasoning capability -- even none (HTTP 400 / code 3051). The
    profile gates per family with exact exclusions for
    mistral-medium-2505/2508.
  • extra_body.think (Ollama quirk) is never emitted (HTTP 422).
  • Vision only on vision-capable models; supports_vision=True
    provider-wide so Hermes routes images correctly.

Included

  • plugins/model-providers/mistral/init.py + plugin.yaml
  • tests/providers/test_mistral_profile.py -- 12 tests (discovery,
    reasoning mapping contracts, never-emits-think)
  • Validated E2E against the live API: 34 chat models (basic, stream,
    tools, reasoning, vision); 32/34 OK -- the 2 failures are
    account-gated (labs-leanstral-*, HTTP 403).

Closes #42357

Production-grade Mistral profile (api.mistral.ai):
- reasoning_effort gated per model family; never emits 'high'
  (Hermes 0.19 stream parser crashes on Mistral's list-content
  reasoning deltas); explicit disable maps to 'none'
- exclusions for mistral-medium-2505/2508 (no reasoning cap)
- fetch_models filters live catalog to completion_chat models
- supports_vision=True, default_vision_model=mistral-large-latest
- never emits extra_body.think (rejected 422 by Mistral)

Tests: 12 unit tests (tests/providers/test_mistral_profile.py),
validated E2E against the live API on 34 chat models.

Closes NousResearch#42357
@teknium1

teknium1 commented Aug 1, 2026

Copy link
Copy Markdown
Contributor

Thanks for the careful provider profile and focused coverage.

This automated hermes-sweeper review is closing this under the standing in-tree-provider-integration policy:

  • The PR adds a new bundled third-party inference-provider integration at plugins/model-providers/mistral/ (fb94b17effa6).
  • AGENTS.md:797-809 requires new third-party product and niche LLM-provider integrations to ship as standalone plugin repositories, rather than adding another in-tree plugin.
  • The supported route already exists: providers/__init__.py:163-171 discovers user-installed provider plugins from $HERMES_HOME/plugins/model-providers/.

Please publish this as a standalone Mistral provider plugin users can install into ~/.hermes/plugins/ (or via a pip entry point); it can be promoted in #plugins-skills-and-skins. This is a maintenance/coupling decision, not a judgment on the implementation quality.


Closed as not-planned per standing maintainer policy (in-tree-provider-integration). This is a design-direction decision, not a code-quality judgment — see the Contribution Rubric in AGENTS.md for what the project is looking for. If you believe this policy was misapplied to your change, comment here and a maintainer will take a look.

@teknium1 teknium1 closed this Aug 1, 2026
@teknium1 teknium1 added the sweeper:not-planned Sweeper: closed per standing maintainer policy (design direction) label Aug 1, 2026
@merouaneagar

Copy link
Copy Markdown
Author

Published as a standalone plugin repository per the in-tree policy: https://github.com/merouaneagar/hermes-mistral-provider

Install with: hermes plugins install merouaneagar/hermes-mistral-provider

Same profile, same 12 tests, validated E2E on 34 chat models. Thanks for the quick review.

@alt-glitch alt-glitch added type/feature New feature or request P3 Low — cosmetic, nice to have comp/plugins Plugin system and bundled plugins labels Aug 1, 2026
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 sweeper:not-planned Sweeper: closed per standing maintainer policy (design direction) type/feature New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants