{
  "schemaVersion": 1,
  "batchId": "pseo-batch2-20261014",
  "blueprintId": "blueprint-28",
  "kind": "recipe",
  "slug": "cjk-subtitle-font-and-burnin-check",
  "locale": "zh",
  "evidenceClass": "local-media-run",
  "sourcePath": "content/pseo/batch2-20261014/recipes/cjk-subtitle-font-and-burnin-check.json",
  "sourceHash": "0608da8625c4c6e159d200f6f4a672ba380857c30f5a8e0d26f1e64951ba3272",
  "contentHash": "4b0447ca3814952e9a56c0fcc8fc82cdf50caf12f745e0fdd0f21a26c699ceaf",
  "contentVersion": "authored-4b0447ca3814952e9a56c0fc",
  "rendererHash": "727572c29f88632162b30bf97d95dc1be416eb61ca002023ad1c1b1410d29fbd",
  "copy": {
    "title": "CJK 字幕安全烧录：字体缺字、UTF-8 预检与解码帧验收",
    "description": "用合法且固定版本的 Noto CJK 字体、无依赖 cmap 检查器与真实 FFmpeg/libass 烧录，完成原创 3.6 秒字幕练习。附四张解码帧与 29 项已执行检查，把缺字检查和文字/地区字形正确性分开。",
    "goal": "交付带字幕的视频前，区分四类失败：字幕字节错误、字体没有目标码点、渲染器选了其他字体，以及画面文字不符合预期。本配方提供真实本地执行样例，没有测试 MiniMax 模型。",
    "preparation": [
      "将原创 SRT、Node 脚本、未修改 Noto Sans CJK SC Regular OTF 与 OFL/版权声明下载到同一目录。再分发字体时保留其独立许可。",
      "准备 Node.js 24 和已有带 libass/libx264 的 FFmpeg 6.0；配方不安装或再分发 FFmpeg。本次实际使用 Node v24.14.0、libass 0.17.0 和字体 2.004。",
      "选择新的本地输出目录。样例为静音、1280×720、3.6 秒短片；该脚本不是完整视频交付导出器。",
      "先读懂四条预期字幕。SC 字体有非零码点映射，不等于采用日语、韩语或繁体中文场景偏好的地区字形。"
    ],
    "steps": [
      {
        "title": "01. 保留准确字体，先核对字幕文本",
        "body": "NotoSansCJKsc-Regular.otf 必须和 OFL.txt、FONT-COPYRIGHT.txt 一起保存。官方 Sans2.004 未修改字体通过 SHA-256 与字体族名固定。先以 UTF-8 打开 sample.srt，对照四条正文和时间范围，再开始渲染。解析器明确拒绝标记、重叠字幕和变体序列，不猜未知编码，也不会悄悄改写字幕。 SRT 起止必须按 10 毫秒对齐，因为 ASS 使用厘秒精度；更细的数值会被拒绝，不直接取整。",
        "commands": [
          "node --version",
          "node run-preflight-tests.mjs"
        ]
      },
      {
        "title": "02. 将码点覆盖当作一项预检",
        "body": "subtitle-check.mjs 读取字体 Unicode cmap format 4/12，检查非零且在范围内的字形 ID。本例 43 个不重复非空白码点均有映射。22 项实跑场景包括已知缺字、字体缺失/修改、错误 UTF-8/UTF-16、重叠、危险路径和参数边界。覆盖不是整形或排版证明：错误的地区字形或难读布局，仍可能有有效映射。"
      },
      {
        "title": "03. 用固定滤镜文件名实际烧录",
        "body": "传入 FFmpeg 绝对路径和新输出目录。脚本生成原创几何测试片，把支持的纯文本 SRT 转成固定样式 ASS，再使用 libass 烧录。用户路径先复制成临时目录里的常量文件名，不直接拼进滤镜表达式。子进程使用 shell:false，编码/滤镜各一个线程，日志有上限，单进程限时一分钟。本次 macOS 字体提供者为 CoreText；日志确认加载配套字体并选中其 PostScript 字体名，但不宣称完全隔离系统字体。",
        "commands": [
          "node run-recipe.mjs --ffmpeg /absolute/path/to/ffmpeg --out ./fresh-output",
          "node run-recipe.mjs --ffmpeg /absolute/path/to/ffmpeg --out ./another-fresh-output --input ./sample-source.mp4 --srt ./sample.srt --font ./NotoSansCJKsc-Regular.otf"
        ]
      },
      {
        "title": "04. 解码后读回文字，再保存执行回执",
        "body": "逐一对照 keyframe-01 至 keyframe-04 与预期的中英、简体/繁体、日语/韩语字幕。脚本实际解码 PNG，并和无字幕源片比较字幕区域像素；这种变化不证明字形身份。还需查看真实字体选择日志和覆盖报告。回执包含 7 项媒体断言、22 项预检、文件尺寸/哈希和真实工具版本。本次记录了有限目视读回，地区排版与其他字幕仍需独立审核。"
      }
    ],
    "acceptance": [
      "sample.srt 严格按 UTF-8 解码，字幕时间有序、有效、不重叠，22 项预检通过。",
      "配套字体字节与固定 SHA-256 一致，再分发时保留 OFL 许可和版权声明。",
      "本例 43 个非空白码点均有有效非零字形 ID，不因此推导全 Unicode 或地区字形覆盖。",
      "真实 FFmpeg 烧录完成，日志记录选中的配套 Noto 字体；缺字诊断或无法确认字体选择时失败。",
      "四张指定时刻关键帧均实际解码，且字幕区域相较源片有测量得到的像素变化。",
      "目视核对预期文字、方框缺字、裁切和标点；PNG 非空或像素变化不能单独完成验收。",
      "回执标识实际版本与输出哈希，明确没有运行生产/提供商任务，区分本地字幕渲染和生成质量证据。"
    ],
    "troubleshooting": [
      {
        "symptom": "还没渲染，文本已经出现替换符。",
        "change": "从源文件明确导出 UTF-8，再跑预检；不要只改编码标签而保留未知字节。"
      },
      {
        "symptom": "覆盖报告发现某个 U+ 码点缺字。",
        "change": "找到准确码点，选择合法且覆盖它的字体，重新核对族名、哈希、渲染和画面。不接受未记录的系统回退。"
      },
      {
        "symptom": "字体有字形，但与目标语言习惯不符。",
        "change": "把默认码点覆盖与地区 CJK 字形分开；选择对应语言版本，并由熟悉该语言排版的人核对。SC 样例不证明地区字形正确。"
      },
      {
        "symptom": "渲染成功退出，但看不到字幕或被裁切。",
        "change": "查看实际时间范围、字体选择诊断和解码帧。适配真实短片前，先核对 1280×720、3.6 秒示例限制与字幕位置。"
      },
      {
        "symptom": "命令被路径、字体或已有输出检查拒绝。",
        "change": "使用新的受控目录、原配字体、普通本地文件和 FFmpeg 绝对路径。脚本拒绝覆盖、软链接、穿越和网络输入。"
      },
      {
        "symptom": "样例正常，但完整交付会丢掉音频或 3.6 秒之后内容。",
        "change": "不要原样用示例脚本交付完整视频。另行验证导出命令中的时长、音频映射、尺寸与字幕安全区域。"
      },
      {
        "symptom": "201–209 毫秒的字幕在转换前被拒绝。",
        "change": "使用按 10 毫秒对齐且时长为正的起止。示例不对毫秒边界直接取整，避免两端都折叠成 ASS 的 0.20 秒。"
      }
    ],
    "ending": "将源字幕、准确字体/许可、渲染日志、四张解码帧与执行回执一起保存。配套哈希只标识本次本地运行，不同平台/构建可能改变输出字节。没有宣称模型生成、生产计费或搜索流量结果。",
    "assetCaption": "原创几何短片与中英/CJK 字幕；未修改 OFL 字体；真实 FFmpeg 烧录、四张解码 PNG、覆盖/命令日志和 29 项执行证据。",
    "prompt": ""
  },
  "assets": [],
  "artifacts": [
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/run-recipe.mjs",
      "label": {
        "en": "Run the bounded FFmpeg burn-in",
        "zh": "运行有上限的 FFmpeg 字幕烧录"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/subtitle-check.mjs",
      "label": {
        "en": "UTF-8/SRT and cmap preflight module",
        "zh": "UTF-8/SRT 与 cmap 预检模块"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/run-preflight-tests.mjs",
      "label": {
        "en": "22 executed preflight scenarios",
        "zh": "22 项已执行预检场景"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/NotoSansCJKsc-Regular.otf",
      "label": {
        "en": "Pinned unmodified Noto CJK SC font (16.44 MB)",
        "zh": "固定未修改 Noto CJK SC 字体（16.44 MB）"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/OFL.txt",
      "label": {
        "en": "Original SIL OFL 1.1 font license",
        "zh": "原始 SIL OFL 1.1 字体许可"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/FONT-COPYRIGHT.txt",
      "label": {
        "en": "Font copyright notice",
        "zh": "字体版权声明"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/LICENSE-original-assets.txt",
      "label": {
        "en": "Original asset and sample-script reuse terms",
        "zh": "原创素材与示例脚本使用条款"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/sample.srt",
      "label": {
        "en": "Original four-cue UTF-8 subtitle file",
        "zh": "原创四条 UTF-8 字幕"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/sample.ass",
      "label": {
        "en": "Actual fixed-style ASS used in this run",
        "zh": "本次实跑使用的固定样式 ASS"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/sample-source.mp4",
      "label": {
        "en": "Original 3.6-second geometric source slate",
        "zh": "原创 3.6 秒几何源测试片"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/subtitle-burned.mp4",
      "label": {
        "en": "Actual subtitle burn-in sample",
        "zh": "实际烧录字幕的样例"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/keyframe-01.png",
      "label": {
        "en": "Decoded bilingual keyframe at 0.6s",
        "zh": "0.6 秒中英混排解码帧"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/keyframe-02.png",
      "label": {
        "en": "Decoded Simplified Chinese keyframe at 1.4s",
        "zh": "1.4 秒简体中文解码帧"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/keyframe-03.png",
      "label": {
        "en": "Decoded Traditional Chinese keyframe at 2.2s",
        "zh": "2.2 秒繁体中文解码帧"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/keyframe-04.png",
      "label": {
        "en": "Decoded Japanese/Korean keyframe at 3.0s",
        "zh": "3.0 秒日语/韩语解码帧"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/coverage-report.json",
      "label": {
        "en": "Actual per-codepoint glyph mapping report",
        "zh": "实际逐码点字形映射报告"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/command-log.json",
      "label": {
        "en": "Executed FFmpeg argument log",
        "zh": "已执行 FFmpeg 参数日志"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/ffmpeg-log.txt",
      "label": {
        "en": "Actual renderer and font-selection log",
        "zh": "实际渲染与字体选择日志"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/execution-receipt.json",
      "label": {
        "en": "Actual media execution and SHA-256 receipt",
        "zh": "实际媒体执行与 SHA-256 回执"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/preflight-test-receipt.json",
      "label": {
        "en": "Actual negative/positive preflight receipt",
        "zh": "实际正负向预检回执"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/visual-review.json",
      "label": {
        "en": "Limited four-frame visual readback",
        "zh": "四帧有限目视读回记录"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/sources.json",
      "label": {
        "en": "Pinned official font/license source evidence",
        "zh": "固定官方字体/许可来源证据"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/README.en.md",
      "label": {
        "en": "English runnable command and review guide",
        "zh": "英文运行命令与检查说明"
      }
    },
    {
      "path": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/README.zh.md",
      "label": {
        "en": "Chinese runnable command and review guide",
        "zh": "中文运行命令与检查说明"
      }
    }
  ],
  "execution": {
    "nodeVersion": "v24.14.0",
    "ffmpegVersion": "ffmpeg version 6.0 Copyright (c) 2000-2023 the FFmpeg developers",
    "fontVersion": "Version 2.004;hotconv 1.0.118;makeotfexe 2.5.65603",
    "command": "node run-recipe.mjs --ffmpeg /absolute/path/to/ffmpeg --out ./fresh-output",
    "receiptPath": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/execution-receipt.json",
    "passedScenarios": [
      "strict-UTF8-SRT-preflight",
      "pinned-font-cmap-coverage",
      "bounded-actual-libass-burnin",
      "font-selection-observed",
      "four-keyframes-decoded",
      "four-subtitle-band-pixel-differences",
      "media-and-frame-output-hashes",
      "valid-four-cue-UTF8-and-CJK-cmap",
      "known-missing-codepoint-detected",
      "invalid-UTF8-rejected",
      "UTF16-BOM-rejected",
      "NUL-control-rejected",
      "timestamp-minute-range-rejected",
      "non-centisecond-SRT-boundaries-rejected",
      "collapsed-ASS-range-rejected",
      "overlapping-cues-rejected",
      "ASS-and-HTML-markup-refused",
      "variation-sequence-refused",
      "truncated-font-refused",
      "CLI-option-value-boundary",
      "CLI-duplicate-options-refused",
      "missing-font-file-refused",
      "font-symlink-refused",
      "input-path-traversal-refused",
      "network-input-refused",
      "output-path-traversal-refused",
      "missing-glyph-stops-before-FFmpeg",
      "pinned-font-hash-drift-refused",
      "special-filename-is-data-not-shell"
    ],
    "productionTaskRun": false,
    "providerModelTest": false,
    "fontProviderObserved": "coretext",
    "preflightReceiptPath": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/preflight-test-receipt.json"
  },
  "hero": {
    "imagePath": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/keyframe-04.png",
    "videoPath": "/learning-assets/pseo-batch2-20261014/cjk-subtitle-font-and-burnin-check/subtitle-burned.mp4",
    "label": {
      "en": "Actual local subtitle render; no provider/model generation",
      "zh": "实际本地字幕渲染；未进行提供商/模型生成"
    }
  },
  "sources": [
    {
      "title": "Noto CJK official Sans2.004 license",
      "url": "https://github.com/notofonts/noto-cjk/blob/523d033d6cb47f4a80c58a35753646f5c3608a78/LICENSE"
    },
    {
      "title": "Noto CJK official language/font download guide",
      "url": "https://github.com/notofonts/noto-cjk/blob/523d033d6cb47f4a80c58a35753646f5c3608a78/Sans/README.md"
    },
    {
      "title": "FFmpeg official subtitle and ASS filter documentation",
      "url": "https://ffmpeg.org/ffmpeg-filters.html#subtitles-1"
    },
    {
      "title": "OpenType official cmap specification",
      "url": "https://learn.microsoft.com/en-us/typography/opentype/spec/cmap"
    }
  ],
  "shots": [],
  "demonstration": null
}
