Skip to content

Fix/mistral api support - #602

Merged
codelion merged 2 commits into
algorithmicsuperintelligence:mainfrom
stephba:fix/mistral-api-support
Nov 19, 2026
Merged

codelion merged 2 commits into
algorithmicsuperintelligence:mainfrom
stephba:fix/mistral-api-support

Conversation

@stephba

@stephba stephba commented Nov 18, 2026

Copy link
Copy Markdown
Contributor

Openevolve fails on the following config:

llm:
  models:
    - name: "mistral-large-4"
      reasoning_effort: "medium"
      temperature: 0.9
  api_base: "https://api.mistral.ai/v1"
  api_key: ${MISTRAL_API_KEY}

This pull request includes two fixes to add Mistral API support to openevolve:

  1. Mistral uses random_seed instead of seed (https://docs.mistral.ai/api/endpoint/chat#operation-chat_completion_v1_chat_completions_post_request_random_seed)
  2. Mistral's reasoning models return a list of chunks instead of a plain string (https://docs.mistral.ai/inference/conversations/reasoning#usage)

@CLAassistant

CLAassistant commented Nov 18, 2026 •

Copy link
Copy Markdown

CLA assistant check
All committers have signed the CLA.

@CLAassistant

Copy link
Copy Markdown

CLA assistant check
Thank you for your submission! We really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.
You have signed the CLA already but the status is still pending? Let us recheck it.

@codelion
codelion merged commit 01583a4 into algorithmicsuperintelligence:main Nov 19, 2026
5 checks passed
will-rice added a commit to will-rice/openevolve that referenced this pull request Nov 21, 2026
Upstream's fixes: a NaN combined_score ranks worst (algorithmicsuperintelligence#603), the evaluator's and
the novelty judge's LLM calls count in the token totals (algorithmicsuperintelligence#604), Mistral API
support (algorithmicsuperintelligence#602), responses cut off at max_tokens are reported (algorithmicsuperintelligence#599), nested
candidate definitions dedent (algorithmicsuperintelligence#601), llm.system_message is no longer dropped
(algorithmicsuperintelligence#598), Gemini seeding without a trailing slash (algorithmicsuperintelligence#600) and an R example fix (algorithmicsuperintelligence#597).

Two conflicts, both where the fork had moved upstream's code:
- llm/ensemble.py: upstream's per-call usage sum (_record_usage, take_usage)
  beside the fork's last_message and last_backend, both kept.
- process_parallel.py: the fork evaluates a child in _evaluate_child (generated
  and injected children alike); upstream's count of the evaluator's own LLM calls
  moves there, after the evaluation, into the result's and the metadata's usage.

The fork's suite fails the same 23 tests before and after the merge (upstream's
own, unrelated to it).

Claude-Session: https://claude.ai/code/session_01RnaESRvvoubZsW6wWrQAPQ
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants