diff --git a/public/script.js b/public/script.js index 156540456..e3a3c42d0 100644 --- a/public/script.js +++ b/public/script.js @@ -8566,7 +8566,7 @@ export function showSwipeButtons() { //had to add this to make the swipe counter work //(copied from the onclick functions for swipe buttons.. - //don't know why the array isn't set for non-swipe messsages in Generate or addOneMessage..) + //don't know why the array isn't set for non-swipe messages in Generate or addOneMessage..) if (chat[chat.length - 1]['swipe_id'] === undefined) { // if there is no swipe-message in the last spot of the chat array chat[chat.length - 1]['swipe_id'] = 0; // set it to id 0 chat[chat.length - 1]['swipes'] = []; // empty the array diff --git a/public/scripts/custom-request.js b/public/scripts/custom-request.js index 14915632e..aaedf8417 100644 --- a/public/scripts/custom-request.js +++ b/public/scripts/custom-request.js @@ -279,9 +279,9 @@ export class TextCompletionService { instructPreset, ); } else { // e.g. "<|im_start|>assistant: Hello, my name is" - const overridenInstructPreset = structuredClone(instructPreset); - overridenInstructPreset.output_suffix = ''; - overridenInstructPreset.wrap = false; + const overriddenInstructPreset = structuredClone(instructPreset); + overriddenInstructPreset.output_suffix = ''; + overriddenInstructPreset.wrap = false; messageContent = formatInstructModeChat( message.role, message.content, @@ -291,7 +291,7 @@ export class TextCompletionService { undefined, undefined, undefined, - overridenInstructPreset, + overriddenInstructPreset, ); } } diff --git a/public/scripts/nai-settings.js b/public/scripts/nai-settings.js index e795f5230..aff937d45 100644 --- a/public/scripts/nai-settings.js +++ b/public/scripts/nai-settings.js @@ -584,7 +584,7 @@ export function getNovelGenerationData(finalPrompt, settings, maxLength, isImper }; } -// Check if the prefix needs to be overriden to use instruct mode +// Check if the prefix needs to be overridden to use instruct mode function selectPrefix(selected_prefix, finalPrompt) { let useInstruct = false; const clio = nai_settings.model_novel.includes('clio'); diff --git a/public/scripts/personas.js b/public/scripts/personas.js index dca41078e..525831003 100644 --- a/public/scripts/personas.js +++ b/public/scripts/personas.js @@ -132,7 +132,7 @@ function reloadUserAvatar(force = false) { /** * Sort the given personas * @param {string[]} personas - The persona names to sort - * @returns {string[]} The sorted persona names arrray, same reference as passed in + * @returns {string[]} The sorted persona names array, same reference as passed in */ function sortPersonas(personas) { const option = $('#persona_sort_order').find(':selected'); @@ -1821,7 +1821,7 @@ function registerPersonaSlashCommands() { defaultValue: 'chat', enumList: [ new SlashCommandEnumValue('chat', 'Lock the persona to the current chat.'), - new SlashCommandEnumValue('character', 'Lock this persona to the currently selected character. If the setting is enabled, mutliple personas can be locked to the same character.'), + new SlashCommandEnumValue('character', 'Lock this persona to the currently selected character. If the setting is enabled, multiple personas can be locked to the same character.'), new SlashCommandEnumValue('default', 'Lock this persona as the default persona for all new chats.'), ], }), @@ -1857,7 +1857,7 @@ function registerPersonaSlashCommands() { defaultValue: 'chat', enumList: [ new SlashCommandEnumValue('chat', 'Lock the persona to the current chat.'), - new SlashCommandEnumValue('character', 'Lock this persona to the currently selected character. If the setting is enabled, mutliple personas can be locked to the same character.'), + new SlashCommandEnumValue('character', 'Lock this persona to the currently selected character. If the setting is enabled, multiple personas can be locked to the same character.'), new SlashCommandEnumValue('default', 'Lock this persona as the default persona for all new chats.'), ], }), diff --git a/public/scripts/popup.js b/public/scripts/popup.js index 1e1e3e482..bc45a20c3 100644 --- a/public/scripts/popup.js +++ b/public/scripts/popup.js @@ -315,7 +315,7 @@ export class Popup { if (defaultButton) defaultButton.classList.add('menu_button_default'); // Styling differences depending on the popup type - // General styling for all types first, that might be overriden for specific types below + // General styling for all types first, that might be overridden for specific types below this.mainInput.style.display = 'none'; this.inputControls.style.display = customInputs ? 'block' : 'none'; this.closeButton.style.display = 'none'; diff --git a/public/scripts/reasoning.js b/public/scripts/reasoning.js index 91c12e86a..cb2b58d46 100644 --- a/public/scripts/reasoning.js +++ b/public/scripts/reasoning.js @@ -426,7 +426,7 @@ export class ReasoningHandler { if (!this.#isParsingReasoning) return mesChanged; - // If we are in manual parsing mode, all currently streaming mes tokens will go the the reasoning block + // If we are in manual parsing mode, all currently streaming mes tokens will go to the reasoning block this.reasoning = parseTarget.slice(power_user.reasoning.prefix.length); message.mes = ''; diff --git a/public/scripts/stats.js b/public/scripts/stats.js index fed4b962e..94d14b9fa 100644 --- a/public/scripts/stats.js +++ b/public/scripts/stats.js @@ -264,9 +264,9 @@ function countWords(str) { * @param {string} type - The type of the message processing (e.g., 'append', 'continue', 'appendFinal', 'swipe'). * @param {Object} characters - Object containing character data. * @param {string} this_chid - The character id. - * @param {string} oldMesssage - The old message that's being processed. + * @param {string} oldMessage - The old message that's being processed. */ -async function statMesProcess(line, type, characters, this_chid, oldMesssage) { +async function statMesProcess(line, type, characters, this_chid, oldMessage) { if (this_chid === undefined || characters[this_chid] === undefined) { return; } @@ -295,7 +295,7 @@ async function statMesProcess(line, type, characters, this_chid, oldMesssage) { stat.user_msg_count++; stat.user_word_count += countWords(line.mes); } else { - let oldLen = oldMesssage.split(' ').length; + let oldLen = oldMessage.split(' ').length; stat.user_word_count += countWords(line.mes) - oldLen; } } else { @@ -305,7 +305,7 @@ async function statMesProcess(line, type, characters, this_chid, oldMesssage) { stat.non_user_msg_count++; stat.non_user_word_count += countWords(line.mes); } else { - let oldLen = oldMesssage.split(' ').length; + let oldLen = oldMessage.split(' ').length; stat.non_user_word_count += countWords(line.mes) - oldLen; } } diff --git a/public/scripts/tags.js b/public/scripts/tags.js index 702b589ea..f88311617 100644 --- a/public/scripts/tags.js +++ b/public/scripts/tags.js @@ -917,7 +917,7 @@ function newTag(tagName) { /** * @typedef {object} PrintTagListOptions - Optional parameters for printing the tag list. * @property {Tag[]|function(): Tag[]} [tags=undefined] - Optional override of tags that should be printed. Those will not be sorted. If no supplied, tags for the relevant character are printed. Can also be a function that returns the tags. - * @property {Tag|Tag[]} [addTag=undefined] - Optionally provide one or multiple tags that should be manually added to this print. Either to the overriden tag list or the found tags based on the entity/key. Will respect the tag exists check. + * @property {Tag|Tag[]} [addTag=undefined] - Optionally provide one or multiple tags that should be manually added to this print. Either to the overridden tag list or the found tags based on the entity/key. Will respect the tag exists check. * @property {object|number|string} [forEntityOrKey=undefined] - Optional override for the chosen entity, otherwise the currently selected is chosen. Can be an entity with id property (character, group, tag), or directly an id or tag key. * @property {boolean|string} [empty=true] - Whether the list should be initially empty. If a string string is provided, 'always' will always empty the list, otherwise it'll evaluate to a boolean. * @property {boolean} [sort=true] - Whether the tags should be sorted via the sort function, or kept as is. diff --git a/public/scripts/world-info.js b/public/scripts/world-info.js index 6409c6efb..b56087835 100644 --- a/public/scripts/world-info.js +++ b/public/scripts/world-info.js @@ -2316,7 +2316,7 @@ export function deleteWIOriginalDataValue(data, uid) { /** * Splits a given input string that contains one or more keywords or regexes, separated by commas. * - * Each part can be a valid regex following the pattern `/myregex/flags` with optional flags. Commmas inside the regex are allowed, slashes have to be escaped like this: `\/` + * Each part can be a valid regex following the pattern `/myregex/flags` with optional flags. Commas inside the regex are allowed, slashes have to be escaped like this: `\/` * If a regex doesn't stand alone, it is not treated as a regex. * * @param {string} input - One or multiple keywords or regexes, separated by commas diff --git a/src/endpoints/characters.js b/src/endpoints/characters.js index 0923a3545..3e96a3de5 100644 --- a/src/endpoints/characters.js +++ b/src/endpoints/characters.js @@ -1048,7 +1048,7 @@ router.post('/edit', validateAvatarUrlMiddleware, async function (request, respo return response.sendStatus(200); } catch { - console.error('An error occured, character edit invalidated.'); + console.error('An error occurred, character edit invalidated.'); } }); @@ -1094,7 +1094,7 @@ router.post('/edit-attribute', validateAvatarUrlMiddleware, async function (requ await writeCharacterData(avatarPath, newCharJSON, targetFile, request); return response.sendStatus(200); } catch (err) { - console.error('An error occured, character edit invalidated.', err); + console.error('An error occurred, character edit invalidated.', err); } });