ateVoices();
            } catch (err) {
                console.error('Error fetching models:', err);
                showError(err.toString());
            } finally {
                refreshIcon.classList.toggle('refreshing');
                refreshBtn.disabled = false;
            }
        }

        refreshBtn.addEventListener('click', refreshModels);
        refreshModels();
        // End: Refresh Logic

        // Update slider values in real-time
        temperature.addEventListener('input', () =