Trigger inputs

085d852b5784aedeb2739b3f9c948b70c6c24664

Cohee <18619528+Cohee1207@users.noreply.github.com>

1 files changed, +4 -0Ignore whitespace
public/scripts/openai.js+4 -0
@@ -4330,6 +4330,10 @@ async function onModelChange() {
43304330 } else {
43314331 $('#openai_max_context').attr('max', max_128k);
43324332 }
4333+
4334+ oai_settings.openai_max_context = Math.min(Number($('#openai_max_context').attr('max')), oai_settings.openai_max_context);
4335+ $('#openai_max_context').val(oai_settings.openai_max_context).trigger('input');
4336+ $('#temp_openai').attr('max', oai_max_temp).val(oai_settings.temp_openai).trigger('input');
43334337 }
43344338
43354339 if (oai_settings.chat_completion_source === chat_completion_sources.COHERE) {