feat: catalogue dynamique modèles Codex/Claude avec compatibilité CLI locale
Ajout du catalogue enrichi pour les modèles Codex et Claude avec: - Compatibilité estimée avec la version CLI locale détectée - Source d'origine (catalogue/Provider) pour chaque entrée - Support du catalogue Provider API externe - Matrice de compatibilité embarquée dans l'application Frontend: - UI de configuration des modèles avec affichage des états de compatibilité - Suggestions dynamiques avec badges de compatibilité - Messages d'aide contextuels (compatible/unknown/likelyTooRecent) - Alertes non-bloquantes pour les modèles trop récents - Gestion des échecs de catalogue avec saisie manuelle conservée Backend: - Ports CliVersionReader, ProviderModelCatalogue, CompatibilityMatrixSource - Implémentations: ProcessCliVersionReader, HttpProviderModelCatalogue, EmbeddedCompatibilityMatrix - Enrichissement des DTOs avec compatibility, cli_version, warnings - Tests unitaires complets pour le resolver de catalogue
This commit is contained in:
@ -12,7 +12,7 @@ import type {
|
||||
AgentProfile,
|
||||
FirstRunState,
|
||||
OpenCodeProviderCatalogEntry,
|
||||
ProfileModelCatalogEntry,
|
||||
ProfileModelCatalog,
|
||||
ProfileAvailability,
|
||||
} from "@/domain";
|
||||
import type {
|
||||
@ -21,6 +21,7 @@ import type {
|
||||
ProfileGateway,
|
||||
SaveOpenCodeProviderProfileInput,
|
||||
} from "@/ports";
|
||||
import { normalizeProfileModelCatalog } from "./profileCatalog";
|
||||
|
||||
export class TauriProfileGateway implements ProfileGateway {
|
||||
firstRunState(): Promise<FirstRunState> {
|
||||
@ -59,12 +60,12 @@ export class TauriProfileGateway implements ProfileGateway {
|
||||
});
|
||||
}
|
||||
|
||||
listClaudeModels(): Promise<ProfileModelCatalogEntry[]> {
|
||||
return invoke<ProfileModelCatalogEntry[]>("list_claude_models");
|
||||
async listClaudeModels(): Promise<ProfileModelCatalog> {
|
||||
return normalizeProfileModelCatalog(await invoke<unknown>("list_claude_models"));
|
||||
}
|
||||
|
||||
listCodexModels(): Promise<ProfileModelCatalogEntry[]> {
|
||||
return invoke<ProfileModelCatalogEntry[]>("list_codex_models");
|
||||
async listCodexModels(): Promise<ProfileModelCatalog> {
|
||||
return normalizeProfileModelCatalog(await invoke<unknown>("list_codex_models"));
|
||||
}
|
||||
|
||||
configureProfiles(profiles: AgentProfile[]): Promise<AgentProfile[]> {
|
||||
|
||||
Reference in New Issue
Block a user