papercut-setup
Compare original and translation side by side
🇺🇸
Original
English🇨🇳
Translation
ChinesePapercut setup
Papercut 设置
A guided wrapper around . It checks what is installed, asks how much the user wants, runs the installer non-interactively and reports. Use it whenever another papercut skill finds something missing.
install.shinstall.shPreflight
预检查
- Find the repo root (where lives):
install.shon the installed skill folder ends inreadlink. Look in each harness's skills folder in turn (the table is<root>/skills/papercut-setup; typicallyharnesses.sh,~/.claude/skills,~/.agents/skills, or the same under~/.config/opencode/skills). Failing that,<project>/inPAPERCUT_HOME=. If neither exists, the skills probably came from${XDG_CONFIG_HOME:-~/.config}/papercut-explainer/config.env(skills only, no library). Ask where to clone the repo (defaultnpx skills add), run~/papercut-explainer, and use that as the root. The installer then replaces the copied skill folders with links into the checkout (it backs up real folders first). Never guess a path.git clone https://github.com/0xS4N4TG/papercut-explainer <dir> - Run every command from that root. It needs bash, and macOS or Linux (Windows: use WSL).
install.sh - The installer's own prompts need a terminal, which the agent's shell tool lacks. Always pass and the answers as flags. Tell the user they can run
--yesthemselves for the interactive menu../install.sh
- 找到仓库根目录(其中包含 ):已安装 skill 文件夹上的
install.sh结果应以readlink结尾。依次检查每个 harness 的 skills 文件夹(对应列表在<root>/skills/papercut-setup中;通常为harnesses.sh、~/.claude/skills、~/.agents/skills,或~/.config/opencode/skills下的对应目录)。如果仍找不到,则在<project>/中查找${XDG_CONFIG_HOME:-~/.config}/papercut-explainer/config.env。如果两者都不存在,skills 很可能来自PAPERCUT_HOME=(仅包含 skills,不含 library)。询问用户要把仓库克隆到哪个位置(默认npx skills add),运行~/papercut-explainer,并将该目录用作 root。安装程序随后会把复制来的 skill 文件夹替换为指向 checkout 的链接(替换前会备份真实文件夹)。绝不猜测路径。git clone https://github.com/0xS4N4TG/papercut-explainer <dir> - 所有 命令都必须从该 root 运行。安装程序需要 bash,并支持 macOS 或 Linux(Windows:使用 WSL)。
install.sh - 安装程序自身的交互式提示需要终端,而 Agent 的 shell 工具没有终端。始终传入 ,并将答案作为标志传递。告知用户可以自行运行
--yes使用交互式菜单。./install.sh
1. Doctor
1. Doctor(诊断)
./install.sh --doctorAdd , or if the skills went somewhere other than the detected defaults; the doctor only looks where you point it, and with no one complete install location is enough. It prints , (missing) or (wrong). Summarise it in plain words:
--project DIR--skills-dir DIR--target <names>--target[ok][--][!!]- skills installed, config file and
PAPERCUT_LIB - node 20+, npm, ffmpeg, python3
- Remotion agent skills, Python tools (numpy + Pillow)
- voice: importable, a CustomVoice model in the Hugging Face cache
qwen_tts - library files present
Then say which install mode that adds up to (see , Install modes).
papercut-explainer./install.sh --doctor如果 skills 被安装到了检测到的默认位置之外,添加 、 或 ;doctor 只检查你指定的目录,不带 时,一个完整的安装位置就足够了。它会打印 、(缺失)或 (错误)。用通俗语言总结:
--project DIR--skills-dir DIR--target <names>--target[ok][--][!!]- 已安装的 skills、配置文件及
PAPERCUT_LIB - node 20+、npm、ffmpeg、python3
- Remotion agent skills、Python 工具(numpy + Pillow)
- 语音:可导入,Hugging Face 缓存中有 CustomVoice 模型
qwen_tts - library 文件已存在
然后说明这些项目对应哪种安装模式(参见 papercut-explainer 的“安装模式”)。
2. Ask
2. Ask(询问)
Ask only what is still open, in one call (your agent's question tool, for example AskUserQuestion in Claude Code). Run first if you need to know which harnesses it detected (, the default):
./install.sh --dry-run --mode minimal --yes--target auto| Question | Options |
|---|---|
| How much? | Minimal: skills only, seconds. Standard: render with a placeholder voice, ~0.7 GB and a few minutes. Full: Standard + local voiceover, +4-6 GB (a 1.5 GB venv plus a 2.3 or 4.2 GB model) and a 2-minute smoke test. Custom: pick components. |
| Which agents? | Detected on this machine (default, |
| Where do the skills go? | User-wide (the default) or one project ( |
| Copy or link? | Symlink (default, updates with |
Scene-agent model, per agent with file subagents ( | One question per selected agent, each with Inherit (use the session model) as an option. Claude Code: Sonnet (default: cheapest, what the scene agents were tuned on) · Opus (strongest; every parallel scene agent bills at Opus rates) · Haiku · Inherit. Maps to |
| Another provider's model (DeepSeek and others)? | Only if the user asks. Connect the provider inside the agent first (OpenCode |
| TTS model size (Full) | 1.7B, better prosody, ~4.2 GB (default). 0.6B, lighter and faster, ~2.3 GB. |
| Voice-clone model (Full) | No (default), or |
Confirm before any multi-GB download. On a machine with no GPU (not Apple Silicon, no NVIDIA), TTS generation takes minutes per line; suggest recording the voiceover or the placeholder voice instead.
只询问尚未确定的事项,并在一次调用中完成(例如使用 Agent 的 question 工具,如 Claude Code 中的 AskUserQuestion)。如果需要知道检测到了哪些 harness(,默认值),先运行 :
--target auto./install.sh --dry-run --mode minimal --yes| 问题 | 选项 |
|---|---|
| 安装多少? | Minimal:仅安装 skills,数秒。Standard:使用 placeholder voice 渲染,约 0.7 GB,需要数分钟。Full:Standard + 本地 voiceover,额外需要 4-6 GB(1.5 GB venv,加上 2.3 或 4.2 GB 模型),并进行一次 2 分钟的 smoke test。Custom:自行选择组件。 |
| 使用哪些 Agent? | 本机检测到的 Agent(默认, |
| Skills 放在哪里? | 用户级目录(默认)或单个项目( |
| 复制还是链接? | Symlink(默认,可随 |
Scene-agent 模型(仅针对支持 file subagents 的 Agent,即 | 每个选中的 Agent 单独询问一次,选项均包含 Inherit(使用 session model)。Claude Code:Sonnet(默认;成本最低,也是 scene agents 的调优目标)· Opus(能力最强;每个并行 scene agent 都按 Opus 费率计费)· Haiku · Inherit。对应 |
| 另一个 provider 的模型(DeepSeek 等)? | 仅在用户提出要求时询问。首先在 Agent 内连接 provider(OpenCode |
| TTS 模型大小(Full) | 1.7B,韵律效果更好,约 4.2 GB(默认)。0.6B,更轻量、更快速,约 2.3 GB。 |
| Voice-clone 模型(Full) | 不使用(默认),或传入 |
在下载任何数 GB 的内容之前先确认。如果机器没有 GPU(既不是 Apple Silicon,也没有 NVIDIA),TTS 每行生成需要数分钟;建议录制 voiceover 或改用 placeholder voice。
3. Install
3. Install(安装)
./install.sh --mode <minimal|standard|full> --yes [--target auto|all|claude,codex,...] [--claude-model M] [--opencode-model M] [--agent-model NAME=M] [--skills-dir DIR | --project DIR] [--copy] [--tts-model 1.7B|0.6B] [--with-clone]
./install.sh --mode custom --components skills,deps,remotion-skills,pytools,tts,verify --yes- Add first if the user wants to see the plan; it changes nothing.
--dry-run - The scene-builder agent is written as a copy per harness, in that harness's own format (Claude and OpenCode markdown, Codex TOML, Gemini markdown), with the chosen model line or none for Inherit. Harnesses without file subagents get none; then builds scenes itself or uses the harness's own parallel tasks. Skills stay symlinks. To change a model later:
papercut-build(or./install.sh --mode custom --components skills --target codex --agent-model codex=<id> --yes,--claude-model).--opencode-model - Standard and Full take minutes (npm install, Remotion's Chrome, venvs, model download). Run them in the background and check the output; do not hold a foreground call.
- What each mode does: Minimal links the skills and the scene-builder agent (into each selected harness's skills and agents folders). Standard adds a dependency check, the Remotion agent skills (once per selected harness, installed user-wide, so say so when you confirm the plan), a Python venv with numpy, Pillow and soundfile, and a self-test render. Full adds
npx skills add remotion-dev/skills -g -y -a <harness id>: a voice venv with Qwen3-TTS, an ASR backend (mlx-whisper on Apple Silicon, faster-whisper elsewhere), the model download and a one-line smoke test.library/voice/setup_tts.sh - The installer writes ,
PAPERCUT_HOME,PAPERCUT_LIB,PAPERCUT_PYandQWEN_TTS_PYintoASR_PY. An existing skill folder that differs from this checkout is backed up to~/.config/papercut-explainer/config.env(not into the skills folder, so it is not loaded twice); an identical copy, such as one from~/.config/papercut-explainer/backups/, is just replaced.npx skills add
./install.sh --mode <minimal|standard|full> --yes [--target auto|all|claude,codex,...] [--claude-model M] [--opencode-model M] [--agent-model NAME=M] [--skills-dir DIR | --project DIR] [--copy] [--tts-model 1.7B|0.6B] [--with-clone]
./install.sh --mode custom --components skills,deps,remotion-skills,pytools,tts,verify --yes- 如果用户希望先查看计划,先添加 ;它不会更改任何内容。
--dry-run - scene-builder Agent 会按 harness 分别写入一份副本,采用该 harness 自己的格式(Claude 和 OpenCode 使用 markdown,Codex 使用 TOML,Gemini 使用 markdown),并写入所选 model;如果选择 Inherit,则不写 model 行。不支持 file subagents 的 harness 不会获得该 Agent;此时 会自行构建场景,或使用 harness 自身的并行任务。Skills 保持为 symlink。以后更换 model:运行
papercut-build(或使用./install.sh --mode custom --components skills --target codex --agent-model codex=<id> --yes、--claude-model)。--opencode-model - Standard 和 Full 需要数分钟(npm install、Remotion 的 Chrome、venv、模型下载)。应在后台运行并检查输出;不要让调用一直占用前台。
- 各模式具体执行的内容:Minimal 将 skills 和 scene-builder Agent 链接到每个所选 harness 的 skills 与 agents 文件夹。Standard 增加依赖项检查、Remotion agent skills(每个所选 harness 执行一次 ,安装在用户级目录,因此确认计划时应说明这一点)、包含 numpy、Pillow 和 soundfile 的 Python venv,以及一次自测渲染。Full 增加
npx skills add remotion-dev/skills -g -y -a <harness id>:一个包含 Qwen3-TTS 的 voice venv、一个 ASR backend(Apple Silicon 上使用 mlx-whisper,其他平台使用 faster-whisper)、模型下载,以及一次单行 smoke test。library/voice/setup_tts.sh - 安装程序会将 、
PAPERCUT_HOME、PAPERCUT_LIB、PAPERCUT_PY和QWEN_TTS_PY写入ASR_PY。如果现有 skill 文件夹与此 checkout 不同,会将其备份到~/.config/papercut-explainer/config.env(不会放进 skills 文件夹,以免被加载两次);如果副本完全相同(例如来自~/.config/papercut-explainer/backups/),则直接替换。npx skills add
4. Verify and report
4. Verify and report(验证并报告)
Run again with the same , or . Report what is installed, which scene-agent model each agent got, what failed (the installer prints with component names), and the fix. A new Claude Code, Codex or Gemini CLI session picks up newly linked skills (restart it); opencode reloads configuration automatically. Then suggest: "make a papercut explainer about <link>", or one stage at a time ("write a hook for...", "storyboard this script", "set up the voice").
./install.sh --doctor--project--skills-dir--targetneeds attention:使用相同的 、 或 再次运行 。报告已安装的内容、每个 Agent 获得了哪个 scene-agent model、哪些项目失败(安装程序会打印 及组件名称)以及相应的修复方法。Claude Code、Codex 或 Gemini CLI 的新会话会加载新链接的 skills(需重启);opencode 会自动重新加载配置。随后建议:“为一个关于 <link> 的主题制作 papercut explainer”,或者一次完成一个阶段(“为……编写 hook”、“为这个脚本制作 storyboard”、“设置语音”)。
--project--skills-dir--target./install.sh --doctorneeds attention:Troubleshooting
故障排除
| Symptom | Fix |
|---|---|
| Install Node 20+ (nodejs.org, |
| |
| Voice venv: "need Python 3.10-3.12" | Qwen3-TTS has no wheels for newer Python. Install |
| Hugging Face download stalls or fails | Rerun; finished files are kept and the script retries 3 times. It sets |
| First render is slow | Remotion downloads its headless Chrome once. The audio render and |
| Self-test fails | Run |
| Skills don't show | Restart Claude Code, Codex or Gemini CLI (opencode reloads). Check the harness's folder ( |
| opencode: "Configuration is invalid ... tools" | An old copy of the Claude agent file sits in an opencode agents folder. Rerun |
| Scene agents cost too much, or run on the wrong model | Rerun the skills step with another model: |
| Move from Minimal to Standard | |
| Add the voice later | |
| Remove it | |
| Windows | Not supported directly. Use WSL. |
| 症状 | 修复方法 |
|---|---|
| 安装 Node 20+(nodejs.org、 |
缺少 | 运行 |
Voice venv: | Qwen3-TTS 没有适用于较新 Python 的 wheel。安装 |
| Hugging Face 下载停滞或失败 | 重新运行;已完成的文件会保留,脚本会重试 3 次。它会设置 |
| 首次渲染较慢 | Remotion 首次会下载 headless Chrome。音频渲染和 |
| 自测失败 | 直接运行 |
| Skills 未显示 | 重启 Claude Code、Codex 或 Gemini CLI(opencode 会自动重新加载)。检查 harness 的文件夹( |
opencode: | opencode 的 agents 文件夹中残留了 Claude agent 文件的旧副本。重新运行 |
| Scene agents 成本过高或使用了错误的 model | 使用另一个 model 重新运行 skills 步骤: |
| 从 Minimal 升级到 Standard | |
| 以后再添加语音 | |
| 卸载 | |
| Windows | 不直接支持。请使用 WSL。 |
Hand-off
交接
Return to the skill that sent you here, or to for the stage table. Files hold the state: carries the library path, so the other skills resolve it without asking again.
papercut-explainerconfig.env返回调用此 skill 的 skill,或返回 papercut-explainer 查看阶段表。文件会保存状态: 记录 library 路径,因此其他 skills 无需再次询问即可解析该路径。
config.env