VNLEWIKI创作故事,连接世界。
简体中文
VNLE 使用手册

JSON 字段参考

执行和内容

format 和 containerVersion 标识数据容器。execution 包含入口和节点,content 包含文本、译文和内容目录。各表通过 UUID 关联,不要通过显示名称查找。JSON 不支持注释,因此说明放在代码之外,以保证示例仍是有效的 JSON。

// Explanation only — not a JSON file
// execution.entries[entryId].nodeRef -> execution.nodes[nodeId]
// node.text.textRef -> content.texts[textId].sourceMessage
// content.translations[locale][textId].message -> translated segments
// dialogue.continuation.nodeRef -> next node
// end -> stop; never keep advancing

story.json

语言切换和缺失的翻译

将语言与当前节点分开保存。切换语言后,重新解析同一个 textRef:若 locale 对应的译文存在则使用译文,否则使用 sourceMessage。缺少语言表表示该语言没有译文。allowEmpty 支持有意留空的文本。按类型格式化占位符片段,不要直接把 JSON 转成字符串显示。原文指纹用于识别过时的译文,仅凭 workflowStatus 无法判断译文是否仍与原文一致。

以下列出当前故事导出 Schema 中可引用的全部定义,包含所有属性、变体和约束;展开 Schema 也能查看嵌套规则。additionalProperties 为 false 时,不允许额外字段。

JSON Schema · Draft 2020-12

Capability

字段类型/必填含义/规则
Schema · Capability
{
  "type": "string",
  "pattern": "^[a-z][a-z0-9.-]*$",
  "title": "Capability"
}

ContentAsset

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
mediaTypestring · 必填媒体内容的 MIME 类型。
relativePathRelativePath · 必填经过验证的相对资源路径;未经检查不可直接作为文件系统路径使用。
contentHashHash · 必填所引用媒体文件内容的 SHA-256 哈希。
displayNamestring · 必填供人阅读的资源显示名称。
licenseNotestring资源的许可证备注,不表示已经自动完成法律核查。
widthinteger结构与有效值请参阅类型和模式定义。
{"minimum":0,"maximum":2147483647}
heightinteger结构与有效值请参阅类型和模式定义。
{"minimum":0,"maximum":2147483647}
byteSizeinteger结构与有效值请参阅类型和模式定义。
{"minimum":0,"maximum":2147483647}
originalNamestring结构与有效值请参阅类型和模式定义。
Schema · ContentAsset
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "mediaType": {
      "type": "string"
    },
    "relativePath": {
      "$ref": "#/$defs/RelativePath"
    },
    "contentHash": {
      "$ref": "#/$defs/Hash"
    },
    "displayName": {
      "type": "string"
    },
    "licenseNote": {
      "type": "string"
    },
    "width": {
      "type": "integer",
      "minimum": 0,
      "maximum": 2147483647
    },
    "height": {
      "type": "integer",
      "minimum": 0,
      "maximum": 2147483647
    },
    "byteSize": {
      "type": "integer",
      "minimum": 0,
      "maximum": 2147483647
    },
    "originalName": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "mediaType",
    "relativePath",
    "contentHash",
    "displayName"
  ],
  "additionalProperties": false,
  "title": "ContentAsset"
}

ContentCharacter

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
nameTextRefId · 必填本地化名称的文本 ID。
colorstring · 必填角色的显示颜色,不是逻辑值。
{"pattern":"^#[0-9a-fA-F]{6}$"}
defaultPortraitRefId角色默认立绘资源;通用导出不包含此项。
emotionsobject · 必填表情 ID → 表情定义。
{"additionalProperties":{"$ref":"#/$defs/Emotion"}}
emotions[key]Emotion结构与有效值请参阅类型和模式定义。
Schema · ContentCharacter
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "nameTextRef": {
      "$ref": "#/$defs/Id"
    },
    "color": {
      "type": "string",
      "pattern": "^#[0-9a-fA-F]{6}$"
    },
    "defaultPortraitRef": {
      "$ref": "#/$defs/Id"
    },
    "emotions": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/Emotion"
      }
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "nameTextRef",
    "color",
    "emotions"
  ],
  "additionalProperties": false,
  "title": "ContentCharacter"
}

ContentCommandDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
categorystring · 必填用于整理此定义的目录分类。
inputsArray<ParameterDefinition> · 必填带有名称和类型的签名输入参数。
outcomesArray<OutcomeDefinition> · 必填命令可能返回的结果名称,以及对应的数据约定和绑定。
{"minItems":1}
descriptionstring创作者编写的描述,不是可执行指令。
Schema · ContentCommandDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "category": {
      "type": "string"
    },
    "inputs": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/ParameterDefinition"
      }
    },
    "outcomes": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/OutcomeDefinition"
      },
      "minItems": 1
    },
    "description": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "category",
    "inputs",
    "outcomes"
  ],
  "additionalProperties": false,
  "title": "ContentCommandDefinition"
}

ContentItemDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
nameTextRefId · 必填本地化名称的文本 ID。
descriptionTextRefId本地化描述的文本 ID。
iconAssetRefId目录图标的资源 ID。
Schema · ContentItemDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "nameTextRef": {
      "$ref": "#/$defs/Id"
    },
    "descriptionTextRef": {
      "$ref": "#/$defs/Id"
    },
    "iconAssetRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "nameTextRef"
  ],
  "additionalProperties": false,
  "title": "ContentItemDefinition"
}

ContentLocationDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
nameTextRefId · 必填本地化名称的文本 ID。
descriptionTextRefId本地化描述的文本 ID。
previewAssetRefId预览资源的资源 ID。
Schema · ContentLocationDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "nameTextRef": {
      "$ref": "#/$defs/Id"
    },
    "descriptionTextRef": {
      "$ref": "#/$defs/Id"
    },
    "previewAssetRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "nameTextRef"
  ],
  "additionalProperties": false,
  "title": "ContentLocationDefinition"
}

ContentMinigameDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
nameTextRefId本地化名称的文本 ID。
commandRefId · 必填要执行的游戏命令 ID。
Schema · ContentMinigameDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "nameTextRef": {
      "$ref": "#/$defs/Id"
    },
    "commandRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "commandRef"
  ],
  "additionalProperties": false,
  "title": "ContentMinigameDefinition"
}

ContentQuestDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
titleTextRefId · 必填本地化标题的文本 ID。
descriptionTextRefId本地化描述的文本 ID。
objectiveDefinitionsArray<QuestObjective> · 必填任务目标 ID → 目标定义。
Schema · ContentQuestDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "titleTextRef": {
      "$ref": "#/$defs/Id"
    },
    "descriptionTextRef": {
      "$ref": "#/$defs/Id"
    },
    "objectiveDefinitions": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/QuestObjective"
      }
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "titleTextRef",
    "objectiveDefinitions"
  ],
  "additionalProperties": false,
  "title": "ContentQuestDefinition"
}

ContentTextEntry

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
keyKey稳定且可读的键;技术引用仍使用 ID。
categorystring · 必填用于整理此定义的目录分类。
sourceMessage消息 · 必填由文本片段和占位符片段组成的原文消息。
placeholdersobject · 必填占位符键 → 类型及格式定义。
{"additionalProperties":{"$ref":"#/$defs/PlaceholderDefinition"}}
placeholders[key]PlaceholderDefinition结构与有效值请参阅类型和模式定义。
externalUseboolean · 必填标记在节点图之外使用的文本。
Schema · ContentTextEntry
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "category": {
      "type": "string"
    },
    "sourceMessage": {
      "$ref": "#/$defs/Message"
    },
    "placeholders": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/PlaceholderDefinition"
      }
    },
    "externalUse": {
      "type": "boolean"
    }
  },
  "required": [
    "id",
    "category",
    "sourceMessage",
    "placeholders",
    "externalUse"
  ],
  "additionalProperties": false,
  "title": "ContentTextEntry"
}

ContentVariableDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
keyKey · 必填稳定且可读的键;技术引用仍使用 ID。
valueTypeScalarType · 必填期望值的数据约定,包含允许的实体类型。
defaultValueScalarValue · 必填带类型的初始值或默认值。
descriptionstring创作者编写的描述,不是可执行指令。
Schema · ContentVariableDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "key": {
      "$ref": "#/$defs/Key"
    },
    "valueType": {
      "$ref": "#/$defs/ScalarType"
    },
    "defaultValue": {
      "$ref": "#/$defs/ScalarValue"
    },
    "description": {
      "type": "string"
    }
  },
  "required": [
    "id",
    "name",
    "key",
    "valueType",
    "defaultValue"
  ],
  "additionalProperties": false,
  "title": "ContentVariableDefinition"
}

Emotion

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
portraitRefId某个表情的立绘资源;通用导出不包含此项。
Schema · Emotion
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "portraitRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "id",
    "name"
  ],
  "additionalProperties": false,
  "title": "Emotion"
}

EntityType

字段类型/必填含义/规则
Schema · EntityType
{
  "type": "string",
  "enum": [
    "item",
    "quest",
    "location",
    "minigame",
    "asset"
  ],
  "title": "EntityType"
}

EntryRef

字段类型/必填含义/规则
flowRefId · 必填场景或子故事的 ID。
entryRefId · 必填指定流程中的入口 ID。
Schema · EntryRef
{
  "type": "object",
  "properties": {
    "flowRef": {
      "$ref": "#/$defs/Id"
    },
    "entryRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "flowRef",
    "entryRef"
  ],
  "additionalProperties": false,
  "title": "EntryRef"
}

ExecutableChoiceOption

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
textExecutableTextUse · 必填对于文本片段:固定文本内容。对于文本引用:textRef 和 bindings。
conditionExecutableCondition在分支选择或启用选项之前判断的条件。
effectsArray<ExecutableEffect> · 必填由动作节点按顺序应用的状态变更。
continuationExecutableContinuation · 必填节点完成后的后续流程。
Schema · ExecutableChoiceOption
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "text": {
      "$ref": "#/$defs/ExecutableTextUse"
    },
    "condition": {
      "$ref": "#/$defs/ExecutableCondition"
    },
    "effects": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/ExecutableEffect"
      }
    },
    "continuation": {
      "$ref": "#/$defs/ExecutableContinuation"
    }
  },
  "required": [
    "id",
    "text",
    "effects",
    "continuation"
  ],
  "additionalProperties": false,
  "title": "ExecutableChoiceOption"
}

ExecutableCondition

字段类型/必填含义/规则
[oneOf 1].kind"compare" · 必填用于选择有效变体的判别字段。
[oneOf 1].leftExecutableOperand · 必填比较左侧带类型的操作数。
[oneOf 1].operator"eq" | "ne" | "lt" | "lte" | "gt" | "gte" · 必填比较或逻辑运算符;允许值见各变体。
[oneOf 1].rightExecutableOperand · 必填比较右侧带类型的操作数。
[oneOf 2].kind"all" · 必填用于选择有效变体的判别字段。
[oneOf 2].childrenArray<ExecutableCondition> · 必填复合表达式中的子条件。
[oneOf 3].kind"any" · 必填用于选择有效变体的判别字段。
[oneOf 3].childrenArray<ExecutableCondition> · 必填复合表达式中的子条件。
[oneOf 4].kind"not" · 必填用于选择有效变体的判别字段。
[oneOf 4].childExecutableCondition · 必填一元运算符的子条件。
Schema · ExecutableCondition
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "compare"
        },
        "left": {
          "$ref": "#/$defs/ExecutableOperand"
        },
        "operator": {
          "type": "string",
          "enum": [
            "eq",
            "ne",
            "lt",
            "lte",
            "gt",
            "gte"
          ]
        },
        "right": {
          "$ref": "#/$defs/ExecutableOperand"
        }
      },
      "required": [
        "kind",
        "left",
        "operator",
        "right"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "all"
        },
        "children": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/ExecutableCondition"
          }
        }
      },
      "required": [
        "kind",
        "children"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "any"
        },
        "children": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/ExecutableCondition"
          }
        }
      },
      "required": [
        "kind",
        "children"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "not"
        },
        "child": {
          "$ref": "#/$defs/ExecutableCondition"
        }
      },
      "required": [
        "kind",
        "child"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ExecutableCondition"
}

ExecutableContinuation

字段类型/必填含义/规则
[oneOf 1].kind"node" · 必填用于选择有效变体的判别字段。
[oneOf 1].nodeRefId · 必填下一个可执行节点的 ID。
[oneOf 2].kind"end" · 必填用于选择有效变体的判别字段。
Schema · ExecutableContinuation
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "node"
        },
        "nodeRef": {
          "$ref": "#/$defs/Id"
        }
      },
      "required": [
        "kind",
        "nodeRef"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "end"
        }
      },
      "required": [
        "kind"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ExecutableContinuation"
}

ExecutableEffect

字段类型/必填含义/规则
[oneOf 1].kind"set" · 必填用于选择有效变体的判别字段。
[oneOf 1].variableRefId · 必填要读取或写入的变量 ID。
[oneOf 1].valueExecutableOperand · 必填固定值,必须与声明的类型匹配。
[oneOf 2].kind"add" · 必填用于选择有效变体的判别字段。
[oneOf 2].variableRefId · 必填要读取或写入的变量 ID。
[oneOf 2].valueExecutableOperand · 必填固定值,必须与声明的类型匹配。
[oneOf 3].kind"subtract" · 必填用于选择有效变体的判别字段。
[oneOf 3].variableRefId · 必填要读取或写入的变量 ID。
[oneOf 3].valueExecutableOperand · 必填固定值,必须与声明的类型匹配。
Schema · ExecutableEffect
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "set"
        },
        "variableRef": {
          "$ref": "#/$defs/Id"
        },
        "value": {
          "$ref": "#/$defs/ExecutableOperand"
        }
      },
      "required": [
        "kind",
        "variableRef",
        "value"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "add"
        },
        "variableRef": {
          "$ref": "#/$defs/Id"
        },
        "value": {
          "$ref": "#/$defs/ExecutableOperand"
        }
      },
      "required": [
        "kind",
        "variableRef",
        "value"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "subtract"
        },
        "variableRef": {
          "$ref": "#/$defs/Id"
        },
        "value": {
          "$ref": "#/$defs/ExecutableOperand"
        }
      },
      "required": [
        "kind",
        "variableRef",
        "value"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ExecutableEffect"
}

ExecutableEmptyChoice

字段类型/必填含义/规则
[oneOf 1].kind"continue" · 必填用于选择有效变体的判别字段。
[oneOf 1].continuationExecutableContinuation · 必填节点完成后的后续流程。
[oneOf 2].kind"fault" · 必填用于选择有效变体的判别字段。
Schema · ExecutableEmptyChoice
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "continue"
        },
        "continuation": {
          "$ref": "#/$defs/ExecutableContinuation"
        }
      },
      "required": [
        "kind",
        "continuation"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "fault"
        }
      },
      "required": [
        "kind"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ExecutableEmptyChoice"
}

ExecutableNode

字段类型/必填含义/规则
[oneOf 1].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 1].flowRefId · 必填场景或子故事的 ID。
[oneOf 1].kind"dialogue" · 必填用于选择有效变体的判别字段。
[oneOf 1].textExecutableTextUse · 必填对于文本片段:固定文本内容。对于文本引用:textRef 和 bindings。
[oneOf 1].speakerRefId说话角色的 ID;省略表示未指定说话角色。
[oneOf 1].emotionRefId为此句对话选择的角色表情。
[oneOf 1].continuationExecutableContinuation · 必填节点完成后的后续流程。
[oneOf 2].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 2].flowRefId · 必填场景或子故事的 ID。
[oneOf 2].kind"choice" · 必填用于选择有效变体的判别字段。
[oneOf 2].optionOrderArray<Id> · 必填按显示顺序排列的选项 ID。
[oneOf 2].optionsobject · 必填选项 ID → 包含文本、条件和后续流程的选项。
{"additionalProperties":{"$ref":"#/$defs/ExecutableChoiceOption"}}
[oneOf 2].options[key]ExecutableChoiceOption结构与有效值请参阅类型和模式定义。
[oneOf 2].whenEmptyExecutableEmptyChoice · 必填没有可用选项时的行为。
[oneOf 3].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 3].flowRefId · 必填场景或子故事的 ID。
[oneOf 3].kind"branch" · 必填用于选择有效变体的判别字段。
[oneOf 3].conditionExecutableCondition · 必填在分支选择或启用选项之前判断的条件。
[oneOf 3].whenTrueExecutableContinuation · 必填条件为真时的后续流程。
[oneOf 3].whenFalseExecutableContinuation · 必填条件为假时的后续流程。
[oneOf 4].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 4].flowRefId · 必填场景或子故事的 ID。
[oneOf 4].kind"action" · 必填用于选择有效变体的判别字段。
[oneOf 4].effectsArray<ExecutableEffect> · 必填由动作节点按顺序应用的状态变更。
[oneOf 4].continuationExecutableContinuation · 必填节点完成后的后续流程。
[oneOf 5].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 5].flowRefId · 必填场景或子故事的 ID。
[oneOf 5].kind"command" · 必填用于选择有效变体的判别字段。
[oneOf 5].commandRefId · 必填要执行的游戏命令 ID。
[oneOf 5].argumentsobject · 必填传给调用的具名参数值。
{"additionalProperties":{"$ref":"#/$defs/ExecutableOperand"}}
[oneOf 5].arguments[key]ExecutableOperand结构与有效值请参阅类型和模式定义。
[oneOf 5].outcomesobject · 必填命令可能返回的结果名称,以及对应的数据约定和绑定。
{"additionalProperties":{"$ref":"#/$defs/ExecutableOutcomeBinding"}}
[oneOf 5].outcomes[key]ExecutableOutcomeBinding结构与有效值请参阅类型和模式定义。
[oneOf 6].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 6].flowRefId · 必填场景或子故事的 ID。
[oneOf 6].kind"jump" · 必填用于选择有效变体的判别字段。
[oneOf 6].targetEntryRef · 必填带类型的目标引用,例如变量或入口;具体结构见对应变体。
[oneOf 7].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 7].flowRefId · 必填场景或子故事的 ID。
[oneOf 7].kind"end" · 必填用于选择有效变体的判别字段。
[oneOf 8].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 8].flowRefId · 必填场景或子故事的 ID。
[oneOf 8].kind"call" · 必填用于选择有效变体的判别字段。
[oneOf 8].targetEntryRef · 必填带类型的目标引用,例如变量或入口;具体结构见对应变体。
[oneOf 8].continuationExecutableContinuation · 必填节点完成后的后续流程。
[oneOf 9].idId · 必填稳定 ID;显示名称不能用作键。
[oneOf 9].flowRefId · 必填场景或子故事的 ID。
[oneOf 9].kind"return" · 必填用于选择有效变体的判别字段。
Schema · ExecutableNode
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "dialogue"
        },
        "text": {
          "$ref": "#/$defs/ExecutableTextUse"
        },
        "speakerRef": {
          "$ref": "#/$defs/Id"
        },
        "emotionRef": {
          "$ref": "#/$defs/Id"
        },
        "continuation": {
          "$ref": "#/$defs/ExecutableContinuation"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "text",
        "continuation"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "choice"
        },
        "optionOrder": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/Id"
          },
          "uniqueItems": true
        },
        "options": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ExecutableChoiceOption"
          }
        },
        "whenEmpty": {
          "$ref": "#/$defs/ExecutableEmptyChoice"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "optionOrder",
        "options",
        "whenEmpty"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "branch"
        },
        "condition": {
          "$ref": "#/$defs/ExecutableCondition"
        },
        "whenTrue": {
          "$ref": "#/$defs/ExecutableContinuation"
        },
        "whenFalse": {
          "$ref": "#/$defs/ExecutableContinuation"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "condition",
        "whenTrue",
        "whenFalse"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "action"
        },
        "effects": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/ExecutableEffect"
          }
        },
        "continuation": {
          "$ref": "#/$defs/ExecutableContinuation"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "effects",
        "continuation"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "command"
        },
        "commandRef": {
          "$ref": "#/$defs/Id"
        },
        "arguments": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ExecutableOperand"
          }
        },
        "outcomes": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ExecutableOutcomeBinding"
          }
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "commandRef",
        "arguments",
        "outcomes"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "jump"
        },
        "target": {
          "$ref": "#/$defs/EntryRef"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "target"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "end"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "call"
        },
        "target": {
          "$ref": "#/$defs/EntryRef"
        },
        "continuation": {
          "$ref": "#/$defs/ExecutableContinuation"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind",
        "target",
        "continuation"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "id": {
          "$ref": "#/$defs/Id"
        },
        "flowRef": {
          "$ref": "#/$defs/Id"
        },
        "kind": {
          "const": "return"
        }
      },
      "required": [
        "id",
        "flowRef",
        "kind"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ExecutableNode"
}

ExecutableOperand

字段类型/必填含义/规则
[oneOf 1].kind"literal" · 必填用于选择有效变体的判别字段。
[oneOf 1].valueTypedValue · 必填固定值,必须与声明的类型匹配。
[oneOf 2].kind"variable" · 必填用于选择有效变体的判别字段。
[oneOf 2].variableRefId · 必填要读取或写入的变量 ID。
Schema · ExecutableOperand
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "literal"
        },
        "value": {
          "$ref": "#/$defs/TypedValue"
        }
      },
      "required": [
        "kind",
        "value"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "variable"
        },
        "variableRef": {
          "$ref": "#/$defs/Id"
        }
      },
      "required": [
        "kind",
        "variableRef"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ExecutableOperand"
}

ExecutableOutcomeBinding

字段类型/必填含义/规则
resultBindingsobject · 必填命令结果名称 → 用于接收返回值的目标变量。
{"additionalProperties":{"$ref":"#/$defs/Id"}}
resultBindings[key]Id结构与有效值请参阅类型和模式定义。
continuationExecutableContinuation · 必填节点完成后的后续流程。
Schema · ExecutableOutcomeBinding
{
  "type": "object",
  "properties": {
    "resultBindings": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/Id"
      }
    },
    "continuation": {
      "$ref": "#/$defs/ExecutableContinuation"
    }
  },
  "required": [
    "resultBindings",
    "continuation"
  ],
  "additionalProperties": false,
  "title": "ExecutableOutcomeBinding"
}

ExecutableStory

字段类型/必填含义/规则
format"vnle.story" · 必填此数据容器的确切格式标识符。
containerVersion1 · 必填故事容器的整数版本号,目前为 1。
storyBuildIdHash · 必填规范化执行数据的 SHA-256 哈希;仅修改内容不会改变此值。
executionExecutionContract · 必填带类型的执行数据约定。
contentobject · 必填与执行数据分开的语言和目录数据。
{"additionalProperties":false}
content.sourceLocaleLocale · 必填文本的源语言,也是缺失译文时的回退语言。
content.localesArray<Locale> · 必填声明的导出语言,包含源语言。
{"minItems":1}
content.fallbackPolicyFallbackPolicy · 必填目前为 source:缺少译文时使用原文。
content.textsobject · 必填文本 ID → 原文消息、占位符和元数据。
{"additionalProperties":{"$ref":"#/$defs/ContentTextEntry"}}
content.texts[key]ContentTextEntry结构与有效值请参阅类型和模式定义。
content.translationsobject · 必填语言代码 → 文本 ID → 译文;缺少条目时回退到原文。
{"additionalProperties":{"type":"object","propertyNames":{"pattern":"^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"},"additionalProperties":{"$ref":"#/$defs/Translation"},"minProperties":1}}
content.translations[key]object结构与有效值请参阅类型和模式定义。
content.charactersobject · 必填角色 ID → 含本地化姓名和表情的角色。
{"additionalProperties":{"$ref":"#/$defs/ContentCharacter"}}
content.characters[key]ContentCharacter结构与有效值请参阅类型和模式定义。
content.questsobject · 必填任务 ID → 含目标的任务定义。
{"additionalProperties":{"$ref":"#/$defs/ContentQuestDefinition"}}
content.quests[key]ContentQuestDefinition结构与有效值请参阅类型和模式定义。
content.itemsobject · 必填物品 ID → 物品定义。
{"additionalProperties":{"$ref":"#/$defs/ContentItemDefinition"}}
content.items[key]ContentItemDefinition结构与有效值请参阅类型和模式定义。
content.locationsobject · 必填地点 ID → 地点定义。
{"additionalProperties":{"$ref":"#/$defs/ContentLocationDefinition"}}
content.locations[key]ContentLocationDefinition结构与有效值请参阅类型和模式定义。
content.minigamesobject · 必填小游戏 ID → 定义;具体玩法由游戏端实现。
{"additionalProperties":{"$ref":"#/$defs/ContentMinigameDefinition"}}
content.minigames[key]ContentMinigameDefinition结构与有效值请参阅类型和模式定义。
content.assetsobject · 必填资源 ID → 媒体定义;通用导出目前不提供已解析的引擎资源。
{"additionalProperties":{"$ref":"#/$defs/ContentAsset"}}
content.assets[key]ContentAsset结构与有效值请参阅类型和模式定义。
content.variableDefinitionsobject · 必填作者创建的变量定义,包含名称和文本引用。
{"additionalProperties":{"$ref":"#/$defs/ContentVariableDefinition"}}
content.variableDefinitions[key]ContentVariableDefinition结构与有效值请参阅类型和模式定义。
content.commandDefinitionsobject · 必填作者创建的命令定义,包含文本引用。
{"additionalProperties":{"$ref":"#/$defs/ContentCommandDefinition"}}
content.commandDefinitions[key]ContentCommandDefinition结构与有效值请参阅类型和模式定义。
Schema · ExecutableStory
{
  "type": "object",
  "properties": {
    "format": {
      "const": "vnle.story"
    },
    "containerVersion": {
      "const": 1
    },
    "storyBuildId": {
      "$ref": "#/$defs/Hash"
    },
    "execution": {
      "$ref": "#/$defs/ExecutionContract"
    },
    "content": {
      "type": "object",
      "properties": {
        "sourceLocale": {
          "$ref": "#/$defs/Locale"
        },
        "locales": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/Locale"
          },
          "minItems": 1,
          "uniqueItems": true
        },
        "fallbackPolicy": {
          "$ref": "#/$defs/FallbackPolicy"
        },
        "texts": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentTextEntry"
          }
        },
        "translations": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[A-Za-z]{2,8}(-[A-Za-z0-9]{1,8})*$"
          },
          "additionalProperties": {
            "type": "object",
            "propertyNames": {
              "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
            },
            "additionalProperties": {
              "$ref": "#/$defs/Translation"
            },
            "minProperties": 1
          }
        },
        "characters": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentCharacter"
          }
        },
        "quests": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentQuestDefinition"
          }
        },
        "items": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentItemDefinition"
          }
        },
        "locations": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentLocationDefinition"
          }
        },
        "minigames": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentMinigameDefinition"
          }
        },
        "assets": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentAsset"
          }
        },
        "variableDefinitions": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentVariableDefinition"
          }
        },
        "commandDefinitions": {
          "type": "object",
          "propertyNames": {
            "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
          },
          "additionalProperties": {
            "$ref": "#/$defs/ContentCommandDefinition"
          }
        }
      },
      "required": [
        "sourceLocale",
        "locales",
        "fallbackPolicy",
        "texts",
        "translations",
        "characters",
        "quests",
        "items",
        "locations",
        "minigames",
        "assets",
        "variableDefinitions",
        "commandDefinitions"
      ],
      "additionalProperties": false
    }
  },
  "required": [
    "format",
    "containerVersion",
    "storyBuildId",
    "execution",
    "content"
  ],
  "additionalProperties": false,
  "title": "ExecutableStory"
}

ExecutableTextUse

字段类型/必填含义/规则
textRefId · 必填对 content.texts 及其文本数据约定的引用。
bindingsobject · 必填占位符或参数名称 → 带类型的操作数。
{"additionalProperties":{"$ref":"#/$defs/ExecutableOperand"}}
bindings[key]ExecutableOperand结构与有效值请参阅类型和模式定义。
Schema · ExecutableTextUse
{
  "type": "object",
  "properties": {
    "textRef": {
      "$ref": "#/$defs/Id"
    },
    "bindings": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/ExecutableOperand"
      }
    }
  },
  "required": [
    "textRef",
    "bindings"
  ],
  "additionalProperties": false,
  "title": "ExecutableTextUse"
}

ExecutionContract

字段类型/必填含义/规则
format"vnle.execution" · 必填此数据容器的确切格式标识符。
contractVersionRuntimeVersion · 必填执行兼容性版本:主版本号和次版本号。
projectIdId · 必填源项目的稳定 ID。
requiredCapabilitiesArray<Capability> · 必填完整运行时适配器在启动前必须检查的能力。
limitsobject · 必填自动执行与递归的限制。
{"additionalProperties":false}
limits.maxAutomaticTransitions1000 · 必填没有用户输入时允许的最大自动跳转次数。
limits.maxConditionDepth32 · 必填条件的最大嵌套深度。
limits.maxConditionTerms1024 · 必填条件项的最大数量。
limits.maxCallDepth32 · 必填子故事嵌套调用的最大深度。
entriesobject · 必填入口 ID → 流程和节点引用。
{"additionalProperties":{"$ref":"#/$defs/RuntimeEntry"}}
entries[key]RuntimeEntry结构与有效值请参阅类型和模式定义。
nodesobject · 必填节点 ID → 可执行节点;kind 决定其字段。
{"additionalProperties":{"$ref":"#/$defs/ExecutableNode"}}
nodes[key]ExecutableNode结构与有效值请参阅类型和模式定义。
variablesobject · 必填变量 ID → 带类型的运行时变量定义。
{"additionalProperties":{"$ref":"#/$defs/RuntimeVariable"}}
variables[key]RuntimeVariable结构与有效值请参阅类型和模式定义。
commandsobject · 必填命令 ID → 带类型的运行时签名。
{"additionalProperties":{"$ref":"#/$defs/RuntimeSignature"}}
commands[key]RuntimeSignature结构与有效值请参阅类型和模式定义。
textContractsobject · 必填文本 ID → 执行所需的占位符数据约定。
{"additionalProperties":{"$ref":"#/$defs/PlaceholderContract"}}
textContracts[key]PlaceholderContract结构与有效值请参阅类型和模式定义。
Schema · ExecutionContract
{
  "type": "object",
  "properties": {
    "format": {
      "const": "vnle.execution"
    },
    "contractVersion": {
      "$ref": "#/$defs/RuntimeVersion"
    },
    "projectId": {
      "$ref": "#/$defs/Id"
    },
    "requiredCapabilities": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Capability"
      },
      "uniqueItems": true
    },
    "limits": {
      "type": "object",
      "properties": {
        "maxAutomaticTransitions": {
          "const": 1000
        },
        "maxConditionDepth": {
          "const": 32
        },
        "maxConditionTerms": {
          "const": 1024
        },
        "maxCallDepth": {
          "const": 32
        }
      },
      "required": [
        "maxAutomaticTransitions",
        "maxConditionDepth",
        "maxConditionTerms",
        "maxCallDepth"
      ],
      "additionalProperties": false
    },
    "entries": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/RuntimeEntry"
      }
    },
    "nodes": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/ExecutableNode"
      }
    },
    "variables": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/RuntimeVariable"
      }
    },
    "commands": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/RuntimeSignature"
      }
    },
    "textContracts": {
      "type": "object",
      "propertyNames": {
        "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
      },
      "additionalProperties": {
        "$ref": "#/$defs/PlaceholderContract"
      }
    }
  },
  "required": [
    "format",
    "contractVersion",
    "projectId",
    "requiredCapabilities",
    "limits",
    "entries",
    "nodes",
    "variables",
    "commands",
    "textContracts"
  ],
  "additionalProperties": false,
  "title": "ExecutionContract"
}

FallbackPolicy

字段类型/必填含义/规则
Schema · FallbackPolicy
{
  "type": "string",
  "enum": [
    "block",
    "source"
  ],
  "title": "FallbackPolicy"
}

Hash

字段类型/必填含义/规则
Schema · Hash
{
  "type": "string",
  "pattern": "^sha256:[0-9a-f]{64}$",
  "title": "Hash"
}

Id

字段类型/必填含义/规则
Schema · Id
{
  "type": "string",
  "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$",
  "title": "Id"
}

Key

字段类型/必填含义/规则
Schema · Key
{
  "type": "string",
  "pattern": "^[A-Za-z][A-Za-z0-9_.-]{0,127}$",
  "title": "Key"
}

Locale

字段类型/必填含义/规则
Schema · Locale
{
  "type": "string",
  "pattern": "^[A-Za-z]{2,8}(-[A-Za-z0-9]{1,8})*$",
  "title": "Locale"
}

消息

字段类型/必填含义/规则
kind"segments" · 必填用于选择有效变体的判别字段。
segmentsArray<object | object> · 必填按顺序排列的文本和占位符消息片段。
Schema · Message
{
  "type": "object",
  "properties": {
    "kind": {
      "const": "segments"
    },
    "segments": {
      "type": "array",
      "items": {
        "oneOf": [
          {
            "type": "object",
            "properties": {
              "kind": {
                "const": "text"
              },
              "text": {
                "type": "string"
              }
            },
            "required": [
              "kind",
              "text"
            ],
            "additionalProperties": false
          },
          {
            "type": "object",
            "properties": {
              "kind": {
                "const": "placeholder"
              },
              "placeholderRef": {
                "$ref": "#/$defs/Id"
              }
            },
            "required": [
              "kind",
              "placeholderRef"
            ],
            "additionalProperties": false
          }
        ]
      }
    }
  },
  "required": [
    "kind",
    "segments"
  ],
  "additionalProperties": false,
  "title": "Message"
}

OutcomeDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
resultsArray<ResultDefinition> · 必填某个结果中带名称和类型的返回值。
Schema · OutcomeDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "results": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/ResultDefinition"
      }
    }
  },
  "required": [
    "id",
    "name",
    "results"
  ],
  "additionalProperties": false,
  "title": "OutcomeDefinition"
}

ParameterDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
valueTypeValueType · 必填期望值的数据约定,包含允许的实体类型。
defaultValueTypedValue带类型的初始值或默认值。
Schema · ParameterDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "valueType": {
      "$ref": "#/$defs/ValueType"
    },
    "defaultValue": {
      "$ref": "#/$defs/TypedValue"
    }
  },
  "required": [
    "id",
    "name",
    "valueType"
  ],
  "additionalProperties": false,
  "title": "ParameterDefinition"
}

PlaceholderContract

字段类型/必填含义/规则
map[key]ScalarType结构与有效值请参阅类型和模式定义。
Schema · PlaceholderContract
{
  "type": "object",
  "propertyNames": {
    "pattern": "^[0-9a-f]{8}-[0-9a-f]{4}-4[0-9a-f]{3}-[89ab][0-9a-f]{3}-[0-9a-f]{12}$"
  },
  "additionalProperties": {
    "$ref": "#/$defs/ScalarType"
  },
  "title": "PlaceholderContract"
}

PlaceholderDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
displayNamestring · 必填供人阅读的资源显示名称。
valueTypeScalarType · 必填期望值的数据约定,包含允许的实体类型。
Schema · PlaceholderDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "displayName": {
      "type": "string"
    },
    "valueType": {
      "$ref": "#/$defs/ScalarType"
    }
  },
  "required": [
    "id",
    "displayName",
    "valueType"
  ],
  "additionalProperties": false,
  "title": "PlaceholderDefinition"
}

QuestObjective

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
labelTextRefId · 必填本地化标签的文本 ID。
descriptionTextRefId本地化描述的文本 ID。
Schema · QuestObjective
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "labelTextRef": {
      "$ref": "#/$defs/Id"
    },
    "descriptionTextRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "id",
    "labelTextRef"
  ],
  "additionalProperties": false,
  "title": "QuestObjective"
}

RelativePath

字段类型/必填含义/规则
Schema · RelativePath
{
  "type": "string",
  "minLength": 1,
  "maxLength": 1024,
  "title": "RelativePath"
}

ResultDefinition

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
namestring · 必填创作者设置的名称,不可用作引用键。
valueTypeValueType · 必填期望值的数据约定,包含允许的实体类型。
Schema · ResultDefinition
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "name": {
      "type": "string"
    },
    "valueType": {
      "$ref": "#/$defs/ValueType"
    }
  },
  "required": [
    "id",
    "name",
    "valueType"
  ],
  "additionalProperties": false,
  "title": "ResultDefinition"
}

RuntimeEntry

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
flowRefId · 必填场景或子故事的 ID。
nodeRefId · 必填下一个可执行节点的 ID。
Schema · RuntimeEntry
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "flowRef": {
      "$ref": "#/$defs/Id"
    },
    "nodeRef": {
      "$ref": "#/$defs/Id"
    }
  },
  "required": [
    "id",
    "flowRef",
    "nodeRef"
  ],
  "additionalProperties": false,
  "title": "RuntimeEntry"
}

RuntimeSignature

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
inputsArray<object> · 必填带有名称和类型的签名输入参数。
outcomesArray<object> · 必填命令可能返回的结果名称,以及对应的数据约定和绑定。
{"minItems":1}
Schema · RuntimeSignature
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "inputs": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/$defs/Id"
          },
          "valueType": {
            "$ref": "#/$defs/ValueType"
          },
          "defaultValue": {
            "$ref": "#/$defs/TypedValue"
          }
        },
        "required": [
          "id",
          "valueType"
        ],
        "additionalProperties": false
      }
    },
    "outcomes": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "id": {
            "$ref": "#/$defs/Id"
          },
          "results": {
            "type": "array",
            "items": {
              "type": "object",
              "properties": {
                "id": {
                  "$ref": "#/$defs/Id"
                },
                "valueType": {
                  "$ref": "#/$defs/ValueType"
                }
              },
              "required": [
                "id",
                "valueType"
              ],
              "additionalProperties": false
            }
          }
        },
        "required": [
          "id",
          "results"
        ],
        "additionalProperties": false
      },
      "minItems": 1
    }
  },
  "required": [
    "id",
    "inputs",
    "outcomes"
  ],
  "additionalProperties": false,
  "title": "RuntimeSignature"
}

RuntimeVariable

字段类型/必填含义/规则
idId · 必填稳定 ID;显示名称不能用作键。
valueTypeScalarType · 必填期望值的数据约定,包含允许的实体类型。
defaultValueScalarValue · 必填带类型的初始值或默认值。
Schema · RuntimeVariable
{
  "type": "object",
  "properties": {
    "id": {
      "$ref": "#/$defs/Id"
    },
    "valueType": {
      "$ref": "#/$defs/ScalarType"
    },
    "defaultValue": {
      "$ref": "#/$defs/ScalarValue"
    }
  },
  "required": [
    "id",
    "valueType",
    "defaultValue"
  ],
  "additionalProperties": false,
  "title": "RuntimeVariable"
}

RuntimeVersion

字段类型/必填含义/规则
major1 · 必填不兼容的主版本号;必须拒绝不受支持的版本。
minor1 · 必填同一主版本内的扩展版本号。
Schema · RuntimeVersion
{
  "type": "object",
  "properties": {
    "major": {
      "const": 1
    },
    "minor": {
      "const": 1
    }
  },
  "required": [
    "major",
    "minor"
  ],
  "additionalProperties": false,
  "title": "RuntimeVersion"
}

ScalarType

字段类型/必填含义/规则
Schema · ScalarType
{
  "type": "string",
  "enum": [
    "boolean",
    "integer",
    "string"
  ],
  "title": "ScalarType"
}

ScalarValue

字段类型/必填含义/规则
[oneOf 1].type"boolean" · 必填类型判别字段;允许值由所在的 Schema 定义决定。
[oneOf 1].valueboolean · 必填固定值,必须与声明的类型匹配。
[oneOf 2].type"integer" · 必填类型判别字段;允许值由所在的 Schema 定义决定。
[oneOf 2].valueinteger · 必填固定值,必须与声明的类型匹配。
{"minimum":-2147483648,"maximum":2147483647}
[oneOf 3].type"string" · 必填类型判别字段;允许值由所在的 Schema 定义决定。
[oneOf 3].valuestring · 必填固定值,必须与声明的类型匹配。
Schema · ScalarValue
{
  "oneOf": [
    {
      "type": "object",
      "properties": {
        "type": {
          "const": "boolean"
        },
        "value": {
          "type": "boolean"
        }
      },
      "required": [
        "type",
        "value"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "const": "integer"
        },
        "value": {
          "type": "integer",
          "minimum": -2147483648,
          "maximum": 2147483647
        }
      },
      "required": [
        "type",
        "value"
      ],
      "additionalProperties": false
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "const": "string"
        },
        "value": {
          "type": "string"
        }
      },
      "required": [
        "type",
        "value"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ScalarValue"
}

Translation

字段类型/必填含义/规则
textRefId · 必填对 content.texts 及其文本数据约定的引用。
localeLocale · 必填此译文条目的语言代码。
message消息 · 必填遵循占位符数据约定的译文消息。
allowEmptyboolean · 必填允许译文有意留空。
workflowStatus"draft" | "translated" | "reviewed" · 必填翻译工作流状态,不是运行时分支。
basedOnSourceFingerprintHash · 必填此译文所依据的原文信息;不匹配表示译文已过时。
reviewedContextFingerprintHash译文处于已审核状态时的上下文指纹。
origin"ai"结构与有效值请参阅类型和模式定义。
Schema · Translation
{
  "type": "object",
  "properties": {
    "textRef": {
      "$ref": "#/$defs/Id"
    },
    "locale": {
      "$ref": "#/$defs/Locale"
    },
    "message": {
      "$ref": "#/$defs/Message"
    },
    "allowEmpty": {
      "type": "boolean"
    },
    "workflowStatus": {
      "type": "string",
      "enum": [
        "draft",
        "translated",
        "reviewed"
      ]
    },
    "basedOnSourceFingerprint": {
      "$ref": "#/$defs/Hash"
    },
    "reviewedContextFingerprint": {
      "$ref": "#/$defs/Hash"
    },
    "origin": {
      "const": "ai"
    }
  },
  "required": [
    "textRef",
    "locale",
    "message",
    "allowEmpty",
    "workflowStatus",
    "basedOnSourceFingerprint"
  ],
  "additionalProperties": false,
  "title": "Translation"
}

TypedValue

字段类型/必填含义/规则
[oneOf 2].type"reference" · 必填类型判别字段;允许值由所在的 Schema 定义决定。
[oneOf 2].entityTypeEntityType · 必填实体引用的目录类型。
[oneOf 2].valueId · 必填固定值,必须与声明的类型匹配。
Schema · TypedValue
{
  "oneOf": [
    {
      "$ref": "#/$defs/ScalarValue"
    },
    {
      "type": "object",
      "properties": {
        "type": {
          "const": "reference"
        },
        "entityType": {
          "$ref": "#/$defs/EntityType"
        },
        "value": {
          "$ref": "#/$defs/Id"
        }
      },
      "required": [
        "type",
        "entityType",
        "value"
      ],
      "additionalProperties": false
    }
  ],
  "title": "TypedValue"
}

ValueType

字段类型/必填含义/规则
[oneOf 2].kind"reference" · 必填用于选择有效变体的判别字段。
[oneOf 2].entityTypeEntityType · 必填实体引用的目录类型。
Schema · ValueType
{
  "oneOf": [
    {
      "$ref": "#/$defs/ScalarType"
    },
    {
      "type": "object",
      "properties": {
        "kind": {
          "const": "reference"
        },
        "entityType": {
          "$ref": "#/$defs/EntityType"
        }
      },
      "required": [
        "kind",
        "entityType"
      ],
      "additionalProperties": false
    }
  ],
  "title": "ValueType"
}