fix: add legacy translation support in Auto Translate Cached Only option
This commit is contained in:
@@ -170,7 +170,7 @@ export const languageEnglish = {
|
||||
summarizationPrompt: "The prompt that is used for summarization. if it is blank, it will use the default prompt. you can also use ChatML formating with {{slot}} for the chat data.",
|
||||
translatorPrompt: "The prompt that is used for translation. if it is blank, it will use the default prompt. you can also use ChatML formating with {{slot}} for the dest language, {{solt::content}} for the content, and {{slot::tnote}} for the translator note.",
|
||||
translateBeforeHTMLFormatting: "If enabled, it will translate the text before Regex scripts and HTML formatting. this could make the token lesser but could break the formatting.",
|
||||
autoTranslateCachedOnly: "If enabled, it will automatically translate only the text that the user has translated previously.",
|
||||
autoTranslateCachedOnly: "If enabled with Auto Translation option on, it will automatically translate only the text that the user has translated previously.",
|
||||
presetChain: "If it is not blank, the preset will be changed and applied randomly every time when user sends a message in the preset list in this input. preset list should be seperated by comma, for example, `preset1,preset2`.",
|
||||
legacyMediaFindings: "If enabled, it will use the old method to find media assets, without using the additional search algorithm.",
|
||||
comfyWorkflow: "Put the API workflow of comfy UI. you can get your API workflow in comfy UI by pressing the 'Workflow > Export (API)' button. you must also put {{risu_prompt}} in you workflow text. the {{risu_prompt}} will be replaced with the prompt provided by the Risu.",
|
||||
|
||||
@@ -143,7 +143,9 @@
|
||||
if(DBState.db.autoTranslateCachedOnly && DBState.db.translatorType === 'llm'){
|
||||
const cache = DBState.db.translateBeforeHTMLFormatting
|
||||
? await getLLMCache(data)
|
||||
: await getLLMCache(await ParseMarkdown(data, charArg, 'pretranslate', chatID, getCbsCondition()))
|
||||
: !DBState.db.legacyTranslation
|
||||
? await getLLMCache(await ParseMarkdown(data, charArg, 'pretranslate', chatID, getCbsCondition()))
|
||||
: await getLLMCache(await ParseMarkdown(data, charArg, mode, chatID, getCbsCondition()))
|
||||
|
||||
translateText = cache !== null
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user