Skip to content

Agent Panel: Support for Mistral Provider tool calling #29855

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
KorigamiK opened this issue May 3, 2025 · 8 comments · Fixed by #29994
Closed

Agent Panel: Support for Mistral Provider tool calling #29855

KorigamiK opened this issue May 3, 2025 · 8 comments · Fixed by #29994
Labels
ai Improvement related to Assistant, Copilot, or other AI features

Comments

@KorigamiK
Copy link
Contributor

KorigamiK commented May 3, 2025

Summary

Currently not all providers support the tool calling necessary for use with the agent.

The Mistral provider currently lacks this functionality. (as of 2025-05-05 this has also not been implemented for LM Studio or DeepSeek too)

See also:

@KorigamiK KorigamiK added agent ai Improvement related to Assistant, Copilot, or other AI features labels May 3, 2025
@maxdeviant
Copy link
Member

which means there's virtually no benefit of using an open source editor if it locks you to subscribing to their partnered or proprietary subscription models.

We're not trying to lock anyone into using certain models or restrict which models can be used.

The providers/models that cannot use tools are only because we haven't implemented tool use for them yet.

Right now our focus is building a really great experience for the Agent, and to do that we've had to necessarily focus on Claude.

But tool use support will be coming for other models (and PRs that do so are welcome).

@notpeter notpeter changed the title Agent Panel: Allow using non-zed recommended models for tool use in the agent panel Agent Panel: Support for Mistral Provider May 5, 2025
@notpeter notpeter changed the title Agent Panel: Support for Mistral Provider Agent Panel: Support for Mistral Provider tool calling May 5, 2025
@notpeter
Copy link
Member

notpeter commented May 5, 2025

I've edited the description of this issue to update this to a feature request for the Mistral provider to support tool calling with in the Agent Panel. Thanks for reporting.

@vlebert

This comment has been minimized.

@notpeter
Copy link
Member

notpeter commented May 8, 2025

Mistral provide the same function calling API as OpenAI so why not allow tool use just to test how it behave ?

@vlebert Feel free to help test here: #29994. That's literally what we are doing.
Asking why Zed hasn't yet shipped a partially broken implementation is going to fall on deaf ears.

bennetbo added a commit that referenced this issue May 19, 2025
Closes #29855

Implement tool use handling in Mistral provider, including mapping tool
call events and updating request construction. Add support for
tool_choice and parallel_tool_calls in Mistral API requests.

This works fine with all the existing models. Didn't touched anything
else but for future. Fetching models using their models api, deducting
tool call support, parallel tool calls etc should be done from model
data from api response.

<img width="547" alt="Screenshot 2025-05-06 at 4 52 37 PM"
src="https://github.com/user-attachments/assets/4c08b544-1174-40cc-a40d-522989953448"
/>

Tasks:

- [x] Add tool call support
- [x] Auto Fetch models using mistral api
- [x] Add tests for mistral crates.
- [x] Fix mistral configurations for llm providers.

Release Notes:

- agent: Add tool call support for existing mistral models

---------

Co-authored-by: Peter Tripp <peter@zed.dev>
Co-authored-by: Bennet Bo Fenner <bennet@zed.dev>
@vlebert
Copy link

vlebert commented May 21, 2025

Hi
So the branch have been merged 2 days ago and I am on last version (0.186.12). I still can't use tools with Mistral models.

Image

Is the issue on my side ? Or is it not available yet in last version (maybe I don't understand the build cycle)

Moreover, the doc seems in advance if the main build still does not support Mistral with tools :

The Zed Assistant comes pre-configured with several Mistral models (codestral-latest, mistral-large-latest, mistral-medium-latest, mistral-small-latest, open-mistral-nemo, and open-codestral-mamba). All the default models support tool use. If you wish to use alternate models or customize their parameters, you can do so by adding the following to your Zed settings.json:

@jipiboily
Copy link

It's not in the release changelogs (preview or stable) so probably just not released yet.

@notpeter
Copy link
Member

This went out with today's Zed Preview v0.188.x
https://github.com/zed-industries/zed/releases/tag/v0.188.0-pre

In general, things in main are released on Wednesday into Preview.
Then the following week Preview becomes stable.

We ship docs immediately to reflect current main, as we do not have a fancier system such that all docs sections reflect the version(s) in which they became available.

@jipiboily
Copy link

Thanks for the release, the details about release cycle!

Also, what a great timing with devstral release! :)

And thanks to the Zed for an AMAZING editor! ❤

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
ai Improvement related to Assistant, Copilot, or other AI features
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants