Skip to content

What SillyTavern “world lorebooks” actually do

📌 How to read this: Mechanisms only—no “click this menu” walkthrough. UI depends on your SillyTavern build; field semantics belong to World Info (official).

SillyTavern 世界书逻辑科普(中文)

Settings in plain English (start here)

Before the tables, think of each lore entry as a sticky note the app may paste into the big prompt the model reads:

Label you’ll seePlain meaning
KeywordsIf these words show up in scanned chat (and rules pass), this note may attach.
ContentThe actual text the model gains when the note attaches.
Scan depthDon’t only read your latest line—also look N message pairs back for keywords.
Token budget / %All lore notes together have a length cap; overflow entries may be skipped.
Insertion orderWhen several notes attach in the same slot, sort key; larger numbers usually sit lower in that bundle and often weigh more on the next reply.
Insertion positionWhere in the prompt stack the note sits—near character text, near Author’s Note, at message depth @D, etc.
Constant (blue)Try to include every turn without keywords (still respects budget).
Normal (green)Needs keyword hits.
RecursionText from note A can mention a keyword for note B, chaining activations.

Wording in your build may differ slightly; this is the idea layer.

📖 What a lorebook is

MetaphorMeaning
📕 Dictionary / encyclopediaA word appears in chat → a note can be merged into the big text the model reads
🎯 Minimal patternKeywords match → Content may activate
⚠️ LimitActivation ≠ the model must obey verbatim; it only raises the chance the fact is used

Logic example: A “used-book shop owner” card and the line “tonight I’m picking up a batch of rare catalogs on Lantern Row.” The model may not know what Lantern Row is; a lore entry keyed on that name explains the street, mood, and how it ties to the shop. When the name appears, the entry can enter context so the scene stays coherent.

🧠 Two scopes (conceptual)

TypeScope (idea)Typical use
🌐 GlobalShared across many charactersShared setting tables, props, etc.
👤 Bound to a characterMainly for one cardPrivate backstory, character-only facts

Whether exports bundle the primary bound book depends on format/version—no UI steps here.

🧩 Context and ordering: why placement matters

Treat one model request as a capacity-limited container:

IdeaIntuition
📦 ContextTotal tokens the model can see; old material can fall out
🔒 Stickier blockse.g. character description, some WI set to constant—often described in tutorials as harder to push out
📜 More roll-offMost chat history, some example chats—long runs push earlier lines away

Community tutorials about SillyTavern’s “blue” prompt strip (chat-facing layer) often summarize:

⬇️ Within that strip, lower in the stack tends to weigh more on the current reply.

So “as low as possible” is not automatically best—you balance character text, Author’s Note relatives, and WI.

Author’s Note (concept): pins helper text above the N‑th chat message; WI entries placed “before/after Author’s Note” move with that anchor.

🎛️ Entry-level insertion position (relative strength table)

From the same tutorial lineage—conceptual strength, not a click map:

Placement (label)Relative strength (tutorial)Note
⬆️ Before character definitionWeakestMore “background”
⬇️ After character definitionSlightly stronger, still weak
📝 Before Author’s NoteStrongTracks AN depth
📝 After Author’s NoteVery strongSame; easy to over-pack
@D (depth slot)VariableInserts above the N‑th message (exact rules per build)

💡 Short chats (new threads): character text, WI around it, and the first message jointly bootstrap the run—tutorials warn against moving everything to “right around Author’s Note” on day one.

🔢 Insertion order when several entries fire

Rule (aligned with official docs)Meaning
⬆️ Smaller numberHigher in the WI chunk for that same placement
⬇️ Larger numberLower in the chunk—usually stronger on the next token

If placements differ, sort by placement tier first, then Order inside each tier.

Author-style tips:

TipMeaning
🎯 Importance → lower in stackWithin a tier, raise Order for what must dominate
🌍 Big world bibleCan live higher (e.g. before character block)
📟 Status HUD / rulesOften lower; if the model “forgets” state, try even lower

Shorter intro: SillyTavern lorebook order for beginners.

🎲 Trigger probability

ValueBehavior (concept)
100Always attempt insert when otherwise eligible
50Coin flip each eligible turn
0Effectively off

Tutorials note the UX can feel like “rare events happen often”—verify empirically.

🚦 Status modes

IconModeBehavior (concept)
🟢NormalKeyword-driven
🔵ConstantTries every turn without keywords (tutorial analogy: “permanent prompt”)
DisabledInactive

🔵 Constant + depth: can mimic Author’s Note–like anchoring (still budget-limited).

🔌 Logic (AND / OR / NOT intuition)

LogicIntuition
ANDAll required keys must appear
Comma listsOften OR among primary keys (product-dependent)
NOTFire when A matches and B does not

Secondary boxes are often empty in simple setups.

👥 Character filter / exclusion (concept)

ModeStory (tutorial)
Only these charactersGroup chat: secret one actor knows
🚫 Exclude charactersGroup chat: everyone except one knows

⚙️ Global activation settings

Merging global vs character lore

Strategy (label)Tutorial note
Even sortAuthor finds behavior messy—don’t rely on it blindly
Character-first / global-firstDescriptions vs reality can drift

Key claim (tutorial): Insertion position + Order beat these merge modes. Example spirit: Order 100 still ends below Order 99 in the same band—not flipped by “global vs character” alone.

Scan depth

IdeaMeaning
Pair user + assistant messagesDepth 1 ≈ scan one recent pair; 2 ≈ two pairs…
Typical1–2; adventure cards may need more
CeilingCommunity cites ~ten pairs—verify your fork

Recursive scanning

OffOn
Text inside entry A cannot wake entry B by mentioning B’s keysChain: A’s injected text can trigger B

Classic logic: Bessie → text mentions RufusRufus entry loads.

Budget & eviction priority

ControlRole
Context % / budget capHard cap on WI tokens
Overflow alertWarn when WI exceeds allowance

When over budget (tutorial ordering):

Priority (high → low)Rule
1🔵 Constant beats 🟢 normal
2Higher Order beats lower
3Direct keyword hits in chat beat recursion-only activations

🔤 Other toggles (logic)

ToggleRole
Case-sensitive keysRose vs rose
Whole-wordBlock hotdog firing dog; bad for CJK without spaces—often leave off
Min activationsAlternate scan mode; tutorial: easy to misuse, rarely needed

🧪 Regex (purpose only)

Good for staged mechanics (affection tiers, state machines)—flexible triggers; details live in dedicated regex guides.

🌟 Closing frame

LensOne line
🔧 EngineeringLorebooks are ordered, budgeted, chainable prompt inserts
🎮 PlayRulesets, mode instructions, not just “world bible”

Some models also show extra attention to the first/last tiny slices of context (community stress tests)—treat as advanced, validate with logs.

More on this site


Browse PNG + embedded JSON on Mac with Sillycard.

Topic: Blog · Latest posts

Sillytavern Card Viewer / Editor / Manager on iOS & macOS — Sillycard & Sillycard on Phone. App languages: English, 简体中文, 繁體中文, 日本語, Русский. Privacy policy. © 2026 Sillycard