SuperAPI AI Directory

scene-ppt

Office & productivity

View repository

Updated 10-16 19:42

About this skill

Scene explainer PPT (scene-ppt)

"Make it into a PPT" = one 16:9 image per page, not a .pptx file. The text on the image cannot be edited afterward.

This skill comes with its own image generation script and the style cards you'll need; no need to install other skills. Below, S refers to this skill's script directory:

S=<本 SKILL.md 所在目录>/scripts

Core: change the world, not the skin

The whole PPT uses onlyone worldto tell it through: characters in the world = the objects to explain, objects in the world = concepts. For example, explaining Skill:

World Who AI is What Prompt is What Skill is
Back kitchen The new apprentice The head chef's one-breath verbal instructions A recipe book + compartmentalized prep rack
Chinese herbal medicine shop The new young assistant Dumping all the herbs into one pot at once A prescription + a hundred-drawer cabinet

Once the world is set, each page's scene grows naturally out of this world (front desk, back kitchen, prep room, tasting…), and the pages are naturally different from one another. See reference/lessons.md。

Default world (check first every time you start)

python3 $S/settings.py get world(printing a world ID = there is a default;printing a blank line = not set yet)。

World IDs:classroom small classroom,kitchen back kitchen,rpg RPG skill book,island pixel island,retro 50s retro ad,pharmacy Chinese herbal medicine shop,captain captain's checklist,bricks building block instructions,studio film set,library forest library,pitstop racing pit stop (details in reference/worlds.md). If the user directly names a world, there's no need to open the selection page; directly set world。

Situation What to do
There is a default Tell the user "This time we'll use the default world: X, say so if you want to change it", and go straight ahead
None (first time using) First python3 $S/doctor.py self-check; then python3 $S/world_picker.py <任务目录>/世界选择.html open the world selection page, the user looks at the samples and picks one → python3 $S/settings.py set world <世界ID>
"Change the default world" Reopen the selection page, and after choosing set world
"Use RPG this time" Just this once, don't change the setting; at outline.md the top write "World this time: rpg"
The choice is small classroom (classroom) You need the user's character:settings.py get-character(on first use it will report "no character", which is normal). If there is none, import-character ~/.comic-maker/characters/<ID>(if comic small classroom has been used), or use the IP image the user provides add-character(fields see "Character profile fields" below), if there's no IP first generate one with comic small classroom

The world library is in reference/worlds.md(mappings, scenes, art style, carriers, author reviews, samples). Data is stored in ~/.scene-ppt/, upgrading the skill will not overwrite it; when the home directory is not writable (Codex sandbox), it is automatically saved to the current project's .scene-ppt/, and will be read automatically when used in this project later; you can also specify it with the environment variable SCENE_PPT_HOME .

When several conditions overlap: if the user names a world → do not open the selection page; in fast mode → skip the outline sign-off; if the user only wants a few pages → those pages are all there is, deliver as soon as they are done; the first-use attempt to confirm only waits for the user in confirm mode.

Character profile fields (only needed for the mini-classroom world)

Field How to write it Where it is used Example
Character ID Lowercase English Folder name tuantuan
--ref Character image, png / jpg / webp are all fine, preferably a single character, front-facing, clean background, no text in the image; it will be converted to ref.png automatically used as a base image when generating images 团团.png
--name Chinese name Scene description, dialogue Tuantuan
--desc-cn Chinese appearance phrase,without the name, can be directly followed by the name When the protagonist first appears on each page, write "<desc_cn>" a lesser panda wearing round-framed glasses and a beige knit vest
--name-en / --species-en / --desc-en English name, species, English appearance (shared with the comic mini-classroom; this skill does not use it directly, just write it according to the image) Comic mini-classroom Tuantuan / Red Panda / red panda with cream face markings, round glasses…
--series Series name 4–6 characters Cover series name wooden sign Tuantuan Mini-Classroom

After writing, show it to the user once(name, appearance, series name), and once the user confirms it, then add-character。

Division of labor

  • Current assistant (Claude or Codex): read the materials, write the mapping and outline according to the default world, design the scene for each page, decide every word on the image, and check the image page by page.
  • Codex built-in imagegen: only generates images exactly according to the prompt, without rewriting.

Process

Step What to do Output
1 Read the materials Extract the concepts to be explained (usually 6–15; if the materials are very short, just count however many they naturally have, do not force a split), and label each with a type: contrast / process / layered structure / misuse counterexample / version iteration / essential conclusion; use only the original text for numbers and facts Concept list
2 Mapping + outline (the user signs off once) Write the mapping table according to the default world (the examples in the world library are all about AI, so rethink them according to this round of materials; if a metaphor would distort the original concept, raise it); then write the outline according to templates/outline.md : cover → table of contents (can be omitted if within 6 pages) / chapters → content pages → ending, and for each page write the page type, a one-sentence scene, and a text list;do not use the same scene structure twice in a row. Show both to the user together outline.md
3 Write each page According to templates/page-example.txt(Chinese herbal medicine shop example) andthe current world's examples/<世界>/(if any), write adapt/<图号>-<风格>.txt(image number two digits 01、02..., the style is the number in the world card, such as 03-N50.txt; the file must have two sections, [Visuals and Layout] and [Text That Must Be Placed Verbatim (Single Source of Truth)], following the example): the first sentence covers aspect ratio, title carrier, main scene (state the subject's proportion of the frame), what carrier the text is placed on, character appearance; the text list verbatim adapt/*.txt
4 Generate images the command below.First use or just switched worlds: first generate the cover + 1 content page for the user to see, and wait for the user to say it's okaythen generate the whole set out/、发布/、review.html
5 Check Look at the images page by page (see "Pre-delivery Check"); if there is a problem, change only one place and regenerate 发布/01.png…

Quick mode (the user says "just do it" or "you decide"): skip the sign-off in step 2 and generate the images directly.

Image generation command

python3 $S/check_prompts.py <任务目录>                       # 检查:「」只留给要画的字、写了主体占比
python3 $S/render_codex.py <任务目录> --only 01-             # 第一次 / 换世界:先出封面(--only 按文件名开头匹配,可用逗号:--only 01-,03- 同时出封面和第 3 页)
python3 $S/render_codex.py <任务目录> --batch 6 --parallel 4  # 出剩下的 + 核对 Codex 收到的提示词是否逐字
python3 $S/make_page.py <任务目录> --title "标题"             # 对比页(出图后会自动生成;想改标题再跑这条)
  • The style block comes from this skill's styles/(the world card says which one to use).
  • Classroom world (N49): when --ref is not provided, automatically use the default character's reference image; without a character it will error.
  • If you change a page's adapt/, just rerun render_codex.py: for pages whose prompt changed, the old image is automatically moved to _v1/ and regenerated.
  • After each generation, automatically rebuild 发布/: place all already-generated pages in the order of the whole set, with the filename number = which page it is (page 3 is 03.png; pages not yet generated leave the number blank).
  • By default, use the model configured in your own Codex (--model / --effort can specify).
  • Run this skill yourself in Codex: do not call render_codex.py(it would start another Codex). Run check_prompts.py、build_prompts.py, for prompts/ call the built-in imagegen for each file (prompt = the full text as is; classroom world referenced_image_paths = character ref.png absolute path, do not pass num_last_images_to_include), save as out/<同名>.png, then run verify_log.py and make_page.py(make_page.py will also tidy up 发布/). After calling imagegen, do not print the entire tool return (it contains very long image data); take only the save path, copy it to out/ , then look at the image.

How to write each page (iron rules)

  1. First sentence:16:9 横版,一页讲课演示文稿(封面 / 对比页 / 流程页…)。
  2. Title carrier must be uniform across the whole set(all on the upper-left wooden sign / all on the top ribbon / all on the plaque); only then does page-turning feel like one set.
  3. Each page has 1 title + 2-9 pieces of short text; title <= 20 characters, each piece <= 22 characters.
  4. Place text on carriers native to the world (recipe card, rice-paper slip, checklist clipboard, buoy label), not floating in the air.
  5. Use neutral words for character names (the names before "" in the text list): left card, middle slip, right slip, top strip;do not use ordinal words(first cell, note one, step one, error one). In the image description, do not write "write card A"; directly write "write the sentence 'such-and-such'" or "write the left card". Numbers and hierarchical words (level one, upper layer) will be drawn on.
  6. Write the subject's proportion of the frame ("about seventy percent in the lower part", "about sixty percent of the image width").
  7. Do not add a single character of effects, numbers, or conclusions not in the original text(if the original text has no score, write "—").
  8. Describe character appearance in detail ("a round, chubby chef, white tall hat, red neckerchief, handlebar mustache") so it stays consistent across pages. Classroom world: the first time the protagonist appears, write "<Chinese appearance><name>" (the character profile's desc_cn + name)。

Pre-delivery check (the current assistant looks at the images page by page; must be done)

The "prompt verbatim" reported by the script only means the prompt received by imagegen was not rewritten,it does not mean the text in the image was drawn correctly。

  • Wrong characters, missing characters; whether character names were drawn on ("Jia Ka", "Level One").
  • Whether the small text the model added on its own goes too far.
  • Whether the subject is too empty, whether the text is cropped, whether there are stitched vertical seams.
  • When reporting, split into two items: prompt verbatim N/N; image text has been looked at, problems listed one by one.
  • If there are problems: change only one place at a time and regenerate, show old and new side by side to the user.

Add a new world

See reference/worlds.md at the end: write in ~/.scene-ppt/worlds/, produce 1–2 trial pages,only after the user says they like it and there is a sample page, go to the selection page。

Table of contents

  • reference/worlds.md: world library;reference/world-samples/: world sample pages
  • reference/page-types.md: page type → scene writing method;reference/lessons.md: tested rules and evidence
  • templates/outline.md outline template,templates/page-example.txt single-page writing method,templates/common.txt general constraints,templates/codex-task.md task template for Codex
  • styles/: usable style cards (N49 mini class, N24 back kitchen, N50 RPG, N42 pixel, N02 retro ad, N78 Chinese style, N03 building blocks, N41 Japanese animation, N11 picture book)
  • examples/: full set of prompts + thumbnails (mini class orange, back kitchen, RPG, Chinese medicine shop)
  • scripts/:doctor.py self-check,settings.py default world and characters,world_picker.py world selection page,render_codex.py image generation,check_prompts.py、build_prompts.py、verify_log.py、make_page.py

Task directory

Create it under the user's project or working directory (if there is no project, create it in the current directory ppt/); the world selection page is also generated in the task directory.

<项目>/ppt/<NN-简述>/
  outline.md  adapt/<图号>-<风格>.txt  (可选)common.txt
  prompts/ out/ logs/      脚本生成
  review.html  发布/01.png…  _v1/(旧图)