[feat] nai improvements, better authornote
This commit is contained in:
@@ -9,7 +9,7 @@
|
||||
import LoreBook from "./LoreBook/LoreBookSetting.svelte";
|
||||
import { alertConfirm, alertError, alertNormal, alertSelectChar, alertTOS } from "../../ts/alert";
|
||||
import BarIcon from "./BarIcon.svelte";
|
||||
import { findCharacterbyId, selectMultipleFile } from "../../ts/util";
|
||||
import { findCharacterbyId, getAuthorNoteDefaultText, selectMultipleFile } from "../../ts/util";
|
||||
import { onDestroy } from "svelte";
|
||||
import {isEqual, cloneDeep} from 'lodash'
|
||||
import Help from "../Others/Help.svelte";
|
||||
@@ -225,7 +225,12 @@
|
||||
|
||||
{/if}
|
||||
<span class="text-textcolor">{language.authorNote} <Help key="chatNote"/></span>
|
||||
<TextAreaInput margin="both" autocomplete="off" bind:value={currentChar.data.chats[currentChar.data.chatPage].note}></TextAreaInput>
|
||||
<TextAreaInput
|
||||
margin="both"
|
||||
autocomplete="off"
|
||||
bind:value={currentChar.data.chats[currentChar.data.chatPage].note}
|
||||
placeholder={getAuthorNoteDefaultText()}
|
||||
/>
|
||||
<span class="text-textcolor2 mb-6 text-sm">{tokens.localNote} {language.tokens}</span>
|
||||
<div class="flex mt-6 items-center">
|
||||
<Check bind:check={$DataBase.jailbreakToggle} name={language.jailbreakToggle}/>
|
||||
|
||||
@@ -77,10 +77,14 @@
|
||||
}} />
|
||||
{/if}
|
||||
{/if}
|
||||
{#if proompt.type === 'persona' || proompt.type === 'description'}
|
||||
{#if proompt.type === 'authornote'}
|
||||
<span>{language.defaultPrompt}</span>
|
||||
<TextInput bind:value={proompt.defaultText} />
|
||||
{/if}
|
||||
{#if proompt.type === 'persona' || proompt.type === 'description' || proompt.type === 'authornote'}
|
||||
{#if !proompt.innerFormat}
|
||||
<CheckInput name={language.customInnerFormat} check={false} className="mt-2" onChange={() => {
|
||||
if(proompt.type === 'persona' || proompt.type === 'description'){
|
||||
if(proompt.type === 'persona' || proompt.type === 'description' || proompt.type === 'authornote'){
|
||||
proompt.innerFormat = "{{slot}}"
|
||||
}
|
||||
}} />
|
||||
@@ -88,7 +92,7 @@
|
||||
<span>{language.innerFormat}</span>
|
||||
<TextAreaInput bind:value={proompt.innerFormat}/>
|
||||
<CheckInput name={language.customInnerFormat} check={true} className="mt-2" onChange={() => {
|
||||
if(proompt.type === 'persona' || proompt.type === 'description'){
|
||||
if(proompt.type === 'persona' || proompt.type === 'description' || proompt.type === 'authornote'){
|
||||
proompt.innerFormat = null
|
||||
}
|
||||
}} />
|
||||
|
||||
Reference in New Issue
Block a user