đź§ CHRONICLE CODEX - Self-maintaining continuity system
🧠CHRONICLE CODEX A self-maintaining continuity system for long AI Dungeon adventures. CHRONICLE CODEX is built for stories where the cast, world and plot keep growing until manual Story Card upkeep starts getting in the way of actually playing. It watches the real adventure history, learns recurring entities from evidence, maintains useful continuity, and leaves things alone when the story has not earned an update. 📚 SMART AUTO-CODEX Automatically detect and maintain: 👤 Characters 📍 Locations 🗡️ Items / vehicles / important objects 🏛️ Factions / organisations / businesses Detection is not “capital letters = character”. CHRONICLE CODEX combines repeated appearances, separate turns, dialogue/actions, naming cues, titles, movement language, venue names, item-use language, organisation behaviour and typed descriptions before automatic creation is allowed. It uses a 5,000+ term ordinary-word shield plus morphology and contextual sentence-start guards to reject generic prose, dialogue verbs, descriptors, scene/body nouns, food, weather, time words, roles, pronouns, product modifiers and control text. Repeated mentions in one long action still count as one turn, while their classification clues and strongest local evidence are combined. Aliases are evidence-based too. Supported aliases can merge; conflicting aliases become ambiguous instead of joining the wrong entities. Article variants such as Moonfang / The Moonfang can merge when their type evidence agrees without blindly merging unrelated names. 🔄 STORY CARDS THAT EVOLVE Managed cards collect new evidence local to that entity. A dramatic event elsewhere in the same paragraph does not automatically rewrite everyone mentioned in it. When a refresh is justified, it preserves facts that remain true, adds supported durable changes, removes facts later canon actually invalidated, and returns unchanged when the card already says what matters. With manual protection enabled, edits to the core card fields protect the card from automatic refresh. /lc resume <name> accepts your edited version as the new baseline whenever you want automation back. Managed cards carry an internal sentinel so they can be re-linked after script-state loss. 🧠DYNAMIC PLOT ESSENTIALS Plot Essentials can be assessed after a configurable number of actions, but the interval does not force a rewrite. CHRONICLE CODEX first checks whether anything meaningful changed. Generated Plot Essentials focus on durable current continuity: protagonist state/location, active goals, important relationships, unresolved threats or obligations, significant possessions/conditions, active rules and major revelations. It avoids becoming a scene-by-scene diary. Manual Plot Essentials are preserved; disabling generation releases the script override instead of wiping the base memory. ✍️ DYNAMIC AUTHOR’S NOTE Author’s Note runs independently and focuses on the next generation: genre, tone, atmosphere, pacing, POV/style emphasis and current scene mode. It is not duplicate lore storage and it is instructed not to seize player agency. 🌊 CHARACTER CURRENT Active NPCs can keep a compact narrator-side state containing: • mood • immediate intent • pressure • working assumption • present restraint / what they are choosing not to say When enabled, recently active snapshots can subtly influence hesitation, attention, tone, choices and subtext. The system is conservative: unknown fields can stay blank, stale snapshots expire, and it cannot invent dramatic secrets simply to make an NPC more interesting. ⚙️ FULL CONTROL A CHRONICLE CODEX — Config Story Card is created automatically. Switch the master system, creation, refresh, each entity type, detection strictness, mention requirements, cooldowns, manual protection, Plot Essentials, Author’s Note, memory sensitivity, Character Current, influence, expiry, limits and history window independently. 🛡️ BUILT FOR LONG STORIES CHRONICLE CODEX handles retry/undo, stale evidence, duplicate aliases, malformed worker output, backoff, manual edits, context clipping and scheduler fairness. Core Story Card writes use AI Dungeon’s documented scripting helper shape rather than depending on undocumented extra arguments. It watches. It waits for evidence. It remembers what matters. Use it with fantasy, superhero, horror, romance, crime, sci-fi, slice-of-life, historical adventures or mixed settings. It is deliberately scenario-agnostic and adapts to the story you actually play. GITHUB - https://github.com/amazingrand0mproductions-crypto/-CHRONICLE-CODEX/tree/main
