mirror of
https://github.com/turboderp-org/exui.git
synced 2026-04-20 14:29:52 +00:00
Add Gemma prompt format
This commit is contained in:
@@ -140,6 +140,10 @@ export class SessionSettings {
|
||||
this.sss_roles.setVisible(hasRoles);
|
||||
this.sss_stopConditions.setVisible(hasRoles);
|
||||
|
||||
let opt = globals.g.promptFormatsOptions[this.settings.prompt_format];
|
||||
let hasSysPrompt = opt.supports_system_prompt;
|
||||
this.sss_systemPrompt.setVisible(hasSysPrompt);
|
||||
|
||||
let mirostat = this.settings.mirostat;
|
||||
this.sss_i_mirostat_tau.setVisible(mirostat);
|
||||
this.sss_i_mirostat_eta.setVisible(mirostat);
|
||||
|
||||
@@ -19,6 +19,7 @@ export const g = {
|
||||
// ..
|
||||
|
||||
promptFormats: null,
|
||||
promptFormatsOptions: null,
|
||||
smoothScrolling: true,
|
||||
|
||||
}
|
||||
@@ -28,5 +29,14 @@ export const g = {
|
||||
export function receiveGlobals(response) {
|
||||
if (response.current_model) g.loadedModelUUID = response.current_model;
|
||||
if (response.current_session) g.currentSessionUUID = response.current_model;
|
||||
if (response.prompt_formats) g.promptFormats = response.prompt_formats;
|
||||
if (response.prompt_formats) {
|
||||
g.promptFormats = [];
|
||||
g.promptFormatsOptions = {};
|
||||
for (let i = 0; i < response.prompt_formats.length; i++)
|
||||
{
|
||||
let name = response.prompt_formats[i].name;
|
||||
g.promptFormats.push(name);
|
||||
g.promptFormatsOptions[name] = response.prompt_formats[i];
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user