Script Helper

Script Helper

846

5.6k

AI lorebook script assistant.


Includes example scripts covering Advanced Lorebooks, Relationship Progression script, Dynamic Scenario script, Memory System script, Dynamic Lorebook script, Time-Based Scenario script, and all available properties.

06.11.2025: Original prompt has been moved to the Example texts. Content has been revamped into a lorebook. It can now do a whole lot more stuff.

WARNING: Whatever the response output is, it is very likely that you will need to fine-tune the script with some human touch. I have managed to make some functional lorebooks using this helper but not without a bit of trial and error, and by referencing the base templates that are already included in the different script categories. Additionally, it helps if you understand the basics... Or you can figure it out along the way. If you are starting to get a hang of it, then maybe think about looking at a full guide (thank you, Janitor<3 lovelies). Don't forget that there is a built in test and debugging feature like I did for my past 5 lorebooks.

I couldn't feed NSFW stuff directly into ChatGPT, so I made this script helper. I suggest using Deepseek V3.2. It's quite good at coding.

Here are some things I have learnt about making scripts that might be useful to know.

What Scripts can do:

  • It can make a functional probability system. It can give stuff weights (more/less likely to trigger), and it can make stuff apply at random. This is great for setting up random or situational events since there's a lot it can do with 'IF'.

  • It can add more complicated conditions/triggers that a regular lorebook cannot. e.g. For a multi-chara bot it can prevent anymore than 3 character's detailed info from triggering and instead swap to shorter summaries of all characters from there on (incredible token saver).

What Scripts can't do:

  • Scripts cannot read the Chat Memory.

  • Scripts cannot read or scrape from external URLs.

Adding message depth:

  • I struggled to get the Helper to add this in correctly, so just copy paste the following into your message so it has better reference (or you can add this near the start of your script manually and change instances of lastmessage to lastmessages):

// Use this as ref for adding in a multi-message context string, change chat.last_message property to chat.last_messages for better flow. NOTE THAT THIS EFFECTS THE WHOLE SCRIPT UNLESS YOU SPECIFY WHAT IT SHOULDN'T EFFECT.

var lastMessages = context.chat.last_messages

.slice(-6) // depth is configurable, set depth to -10 for the max amount of messages this script can detect a keyword.

.map(function(m) { return m.message.toLowerCase(); })

.join(" ");

proxy allowed

Published chats

0

comments

Leave a comment or feedback for the creator ❤️