Merge pull request #2600 from Succubyss/gemini-1.5-pro-exp-0801

This commit is contained in:
Cohee 2024-08-02 21:39:19 +03:00 committed by GitHub
commit 4b61bcc741
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
5 changed files with 15 additions and 2 deletions

View File

@ -2805,6 +2805,7 @@
<optgroup label="Latest"> <optgroup label="Latest">
<!-- Doesn't work without "latest". Maybe my key is scuffed? --> <!-- Doesn't work without "latest". Maybe my key is scuffed? -->
<option value="gemini-1.5-flash-latest">Gemini 1.5 Flash</option> <option value="gemini-1.5-flash-latest">Gemini 1.5 Flash</option>
<option value="gemini-1.5-pro-latest">Gemini 1.5 Pro</option>
<!-- Points to 1.0, no default 1.5 endpoint --> <!-- Points to 1.0, no default 1.5 endpoint -->
<option value="gemini-pro">Gemini Pro</option> <option value="gemini-pro">Gemini Pro</option>
<option value="gemini-pro-vision">Gemini Pro Vision</option> <option value="gemini-pro-vision">Gemini Pro Vision</option>
@ -2813,6 +2814,7 @@
<option value="chat-bison-001">Bison Chat</option> <option value="chat-bison-001">Bison Chat</option>
</optgroup> </optgroup>
<optgroup label="Sub-versions"> <optgroup label="Sub-versions">
<option value="gemini-1.5-pro-exp-0801">Gemini 1.5 Pro Experiment 2024-08-01</option>
<option value="gemini-1.5-pro-latest">Gemini 1.5 Pro</option> <option value="gemini-1.5-pro-latest">Gemini 1.5 Pro</option>
<option value="gemini-1.0-pro-latest">Gemini 1.0 Pro</option> <option value="gemini-1.0-pro-latest">Gemini 1.0 Pro</option>
<option value="gemini-1.0-pro-vision-latest">Gemini 1.0 Pro Vision</option> <option value="gemini-1.0-pro-vision-latest">Gemini 1.0 Pro Vision</option>

View File

@ -44,6 +44,8 @@
<option data-type="anthropic" value="claude-3-haiku-20240307">claude-3-haiku-20240307</option> <option data-type="anthropic" value="claude-3-haiku-20240307">claude-3-haiku-20240307</option>
<option data-type="google" value="gemini-pro-vision">gemini-pro-vision</option> <option data-type="google" value="gemini-pro-vision">gemini-pro-vision</option>
<option data-type="google" value="gemini-1.5-flash-latest">gemini-1.5-flash-latest</option> <option data-type="google" value="gemini-1.5-flash-latest">gemini-1.5-flash-latest</option>
<option data-type="google" value="gemini-1.5-pro-latest">gemini-1.5-pro-latest</option>
<option data-type="google" value="gemini-1.5-pro-exp-0801">gemini-1.5-pro-exp-0801</option>
<option data-type="openrouter" value="openai/gpt-4-vision-preview">openai/gpt-4-vision-preview</option> <option data-type="openrouter" value="openai/gpt-4-vision-preview">openai/gpt-4-vision-preview</option>
<option data-type="openrouter" value="openai/gpt-4o">openai/gpt-4o</option> <option data-type="openrouter" value="openai/gpt-4o">openai/gpt-4o</option>
<option data-type="openrouter" value="openai/gpt-4-turbo">openai/gpt-4-turbo</option> <option data-type="openrouter" value="openai/gpt-4-turbo">openai/gpt-4-turbo</option>

View File

@ -4665,10 +4665,14 @@ export function isImageInliningSupported() {
// gultra just isn't being offered as multimodal, thanks google. // gultra just isn't being offered as multimodal, thanks google.
const visionSupportedModels = [ const visionSupportedModels = [
'gpt-4-vision', 'gpt-4-vision',
'gemini-1.5-flash-latest',
'gemini-1.5-flash', 'gemini-1.5-flash',
'gemini-1.5-flash-latest',
'gemini-1.5-flash-001',
'gemini-1.0-pro-vision-latest', 'gemini-1.0-pro-vision-latest',
'gemini-1.5-pro',
'gemini-1.5-pro-latest', 'gemini-1.5-pro-latest',
'gemini-1.5-pro-001',
'gemini-1.5-pro-exp-0801',
'gemini-pro-vision', 'gemini-pro-vision',
'claude-3', 'claude-3',
'claude-3-5', 'claude-3-5',

View File

@ -271,7 +271,7 @@ async function sendMakerSuiteRequest(request, response) {
}; };
function getGeminiBody() { function getGeminiBody() {
const should_use_system_prompt = ['gemini-1.5-flash-latest', 'gemini-1.5-pro-latest'].includes(model) && request.body.use_makersuite_sysprompt; const should_use_system_prompt = ['gemini-1.5-flash', 'gemini-1.5-pro'].includes(model) && request.body.use_makersuite_sysprompt;
const prompt = convertGooglePrompt(request.body.messages, model, should_use_system_prompt, request.body.char_name, request.body.user_name); const prompt = convertGooglePrompt(request.body.messages, model, should_use_system_prompt, request.body.char_name, request.body.user_name);
let body = { let body = {
contents: prompt.contents, contents: prompt.contents,

View File

@ -264,8 +264,13 @@ function convertGooglePrompt(messages, model, useSysPrompt = false, charName = '
const PNG_PIXEL = 'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII='; const PNG_PIXEL = 'iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVR42mNkYAAAAAYAAjCB0C8AAAAASUVORK5CYII=';
const visionSupportedModels = [ const visionSupportedModels = [
'gemini-1.5-flash',
'gemini-1.5-flash-latest', 'gemini-1.5-flash-latest',
'gemini-1.5-flash-001',
'gemini-1.5-pro',
'gemini-1.5-pro-latest', 'gemini-1.5-pro-latest',
'gemini-1.5-pro-001',
'gemini-1.5-pro-exp-0801',
'gemini-1.0-pro-vision-latest', 'gemini-1.0-pro-vision-latest',
'gemini-pro-vision', 'gemini-pro-vision',
]; ];