# language_models: Fix tool calling for \`x-ai/grok-code-fast-1\` model via OpenRouter \(\#37094\) · gitcafe/zed

[View on GitCafe](https://git.cafe/gitcafe/zed/commit/c8e99125bdeafb08cb185c64251bf6ea1a523564)

Repository: [gitcafe/zed](https://git.cafe/gitcafe/zed)

Visibility: public

Requested revision: c8e99125bdeafb08cb185c64251bf6ea1a523564

Requested commit: c8e99125bdeafb08cb185c64251bf6ea1a523564

Commit: c8e99125bdeafb08cb185c64251bf6ea1a523564

Tree: 4b95628c83a070c46282c280375a42982b837557

Author: Umesh Yadav

Committer: GitHub

## Message

```
language_models: Fix tool calling for `x-ai/grok-code-fast-1` model via OpenRouter (#37094)

Closes #37022
Closes #36994

This update ensures all Grok models use the JsonSchemaSubset format for
tool schemas.

A previous fix for this issue was too specific, only targeting grok-4
models. This caused other variants, like grok-code-fast-1, to be missed.
We've now broadened the logic to correctly apply the setting to the
entire Grok model family.

Release Notes:

- Fix tool calling for `x-ai/grok-code-fast-1` model via OpenRouter.
```

## Parents

- [835e5ba662e5bade1a4bd91a45e64faa7f64aff4](https://git.cafe/gitcafe/zed/commit/835e5ba662e5bade1a4bd91a45e64faa7f64aff4?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zed/tree/c8e99125bdeafb08cb185c64251bf6ea1a523564?format=markdown)
