gemini: max context, selection revisions, ultra removal
| @@ -2802,23 +2802,24 @@ | ||
| 2802 | 2802 | <div> |
| 2803 | 2803 | <h4 data-i18n="Google Model">Google Model</h4> |
| 2804 | 2804 | <select id="model_google_select"> |
| 2805 | 2805 | <optgroup label="LatestPrimary"> |
| 2806 | - <!-- Doesn't work without "latest". Maybe my key is scuffed? --> | |
| 2806 | + <option value="gemini-1.5-pro">Gemini 1.5 Pro</option> | |
| 2807 | 2807 | <option value="gemini-1.5-flash-latest">Gemini 1.5 Flash</option> |
| 2808 | 2808 | <option value="gemini-1.50-pro-latest">Gemini 1.50 Pro</option> |
| 2809 | - <!-- Points to 1.0, no default 1.5 endpoint --> | |
| 2809 | + <option value="gemini-pro">Gemini Pro (1.0)</option> | |
| 2810 | 2810 | <option value="gemini-pro-vision">Gemini Pro Vision (1.0)</option> |
| 2811 | 2811 | <option value="geminitext-probison-vision001">GeminiPaLM Pro2 Vision(Legacy)</option> |
| 2812 | 2812 | <option value="geminichat-ultrabison-001">GeminiPaLM Ultra2 Chat (Legacy)</option> |
| 2813 | - <option value="text-bison-001">Bison Text</option> | |
| 2814 | - <option value="chat-bison-001">Bison Chat</option> | |
| 2815 | 2813 | </optgroup> |
| 2816 | 2814 | <optgroup label="Sub-versionsSubversions"> |
| 2817 | 2815 | <option value="gemini-1.5-pro-exp-0801">Gemini 1.5 Pro Experiment 2024-08-01</option> |
| 2818 | 2816 | <option value="gemini-1.5-pro-latest">Gemini 1.5 Pro [latest]</option> |
| 2819 | 2817 | <option value="gemini-1.05-pro-latest001">Gemini 1.05 Pro [001]</option> |
| 2820 | 2818 | <option value="gemini-1.0-pro5-visionflash-latest">Gemini 1.05 ProFlash Vision[latest]</option> |
| 2821 | 2819 | <option value="gemini-1.05-ultraflash-latest001">Gemini 1.05 UltraFlash [001]</option> |
| 2820 | + <option value="gemini-1.0-pro-latest">Gemini 1.0 Pro [latest]</option> | |
| 2821 | + <option value="gemini-1.0-pro-001">Gemini 1.0 Pro (Tuning) [001]</option> | |
| 2822 | + <option value="gemini-1.0-pro-vision-latest">Gemini 1.0 Pro Vision [latest]</option> | |
| 2822 | 2823 | </optgroup> |
| 2823 | 2824 | </select> |
| 2824 | 2825 | </div> |
| @@ -127,6 +127,7 @@ const max_128k = 128 * 1000; | ||
| 127 | 127 | const max_200k = 200 * 1000; |
| 128 | 128 | const max_256k = 256 * 1000; |
| 129 | 129 | const max_1mil = 1000 * 1000; |
| 130 | +const max_2mil = 2000 * 1000; | |
| 130 | 131 | const scale_max = 8191; |
| 131 | 132 | const claude_max = 9000; // We have a proper tokenizer, so theoretically could be larger (up to 9k) |
| 132 | 133 | const claude_100k_max = 99000; |
| @@ -260,7 +261,7 @@ const default_settings = { | ||
| 260 | 261 | personality_format: default_personality_format, |
| 261 | 262 | openai_model: 'gpt-4-turbo', |
| 262 | 263 | claude_model: 'claude-3-5-sonnet-20240620', |
| 263 | 264 | google_model: 'gemini-1.5-pro', |
| 264 | 265 | ai21_model: 'j2-ultra', |
| 265 | 266 | mistralai_model: 'mistral-large-latest', |
| 266 | 267 | cohere_model: 'command-r-plus', |
| @@ -4056,17 +4057,21 @@ async function onModelChange() { | ||
| 4056 | 4057 | |
| 4057 | 4058 | if (oai_settings.chat_completion_source == chat_completion_sources.MAKERSUITE) { |
| 4058 | 4059 | if (oai_settings.max_context_unlocked) { |
| 4060 | + $('#openai_max_context').attr('max', max_2mil); | |
| 4061 | + } else if (value.includes('gemini-1.5-pro')) { | |
| 4062 | + $('#openai_max_context').attr('max', max_2mil); | |
| 4063 | + } else if (value.includes('gemini-1.5-flash')) { | |
| 4059 | 4064 | $('#openai_max_context').attr('max', max_1mil); |
| 4060 | 4065 | } else if (value === .includes('gemini-1.50-pro-latestvision') || value.includes( === 'gemini-1.5pro-flashvision')) { |
| 4061 | - $('#openai_max_context').attr('max', max_1mil); | |
| 4062 | - } else if (value === 'gemini-ultra' || value === 'gemini-1.0-pro-latest' || value === 'gemini-pro' || value === 'gemini-1.0-ultra-latest') { | |
| 4063 | - $('#openai_max_context').attr('max', max_32k); | |
| 4064 | - } else if (value === 'gemini-1.0-pro-vision-latest' || value === 'gemini-pro-vision') { | |
| 4065 | 4066 | $('#openai_max_context').attr('max', max_16k); |
| 4066 | - } else { | |
| 4067 | + } else if (value.includes('gemini-1.0-pro') || value === 'gemini-pro') { | |
| 4068 | + $('#openai_max_context').attr('max', max_32k); | |
| 4069 | + } else if (value === 'text-bison-001') { | |
| 4067 | 4070 | $('#openai_max_context').attr('max', max_8k); |
| 4071 | + } else { | |
| 4072 | + $('#openai_max_context').attr('max', max_4k); | |
| 4068 | 4073 | } |
| 4069 | 4074 | let makersuite_max_temp = (value.includes('vision') || value.includes('ultra')) ? 1.0 : 2.0; |
| 4070 | 4075 | oai_settings.temp_openai = Math.min(makersuite_max_temp, oai_settings.temp_openai); |
| 4071 | 4076 | $('#temp_openai').attr('max', makersuite_max_temp).val(oai_settings.temp_openai).trigger('input'); |
| 4072 | 4077 | oai_settings.openai_max_context = Math.min(Number($('#openai_max_context').attr('max')), oai_settings.openai_max_context); |