開始使用

安裝 Mografy。

四行指令,或給 Claude Code、Codex 一段提示詞。Mografy 和它的 Skill 都裝進同一個工作區資料夾,播放器隨即開啟。

用 Agent 安裝

程式代理可以幫你完成全部設定。在想放 Mografy 的資料夾(例如桌面)打開 Claude Code 或 Codex,貼上下面的提示詞。

安裝 Mografy
Install Mografy in a new folder and open its player. Mografy is an open-source tool for making motion graphics with coding agents. It installs from npm into one folder, not globally; do not clone the GitHub repository and do not run npm install -g. Documentation: https://www.mografy.app/docs/getting-started Source: https://github.com/mografy/mografy First check the computer before installing anything: operating system, Node.js version (22.12 or later is required), npm, and free disk space. Tell me what is missing and how you plan to install it. Then install it: 1. In the current folder, run npx mografy@latest init. It creates a mografy workspace folder with projects/ (my films), showcase/ (showcase films), examples/ (reference films) and templates/ (Mografy Templates, empty until I add one), installs Mografy and its extras (3D, music, Stage and the other helpers) into it (package.json and node_modules). It does not create a project and does not install the Mografy Skill. If npm reports a permission error, stop and tell me instead of using sudo. 2. Run cd mografy. 3. Run npx skills add mografy/mografy in the mografy folder, without -g, so the Mografy Skill is installed in this workspace for Claude Code (.claude/skills/mografy) and Codex (.agents/skills/mografy). If it asks which agents, choose Claude Code and Codex. Do not skip this step: the guides for Mografy and its extras are in the Skill. 4. Run npx mografy dev and give me the local address. The player opens on the empty workspace (projects, showcase, examples, templates and the built-in components on the left); new films are created in projects/ when I ask for one. Do not install FFmpeg or Chromium: the first video export downloads FFmpeg into the folder, and Chrome or Edge renders checks and exports (a small Chromium downloads only when neither is installed). If a step fails, read the error, fix the cause and try again; do not skip steps. When you are done, tell me that everything lives in the mografy folder (deleting it removes Mografy), that I should open Claude Code or Codex in that folder to make animations, how to start Mografy again (npx mografy dev in that folder), how to update (npx mografy@latest init in that folder, and npx skills update for the Skill), and suggest a first animation I could ask for.
  1. 先檢查 Node.js 22.12 以上版本、npm 和剩餘磁碟空間,並告訴你缺了什麼。
  2. 接著執行 npx mografy@latest init,建立一個 mografy 工作區資料夾,裡面裝好 Mografy、它的 extras,以及 projects、showcase、examples 和 templates 資料夾。
  3. 接著執行 npx skills add mografy/mografy ,在那個資料夾裡為 Claude Code 和 Codex 安裝 Mografy Skill。
  4. 接著執行 npx mografy dev (在那個資料夾裡)。播放器打開,就代表 Mografy 裝好了。

不裝到全域。 不用 npm install -g、不改 PATH、不用 Git。所有東西都在 mografy 資料夾裡,刪掉資料夾就移除乾淨。有步驟失敗的話,把錯誤訊息貼回給代理。

手動安裝

喜歡用終端機?先安裝 Node.js 22.12 以上,再執行:

終端機
npx mografy@latest init
cd mografy
npx skills add mografy/mografy
npx mografy dev

npx mografy@latest init 會在目前的資料夾建立 mografy 工作區,把 Mografy 和它的 extras 裝進去(package.json 和 node_modules)。它不會建立專案:播放器打開的是空的工作區,左側列出各個資料夾和 16 個內建元件。

npx skills add mografy/mografy 會在工作區裡安裝 Mografy Skill,給 Claude Code(.claude/skills/mografy)以及 Codex 和其他 Agent(.agents/skills/mografy)使用。請不要略過:3D、音樂、Stage 這些 extras 的使用說明都在 Skill 裡。只有想讓每個資料夾都能用 Skill 時,才加上 -g。 npx mografy dev 會打開播放器;npm run dev 也一樣。

想用別的資料夾名稱? npx mografy@latest init my-studio 就會改建立 my-studio。

資料夾裡有什麼

mografy 資料夾是一個工作區:

資料夾
mografy/
  projects/      你的影片,一部一個資料夾(內建元件在 projects/.components)
  showcase/      作品展示的影片: npx mografy add showcase/ <film>
  examples/      參考影片: npx mografy add examples/ <film>
  templates/     所有模板,init 已經放好: npx mografy add <template> projects/<film>
  .claude/  .agents/   Mografy Skill(npx skills add mografy/mografy)
  node_modules/  Mografy 本體和 extras
  mografy.workspace.json

在這個資料夾(或它裡面的任何資料夾)執行的 npx mografy 指令都會用這個工作區:新影片放進 projects/,Showcase 影片下載到 showcase/(npx mografy add showcase/ <影片>)。參考影片和所有模板會隨 init 放進 examples/ 和 templates/,已經安裝好了。要用模板開新影片:npx mografy add <模板> projects/<影片>。在這裡啟動的 MCP 伺服器也會用這個工作區。

用舊版安裝的? 那個資料夾是單一專案,不是工作區,照常可以用。想要這些資料夾的話,在它旁邊執行 npx mografy@latest init,再把專案搬進新的 projects 資料夾。

做第一支動畫

讓播放器開著,在 mografy 資料夾裡打開 Claude Code 或 Codex,告訴它你想要什麼:訊息、長度、格式和風格。資料夾裡的 Skill 讓 Claude 和 Codex 用同一套流程做分鏡、場景程式、逐格檢查和匯出。

看起來對了,就按播放器的 匯出 按鈕,或請 Agent 幫你匯出。格式與預設說明請看 匯出.

Agent 會把每部影片建成 projects/ 裡的一個專案。想自己開一個,在 mografy 資料夾裡執行這行,它會建立 projects/my-film:

終端機
npx mografy init my-film

更新 Mografy

請代理幫你更新 Mografy,或在 mografy 資料夾裡執行:

終端機
npx mografy@latest init
npx skills update

第一行把工作區的 Mografy 和 extras 更新到最新版,第二行更新 Skill;你的專案、展示影片、範例和模板都不會變。先停掉正在執行的播放器,再用 npx mografy dev 重新啟動,然後 重新整理瀏覽器 即可載入新版介面。

FFmpeg 和 Chromium

兩個都不用自己裝。檢查和匯出會用電腦上現有的 Chrome 或 Edge 算圖。第一次匯出影片時,FFmpeg 會下載到 mografy 資料夾並使用這份,不會用 PATH 上的;只有在沒有 Chrome 或 Edge 時,才會用同樣方式下載一個小型 Chromium。

要離線工作?在資料夾裡執行 npx mografy setup 先下載好。3D、音樂、Stage 等輔助工具、所有模板和參考影片都已隨 Mografy 安裝,離線也能用;Showcase 影片會在第一次 npx mografy add 需要時才下載。

選用:全域安裝

只有在你想讓電腦上每個資料夾都能用 mografy 指令和 Skill 時才需要。上面的步驟不需要這一步。

終端機
npm install -g mografy
npx skills add mografy/mografy -g