Lorebooks

Lorebooks let you create keyword-triggered lore entries that inject into NPC conversations only when relevant. Instead of stuffing every detail into an NPC's backstory, you write standalone entries about places, factions, history, customs, or secrets — and the system surfaces them at the right moment.

Every user gets unlimited entries. The number that can activate in a single conversation depends on your plan.

Lorebook tab


Creating an Entry

Open the Atlas and go to the Lorebook tab. Click + New Entry to open the editor.

Lorebook entry

Each entry has the following fields:

Field Description
Title A short label for the entry (max 100 characters). Visible to the AI.
Keywords Comma-separated trigger words (up to 25, each max 50 characters). The entry activates when any keyword appears in conversation.
Content The lore text injected into the conversation (max 1,500 characters). Content past the limit is highlighted in red so you can shorten it.
Scope Controls where the entry can activate. Default is "Everywhere."
Priority A number (default 100). Lower numbers = higher priority when more entries match than the budget allows.
Enabled Toggle the entry on or off without deleting it.
Always On When checked, the entry activates in every conversation (within its scope) regardless of keywords.

How Activation Works

When you talk to an NPC, the system checks your lorebook in two passes:

  1. Always On entries fill first — these activate in every conversation within their scope.
  2. Keyword matches fill next — if any of the entry's keywords appear in the conversation, the entry activates (case-insensitive, whole-word matching).

Entries can also activate semantically — even without an exact keyword match, the system can surface entries that are topically relevant to the conversation. If the player mentions "the old war," an entry with keywords like "the Sundering" or "siege" might still activate.

The total number of entries that can activate per conversation is capped by your plan's budget.


Budget

Plan Slots per conversation
Adventurer 5
Hero 10

The budget bar at the top of the Lorebook tab shows how many Always On entries you're using versus your total slots. The remaining slots are available for keyword and semantic triggers.

Best practice: Keep Always On entries to 1–2 per world. If too many entries are set to Always On, there's no room left for keyword triggers to fire. The budget bar warns you when Always On entries are crowding out dynamic activation.


Scopes

By default, entries are scoped to "Everywhere" — they can activate in any conversation in the world. You can narrow this by adding scopes.

Click + Add Scope to open a searchable list of your world's entities. Scope types:

You can add one scope per type. Multiple scopes are AND-gated — an entry scoped to both a region and a building only activates when the NPC is at that building in that region.

Removing all scopes resets the entry to "Everywhere."


Secondary Keywords

For finer control, expand the Secondary Keywords section in the entry editor. Secondary keywords add a second condition on top of the primary keyword match.

Check Require secondary keys to enable, then choose a logic mode:

Logic Meaning
AND ANY Primary keyword matches AND at least one secondary keyword is present
AND ALL Primary keyword matches AND all secondary keywords are present
NOT ANY Primary keyword matches AND none of the secondary keywords are present
NOT ALL Primary keyword matches AND not all secondary keywords are present

Example: An entry about a tithe scandal might have primary keywords "taxes, money, church" with secondary keywords "Embla, the ledger" set to NOT ANY — the entry fires when the player discusses taxes, but not if they've already mentioned Embla or the ledger.


Import & Export

Importing

Click Import to upload a .json file. RPBuddy accepts lorebooks in the SillyTavern / Character Card V2 character_book format — compatible with SillyTavern, Chub, Risu, Agnai, Kobold, and any platform using the Character Card V2 spec.

Imported entries are safety-screened. Flagged entries appear in a yellow "needs review" section where you can edit the content and re-save.

Exporting

Click Export to download your lorebook as a .json file in SillyTavern character_book format. RPBuddy-specific data (scopes) is preserved in an extensions field, so re-importing into RPBuddy restores your scope settings.


Managing Entries

The list view shows all entries with their title, keywords (first three shown), Always On badge, scope tags, and a content preview.


Tips