Class MistralAiProvider
java.lang.Object
uno.anahata.asi.agi.event.BasicPropertyChangeSource
uno.anahata.asi.agi.provider.AbstractAiProvider
uno.anahata.asi.openai.compatible.OpenAiChatCompletionsProvider
uno.anahata.asi.mistral.MistralAiProvider
- All Implemented Interfaces:
PropertyChangeSource, Rebindable
Dedicated AI Provider for Mistral AI using their native OpenAI-compatible API.
This provider parses rich capability flags, FIM endpoints, reasoning tags, and context lengths directly from Mistral's /v1/models JSON endpoint.
- Author:
- anahata
-
Field Summary
Fields inherited from class BasicPropertyChangeSource
propertyChangeSupport -
Constructor Summary
ConstructorsConstructorDescriptionConstructs a new Mistral AI provider with stable UUID "Mistral". -
Method Summary
Modifier and TypeMethodDescriptionprotected OpenAiCompatibleModelcreateModel(com.fasterxml.jackson.databind.JsonNode node) Constructs a concrete model instance for this provider.Gets a template or hint string to display when the API keys file is empty.Methods inherited from class OpenAiChatCompletionsProvider
createHttpClient, createRequestBuilder, hokusPocus, isRetryable, listModelsMethods inherited from class AbstractAiProvider
ensureKeysFileExists, findModel, getAllSupportedActions, getCurrentKey, getKeysAcquisitionUri, getKeysFilePath, getModels, getNextKey, getProviderDirectory, getProviderId, hasKeys, refreshModels, reloadKeyPoolMethods inherited from class BasicPropertyChangeSource
addPropertyChangeListener, addPropertyChangeListener, rebind, removePropertyChangeListener, removePropertyChangeListenerMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface PropertyChangeSource
getPropertyChangeSupport
-
Constructor Details
-
MistralAiProvider
public MistralAiProvider()Constructs a new Mistral AI provider with stable UUID "Mistral".
-
-
Method Details
-
createModel
Constructs a concrete model instance for this provider.Creates a specialized
MistralModelthat parses capabilities, context lengths, and FIM endpoints.- Overrides:
createModelin classOpenAiChatCompletionsProvider- Parameters:
node- The JSON node containing model metadata.- Returns:
- A new model instance.
-
getApiKeyHint
Gets a template or hint string to display when the API keys file is empty.Implementation details: Provides a standard header hint for the multi-key configuration file.
Provides the Mistral-specific key hint for the api_keys.txt configuration file.
- Overrides:
getApiKeyHintin classOpenAiChatCompletionsProvider- Returns:
- The API key hint text.
-

