A lorebook is not a second memory, and memory is not a second persona. They look similar because both are notes the model can read, and they fail in opposite directions when you mix them up. A fact about you that lands in a lorebook follows the card, so anyone who opens that file inherits it. A fact about the world that lands in memory follows you, so every character you talk to starts treating your setting as biography. Put standing character behaviour in the persona instead and you pay for it on every turn, whether the fact is needed or not.
This page is a sorting rule, not a tour of how memory works. The tour is the memory guide. The cost of stuffing the wrong field is visible on the token counter: persona is permanent, a keyed lorebook entry is only sent when one of its keys appears, and a memory line is not on the card at all.
How to decide where a fact goes
Ask these in order. Stop at the first yes.
- Is it always true of this character, in any conversation? How they talk, what they refuse, the job they have on any Tuesday. That is the persona — description and personality on a character card. It is re-sent with every message. Trim it as if you were paying rent.
- Is it true only of this evening, this room, this scene? Wet Tuesday, the radio on the counter, the inn already quiet. That is the scenario. It is also re-sent every turn in most apps, which is why a scenario that has become a chapter is usually a persona in disguise. The writing guide is blunt about that split.
- Is it about the reader, across conversations? A night shift, a sister's baby, a half marathon. On YanMate that is the memory ledger: a list you can open, correct, delete and export. It is not in the card. It should not be. A card is a character you can hand to someone else.
- Is it about the world, and only needed when a word comes up? The name of a ship, the layout of a town, a rival who exists in this story. That is a lorebook entry: a short passage plus the keys that should bring it in. On a character card it lives in
character_book. On YanMate the World tab says the same job in one sentence: the places, people and running jokes a companion should know about, and when to bring them up. - Is it a one-off that already happened in this chat? Leave it in the transcript. Writing it down twice — once as a message and again as a note — is how contradictions start.
A keyed lorebook entry is a trigger, not a filing cabinet. The model does not "know" the town until a key appears in the recent text. That is the feature. It is also why an entry with no keys, or an entry marked always-on, is a different object wearing the same name: it is back to being paid every turn, which is the persona's job.
Six facts, sorted
These are the kinds of line that actually turn up. The names are from the template gallery, because that is writing we already published, not a hypothetical card.
"Mara still pipettes her own samples on Fridays." Persona. True of her on any day you meet her. Putting it in a lorebook keyed on "Friday" would hide it until someone said the word, which is the opposite of a standing habit.
"The lab after six. One centrifuge is still running." Scenario. It is this evening. If you promote it to persona, every conversation with Mara starts after hours.
"You work nights." Memory. It is about the reader. If you write it into a lorebook on a card you then share, the next person who downloads the card inherits a night shift they do not have. If you write it into the persona, the character believes everyone works nights.
"The ship is called the Hester, port-side corridor first." Lorebook. Key it on Hester, port-side, corridor. It should not sit in memory: memory is labelled as facts about you, and a ship is not. It should not sit in the persona unless the character is the ship.
"Jules keeps a notebook of opponents' tells." Persona if it is who Jules is; lorebook if you are writing a specific opponent into a campaign. The test is whether the fact should fire in a conversation that is not about fencing. If yes, persona. If only when the strip comes up, lorebook.
"Last time you were arguing in the inn." Transcript, or an alternate greeting. It is a previous beat, not a standing fact. Putting it in memory tells every character you were arguing in an inn. Putting it in a constant lorebook entry makes the inn the weather of every session.
The token counter will not tell you which of those is true. It will tell you whether you are paying for the line every turn. Drop the card, read the "sometimes" bucket, and if a twenty-entry book has been folded into the permanent total by another tool, that tool is counting the wrong thing. We built the breakdown because that fold is the usual way a token estimate lies: a lorebook looks enormous in a sum and can cost nothing on a given message, because the entries are alternatives to each other.
The character card viewer is the other half of that check. Drop the same file and read the lorebook panel: keys, whether an entry is constant, V3 @@ decorator lines if they are there. A card that "has a world" and a card whose entries never fire are different files. The viewer will say which one you are holding.
What goes wrong
User facts in a shared lorebook. The card travels. The memory does not, on purpose. An imported V3 card keeps its character_book; that is how the format works, and it is why a line like "the user's name is Dana" inside an entry is a trap. We keep lorebooks on import rather than stripping them. The cost of that honesty is that a bad entry survives the trip.
World facts in the memory ledger. On YanMate, facts about you are shared across characters by default. Tell one companion you work nights and the others can know. That is the point of the shared block. It is also why "the Hester's port-side corridor" should never be a ledger line. It will follow you into a conversation with a language partner who has never heard of the ship.
World facts in the persona. Permanent tokens. The model rereads the corridor on every turn of a chat that is about tea. The token counter's "sent on every message" group exists for this. Cut it out of the description and give it a key.
Always-on lorebook entries that are a second persona. Constant entries, or entries with empty keys, skip the trigger. They are cheaper to write than a persona edit and more expensive to run. The World tab's plain sentence for those is "she always knows this." If the thing she always knows is how she talks, it belongs in personality.
Keys that are too common. Keying an entry on you, the, or a character's own name fires it constantly, which is how a "sometimes" field becomes a permanent one without you noticing. Key the distinctive word: Hester, Rosie's, violetglass. In a live scene test we attached a world entry to a key that only appeared in a long beat; the companion used the entry on that beat and not before. That is the behaviour you want. A key that appears in every greeting will not give it to you.
Two copies of the same fact. A persona line and a lorebook entry that disagree, or a memory line and a lorebook entry that disagree. The model cannot ask which you meant. When instructions and examples fight, the examples tend to win; when two notes fight, retrieval picks. Delete one.
Honest limits
A lorebook is not a novel. Each entry should be the paragraph you would whisper to the model when the key comes up, not the chapter you would publish. The same editorial habit we use for greetings applies: a scene, not a chapter. There is no universal token cap on an entry in the format. There is a budget on the World tab for how much keyed text can be injected at once, because a book that dumps twelve entries into one turn is a persona again.
YanMate's engine is a World Info port so that imported books behave like the books people already have. The panel on top does not say "scan depth". If you need the advanced controls they are there; most entries never need them.
The token counter's lorebook number is an estimate, four characters to a token, labelled as one. It does not simulate which keys will fire in your chat. It refuses to add those entries to the permanent subtotal, which is the claim the page exists to make.
Memory on this product is a ledger about you, not a world bible. The memory guide covers stale facts, guessed pronouns, and notes that existed but were never handed to a new character. None of that is a lorebook problem.
V3 added decorator lines on lorebook entries that V2 cannot hold. If you convert a card down, those lines go. The V2 vs V3 guide is the field list; the viewer will warn on a dual-chunk PNG.
If you want the world in play rather than in a file, a roleplay chat on this site can hold a scene of three characters on the free tier, with the same split: ledger for you, lorebook for the map. If you want a character who already lives in a workplace rather than a campaign, the Mentors shelf is the live one. Sort the fact before you write the entry. The wrong bucket is cheaper to avoid than to unpick from a card you have already sent someone.