Skip to content

Lorebook

EventideMiles edited this page Oct 6, 2026 · 1 revision

Lorebook

The Lorebook is Eventide Quill's typed worldbuilding index: ordinary Markdown notes in folders you choose, scanned into coverage views, a relationship map, and context fuel for the AI — all deterministically, with no AI calls and nothing leaving your machine. You'll find it under the Lorebook tab in the Quill sidebar; its settings live under Settings → Lorebook.

Your entries are plain notes. Rename them, restructure them, or read them in any other app and nothing breaks — the scan is rebuilt from your files each time, with no separate database to corrupt or fall out of sync.

Typed entries and folders

  • Any Markdown file under a configured lorebook folder ("Lorebook folders" in settings) is an entry. Files under nested lore folders report to the deepest match, so Lore/Characters wins over Lore.
  • An entry's type comes from the flat quill-type frontmatter key. The full set: character, location, event, item, faction, plot-thread, theme.
  • Anything else — a misspelling, or a missing key — makes the entry untyped: it still appears in the panel and counts toward totals, but it doesn't participate in manuscript coverage mapping (see below).
  • Each folder can carry a default type, set alongside the folder in settings, so a whole folder can be characters without frontmatter on every file. A file's own quill-type always wins over the folder default.
  • Aliases come from Obsidian's standard aliases frontmatter — a proper list, or a comma/newline-separated string. Name matching covers the filename plus all aliases, case-insensitively, at whole-word boundaries.
  • A mention that is a whole word inside an entry name still counts as covered: "Westbrook" matches an entry named "Westbrook Academy".
  • When the active file is an entry, the panel shows an inline type editor, so you can categorize the note you're looking at without hand-editing frontmatter.

Coverage

Coverage answers "does everything in my story have a note — and does every note still matter?" It runs in two sub-tabs, both computed locally:

  • Document — which entries the active document references (by name or alias) and which are orphaned by it. The entry you're currently viewing is excluded from both lists. Gaps aren't computed here — they need entity extraction.
  • Manuscript — the referenced/orphaned split across the whole manuscript, plus gaps: entities the extractor found appearing at least 3 times with no entry of the same type covering them. The fixed threshold keeps one-off mentions from generating noise, and the list is sorted with the most-mentioned gaps first. Gaps you don't agree with can be dismissed.

Two honest limits: a location note can never cover a character gap (matching is type-aware), and untyped entries can suppress nothing — they're displayed, but only typed entries participate in manuscript coverage.

Relationships

The Relationships sub-tab maps how entries connect. The source is body [[wikilinks]] that you author between lore notes — the same body-syntax-over-frontmatter choice the image galleries make, so Obsidian's rename tracking keeps links valid automatically.

It's an opt-in, writer-authored layer: Quill's detection, context fuel, and coverage remain entirely link-free and don't depend on you maintaining wikilinks. What the view gives you:

  • Edges — direction is collapsed, so an A→B link and a B→A link render as one symmetric connection, deduplicated.
  • Dangling links — [[targets]] that don't resolve to any file, usually planned-but-unwritten entries. They're surfaced like gaps, and clicking one jumps to the exact link in the source note.
  • Unconnected entries — lore notes nothing links to, which may be fine or may be an integration gap.
  • Links that resolve outside the lorebook (to manuscript chapters, say) are ignored — a legitimate reference, not a relationship.

The list view always renders. The entries×entries matrix appears only while at most 50 entries are connected; above that it would be unreadable in a sidebar, and a note tells you the matrix was hidden.

The lorebook coach

Pick Lorebook (📖) in the co-writer's mode picker and the model works as a developmental editor for your world — backstories, motivations, relationships, internal consistency — rather than a prose writer. Its working agreement: gather context before proposing (sibling entries, existing notes, manuscript mentions), dig past first answers on non-visual details, and never invent facts that contradict what the vault returns.

Drafts never write themselves. The coach surfaces each one through a propose_entry tool call, which renders as a draft card in the chat:

  • Save writes the note, adding the quill-type frontmatter at save time.
  • Request changes keeps the coach refining the same draft.
  • Discard drops it without touching the vault.

Every draft, edit, and image proposal flows through the same approval queue described in Co-writer and tools — nothing reaches the vault without your click.

With "Prefer editing existing lore" on (the default), a draft whose exact name already matches any note in the vault is refused, and the refusal does the routing for the model: it names the existing file and its length, then points at the editing tools — fill an empty note with insert_note/append_to_note, revise a populated one with edit_note. This prevents duplicate notes that would strand [[wikilinks]] pointing at the original. Turn the toggle off to allow unconditional creation.

Batch edits and research

For a whole-lorebook pass, the coach hands a file list to run_lorebook_batch, which spawns a subagent — an isolated worker with its own fresh context. The subagent concept, its status cards, and the drill-down view are covered in Co-writer and tools; the lorebook-specific parts:

  • You pass the full file list; the tool splits it. Sizing runs against the subagent's fresh context window, not your chat's remaining space: file bodies are packed to roughly half the model's context window per batch, with a minimum of one file per chunk.
  • At most five batches run per call. Anything beyond is reported back as deferred, with the leftover file list, so the model can re-run for the rest.
  • Edits are not isolated. Every diff lands in the shared review queue exactly like an inline edit, and the cards persist after the subagent closes.
  • Your chat is blocked while it runs — a local model handles one inference at a time, so the subagent is serialized, not concurrent. Cancelling the chat cancels the batch.
  • Subagents can't spawn further subagents — one level deep by construction.

A sibling tool, run_research, spawns a read-only subagent to answer a question against the vault — and, when network tools are on, against external references. What those tools can reach is the truth table on Privacy and network.

Entry images

Attach reference art to an entry by placing ![[file.png]] embeds under a gallery section — a heading matching one of the "Image gallery section headings" (default: Reference, Reference images, Gallery, Forms, Appearance, Art; matching is case-insensitive). The rest of the machinery follows from that one convention:

  • Subheadings inside the section become per-image labels, so a multi-form character can carry "Default form" and "Alternate form" images side by side. ![[file|caption]] captions are kept too.
  • The scanner parses embeds from Obsidian's metadata cache — no file reads, fully synchronous, instant even on large vaults.
  • "Max images per lore entry" caps what the scanner extracts per entry (default 4, range 1–20). It's a budget tool: overflow is silently dropped, though you can still place as many embeds in the note itself as you like.
  • Embeds pointing at missing files keep their place with a visible "missing" badge rather than vanishing.

The AI reaches these images through the get_lore_image tool — by default it returns every image attached to the entry, narrowable by label and/or position. The lore_siblings listing shows which labels exist (with per-label counts), so the model knows what it can request before asking.

Agent attachment. With "Agent image attachments" on (the default), the lorebook coach can propose images alongside a new draft, and the attach_lore_image tool can propose images for existing entries. Models rarely hold raw bytes, so both accept a from_recent reference — a 0-based index into the last 12 images the session has seen, fetched by tools or pasted by you, most recent first. Every proposal is a review card: on approval the bytes are written to the "Attachment folder" (empty = Obsidian's configured attachment folder) and the embed is inserted under the right label; on rejection nothing is ever written to the vault.

Context hygiene. Embed syntax is stripped out of lore context at auto-injection and embedding time — replaced by a one-line marker that preserves the heading and label names so the model knows what it can fetch — keeping chunks lean and stopping filenames from priming hallucinations. The token economics, and why editing views deliberately keep the raw text, are covered in Context management.

Fandom and Wikipedia

For canon research, the co-writer can query Fandom and Wikipedia. Configuration lives under Settings → Lorebook:

  • "Fandom wikis" — a comma-separated allowlist of wiki subdomains (e.g. starwars, memory-alpha, lotr). An empty list disables Fandom everywhere.
  • "Allow any wiki" — the danger toggle that lets the model query any Fandom wiki it chooses. Enabling it shows a warning Notice; prefer the allowlist.
  • "Fandom page cache" (default on) — lookups are saved to a local cache so repeats skip the network and work offline. Once a page is cached, it answers even with network tools off, because consent happened at sync time. The cache lives in the plugin data folder, not your vault — so it is not included in a vault sync, but it is included in a Portability backup.
  • "Wikipedia language" — the language subdomain for all wikipedia_* tools (default en; validated input).
  • Sync — the "Sync fandom wiki cache" setting action or the "Quill: Sync fandom wiki cache" command downloads every page from one allowlisted wiki at a fair, throttled rate; "Quill: Cancel fandom wiki sync" stops a running sync. The "Cached wikis" section shows per-wiki page and image counts with a clear button per wiki.

Which tools register under which toggles — and what a populated cache answers with the network off — is the truth table on Privacy and network.

The Lorebook tab also hosts two sub-tabs with their own pages: Memories (see Memories) and Hygiene (see Attachment metadata).

Clone this wiki locally