Skip to content

[Feature]: Add outline review and refinement step before content generation #173

@nkmohit

Description

@nkmohit

Problem or Motivation

After outline generation, the app waits 800ms and then immediately starts scene content generation by calling /api/generate/scene-content with no user confirmation step. Users currently can’t remove unwanted scenes, reorder items, or adjust titles before the expensive generation runs.

This is also different from #68 (post-generation editing) because this feature enables controlled pre-generation, saving unnecessary calls for scenes the user doesn’t want.

Proposed Solution

Two-phase approach:

Short term (UI wiring):

  • Wire up the existing OutlinesEditor component (components/generation/outlines-editor.tsx) into the outline->content flow in app/generation-preview/page.tsx.
  • After /api/generate/scene-outlines-stream finishes streaming, pause on the outline step and render OutlinesEditor.
  • Only proceed to content generation after the user clicks a confirm action, using the (possibly edited) outlines.

Long term (conversation loop):

  • Add a conversational refinement loop so users can provide natural-language feedback (e.g., “remove the quiz scenes”, “add a section on positional encoding”, “make it more beginner friendly”).
  • The AI regenerates/refines the outline based on the original requirement + prior outline + user feedback.
  • Repeat until the user confirms, then start scene content generation.

Alternatives Considered

  • Do post-generation editing only (but is less efficient because content generation already happened).
  • Full regeneration from scratch (works but slower and more costly than targeted outline refinement).

Area

Classroom generation

Additional Context

  • There is an OutlinesEditor component in components/generation/outlines-editor.tsx that appears to be planned for this use case but is currently unused.
  • This change would give curators control before expensive generation and supports both manual editing now and AI-assisted iteration later.

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or request

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions