Use prefix in the migrated sysprompts

c340766bb6ba6308cba8899cf3e9adae021ad819

Cohee <18619528+Cohee1207@users.noreply.github.com>

2 files changed, +2 -1Ignore whitespace
public/scripts/sysprompt.js+1 -1
@@ -29,7 +29,7 @@ async function migrateSystemPromptFromInstructMode() {
2929 if (existingPromptName) {
3030 power_user.sysprompt.name = existingPromptName;
3131 } else {
3232 const data = { name: `[Migrated] ${power_user.instruct.preset} (Migrated)`, content: prompt };
3333 await getPresetManager('sysprompt')?.savePreset(data.name, data);
3434 power_user.sysprompt.name = data.name;
3535 }
src/users.js+1 -0
@@ -368,6 +368,7 @@ async function migrateSystemPrompts() {
368368 // Only leave contents that are not in the default prompts
369369 migratedPrompts = migratedPrompts.filter(x => !defaultPrompts.some(y => y.content === x.content));
370370 for (const sysPromptData of migratedPrompts) {
371+ sysPromptData.name = `[Migrated] ${sysPromptData.name}`;
371372 const syspromptPath = path.join(directory.sysprompt, `${sysPromptData.name}.json`);
372373 writeFileAtomicSync(syspromptPath, JSON.stringify(sysPromptData, null, 4));
373374 console.log(`Migrated system prompt ${sysPromptData.name} for ${directory.root.split(path.sep).pop()}`);