scenario-caption-studio

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Scenario Caption Studio

Scenario 字幕工作室

Overview

概述

Caption Studio is one tool model,
model_scenario-caption-studio
: a video in, its speech transcribed (Whisper) or an existing SRT applied, styled captions out, burned into the picture or delivered as a soft track and an
.srt
sidecar. It translates into 18 languages and styles captions three ways. Running that one member is this skill's whole purpose, so the id is named rather than discovered and
model_schema_get
starts the flow directly; availability differs per team, so a member the team lacks is a gap to flag, not a cue to substitute. Connection and the core loop: see the
scenario
skill.
Captioning is the last pass on a finished cut: assemble first (
scenario-video-assembly
), then caption the master once. Captions carry the transcript only; text that must appear letter-perfect without being spoken (CTAs, prices, legal supers) is
scenario-text-overlay
territory. If a sibling skill named here is missing from your available skills, ask the user to install it (
npx skills add scenario-labs/skills --skill <name>
); unattended, proceed from tool schemas and flag the gap.
字幕工作室(Caption Studio)是一个工具模型
model_scenario-caption-studio
:输入视频后,可通过Whisper转录语音或应用现有SRT文件,输出带样式的字幕,支持烧录到画面中,或以软字幕轨加
.srt
外挂文件的形式交付。它支持18种语言翻译,提供三种字幕样式设置方式。运行这一个模型成员就是本技能的全部用途,因此其ID是指定的而非自动发现的,可直接通过
model_schema_get
启动流程;不同团队的可用成员存在差异,因此如果团队缺少某个成员,需要标记该缺口,而不是自行替换。连接方式与核心循环:参见
scenario
技能。
字幕制作是成片的最后一步:先完成剪辑组装(
scenario-video-assembly
),再给母版加一次字幕。字幕仅包含转录内容;那些无需语音但必须完全准确显示的文本(CTA、价格、法律声明字幕)属于
scenario-text-overlay
的功能范围。如果你的可用技能中缺少这里提到的关联技能,请让用户安装(命令:
npx skills add scenario-labs/skills --skill <name>
);在无人值守模式下,可基于工具Schema继续流程,并标记该缺口。

Ask once, then caption

先确认需求,再制作字幕

The destination decides nearly every parameter, so collect one round of answers before touching the schema: where the video ships (a sound-off mobile feed, a paid placement, a seated long-form viewer), whether the spoken language stays or translates (
targetLanguage
,
auto
keeps it), brand colors if any, and which deliverable the platform wants. The deliverable is three switches: burned-in pixels are
outputSubtitles: "video_image"
(the default), the toggleable track is
"video_data"
, the sidecar file is
outputSrt: true
, and an SRT-only pass is that plus
outputVideo: false
, the first pass when the words must be letter-perfect: it priced the same as a burn-in at authoring time, so it buys certainty rather than savings, proving the words before any pixels are paid for. Then map the answers:
DestinationStyleSegmentationPositionOutput
Social mobile short (9:16 Shorts, Reels)
tiktok-bouncy
or
word-pop
;
karaoke-fill
when music drives
maxSegmentWords
3 to 5; 1 with a karaoke preset
middle
: platform UI and native auto-captions own the bottom
Burn in
Ad short, performance cut
modern-chip
or
minimal-underline
, accents set to brand color
3 to 7 words per cue
bottom
, or
top
when an end card or overlay sits below
Burn in for sound-off feeds; add
outputSrt
for the platform's caption upload
YouTube long-form, tutorial, interviewDefault look or
cinematic-fade
; restraint reads as professionalism
maxLines
2,
maxSegmentChars
84 (two 42-character lines, the broadcast convention)
bottom
outputSrt
for the platform's closed captions; burn in only for re-embeds
Cinematic piece, trailer, festival cut
cinematic-fade
Sentence-length cues,
maxSegmentDuration
about 6
bottom
Burn in
Rows are authoring-time starting points to confirm with the user, not platform contracts; unattended, the task's own instructions answer the interview and the matching row's defaults fill what they leave unsaid. The per-placement safe zones behind the position column live in
scenario-formats
.
middle
renders at frame center, which on a centered talking head is the mouth: caption a selfie cut only once its face sits in the upper third (reframe in assembly), because the schema offers no lower-third position. An uploaded track beats burn-in for long-form because viewers toggle and restyle it, assistive tech reads it, and platforms index it for search; burn-in wins wherever the style is the point or a track cannot travel with the file.
发布平台几乎决定了所有参数,因此在接触Schema之前先收集一轮信息:视频的发布渠道(静音移动信息流、付费投放、面向久坐观众的长视频)、语音语言是否需要翻译(
targetLanguage
,设为
auto
则保留原语言)、品牌色(如有),以及平台要求的交付形式。
交付形式由三个开关控制:烧录到画面的字幕对应
outputSubtitles: "video_image"
(默认值),可切换的软字幕轨对应
"video_data"
,外挂字幕文件对应
outputSrt: true
;如果只需要生成SRT文件,可在此基础上加
outputVideo: false
——当字幕文字必须完全准确时,这是第一步:在创作阶段,仅生成SRT的成本和烧录字幕相同,因此它是用来确保准确性而非节省成本的,可以在支付渲染费用前先确认文字内容。
然后将收集到的答案映射到参数中:
发布场景样式分段规则位置输出形式
移动端社交短视频(9:16 比例的 Shorts、Reels)
tiktok-bouncy
或
word-pop
;音乐驱动的内容用
karaoke-fill
maxSegmentWords
设为3到5;使用卡拉OK预设时设为1
middle
(中间):平台UI和原生自动字幕占据底部区域
烧录字幕
短视频广告、效果类剪辑
modern-chip
或
minimal-underline
,强调色设为品牌色
每个字幕提示3到7个词
bottom
(底部),如果底部有片尾卡或叠加层则设为
top
(顶部)
静音信息流用烧录字幕;额外开启
outputSrt
用于平台字幕上传
YouTube 长视频、教程、访谈默认样式或
cinematic-fade
;克制的风格更显专业
maxLines
设为2,
maxSegmentChars
设为84(两行各42字符,广播行业标准)
bottom
(底部)
开启
outputSrt
用于平台隐藏字幕;仅在重新嵌入时使用烧录字幕
电影级作品、预告片、影展剪辑
cinematic-fade
句子长度的提示,
maxSegmentDuration
约6秒
bottom
(底部)
烧录字幕
以上行是创作阶段的起始参考,需要与用户确认,并非平台强制要求;在无人值守模式下,由任务本身的指令回答这些问题,未提及的部分则使用对应行的默认值填充。位置列背后的各场景安全区规则存放在
scenario-formats
中。
middle
(中间)位置会渲染在画面中心,对于居中的人物出镜镜头来说就是嘴巴的位置:因此自拍类剪辑只有在人脸位于画面上三分之一时才能加字幕(需在组装阶段重新构图),因为Schema没有提供下三分之一的位置选项。对于长视频,上传软字幕轨优于烧录字幕,因为观众可以切换和调整样式,辅助技术可以读取字幕,平台也能将其纳入搜索索引;而当样式是核心需求或字幕轨无法随文件传播时,烧录字幕是更好的选择。

The style ladder

样式层级

Three tiers:
stylePreset
picks a ready-made look (7 presets, empty for the default);
stylePrompt
describes a look in plain words and builds a matching style (it carries
cost_impact
);
themeTsx
supplies a full custom theme that replaces the preset, with
stylePrompt
then refining that theme. There is no font parameter: type rides inside the tiers, and it is the strongest signal a style sends, so when the type itself must carry the mood or the brand, put the intent into
stylePrompt
in plain words (the weight, the letterform class, the feeling: "heavy condensed sans, high-energy", "light geometric sans, quiet and premium"); an exact brand face is
themeTsx
territory, and
scenario-text-overlay
chooses faces by meaning for the text cards around the captions. Presets also restyle the words themselves: an authoring-time run of
tiktok-bouncy
uppercased every caption, and the other presets are unverified for casing, so when exact casing matters (a product name, "LoRA") steer with
stylePrompt
or
themeTsx
and verify a frame before delivering.
fontColor
sets the body text (contrast beats aesthetics: white body text survives every backdrop the presets put behind it), and
accentColorStart
/
accentColorEnd
drive the highlight animation (karaoke fills, pops): spend the accent on one thing, usually the brand color, with equal values for a solid and different values for a gradient. Auto sizing (
fontSizePx
empty) rendered words about 30 pixels tall on a 1080x1920 frame at authoring time, unreadable on a phone feed: for vertical social set
fontSizePx
explicitly (60 to 90 on a 1920-tall frame is the authoring-time starting point) and judge a frame at phone scale.
outputTsx: true
returns the theme a run used, so a look that landed can be replayed exactly on the next video.
分为三个层级:
stylePreset
选择预设样式(共7种预设,留空则使用默认样式);
stylePrompt
用自然语言描述样式需求并生成匹配的样式(会产生
cost_impact
成本影响);
themeTsx
提供完整的自定义主题以替换预设,之后可通过
stylePrompt
进一步优化该主题。
没有单独的字体参数:字体包含在各个样式层级中,且是样式传递的最强信号,因此当字体本身需要体现氛围或品牌调性时,请将需求用自然语言写入
stylePrompt
(包括字重、字体类别、风格感受:比如"粗体浓缩无衬线,高能量感"、"细体几何无衬线,静谧高级");如果需要使用精确的品牌字体,则属于
themeTsx
的功能范围,而
scenario-text-overlay
会根据含义为字幕周围的文本卡片选择字体。
预设还会调整文字本身的样式:在创作阶段的一次测试中,
tiktok-bouncy
预设会将所有字幕转为大写,其他预设的大小写处理规则尚未验证,因此当大小写必须精确时(比如产品名"LoRA"),请通过
stylePrompt
或
themeTsx
控制,并在交付前验证单帧效果。
fontColor
设置正文文本颜色(对比度比美观更重要:白色正文可以适配所有预设的背景),
accentColorStart
/
accentColorEnd
控制高亮动画(卡拉OK填充、弹出效果):强调色只需用于一处,通常是品牌色,两个值相同则为纯色,不同则为渐变色。
自动字号(
fontSizePx
留空)在创作阶段的1080x1920画面中渲染的文字高度约为30像素,在手机信息流中无法看清:因此对于竖屏社交内容,请明确设置
fontSizePx
(1920像素高的画面中,60到90是创作阶段的起始参考值),并在手机尺寸下验证单帧效果。设置
outputTsx: true
会返回本次运行使用的主题,因此效果满意的样式可以在下一个视频中完全复用。

Getting the words right

确保文字准确

  • transcriptionPrompt
    is a spelling hint, not a style field: list the names, brands, and jargon the audio contains. The hint raises the odds without guaranteeing them (an authoring-time run misspelled a hinted name twice), so check the transcript for every required name before trusting a burn-in, and on a miss retry with
    large-v3
    or a sharper hint.
  • modelSize
    trades accuracy for speed and cost (
    cost_impact
    ): the
    medium
    default is fine for clean voiceover; step up to
    large-v3
    for noisy audio, accents, or dense terminology;
    .en
    variants are English-only.
  • The model transcribes whatever audio the master carries, so balance the music bed against dialogue before captioning (
    scenario-video-assembly
    ), never after.
  • Corrections and restyles ride the
    subtitles
    input, whose contract is inline content, not a reference (authoring-time): pass the SRT text itself, base64-encoded, as the value. An
    asset_...
    id is not dereferenced there; the id string is base64-decoded as if it were content, and the run still reports success, bills, and renders zero captions (
    segment_count: 0
    in the job record is the tell). Reuse is therefore:
    outputSrt: true
    returns the transcript as an asset,
    asset_download
    it, correct spellings locally if needed, and feed the edited text back base64-encoded, which also covers
    upload_asset
    having no text kind (authoring-time fact). The SRT inherits the run's segmentation (a karaoke run returns word-per-cue), so re-chunk it locally before an ads upload or a calmer restyle. Never deliver a
    subtitles
    run on job status alone: sweep the output as the worked example reviews it, and when captions are missing,
    asset_get
    the subtitles asset the job consumed to see what it received. The schema does not say whether segmentation caps re-chunk a supplied SRT, so set segmentation when transcribing and omit the caps alongside
    subtitles
    .
  • transcriptionPrompt
    是拼写提示,而非样式字段:列出音频中包含的人名、品牌名和专业术语。该提示可以提高准确率但无法完全保证(创作阶段的一次测试中,即使加了提示,某个名字仍被拼错了两次),因此在烧录字幕前,请检查转录本中所有要求的名称,如果出错,可使用
    large-v3
    模型或更精确的提示重试。
  • modelSize
    在准确率、速度和成本之间权衡(会产生
    cost_impact
    ):默认的
    medium
    模型适用于清晰的旁白;如果音频有噪音、有口音或术语密集,则升级到
    large-v3
    ;
    .en
    变体仅支持英语。
  • 模型会转录母版中的所有音频,因此请在加字幕前(通过
    scenario-video-assembly
    )调整好背景音乐与人声的平衡,不要事后再调。
  • 修正和样式调整通过
    subtitles
    输入完成,其约定是接收内联内容而非引用(创作阶段规则):请将SRT文本本身进行base64编码后作为值传入。
    asset_...
    类型的ID不会在此处被解析;ID字符串会被当作内容直接进行base64解码,此时运行仍会报告成功、计费,但不会渲染任何字幕(作业记录中的
    segment_count: 0
    就是判断依据)。因此复用流程是:设置
    outputSrt: true
    将转录本作为资产返回,通过
    asset_download
    下载,如需修正拼写可在本地修改,再将编辑后的文本进行base64编码后传回——这也解决了
    upload_asset
    不支持文本类型的问题(创作阶段的实际限制)。生成的SRT会继承本次运行的分段规则(卡拉OK模式会返回每个词一个提示),因此在上传广告平台或进行更简洁的样式调整前,需要在本地重新分段。永远不要仅根据作业状态就交付
    subtitles
    运行的结果:请像示例中那样检查输出内容,如果发现字幕缺失,可通过
    asset_get
    获取作业使用的字幕资产,查看实际接收到的内容。Schema并未说明分段限制是否会对传入的SRT重新分段,因此请在转录时设置好分段规则,在使用
    subtitles
    输入时省略分段限制参数。

Worked example: a vertical social short, then a Spanish variant

实操示例:竖屏社交短视频,及西班牙语版本

  1. asset_get
    the assembled master: confirm duration and that it is the finished cut, since the price tracks the footage (
    video
    carries
    cost_impact
    ; trim first,
    scenario-video-editing
    ).
  2. model_schema_get
    on
    model_scenario-caption-studio
    .
  3. Price it:
    model_run
    with
    dry_run: true
    and
    parameters={"video": "<asset_id>", "stylePreset": "tiktok-bouncy", "maxSegmentWords": 4, "textPosition": "middle", "transcriptionPrompt": "Scenario, LoRA, Flux", "outputSrt": true}
    . Re-estimate after changing
    targetLanguage
    ,
    modelSize
    ,
    stylePrompt
    , or
    outputSubtitles
    : all carry
    cost_impact
    .
  4. Run it with
    wait: false
    , then
    jobs_wait
    with the
    job_id
    ; on timeout re-call with the returned
    pending_job_ids
    , never
    job_get
    in a loop.
  5. Review before deriving, since a successful job proves nothing about what rendered: download the SRT sidecar with
    asset_download
    (no
    format
    : it converts images only; a run that returns both video and SRT lists the two asset ids in no fixed order, and
    asset_get
    tells them apart by
    mimeType
    ) and check its text for every name the
    transcriptionPrompt
    carries; then download the video and sweep it into contact sheets (
    ffmpeg -vf "fps=2"
    ), reading the burned captions for spelling, casing, and placement, because a defect that appears mid-cue survives a spot check. Pop presets reveal words within a cue, so also sample the last frames of each cue: a flash under 100 ms survives an
    fps=2
    sweep.
  6. Spanish variant: add
    targetLanguage: "es"
    to the same parameters,
    transcriptionPrompt
    included, and
    dry_run
    again (it moves the price) before running. Translation happens inside the run, so one master yields a variant per market. Latin-script segmentation caps do not transfer to Chinese, Japanese, or Korean (streaming style guides run them at a third of the characters per line), so revisit
    maxSegmentChars
    per target language.
  7. File the master, variants, and SRT assets in a collection (
    scenario
    skill) so the delivery set stays findable.
  1. 通过
    asset_get
    获取组装好的母版:确认时长以及它是最终剪辑版本,因为费用是按素材时长计算的(
    video
    参数会产生
    cost_impact
    ;如需裁剪请先通过
    scenario-video-editing
    完成)。
  2. 对
    model_scenario-caption-studio
    调用
    model_schema_get
    。
  3. 预估费用:使用
    dry_run: true
    调用
    model_run
    ,参数为
    parameters={"video": "<asset_id>", "stylePreset": "tiktok-bouncy", "maxSegmentWords": 4, "textPosition": "middle", "transcriptionPrompt": "Scenario, LoRA, Flux", "outputSrt": true}
    。修改
    targetLanguage
    、
    modelSize
    、
    stylePrompt
    或
    outputSubtitles
    后需要重新预估:这些参数都会产生
    cost_impact
    。
  4. 使用
    wait: false
    启动运行,然后用
    job_id
    调用
    jobs_wait
    ;如果超时,使用返回的
    pending_job_ids
    重新调用,永远不要循环调用
    job_get
    。
  5. 在生成变体前先检查效果,因为作业成功并不代表渲染内容正确:通过
    asset_download
    下载SRT外挂文件(不要加
    format
    参数:该参数仅用于转换图片;同时返回视频和SRT的运行中,两个资产ID的顺序不固定,可通过
    asset_get
    的
    mimeType
    区分),检查文本中是否包含
    transcriptionPrompt
    里的所有名称;然后下载视频,用联系表(contact sheet)快速检查(命令:
    ffmpeg -vf "fps=2"
    ),查看烧录字幕的拼写、大小写和位置,因为抽查可能会漏掉字幕中间出现的问题。弹出类预设会在一个提示内逐词显示,因此还需要采样每个提示的最后一帧:100毫秒以下的闪现内容在
    fps=2
    的检查中可能会被漏掉。
  6. 西班牙语版本:在相同参数中添加
    targetLanguage: "es"
    (保留
    transcriptionPrompt
    ),运行前再次执行
    dry_run
    (费用会变化)。翻译在运行过程中完成,因此一个母版可以生成多个市场的变体。拉丁字母的分段限制不适用于中文、日文或韩文(流媒体风格指南中,这些语言的每行字符数约为拉丁字母的三分之一),因此需要根据目标语言重新调整
    maxSegmentChars
    。
  7. 将母版、变体和SRT资产归档到一个集合中(
    scenario
    技能),方便后续查找交付内容。

Common mistakes

常见错误

  • Captioning each clip before assembly: caption the finished master once, or cues drift across cuts and every edit orphans its captions.
  • Expecting the preset look on the soft track:
    video_data
    renders as plain text the viewer toggles; styling survives only when burned in.
  • Styling legal lines or CTAs as captions: disclosures carry locked wording, size, and dwell time that caption logic would re-chunk and retime, and a toggleable track fails "visible without viewer action" rules outright; exact unspoken text is a
    scenario-text-overlay
    card composited in assembly.
  • Setting
    maxSegmentWords: 1
    without a karaoke or pop preset: one-word cues flash as a slideshow unless the style animates them. With a pop preset (the ones that reveal words inside a cue:
    tiktok-bouncy
    ,
    word-pop
    , and the karaoke pair at authoring time), never end a cue on a one-letter word: pop-in timing follows character count, so a trailing "I" or "a" showed for about 70 ms at authoring time. Re-chunking a supplied SRT means owning its timings too: a supplied SRT carries cue times only, so a pop preset spreads its words evenly across each cue and the highlight drifts from the voice wherever a cue outlasts the speech; keep each cue's end on the spoken span, and extend only the last cue to the clip's end.
  • Treating a
    jobs_wait
    timeout as failure: re-call with
    pending_job_ids
    ; video tool jobs outlast the wait window routinely.
  • 在组装前给每个片段加字幕:应该只给最终母版加一次字幕,否则剪辑后字幕时间轴会偏移,每次编辑都会导致字幕失效。
  • 期望软字幕轨保留预设样式:
    video_data
    模式下渲染为纯文本,由观众自行切换;样式只有在烧录时才会保留。
  • 将法律声明或CTA当作字幕设置:披露类内容有固定的措辞、字号和停留时间,字幕逻辑会重新分段和调整时间,而且可切换的字幕轨完全不符合"无需观众操作即可见"的规则;精确的非语音文本应该用
    scenario-text-overlay
    卡片在组装阶段合成。
  • 没有使用卡拉OK或弹出预设时设置
    maxSegmentWords: 1
    :如果没有样式动画,单字提示会像幻灯片一样闪烁。使用弹出类预设时(创作阶段指的是在一个提示内逐词显示的预设:
    tiktok-bouncy
    、
    word-pop
    以及两个卡拉OK预设),永远不要让单个字母的单词出现在提示末尾:弹出动画的时长是按字符数计算的,因此末尾的"I"或"a"在创作阶段的显示时间只有约70毫秒。对传入的SRT重新分段也意味着需要负责时间轴:传入的SRT只包含提示时间,因此弹出预设会将单词均匀分布在每个提示的时长内,如果提示时长超过语音长度,高亮效果就会和语音不同步;请让每个提示的结束时间对齐语音结束位置,仅将最后一个提示延长到视频结尾。
  • 将
    jobs_wait
    超时视为失败:请使用
    pending_job_ids
    重新调用;视频工具作业的运行时间经常超过等待窗口。