AI Agents I Built (2/7) — Story Director: Completing a 30-Chapter Novel
Agent architecture, context management strategies, and character consistency techniques required to complete a full-length novel
What This Post Covers
- 4 structural components of an AI agent designed for long-form narrative completion (world-building, character sheets, outline, continuity tracking)
- Hierarchical reference strategy for connecting 30 chapters within a limited context window (last 3 chapters verbatim + prior chapter summaries + foreshadowing tracker)
- Dialogue-sample-based character sheet design and post-chapter consistency check loops
- Strengths and limitations of AI in long-form narrative — which tasks to delegate to AI and which must remain with the author
Design Target: Why a Creative Agent Differs from a Technical Agent
A technical agent operates on well-defined inputs and outputs: read a file, modify code, run tests. A creative agent's objective — "complete a coherent long-form narrative" — is inherently ambiguous. That distinction produces four concrete design requirements.
- World-building document — Maintain the novel's world, technology rules, and organizational structures as a separate, persistent document. Fixed values that must not be regenerated each chapter are externalized to a reference store.
- Character sheets — Define each character's personality, backstory, relationships, and speech patterns. Sheets must include sample dialogue, not just attribute lists.
- Chapter outline — Design the full 30-chapter arc before writing any chapter. Unplanned generation causes plot diffusion around chapter 10.
- Continuity tracker — Maintain a dedicated document for events that occurred in prior chapters and unresolved foreshadowing threads.
Without these four pillars, defects accumulate past chapter 10: characters behave as different people, or already-resolved events reappear.
Case: "Ghost Network" Specifications
The following are the specifications of "Ghost Network," the full-length novel completed using this technique.
- Length: 30 chapters, 258,000 characters (approximately 800 pages in Korean)
- Genre: Cybersecurity / tech thriller
- Premise: A security expert tracks down the true identity of the anonymous hacking collective "Ghost Network"
- 5-act structure: Introduction (ch. 1–5) → Development (ch. 6–15) → Crisis (ch. 16–22) → Climax (ch. 23–27) → Resolution (ch. 28–30)
These specifications serve as the reference baseline for the techniques described in subsequent sections.
Context Management — Hierarchical Reference Strategy
An LLM's context window is finite. Injecting all 30 chapters at once is impossible; providing no prior context collapses narrative continuity. The combination that works in practice uses four layers.
- Last 3 chapters verbatim — The three immediately preceding chapters are injected as raw text. Style, dialogue rhythm, and scene-level detail must be preserved for the next scene to connect naturally.
- Summarized prior chapters — Chapters older than that are compressed to approximately 300-character summaries. Only plot progression and character state changes are retained; description is discarded.
- Foreshadowing tracker — Unresolved foreshadowing threads, open questions, and deferred plot hooks are maintained as a separate list.
- Character state snapshots — Each character's current location, emotional state, and known information are updated per chapter.
This structure trades "resolution of recent context" against "span of the full narrative" within a token budget. Limitations remain. Minor setup details from early chapters are observed to drop out in later chapters, requiring manual correction. The root cause is detail loss during the summarization step.
Character Consistency — Sheet Design and Post-Chapter Verification
AI does not "remember" a character's personality when writing each chapter — it "references" the sheet. That distinction produces subtle inconsistencies. Three countermeasures address this.
- Dialogue-sample sheets — Include 3–5 sample lines in the sheet alongside personality traits. An example like "…could be, could not be. Need to check." conveys style more precisely than a descriptor like "cautious."
- Post-chapter consistency check — After each chapter is written, run a review pass comparing each character's dialogue and actions against the sheet. Identify and correct utterances that deviate from the defined profile.
- Immediate sheet updates — Significant character changes — growth, betrayal, relationship shifts — are reflected in the sheet immediately after the chapter is complete. The reference baseline for the next chapter must reflect the changed state.
The limitation is most visible in secondary characters. Protagonists accumulate dense sheets and stable speech patterns through high page-count exposure; secondary characters have sparse sheet entries and exhibit voice drift across chapters. This is not fully resolved. Mandatory dialogue samples for secondary character sheets is the identified improvement point.
Strengths and Limitations of AI in Long-Form Narrative
The outcome — a completed 258,000-character novel — is a data point demonstrating feasibility, not a ceiling on quality. AI performance splits clearly by task type.
Where AI performs well - Advancing chapters consistently along a defined plot structure - Technical setting detail (hacking techniques, network architecture, etc.) - Dialogue for characters with fully populated sheets
Where AI falls short - Natural use of metaphor and symbolism - Narrative rhythm designed to deliberately manipulate reader emotion - Nuanced expression of internal character transformation
In conclusion, reaching publication-grade quality requires a human editing layer. AI is effective at driving a draft to a completed state; literary depth is added in the editing phase. That division of labor is the realistic operating model.
Limitations and Corrective Directions
Three corrective points emerged from the design process. Each is directly applicable to any designer facing the same problem.
- Outline first — Attempting chapter-by-chapter improvisation without a prior outline causes plot diffusion around chapter 10. Establishing the full structure before filling in chapters produces a stable result.
- Pre-calculate context budget — Unconditionally injecting the last N chapters verbatim will hit the token ceiling. "Last 3 chapters verbatim + all prior chapters summarized" is the empirically validated balance point.
- Maintain the completion structure — A temptation to close the story early appears around the midpoint (chapter 20). Holding to the planned 30-chapter structure yields better overall quality, because unresolved foreshadowing threads from the first half still require payoff in the remaining chapters.
Applicable Scope and Open Questions
This technique set is most effective for long-form narrative with complex world-building: cybersecurity thrillers, SF, fantasy, mystery — genres where state management of world, characters, and foreshadowing carries high weight. Conversely, short fiction, prose poetry, and essays — forms where micro-level sentence quality dominates — show limited benefit.
Two questions remain open.
- How to recover detail lost during summary compression. Early-chapter setup dropping out in later chapters is a fundamental limitation of the summarization strategy. Whether a retrieval-augmented recall (RAG) layer can compensate requires further experimentation.
- How far secondary character voice can be sheet-codified. Unlike protagonists, secondary characters appear infrequently, leaving their sheets thin. The minimum viable number of dialogue samples and the cost-benefit break-even point need to be quantified.
AI can function as a tool for driving a long-form narrative to completion. What determines the quality ceiling is the design of the sheets, structure, and editing loop.
Series overview: Series index
๋๊ธ
๋๊ธ ์ฐ๊ธฐ