slidemovie 0.1.0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2026 Katsutoshi Seki (関 勝寿)
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
@@ -0,0 +1,110 @@
1
+ Metadata-Version: 2.4
2
+ Name: slidemovie
3
+ Version: 0.1.0
4
+ Summary: Markdown and PowerPoint to narration video generator
5
+ Author: Katsutoshi Seki
6
+ License-Expression: MIT
7
+ Project-URL: Homepage, https://sekika.github.io/slidemovie/
8
+ Project-URL: Source, https://github.com/sekika/slidemovie
9
+ Keywords: powerpoint,markdown,video,tts,presentation,automation
10
+ Classifier: Development Status :: 3 - Alpha
11
+ Classifier: Intended Audience :: Developers
12
+ Classifier: Intended Audience :: Education
13
+ Classifier: Operating System :: OS Independent
14
+ Classifier: Programming Language :: Python :: 3
15
+ Classifier: Programming Language :: Python :: 3.8
16
+ Classifier: Programming Language :: Python :: 3.9
17
+ Classifier: Programming Language :: Python :: 3.10
18
+ Classifier: Programming Language :: Python :: 3.11
19
+ Classifier: Programming Language :: Python :: 3.12
20
+ Classifier: Topic :: Multimedia :: Video
21
+ Classifier: Topic :: Multimedia :: Sound/Audio :: Speech
22
+ Classifier: Topic :: Office/Business :: Office Suites
23
+ Requires-Python: >=3.8
24
+ Description-Content-Type: text/markdown
25
+ License-File: LICENSE
26
+ Requires-Dist: multiai-tts
27
+ Requires-Dist: pptxtoimages
28
+ Dynamic: license-file
29
+
30
+ # slidemovie
31
+
32
+ [![PyPI version](https://badge.fury.io/py/slidemovie.svg)](https://badge.fury.io/py/slidemovie)
33
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
34
+ [![Documentation](https://img.shields.io/badge/docs-github.io-blue)](https://sekika.github.io/slidemovie/)
35
+
36
+ **Markdown and PowerPoint to Narration Video Generator.**
37
+
38
+ `slidemovie` is a Python tool that automates the creation of professional narration videos. By combining the structural simplicity of **Markdown**, the design capabilities of **PowerPoint**, and the power of **AI Text-to-Speech**, you can produce high-quality videos without any video editing software.
39
+
40
+ ---
41
+
42
+ ## 📚 Documentation
43
+
44
+ **For full tutorials, installation guides, and configuration details, please visit:**
45
+
46
+ 👉 **[https://sekika.github.io/slidemovie/](https://sekika.github.io/slidemovie/)**
47
+
48
+ ---
49
+
50
+ ## ✨ Features
51
+
52
+ * **Markdown-Based**: Write your slide content and narration script in a single text file.
53
+ * **AI Narration**: Automatically generates natural voiceovers using **Google Gemini** or **OpenAI** (via `multiai-tts`).
54
+ * **PowerPoint Integration**: Use PowerPoint's AI "Designer" to create professional visuals instantly.
55
+ * **No Video Editing**: Audio and visuals are automatically synchronized.
56
+ * **Incremental Builds**: Only regenerates changed slides to save time and API costs.
57
+
58
+ ## 🎥 Demo
59
+
60
+ **Watch a video generated entirely by slidemovie:**
61
+ [https://www.youtube.com/watch?v=9ZscwE06Pbo](https://www.youtube.com/watch?v=9ZscwE06Pbo)
62
+
63
+ ## 🚀 Quick Start
64
+
65
+ ### 1. Install
66
+
67
+ ```bash
68
+ pip install slidemovie
69
+ ```
70
+
71
+ *Note: You also need to install **FFmpeg**, **Pandoc**, **LibreOffice**, and **Poppler**, and set up your **AI API Key** (Google or OpenAI). See the [documentation](https://sekika.github.io/slidemovie/installation.html) for details.*
72
+
73
+ ### 2. Create a Project
74
+
75
+ Create a Markdown file (e.g., `demo.md`):
76
+
77
+ ```markdown
78
+ # Slide Title
79
+
80
+ - Bullet point 1
81
+ - Bullet point 2
82
+
83
+ ::: notes
84
+ This text will be read aloud by the AI narrator.
85
+ :::
86
+ ```
87
+
88
+ ### 3. Generate Slides
89
+
90
+ Convert Markdown to a draft PowerPoint file:
91
+
92
+ ```bash
93
+ slidemovie demo -p
94
+ ```
95
+
96
+ Open `demo.pptx` in PowerPoint, apply a design, and save it.
97
+
98
+ ### 4. Build Video
99
+
100
+ Generate the final video with AI narration:
101
+
102
+ ```bash
103
+ slidemovie demo -v
104
+ ```
105
+
106
+ The output will be saved in `movie/demo/demo.mp4`.
107
+
108
+ ## 📄 License
109
+
110
+ MIT License
@@ -0,0 +1,81 @@
1
+ # slidemovie
2
+
3
+ [![PyPI version](https://badge.fury.io/py/slidemovie.svg)](https://badge.fury.io/py/slidemovie)
4
+ [![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
5
+ [![Documentation](https://img.shields.io/badge/docs-github.io-blue)](https://sekika.github.io/slidemovie/)
6
+
7
+ **Markdown and PowerPoint to Narration Video Generator.**
8
+
9
+ `slidemovie` is a Python tool that automates the creation of professional narration videos. By combining the structural simplicity of **Markdown**, the design capabilities of **PowerPoint**, and the power of **AI Text-to-Speech**, you can produce high-quality videos without any video editing software.
10
+
11
+ ---
12
+
13
+ ## 📚 Documentation
14
+
15
+ **For full tutorials, installation guides, and configuration details, please visit:**
16
+
17
+ 👉 **[https://sekika.github.io/slidemovie/](https://sekika.github.io/slidemovie/)**
18
+
19
+ ---
20
+
21
+ ## ✨ Features
22
+
23
+ * **Markdown-Based**: Write your slide content and narration script in a single text file.
24
+ * **AI Narration**: Automatically generates natural voiceovers using **Google Gemini** or **OpenAI** (via `multiai-tts`).
25
+ * **PowerPoint Integration**: Use PowerPoint's AI "Designer" to create professional visuals instantly.
26
+ * **No Video Editing**: Audio and visuals are automatically synchronized.
27
+ * **Incremental Builds**: Only regenerates changed slides to save time and API costs.
28
+
29
+ ## 🎥 Demo
30
+
31
+ **Watch a video generated entirely by slidemovie:**
32
+ [https://www.youtube.com/watch?v=9ZscwE06Pbo](https://www.youtube.com/watch?v=9ZscwE06Pbo)
33
+
34
+ ## 🚀 Quick Start
35
+
36
+ ### 1. Install
37
+
38
+ ```bash
39
+ pip install slidemovie
40
+ ```
41
+
42
+ *Note: You also need to install **FFmpeg**, **Pandoc**, **LibreOffice**, and **Poppler**, and set up your **AI API Key** (Google or OpenAI). See the [documentation](https://sekika.github.io/slidemovie/installation.html) for details.*
43
+
44
+ ### 2. Create a Project
45
+
46
+ Create a Markdown file (e.g., `demo.md`):
47
+
48
+ ```markdown
49
+ # Slide Title
50
+
51
+ - Bullet point 1
52
+ - Bullet point 2
53
+
54
+ ::: notes
55
+ This text will be read aloud by the AI narrator.
56
+ :::
57
+ ```
58
+
59
+ ### 3. Generate Slides
60
+
61
+ Convert Markdown to a draft PowerPoint file:
62
+
63
+ ```bash
64
+ slidemovie demo -p
65
+ ```
66
+
67
+ Open `demo.pptx` in PowerPoint, apply a design, and save it.
68
+
69
+ ### 4. Build Video
70
+
71
+ Generate the final video with AI narration:
72
+
73
+ ```bash
74
+ slidemovie demo -v
75
+ ```
76
+
77
+ The output will be saved in `movie/demo/demo.mp4`.
78
+
79
+ ## 📄 License
80
+
81
+ MIT License
@@ -0,0 +1,44 @@
1
+ [build-system]
2
+ requires = ["setuptools>=61.0"]
3
+ build-backend = "setuptools.build_meta"
4
+
5
+ [project]
6
+ name = "slidemovie"
7
+ version = "0.1.0"
8
+ description = "Markdown and PowerPoint to narration video generator"
9
+ readme = "README.md"
10
+ requires-python = ">=3.8"
11
+ license = "MIT"
12
+ authors = [
13
+ {name = "Katsutoshi Seki"}
14
+ ]
15
+ keywords = ["powerpoint", "markdown", "video", "tts", "presentation", "automation"]
16
+ classifiers = [
17
+ "Development Status :: 3 - Alpha",
18
+ "Intended Audience :: Developers",
19
+ "Intended Audience :: Education",
20
+ "Operating System :: OS Independent",
21
+ "Programming Language :: Python :: 3",
22
+ "Programming Language :: Python :: 3.8",
23
+ "Programming Language :: Python :: 3.9",
24
+ "Programming Language :: Python :: 3.10",
25
+ "Programming Language :: Python :: 3.11",
26
+ "Programming Language :: Python :: 3.12",
27
+ "Topic :: Multimedia :: Video",
28
+ "Topic :: Multimedia :: Sound/Audio :: Speech",
29
+ "Topic :: Office/Business :: Office Suites",
30
+ ]
31
+ dependencies = [
32
+ "multiai-tts",
33
+ "pptxtoimages"
34
+ ]
35
+
36
+ [project.urls]
37
+ Homepage = "https://sekika.github.io/slidemovie/"
38
+ Source = "https://github.com/sekika/slidemovie"
39
+
40
+ [project.scripts]
41
+ slidemovie = "slidemovie.cli:main"
42
+
43
+ [tool.setuptools]
44
+ packages = ["slidemovie"]
@@ -0,0 +1,4 @@
1
+ [egg_info]
2
+ tag_build =
3
+ tag_date = 0
4
+
@@ -0,0 +1,3 @@
1
+ from setuptools import setup
2
+
3
+ setup()
@@ -0,0 +1,3 @@
1
+ from .core import Movie
2
+
3
+ __all__ = ["Movie"]
@@ -0,0 +1,171 @@
1
+ #!/usr/bin/env python3
2
+ # -*- coding: utf-8 -*-
3
+
4
+ import argparse
5
+ import sys
6
+ import logging
7
+ import slidemovie
8
+
9
+ # Logging configuration
10
+ logging.basicConfig(
11
+ level=logging.INFO,
12
+ format='%(asctime)s [%(levelname)s] %(message)s',
13
+ datefmt='%Y-%m-%d %H:%M:%S'
14
+ )
15
+ logger = logging.getLogger(__name__)
16
+
17
+ def main():
18
+ """
19
+ Entry point for the slidemovie command-line tool.
20
+
21
+ This function parses command-line arguments to control the `slidemovie.Movie` class,
22
+ which generates narration videos from Markdown and PowerPoint files.
23
+
24
+ Workflow:
25
+ 1. Parse arguments (project name, modes, options).
26
+ 2. Initialize the `Movie` class (loads default/config settings).
27
+ 3. Override settings based on CLI arguments (TTS options, debug mode).
28
+ 4. Configure project paths based on structure (flat or subproject).
29
+ 5. Execute the requested action:
30
+ - `--pptx`: Generates a draft PowerPoint from Markdown.
31
+ - `--video`: Generates the full narration video (TTS, images, stitching).
32
+
33
+ Usage:
34
+ slidemovie PROJECT_NAME [--pptx] [--video] [options...]
35
+ """
36
+ parser = argparse.ArgumentParser(
37
+ description="Automated tool to generate narration videos from Markdown and PowerPoint."
38
+ )
39
+
40
+ # --- Positional Arguments ---
41
+ parser.add_argument(
42
+ "project_name",
43
+ help="Project Name (ID). If in subproject mode (--sub), this is the parent project name."
44
+ )
45
+
46
+ # --- Action Control Options ---
47
+ parser.add_argument(
48
+ "-p", "--pptx",
49
+ action="store_true",
50
+ help="Generate PPTX from Markdown (Drafting mode)."
51
+ )
52
+ parser.add_argument(
53
+ "-v", "--video",
54
+ action="store_true",
55
+ help="Generate all video assets from Markdown and PPTX (Build mode)."
56
+ )
57
+
58
+ # --- Path & Project Structure Options ---
59
+ parser.add_argument(
60
+ "-s", "--source-dir",
61
+ default=".",
62
+ help="Directory containing source files (md, pptx). Default is current directory."
63
+ )
64
+ parser.add_argument(
65
+ "--sub",
66
+ metavar="SUB_NAME",
67
+ help="Subproject name (Child folder name). If specified, runs in hierarchical mode."
68
+ )
69
+ parser.add_argument(
70
+ "-o", "--output-root",
71
+ help="Root directory for video output. If not specified, determined automatically."
72
+ )
73
+ parser.add_argument(
74
+ "-f", "--filename",
75
+ help="Output video filename (without extension). Defaults to project ID."
76
+ )
77
+
78
+ # --- TTS Settings Options (CLI Overrides) ---
79
+ parser.add_argument("--tts-provider", help="TTS Provider (e.g., google, openai)")
80
+ parser.add_argument("--tts-model", help="TTS Model name")
81
+ parser.add_argument("--tts-voice", help="TTS Voice/Speaker setting")
82
+ parser.add_argument("--prompt", help="Override TTS system prompt")
83
+
84
+ # --- Other Options ---
85
+ parser.add_argument(
86
+ "--debug",
87
+ action="store_true",
88
+ help="Enable debug mode (Verbose logging, etc)."
89
+ )
90
+
91
+ args = parser.parse_args()
92
+
93
+ # Exit if no action is specified
94
+ if not args.pptx and not args.video:
95
+ parser.print_help()
96
+ sys.exit(1)
97
+
98
+ # 1. Initialize Movie instance (Load configuration files)
99
+ try:
100
+ movie = slidemovie.Movie()
101
+ except NameError:
102
+ logger.error("Movie class is not defined. Make sure to import it correctly.")
103
+ sys.exit(1)
104
+ except Exception as e:
105
+ logger.error(f"Failed to initialize Movie class: {e}")
106
+ sys.exit(1)
107
+
108
+ # 2. Override settings with CLI options
109
+ if args.tts_provider:
110
+ movie.tts_provider = args.tts_provider
111
+ if args.tts_model:
112
+ movie.tts_model = args.tts_model
113
+ if args.tts_voice:
114
+ movie.tts_voice = args.tts_voice
115
+ if args.prompt:
116
+ movie.prompt = args.prompt
117
+
118
+ if args.debug:
119
+ movie.ffmpeg_loglevel = 'info'
120
+ movie.show_skip = True
121
+ logger.setLevel(logging.DEBUG)
122
+ logger.info("Debug mode enabled.")
123
+
124
+ # 3. Configure Path Settings
125
+ try:
126
+ if args.sub:
127
+ # Hierarchical Mode (Parent/Child)
128
+ logger.info(f"Configuring subproject paths: {args.project_name}/{args.sub}")
129
+ movie.configure_subproject_paths(
130
+ parent_project_name=args.project_name,
131
+ subproject_name=args.sub,
132
+ source_parent_dir=args.source_dir,
133
+ output_root_dir=args.output_root,
134
+ output_filename=args.filename
135
+ )
136
+ else:
137
+ # Standard Mode (Flat)
138
+ logger.info(f"Configuring project paths: {args.project_name}")
139
+ movie.configure_project_paths(
140
+ project_name=args.project_name,
141
+ source_dir=args.source_dir,
142
+ output_root_dir=args.output_root,
143
+ output_filename=args.filename
144
+ )
145
+ except Exception as e:
146
+ logger.error(f"Failed to configure paths: {e}")
147
+ sys.exit(1)
148
+
149
+ # 4. Execute Actions
150
+
151
+ # Generate PPTX (--pptx)
152
+ if args.pptx:
153
+ logger.info("=" * 60)
154
+ logger.info("MODE: Build Slide PPTX")
155
+ logger.info("=" * 60)
156
+ movie.build_slide_pptx()
157
+ logger.info("PPTX generation process finished.")
158
+ if not args.video:
159
+ logger.info("Please edit the generated PPTX file and run with --video to create the movie.")
160
+
161
+ # Generate Video (--video)
162
+ if args.video:
163
+ logger.info("=" * 60)
164
+ logger.info("MODE: Build All Video Assets")
165
+ logger.info("=" * 60)
166
+ movie.build_all()
167
+
168
+ logger.info("All video processes finished.")
169
+
170
+ if __name__ == "__main__":
171
+ main()