Skip to content

The easy-to-use open source Business Intelligence and Embedded Analytics tool that lets everyone work with data :bar_chart:

Correct the Mistral alias names in the whitelisted-id docstring (#83864)

Paolo Rascunàe6cf339241a2
diff --git a/src/metabase/metabot/self/mistral.clj b/src/metabase/metabot/self/mistral.clj
index e19f9ca2729..264a8f71f90 100644
--- a/src/metabase/metabot/self/mistral.clj
+++ b/src/metabase/metabot/self/mistral.clj
@@ -52,10 +52,13 @@
(reasoning-model? model))
(defn- whitelisted-id
- "The [[supported-models]] id a `/models` catalog entry resolves to, or nil when unsupported.
- Mistral models have a generic `:id` like `mistral-medium-latest` but `:aliases` contains version specific aliases
- like `mistral-medium-3-5` or `mistral-medium-2604`, so a whitelisted id is matched against the entry's own id and
- its aliases."
+ "The [[supported-models]] id that a `/models` catalog entry resolves to, or nil when unsupported.
+
+ Each catalog entry has one `:id` and a list of `:aliases`
+ (https://docs.mistral.ai/openapi.yaml, `BaseModelCard`). One model can have several names: Mistral Medium 3.5
+ has `mistral-medium-3-5`, `mistral-medium-3` and `mistral-medium-latest`
+ (https://docs.mistral.ai/models/mistral-medium-3-5-26-04). The whitelisted id can be the `:id` or an alias, so
+ this checks both."
[{:keys [id aliases]}]
(some #(when (contains? supported-models %) %)
(cons id aliases)))