mirror of
https://github.com/LostRuins/koboldcpp.git
synced 2026-05-20 01:09:57 +00:00
update lite
This commit is contained in:
parent
c32b4305e2
commit
9cf2119cb8
1 changed files with 43 additions and 15 deletions
|
|
@ -12860,6 +12860,25 @@ Current version indicated by LITEVER below.
|
|||
return (epchoice==7 || epchoice==10 || epchoice==11);
|
||||
}
|
||||
|
||||
function find_oai_model()
|
||||
{
|
||||
inputBox("Find model by name (case insensitive)\nBest match will be selected.","Find model by name","","", ()=>{
|
||||
let coai = getInputBoxValue().trim();
|
||||
let dropdown = get_custom_ep_model_dropdown();
|
||||
var mdlopt = dropdown.querySelector('option.custom_model_option');
|
||||
if(coai!="")
|
||||
{
|
||||
coai = coai.toLowerCase();
|
||||
for (var i = 0; i < dropdown.options.length; i++) {
|
||||
if (dropdown.options[i].text.toLowerCase().indexOf(coai) !== -1) {
|
||||
dropdown.selectedIndex = i;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
oai_model_change(ep_should_always_use_chat_completions());
|
||||
},false);
|
||||
}
|
||||
function select_custom_oai_model()
|
||||
{
|
||||
inputBox("Enter custom model name","Custom Model Name",localsettings.saved_oai_custommodel,"", ()=>{
|
||||
|
|
@ -13138,9 +13157,6 @@ Current version indicated by LITEVER below.
|
|||
|
||||
function toggleclaudemodel()
|
||||
{
|
||||
document.getElementById("claudesystemprompt").classList.remove("hidden");
|
||||
document.getElementById("claudejailbreakprompt").classList.remove("hidden");
|
||||
|
||||
if(document.getElementById("custom_claude_model").value.toLowerCase().includes("claude-3-7")||
|
||||
document.getElementById("custom_claude_model").value.toLowerCase().includes("claude-sonnet-4")||
|
||||
document.getElementById("custom_claude_model").value.toLowerCase().includes("claude-haiku-4")||
|
||||
|
|
@ -20667,6 +20683,7 @@ Current version indicated by LITEVER below.
|
|||
|
||||
let sysprompt = document.getElementById("claudesystemprompt").value;
|
||||
let assistantprompt = document.getElementById("claudejailbreakprompt").value;
|
||||
let assistantpromptrole = document.getElementById("claudejailbreakpromptrole").value;
|
||||
let claudethinking = (document.getElementById("claudethinking").checked?true:false);
|
||||
|
||||
claude_payload =
|
||||
|
|
@ -20730,7 +20747,8 @@ Current version indicated by LITEVER below.
|
|||
}
|
||||
if(assistantprompt)
|
||||
{
|
||||
claude_payload.messages.push({"role": "assistant", "content": assistantprompt});
|
||||
let usedrole = (assistantpromptrole==2)?"system":(assistantpromptrole==1?"assistant":"user");
|
||||
claude_payload.messages.push({"role": usedrole, "content": assistantprompt});
|
||||
}
|
||||
|
||||
|
||||
|
|
@ -30582,7 +30600,7 @@ Current version indicated by LITEVER below.
|
|||
<input class="form-control" name="username" autocomplete="username" type="text" id="custom_oai_endpoint" placeholder="OpenAI API URL" value="" onblur="">
|
||||
<input class="form-control" name="password" autocomplete="current-password" type="password" id="custom_oai_key" placeholder="API Key (Required)" value="" onfocus="focus_api_keys()" onblur="blur_api_keys()"><br>
|
||||
Model Choice:<br>
|
||||
<select title="OpenAI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control" id="custom_oai_model" onchange="oai_model_change(true)">
|
||||
<select title="OpenAI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control" id="custom_oai_model" onchange="oai_model_change(true)">
|
||||
<option value="gpt-3.5-turbo-instruct" selected="selected">gpt-3.5-turbo-instruct</option>
|
||||
<option value="davinci-002">davinci-002</option>
|
||||
<option value="gpt-3.5-turbo">gpt-3.5-turbo</option>
|
||||
|
|
@ -30609,7 +30627,7 @@ Current version indicated by LITEVER below.
|
|||
<option value="o4-mini">o4-mini</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<select title="OpenRouter AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control hidden" id="custom_openrouter_model" onchange="oai_model_change(true)">
|
||||
<select title="OpenRouter AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control hidden" id="custom_openrouter_model" onchange="oai_model_change(true)">
|
||||
<option value="openai/gpt-3.5-turbo">openai/gpt-3.5-turbo</option>
|
||||
<option value="openai/gpt-4">openai/gpt-4</option>
|
||||
<option value="openai/gpt-4o">openai/gpt-4o</option>
|
||||
|
|
@ -30620,7 +30638,7 @@ Current version indicated by LITEVER below.
|
|||
<option value="gryphe/mythomax-l2-13b">gryphe/mythomax-l2-13b</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<select title="Mistral AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control hidden" id="custom_mistralai_model" onchange="oai_model_change(true)">
|
||||
<select title="Mistral AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control hidden" id="custom_mistralai_model" onchange="oai_model_change(true)">
|
||||
<option value="open-mistral-7b">open-mistral-7b</option>
|
||||
<option value="open-mistral-nemo">open-mistral-nemo</option>
|
||||
<option value="open-mixtral-8x22b">open-mixtral-8x22b</option>
|
||||
|
|
@ -30636,7 +30654,7 @@ Current version indicated by LITEVER below.
|
|||
<option value="codestral-latest">codestral-latest</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<select title="Featherless AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control hidden" id="custom_featherless_model" onchange="oai_model_change(true)">
|
||||
<select title="Featherless AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control hidden" id="custom_featherless_model" onchange="oai_model_change(true)">
|
||||
<option value="Sao10K/L3-8B-Lunaris-v1">Sao10K/L3-8B-Lunaris-v1</option>
|
||||
<option value="Sao10K/L3-8B-Stheno-v3.2">Sao10K/L3-8B-Stheno-v3.2</option>
|
||||
<option value="unsloth/llama-3-8b-Instruct">unsloth/llama-3-8b-Instruct</option>
|
||||
|
|
@ -30650,7 +30668,7 @@ Current version indicated by LITEVER below.
|
|||
<option value="meta-llama/Meta-Llama-3.1-405B-Instruct">meta-llama/Meta-Llama-3.1-405B-Instruct</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<select title="Grok AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control hidden" id="custom_grok_model" onchange="oai_model_change(true)">
|
||||
<select title="Grok AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control hidden" id="custom_grok_model" onchange="oai_model_change(true)">
|
||||
<option value="grok-2-1212">grok-2-1212</option>
|
||||
<option value="grok-3" selected>grok-3</option>
|
||||
<option value="grok-3-mini">grok-3-mini</option>
|
||||
|
|
@ -30658,7 +30676,7 @@ Current version indicated by LITEVER below.
|
|||
<option value="grok-4-0709">grok-4-0709</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<select title="Pollinations AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control hidden" id="custom_pollinations_model" onchange="oai_model_change(true)">
|
||||
<select title="Pollinations AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control hidden" id="custom_pollinations_model" onchange="oai_model_change(true)">
|
||||
<option value="bidara">bidara</option>
|
||||
<option value="chickytutor">chickytutor</option>
|
||||
<option value="gemini">gemini</option>
|
||||
|
|
@ -30668,7 +30686,7 @@ Current version indicated by LITEVER below.
|
|||
<option value="openai-fast">openai-fast</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<select title="Nvidia NIM AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 220px)" class="form-control hidden" id="custom_nvidianim_model" onchange="oai_model_change(true)">
|
||||
<select title="Nvidia NIM AI Model Selection" style="padding:4px;display:inline;width:calc(100% - 200px)" class="form-control hidden" id="custom_nvidianim_model" onchange="oai_model_change(true)">
|
||||
<option value="deepseek-ai/deepseek-v3.1-terminus">deepseek-ai/deepseek-v3.1-terminus</option>
|
||||
<option value="google/gemma-3-27b-it">google/gemma-3-27b-it</option>
|
||||
<option value="meta/llama-3.3-70b-instruct">meta/llama-3.3-70b-instruct</option>
|
||||
|
|
@ -30679,8 +30697,9 @@ Current version indicated by LITEVER below.
|
|||
<option value="z-ai/glm4.7">z-ai/glm4.7</option>
|
||||
<option style="display:none;" class="custom_model_option" value="custom">[Custom]</option>
|
||||
</select>
|
||||
<button type="button" class="btn btn-primary" style="display:inline;width:105px;" id="oaifetchlist" onclick="oai_fetch_models()">Fetch List</button>
|
||||
<button type="button" class="btn btn-primary" style="display:inline;width:105px;" id="oaiusecustom" onclick="select_custom_oai_model()">Use Custom</button>
|
||||
<button type="button" class="btn btn-primary" style="display:inline;width:42px;height:34px;vertical-align: top;" id="oaifindmodel" onclick="find_oai_model()">🔎</button>
|
||||
<button type="button" class="btn btn-primary" style="display:inline;width:70px;height:34px;vertical-align: top;" id="oaifetchlist" onclick="oai_fetch_models()">Fetch</button>
|
||||
<button type="button" class="btn btn-primary" style="display:inline;width:70px;height:34px;vertical-align: top;" id="oaiusecustom" onclick="select_custom_oai_model()">Custom</button>
|
||||
<div class="hidden" id="oaiemulatecompletionsbox">
|
||||
<div><input type="checkbox" id="oaiemulatecompletions" title="Emulate Completions with Prefill">
|
||||
<div class="box-label">Emulate Completions API with Prefill</div></div>
|
||||
|
|
@ -30763,8 +30782,17 @@ Current version indicated by LITEVER below.
|
|||
<input type="checkbox" title="Add endpoint version" id="claudeaddversion" onchange="" checked>
|
||||
<div class="box-label" title="Add endpoint version">Add Endpoint Version</div>
|
||||
|
||||
<textarea class="form-control hidden" title="Claude System Prompt" rows="2" style="resize: vertical; line-height:1.1; padding:4px; display:inline; width: 100%" id="claudesystemprompt" placeholder="(Enter System Prompt, which steers overall AI behavior.)" onload=""></textarea>
|
||||
<textarea class="form-control hidden" title="Claude Assistant Postfix" rows="2" style="resize: vertical; line-height:1.1; padding:4px; display:inline; width: 100%" id="claudejailbreakprompt" placeholder="(Enter Assistant Postfix, which forces the AI to start responses with this text.)" onload=""></textarea>
|
||||
<textarea class="form-control" title="Claude System Prompt" rows="2" style="resize: vertical; line-height:1.1; padding:4px; display:inline; width: 100%" id="claudesystemprompt" placeholder="(Enter System Prompt, which steers overall AI behavior.)" onload=""></textarea>
|
||||
|
||||
<div style="display:flex">
|
||||
<select title="Claude Postfix Role" class="form-control" style="height: 25px; font-size:12px; padding:4px;display:inline;width:100px" id="claudejailbreakpromptrole">
|
||||
<option value="0">User</option>
|
||||
<option value="1" selected>Assistant</option>
|
||||
<option value="2">System</option>
|
||||
</select>
|
||||
<textarea title="Enter Claude Postfix" class="form-control" rows="2" style="resize: vertical; line-height:1.1; padding:4px; display:inline; width: 100%" id="claudejailbreakprompt" placeholder="(Enter a postfix, which forces the AI to start responses with this text.)" onload=""></textarea>
|
||||
</div>
|
||||
|
||||
|
||||
<div id="claudethinkingbox" class="hidden">
|
||||
<div class="box-label" title="Enable Thinking">Enable Thinking </div>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue