Respect an explicit user choice. Otherwise:
- A person-containing video explicitly or provisionally resolved as the likeness
source: continue the video-to-avatar creation flow. Do not enter the generic avatar
picker and do not ask the user to choose among saved or official identities.
- No ready saved avatar: show at most five suitable official avatars and include the
reserved create card in the same choice surface. This is a strict empty-state
contract: never render a sixth official recommendation, and never omit the
creation option merely because official avatars are available.
- Ready saved avatars exist: show them first (up to five total cards), then the
reserved create card.
- Exactly one ready saved avatar: offer it first and ask whether to use it.
- Multiple ready saved avatars: prefer higher live usage count; when counts tie, prefer
the newest creation. If usage metadata is absent, rank by newest creation only;
never invent a frequency.
In embedded ChatCut, avatar identity selection is media-preview-only and is a strict exception to the generic
single-branch
rule. Always use visual cards through the Widget Forms
Skill, including when exactly one ready saved avatar exists. Never ask a text-only
category question such as "use the saved avatar" versus "browse official avatars",
and never use
,
, or label-only identity cards for avatar
selection. For an avatar card in ChatCut's native widget — official or the user's own
saved avatar — write only its exact
as
; the host resolves the
current name, preview video or fallback image, aspect ratio, and submitted value from the live avatar
identity even when the tool payload does not expose a preview URL. Never copy
,
,
, or
onto an
option. If the host cannot
resolve preview media, omit that identity rather than falling back to text. Prefer
the live preview video when available and use the preview image only as its poster
or fallback. When
the user has ready saved avatars, place their cards before official recommendations.
Ask one most important missing question at a time and do not repeat answered questions.
The raw tags and visual-card requirements below describe embedded ChatCut only. In Antigravity, the
host adapter takes priority: use concise text choices with stable
values mapped internally to returned names and descriptions, and direct the user to ChatCut's Digital Humans library for previews. Never emit raw ChatCut tags or promise chat avatar video. Preserve the separate
value; it returns to this workflow for a conversation attachment plus
, rather than automatically opening a native dialog. This adapter changes presentation only; identity readiness, required inputs and consent checks remain mandatory.
For a saved identity whose
row has no preview URLs, call
for that exact candidate before rendering it; use the selected ready
revision's returned preview media and do not invent or copy media from another avatar.
One reserved label-only option value opens a native editor surface instead of
submitting an answer. Write it with no
:
- — opens the native creation dialog where the user uploads a photo
and creates a personal avatar. Keep its card label a short "create your own
avatar" phrase (e.g. 创建专属数字人); do not mention uploading a photo — the
dialog explains that itself.
Clicking that card does not produce a form answer. When the user finishes in the
native dialog, their chosen or newly created avatar is sent back automatically as
this question's answer with the avatar attached; treat that reply as the avatar
selection and do not re-ask.
The selection shape is therefore one
containing up to five avatar
preview cards (saved first, then official) followed by the creation card. Localize
the visible question and card label to the conversation language:
text
<widget>
<form-visual id="avatar" question="Please choose an avatar" required="true">
<visual-option avatar-id="<saved-or-official-identity-id>"/>
<visual-option value="create_avatar" name="Create your own avatar"/>
</form-visual>
</widget>
Creating an identity is separate from generating a video:
- Resolve the source or prompt and name.
- Obtain required consent.
- Create the identity through .
- Wait until it is ready or terminal. Where offers
, call with the and do what its
result says; otherwise re-read it with
manage_avatar action=get refresh=true
in a later turn.
- Save it under My avatars. Do not auto-generate a video merely because avatar
creation succeeded.
When asking for a portrait in an embedded ChatCut Widget, always mark the upload as an avatar source so
the host uses the same validation, JPEG normalization, private transport storage, and
upload-readiness behavior as the native Digital Humans dialog:
text
<widget>
<form-files id="avatar_source" label="Please upload a portrait photo"
accept="image/jpeg,image/png" purpose="avatar-source"
multiple="false" required="true"/>
<form-text id="avatar_name" label="Name this avatar" required="true"/>
</widget>
Do not use an unmarked generic
upload for avatar creation.
Published plugin forms do not provide this native upload control. Ask the user to
attach the portrait through their host, then use the Asset Import Skill and pass the
returned ChatCut image asset id to
.
尊重用户的明确选择。否则:
- 明确或暂定将包含人物的视频解析为外貌来源:继续执行视频转 avatar 的创建流程。不要进入通用 avatar 选择器,也不要询问用户选择已保存或官方身份。
- 没有就绪的已保存 avatar:最多展示五个合适的官方 avatar,并在同一选择界面中加入保留的创建卡片。这是严格的空状态契约:绝不能展示第六个官方推荐,也绝不能因为存在官方 avatar 就省略创建选项。
- 存在就绪的已保存 avatar:先展示这些 avatar(总计最多五张卡片),然后展示创建卡片。
- 恰好有一个就绪的已保存 avatar:首先提供该 avatar,并询问是否使用它。
- 存在多个就绪的已保存 avatar:优先选择实时使用次数较高的;次数相同时,优先选择创建时间最新的。如果缺少使用次数元数据,则仅按创建时间由新到旧排序;绝不虚构使用频率。
在嵌入式 ChatCut 中,avatar 身份选择仅用于媒体预览,是通用单分支
规则的严格例外。始终通过 Widget Forms Skill 使用可视化卡片,即使恰好只有一个就绪的已保存 avatar 也应如此。不要询问“使用已保存的 avatar”还是“浏览官方 avatar”这类纯文本分类问题,也不要使用
、
或仅含标签的身份卡片来选择 avatar。对于 ChatCut 原生组件中的 avatar 卡片——无论是官方 avatar 还是用户自己的已保存 avatar——只将其确切
写入
;即使工具载荷未公开预览 URL,宿主也会从实时 avatar 身份中解析当前名称、预览视频或回退图像、宽高比和提交值。不要将
、
、
或
复制到
选项上。如果宿主无法解析预览媒体,应省略该身份,而不是回退为文本。存在实时预览视频时应优先使用,预览图像只能作为封面或回退图像。当用户拥有就绪的已保存 avatar 时,应将其卡片放在官方推荐之前。每次只询问一个最重要的缺失问题,不要重复询问已经回答的问题。
以下原始标签和可视化卡片要求仅适用于嵌入式 ChatCut。在 Antigravity 中,
宿主适配器具有优先权:使用简洁的文本选项,并将稳定的
值在内部映射到返回的名称和描述,同时引导用户前往 ChatCut 的 Digital Humans 库查看预览。不要输出原始 ChatCut 标签,也不要承诺提供聊天内 avatar 视频。保留独立的
值;它会通过对话附件加
返回此工作流,而不是自动打开原生对话框。该适配器仅改变呈现方式;身份就绪状态、必需输入和授权检查仍然必须执行。
对于
行中没有预览 URL 的已保存身份,在渲染前对该确切候选项调用
。使用所选就绪版本返回的预览媒体,不要虚构或复制其他 avatar 的媒体。
一个保留的仅标签选项值会打开原生编辑界面,而不是提交答案。写入时不要附带
:
- ——打开原生创建对话框,用户可在其中上传照片并创建个人 avatar。卡片标签应保持为简短的“创建专属数字人”之类的短语;不要提及上传照片,对话框本身会进行说明。
点击该卡片不会产生表单答案。当用户在原生对话框中完成操作时,其选择或新建的 avatar 会自动作为本问题的答案回传,并附带 avatar;将该回复视为 avatar 选择,不要再次询问。
因此,选择结构为一个
,其中最多包含五张 avatar 预览卡片(先显示已保存的 avatar,再显示官方 avatar),最后是创建卡片。将可见问题和卡片标签本地化为对话语言:
text
<widget>
<form-visual id="avatar" question="Please choose an avatar" required="true">
<visual-option avatar-id="<saved-or-official-identity-id>"/>
<visual-option value="create_avatar" name="Create your own avatar"/>
</form-visual>
</widget>
创建身份与生成视频是两个独立过程:
- 解析来源或提示词以及名称。
- 取得所需授权。
- 通过 创建身份。
- 等待其进入就绪或终态。如果 支持 ,则使用 调用 ,并按照其结果执行;否则在后续轮次中使用
manage_avatar action=get refresh=true
重新读取。
- 将其保存在 My avatars 下。不要仅因 avatar 创建成功就自动生成视频。
在嵌入式 ChatCut Widget 中要求用户提供人像照片时,始终将上传项标记为 avatar 来源,使宿主采用与原生 Digital Humans 对话框相同的验证、JPEG 标准化、私密传输存储和上传就绪行为:
text
<widget>
<form-files id="avatar_source" label="Please upload a portrait photo"
accept="image/jpeg,image/png" purpose="avatar-source"
multiple="false" required="true"/>
<form-text id="avatar_name" label="Name this avatar" required="true"/>
</widget>
不要将未标记的通用
上传控件用于创建 avatar。已发布的插件表单不提供此原生上传控件。请用户通过宿主附加人像照片,然后使用 Asset Import Skill,并将返回的 ChatCut 图像资产 ID 传给
。