Skip to content

okwow123/WebtoonGenerator

Repository files navigation

Webtoon Generator - AI-Powered Korean Webtoon Creation

A Minimax API-based automated webtoon generation system that transforms web novels into professional webtoon content.

๐ŸŽฌ Project Overview

Webtoon Title: The Superstition of the Funeral Home (์žฅ๋ก€์‹์žฅ์˜ ๋ฏธ์‹ )
Episode: 1
Genre: Horror, Thriller, Emotional, Humanism
Total Panels: 145 cuts
AI Model: Minimax image-01

๐Ÿ“ Project Structure

webtoon-generator/
โ”œโ”€โ”€ _workspace/              # All generated content
โ”‚   โ”œโ”€โ”€ 01_research/         # Concept and research phase
โ”‚   โ”‚   โ””โ”€โ”€ concept.json     # Webtoon concept document
โ”‚   โ”œโ”€โ”€ 02_story/            # Script and storyboard
โ”‚   โ”‚   โ”œโ”€โ”€ beatsheet.json   # 145-panel story breakdown
โ”‚   โ”‚   โ””โ”€โ”€ script.md        # Full dialogue and narration script
โ”‚   โ”œโ”€โ”€ 03_visual/           # Visual production
โ”‚   โ”‚   โ””โ”€โ”€ panels/          # 145 AI-generated panel images
โ”‚   โ””โ”€โ”€ 04_output/           # Final output
โ”‚       โ””โ”€โ”€ index.html       # Complete webtoon HTML
โ”œโ”€โ”€ skills/                  # Methodology documents (6 files)
โ”‚   โ”œโ”€โ”€ ORCHESTRATOR.md      # Workflow orchestration
โ”‚   โ”œโ”€โ”€ RESEARCH.md          # Trend research methodology
โ”‚   โ”œโ”€โ”€ SCENARIO.md          # Script writing methodology
โ”‚   โ”œโ”€โ”€ PANEL_BREAKDOWN.md   # Panel breakdown methodology
โ”‚   โ”œโ”€โ”€ VISUAL_RENDER.md      # Image generation methodology
โ”‚   โ””โ”€โ”€ ASSEMBLY.md          # Final assembly methodology
โ”œโ”€โ”€ src/                     # Source code
โ”‚   โ”œโ”€โ”€ minimax_api.py       # Minimax API client
โ”‚   โ”œโ”€โ”€ orchestrator.py      # Main orchestrator
โ”‚   โ”œโ”€โ”€ agents/              # AI agents
โ”‚   โ”‚   โ”œโ”€โ”€ research_agent.py
โ”‚   โ”‚   โ”œโ”€โ”€ scenario_agent.py
โ”‚   โ”‚   โ”œโ”€โ”€ visual_agent.py
โ”‚   โ”‚   โ””โ”€โ”€ assembly_agent.py
โ”‚   โ””โ”€โ”€ utils/
โ”‚       โ”œโ”€โ”€ image_generator.py
โ”‚       โ””โ”€โ”€ html_assembler.py
โ”œโ”€โ”€ config/
โ”‚   โ””โ”€โ”€ default_config.yaml
โ”œโ”€โ”€ generate_real_images.py   # Image generation script
โ”œโ”€โ”€ generate_fast.py         # Optimized generation script
โ”œโ”€โ”€ main.py                   # CLI entry point
โ”œโ”€โ”€ requirements.txt           # Python dependencies
โ””โ”€โ”€ README.md               # This file

๐Ÿ”„ Workflow

The project follows a 6-stage automated pipeline:

Stage 1: Research (01_research)

  • Trend analysis in Korean webtoon market
  • Concept establishment
  • Target audience analysis
  • World-building and setting development

Stage 2: Scenario (02_story)

  • Episode outline creation
  • Beatsheet writing (145 panels)
  • Dialogue and narration writing
  • Scene breakdown and pacing

Stage 3: Visual Production (03_visual)

  • Reference sheet generation
  • Panel image generation with AI
  • Quality validation
  • Regeneration loop for failed panels

Stage 4: Assembly (04_output)

  • HTML assembly
  • Vertical scroll layout
  • Atmosphere effects (fog, rain, dark overlays)
  • Final quality check

๐Ÿ› ๏ธ Installation & Setup

# Navigate to project directory
cd webtoon-generator

# Install dependencies
pip3 install requests pillow pyyaml

# Set API key (optional - already configured in config/)
export MINIMAX_API_KEY="your_api_key_here"
export MINIMAX_GROUP_ID="your_group_id_here"

๐Ÿš€ Usage

Generate All Panel Images

python3 generate_real_images.py

Generate with Resume (Skip Existing)

This optimized script automatically skips panels that have already been generated:

python3 generate_fast.py

View the Webtoon

Recommended: Open the Portfolio Viewer

Simply open webtoon_viewer.html in your browser:

# macOS
open webtoon_viewer.html

# Or use the absolute path:
open /Users/kimminje/project/webtoon-generator/webtoon_viewer.html

Full Webtoon (145 panels)

For the complete 145-panel episode:

# Option 1: Direct open
open _workspace/04_output/index.html

# Option 2: Local server (recommended for best performance)
cd _workspace/04_output
python3 -m http.server 8080
# Then visit: http://localhost:8080

Note: The portfolio viewer (webtoon_viewer.html) provides the best viewing experience with project metadata, scene breakdown, and atmospheric effects. The full webtoon is available in _workspace/04_output/index.html.

๐Ÿ“– Webtoon Content

Episode 1: The Superstition of the Funeral Home

Synopsis

A 10-year veteran office worker in Pangyo receives news that his close friend's father has passed away. Despite knowing his pregnant wife would disapprove, he decides to attend the funeral. On the way home, he follows traditional Korean superstitions - scattering salt, visiting a public restroom, and walking around a supermarket. That night, strange events begin to occur...

Key Scenes

Cut Scene Description
1-17 Opening Introduction to superstition and ghosts
18-30 Background 10-year work life, friendships
31-41 Conflict Should he go to the funeral?
42-53 Journey Driving to funeral in the rain
54-69 Horror 2:17 AM, door handle moving
70-80 Twist CCTV footage reveals a faceless woman
81-145 Resolution The meaning of superstition, Mahura plate story

Narrative Themes

  • Superstition vs. Rationality
  • Fear of the Unknown
  • Family Protection Instinct
  • Korean Funeral Traditions
  • Ghost and Grudge Mythology

๐Ÿ“š Methodology

This project follows a multi-agent workflow inspired by the webtoon-harness methodology:

Multi-Agent Architecture

  • Research Agent: Analyzes trends and establishes concepts
  • Scenario Agent: Creates beatsheets and scripts
  • Visual Agent: Generates panel images using AI
  • Assembly Agent: Assembles final HTML output

Key Design Principles

  1. Reference Sheet First: Generate character/location reference images before panel production
  2. In-Image Text: All text (dialogue, narration) is rendered within images
  3. Validation Loop: Check each panel for quality, regenerate if needed
  4. Consistent Style: Maintain visual consistency across all 145 panels

Horror Webtoon Guidelines

  • Dark color palette (black, dark blue, gray)
  • Atmosphere effects (fog, rain, shadows)
  • Sound effect overlays (์ฒ ์ปฅ, ๋นต๋นต)
  • Tension-building through pacing

๐ŸŽจ Visual Style Guide

Color Palette

Purpose Color Hex
Background Black #0a0a0f
Horror Accent Dark Red #8b0000
Funeral Gray Gray #4a4a4a
Night Blue Deep Blue #1a1f3a
Text Warm Beige #d4c4a8

Aspect Ratio

  • Panel: 9:16 (540x960 pixels)
  • Optimized for mobile vertical scroll

Art Style

  • Korean webtoon aesthetic
  • Realistic shading with comic style
  • Horror atmosphere through lighting
  • Cultural authenticity in settings

๐Ÿ”ง API Configuration

Minimax API

API_URL = "https://api.minimax.io/v1/image_generation"
MODEL = "image-01"
RESPONSE_FORMAT = "base64"
ASPECT_RATIO = "9:16"

Config File (config/default_config.yaml)

# Minimax API
minimax_api_key: ""  # Your API key
minimax_base_url: "https://api.minimax.chat/v1"
minimax_group_id: ""  # Your Group ID

# Image Settings
image:
  default_width: 1280
  default_height: 1706
  default_style: "webtoon"
  max_concurrent: 3
  aspect_ratio: "9:16"

# Output Settings
output:
  format: "html"
  generate_thumbnails: true
  output_dir: "_workspace/04_output"

๐Ÿ“Š Project Statistics

Metric Value
Total Panels 145
Total Cuts 145
File Size (Images) ~32 MB
HTML Size ~250 KB
Estimated Reading Time 5-7 minutes
Generation Time ~60 minutes

๐Ÿ“ Methodological Documents

Detailed methodology documents are available in the skills/ directory:

๐Ÿ“ฆ Generated Output Structure

_workspace/
โ”œโ”€โ”€ 01_research/
โ”‚   โ””โ”€โ”€ concept.json           # Webtoon concept and metadata
โ”œโ”€โ”€ 02_story/
โ”‚   โ”œโ”€โ”€ beatsheet.json         # 145-panel story breakdown
โ”‚   โ””โ”€โ”€ script.md              # Full dialogue script
โ”œโ”€โ”€ 03_visual/
โ”‚   โ””โ”€โ”€ panels/
โ”‚       โ”œโ”€โ”€ panel_001.jpg      # First panel
โ”‚       โ”œโ”€โ”€ panel_002.jpg      # Second panel
โ”‚       โ””โ”€โ”€ ...
โ”‚       โ””โ”€โ”€ panel_145.jpg      # Last panel
โ””โ”€โ”€ 04_output/
    โ””โ”€โ”€ index.html             # Final webtoon HTML

๐ŸŽฏ Features

Automated Pipeline

  • End-to-end webtoon generation from concept to final HTML
  • Multi-agent architecture for specialized tasks
  • Quality validation at each stage

AI-Powered Visual Generation

  • Minimax image-01 model for high-quality panel generation
  • Consistent character and scene appearance
  • Horror atmosphere effects (fog, rain, dark overlays)

Responsive Webtoon Viewer

  • Mobile-optimized vertical scroll layout
  • Lazy loading for images
  • Atmospheric effects overlay
  • Sound effect bubbles

Production-Ready

  • Batch processing for efficient image generation
  • Resume capability (skip already generated panels)
  • Error handling and validation

๐Ÿ› Troubleshooting

Common Issues

API Key Error

Error: Invalid API key

Solution: Set your Minimax API key in config/default_config.yaml or as environment variable

Image Generation Fails

Error: Failed to generate image

Solution: Check your API quota and internet connection, then retry

Panels Not Loading

Image not found: panel_001.jpg

Solution: Run python3 generate_real_images.py to generate all panel images

Performance Tips

  1. Use Resume Mode: Run python3 generate_fast.py to skip already generated panels
  2. Batch Size: Adjust max_concurrent in config for your API rate limit
  3. Quality Check: Review generated panels before final assembly

๐Ÿ“‹ Requirements

  • Python 3.7+
  • requests library
  • pillow library
  • pyyaml library
  • Minimax API key

๐Ÿ“„ License

This project is for educational and portfolio purposes.

๐Ÿ™ Acknowledgments

  • Inspired by webtoon-harness methodology
  • Powered by Minimax AI image generation API
  • Korean webtoon industry for creative inspiration

๐Ÿ”— Related Documentation

๐ŸŒ Portfolio Viewer

For the best viewing experience with full project information, atmospheric effects, and easy navigation:

๐Ÿ“‚ Open: webtoon_viewer.html

Open directly in your browser:

open webtoon_viewer.html

Or use the full path:

open /Users/kimminje/project/webtoon-generator/webtoon_viewer.html

This portfolio viewer includes:

  • Project overview and synopsis
  • Episode metadata (genre, panel count, reading time)
  • Key scene breakdown
  • Sample panels with atmospheric overlays
  • Navigation links to the full webtoon

File Locations:

webtoon-generator/
โ”œโ”€โ”€ webtoon_viewer.html     # โ† Portfolio viewer (recommended)
โ””โ”€โ”€ _workspace/
    โ””โ”€โ”€ 04_output/
        โ””โ”€โ”€ index.html      # โ† Full 145-panel webtoon

Results:

แ„‰แ…ณแ„แ…ณแ„…แ…ตแ†ซแ„‰แ…ฃแ†บ 2026-07-08 แ„‹แ…ฉแ„’แ…ฎ 7 28 57 แ„‰แ…ณแ„แ…ณแ„…แ…ตแ†ซแ„‰แ…ฃแ†บ 2026-07-08 แ„‹แ…ฉแ„’แ…ฎ 7 29 43 แ„‰แ…ณแ„แ…ณแ„…แ…ตแ†ซแ„‰แ…ฃแ†บ 2026-07-08 แ„‹แ…ฉแ„’แ…ฎ 7 30 27

Generated with AI-powered webtoon production pipeline

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

Packages

Contributors

Languages