diff --git a/lib/core/providers/app_providers.dart b/lib/core/providers/app_providers.dart index 30b58a4..198d7f2 100644 --- a/lib/core/providers/app_providers.dart +++ b/lib/core/providers/app_providers.dart @@ -1002,7 +1002,8 @@ Future loadConversation(Ref ref, String conversationId) async { } // Provider to automatically load and set the default model from user settings or OpenWebUI -final defaultModelProvider = FutureProvider((ref) async { +@riverpod +Future defaultModel(Ref ref) async { // Initialize the settings watcher (side-effect only) ref.read(_settingsWatcherProvider); // Read settings without subscribing to rebuilds to avoid watch/await hazards @@ -1148,7 +1149,7 @@ final defaultModelProvider = FutureProvider((ref) async { DebugLogger.error('set-default-failed', scope: 'models/default', error: e); return null; } -}); +} // Background model loading provider that doesn't block UI // This just schedules the loading, doesn't wait for it