Root cause: AR retries book_outline when score < 60; each retry's package step creates a new batch of chapters. InProgress chapters can't be deleted on rejection so multiple sets accumulate. The boardroom deliberation (4 rounds) is the quality gate — no retry needed at the outline level. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
201 lines
8.6 KiB
YAML
201 lines
8.6 KiB
YAML
name: book_outline
|
||
description: "Boardroom debate to lock the book concept, produce a character bible (for fiction) + full chapter outline, then spawn chapter writing tasks."
|
||
debug: true
|
||
system: agent_prompt
|
||
context_builders:
|
||
- markov_names
|
||
|
||
participant_prompt:
|
||
- "= identity.md"
|
||
|
||
agent_prompt:
|
||
- "= identity.md"
|
||
|
||
sections:
|
||
- agent
|
||
- project
|
||
- history
|
||
- rag
|
||
- deliverables
|
||
- participants
|
||
- participants_prompt
|
||
- message
|
||
- instructions
|
||
|
||
steps:
|
||
- type: think
|
||
rotate_participants: true
|
||
loop:
|
||
max_iterations: 4
|
||
hint: |
|
||
You are {agent.name}. This is round {task.iteration} of the creative boardroom.
|
||
|
||
GENRE: {genre_name|[infer from project description if blank]}
|
||
AUDIENCE: {genre_audience|[infer from project description if blank]}
|
||
STRUCTURE GUIDE: {outline_structure|[use standard 3-act structure with chapter hooks if blank]}
|
||
|
||
The room is deciding on ONE book concept to write. The trend research
|
||
is in the DELIVERABLES and RAG above — everyone has read it.
|
||
|
||
═══════════════════════════════════════════════
|
||
PRE-ASSIGNED CHARACTER NAMES (fiction projects — use these exactly)
|
||
═══════════════════════════════════════════════
|
||
These names were generated for this project. Do NOT substitute generic defaults
|
||
like Jax, Elara, Ryder, Quinn, Lyra, Knox, or Zane.
|
||
|
||
Protagonist: {protagonist_name}
|
||
Love interest: {love_interest_name}
|
||
Antagonist: {antagonist_name}
|
||
Supporting: {supporting_1}, {supporting_2}, {supporting_3}
|
||
Setting/Town: {place_name}
|
||
|
||
(Non-fiction projects: ignore the character names above — they are not applicable.)
|
||
═══════════════════════════════════════════════
|
||
|
||
From YOUR area of expertise, argue for (or against) a specific concept:
|
||
- Which of the research concepts has the strongest hook for this audience?
|
||
- What protagonist archetype will readers obsess over?
|
||
- What central conflict creates the best chapter-to-chapter tension?
|
||
- What's the opening chapter hook that makes a reader continue?
|
||
- What should the chapter length and structure be?
|
||
|
||
React to what prior speakers argued. Push back on weak ideas. Build on strong ones.
|
||
Be specific — no vague enthusiasm. Name the concept, argue WHY.
|
||
|
||
When the group has agreed on ONE specific concept (title, hook, protagonist, conflict, structure):
|
||
"consensus_reached: true"
|
||
|
||
- type: think
|
||
agent: first_available
|
||
hint: |
|
||
The boardroom has selected ONE concept. Your job is to write the SINGLE CANONICAL outline.
|
||
|
||
⚠️ CRITICAL RULES:
|
||
- Do NOT present multiple options, alternatives, or "Option A / Option B" variants.
|
||
- Do NOT include chapter ideas from the deliberation rounds that were NOT selected.
|
||
- Write ONE definitive chapter list. If the project calls for 10 chapters, write EXACTLY 10.
|
||
- Every chapter entry must follow the exact format: "- Chapter N: [Title]" (sequential, no gaps).
|
||
|
||
Synthesize the agreed concept into a COMPLETE BOOK OUTLINE document.
|
||
|
||
═══════════════════════════════════════════════
|
||
PART 1: CHARACTER BIBLE (fiction only — omit entirely for non-fiction)
|
||
═══════════════════════════════════════════════
|
||
If this is a fiction project, write a Character Bible FIRST:
|
||
|
||
# [Book Title] — Character Bible
|
||
|
||
## {protagonist_name}
|
||
- Age:
|
||
- Voice: [describe the internal narrative voice — e.g., "sardonic, first-person, teen"]
|
||
- Background: [2 sentences]
|
||
- Want: [what they think they want]
|
||
- Need: [what they actually need to grow]
|
||
- Fatal flaw: [the trait that creates conflict]
|
||
- Speech pattern: [how they talk — with examples]
|
||
|
||
## {love_interest_name}
|
||
- Age:
|
||
- Role in story:
|
||
- Why readers root for them:
|
||
- Dynamic with protagonist:
|
||
- Secret or wound they carry:
|
||
|
||
## {antagonist_name}
|
||
- Type: [person / institution / supernatural / internal]
|
||
- Motivation:
|
||
- How they challenge the protagonist:
|
||
|
||
## Supporting Characters
|
||
- {supporting_1}: [role and relationship to protagonist]
|
||
- {supporting_2}: [role and relationship to protagonist]
|
||
- {supporting_3}: [role and relationship to protagonist]
|
||
|
||
## World Rules (if paranormal/fantasy/speculative)
|
||
- [Powers, systems, constraints — be precise]
|
||
- [What limits them? What are the costs?]
|
||
|
||
═══════════════════════════════════════════════
|
||
PART 2: CHAPTER OUTLINE (all projects)
|
||
═══════════════════════════════════════════════
|
||
|
||
# [Book Title]
|
||
## Concept Summary
|
||
- Hook: one sentence that sells the book
|
||
- Genre: {genre_name}
|
||
- Protagonist: name, age, background, flaw, want vs need
|
||
- Antagonist / Central Conflict: what stands in their way
|
||
- Setting: world, time, atmosphere
|
||
- Format: target chapter length ~{chapter_target_words} words, POV (1st/3rd)
|
||
- Target audience: {genre_audience}
|
||
|
||
## Chapter Outline
|
||
For each chapter (target {chapter_count} chapters):
|
||
- Chapter N: [Title]
|
||
- Summary: 2–3 sentences of what happens
|
||
- Emotional beat: what the reader feels
|
||
- Hook / cliffhanger: how this chapter ends
|
||
|
||
## Voice & Tone Guide
|
||
Three sentences describing the narrative voice per the style guide below.
|
||
PROSE STYLE: {prose_style}
|
||
One example opening sentence.
|
||
|
||
## Publishing Notes
|
||
Why this book fits the genre and target audience.
|
||
|
||
- type: document
|
||
filename: "{{task_name_slug}}"
|
||
|
||
- type: package
|
||
packet_type: IntakeResponse
|
||
hint: |
|
||
You are the Project Manager serializing the FINAL OUTLINE DOCUMENT above into chapter tasks.
|
||
|
||
⚠️ STRICT DEDUPLICATION RULES:
|
||
- Use ONLY the chapters listed in PART 2: CHAPTER OUTLINE of the document above.
|
||
- IGNORE all chapter suggestions from the boardroom deliberation rounds.
|
||
- Count ONLY entries formatted as "- Chapter N:" in PART 2. That count = your action count.
|
||
- A 10-chapter outline = exactly 10 actions. A 12-chapter outline = exactly 12 actions.
|
||
- If you produce more actions than chapter entries in PART 2, you have made an error — recount.
|
||
|
||
For each chapter in PART 2 (and ONLY those chapters), create one create_task action:
|
||
|
||
CRITICAL — Fill in these values from the outline document:
|
||
- genre_name: the exact genre (e.g., "YA Romance", "Science Fiction", "Literary Fiction")
|
||
- genre_audience: the target audience (e.g., "Young adults 14–18", "Adult romance readers")
|
||
- prose_style: copy the 3-sentence Voice & Tone Guide from the outline exactly
|
||
- chapter_target_words: the target word count per chapter as a number string (e.g., "3500")
|
||
- chapter_ref: zero-padded two-digit chapter number, e.g. "ch-01", "ch-02", ... "ch-18"
|
||
|
||
Rules:
|
||
- EXACTLY one action per chapter from PART 2 of the outline — no more, no less
|
||
- task_name format: "Write Chapter N: [Chapter Title]" (N is a plain number, 1, 2, 3...)
|
||
- agent_name: always "Iris"
|
||
- task_type: always "book_chapter"
|
||
- description: Include the chapter summary, POV character, emotional beat, and cliffhanger from the outline.
|
||
Start with: "You are writing Chapter N of [Book Title]. [chapter summary]. POV: [character name]."
|
||
- depends_on: the exact task_name of the PREVIOUS chapter (empty string for Chapter 1)
|
||
|
||
The depends_on chain creates sequential writing — each chapter waits for the previous to be committed.
|
||
schema:
|
||
actions:
|
||
- type: create_task
|
||
task_name: "string"
|
||
agent_name: "string"
|
||
task_type: "string"
|
||
description: "string"
|
||
depends_on: "string"
|
||
context:
|
||
genre_name: "string"
|
||
genre_audience: "string"
|
||
prose_style: "string"
|
||
chapter_target_words: "string"
|
||
chapter_ref: "string"
|
||
|
||
- type: close
|
||
rag_update: true
|
||
|
||
adjudication:
|
||
enabled: false
|