feat: add versioned Blender production contracts

This commit is contained in:
NINI
2026-10-09 23:18:07 +09:00
parent b2b37a1105
commit d4f1a800aa
52 changed files with 1601 additions and 224 deletions
+829 -9
View File
@@ -2,7 +2,10 @@
"type": "object",
"properties": {
"schema_version": {
"const": "1.0"
"enum": [
"1.0",
"1.1"
]
},
"project_id": {
"type": "string",
@@ -1620,6 +1623,687 @@
}
}
]
},
"BlendFile": {
"type": "object",
"properties": {
"path": {
"type": "string"
},
"verified": {
"type": "boolean"
},
"sha256": {
"anyOf": [
{
"type": "null"
},
{
"type": "string",
"pattern": "^[a-f0-9]{64}$"
}
]
},
"blender_version": {
"anyOf": [
{
"type": "null"
},
{
"type": "string",
"minLength": 1
}
]
}
},
"required": [
"path",
"verified",
"sha256",
"blender_version"
],
"additionalProperties": false,
"allOf": [
{
"if": {
"properties": {
"verified": {
"const": true
}
}
},
"then": {
"properties": {
"path": {
"type": "string",
"minLength": 1
},
"sha256": {
"type": "string",
"pattern": "^[a-f0-9]{64}$"
},
"blender_version": {
"type": "string",
"minLength": 1
}
}
}
}
]
},
"RenderProfile": {
"type": "object",
"properties": {
"engine": {
"enum": [
"BLENDER_EEVEE",
"CYCLES"
]
},
"device": {
"enum": [
"CPU",
"GPU"
]
},
"fps": {
"type": "integer",
"minimum": 1
},
"width": {
"type": "integer",
"minimum": 1
},
"height": {
"type": "integer",
"minimum": 1
},
"samples": {
"type": "integer",
"minimum": 1
},
"seed": {
"type": "integer",
"minimum": 0
}
},
"required": [
"engine",
"device",
"fps",
"width",
"height",
"samples",
"seed"
],
"additionalProperties": false,
"allOf": [
{
"if": {
"properties": {
"engine": {
"const": "BLENDER_EEVEE"
}
}
},
"then": {
"properties": {
"device": {
"const": "GPU"
}
}
}
}
]
},
"08-scenes-1.1": {
"type": "object",
"properties": {
"scenes": {
"type": "array",
"items": {
"type": "object",
"properties": {
"cut_id": {
"type": "string"
},
"description": {
"type": "string"
},
"start_state": {
"type": "string"
},
"end_state": {
"type": "string"
},
"camera": {
"type": "string"
}
},
"required": [
"cut_id",
"description",
"start_state",
"end_state",
"camera"
],
"additionalProperties": false
}
},
"connections": {
"type": "array",
"items": {
"type": "object",
"properties": {
"from_cut_id": {
"type": "string"
},
"to_cut_id": {
"type": "string"
},
"mode": {
"enum": [
"continuous",
"cut"
]
},
"reason": {
"type": "string"
}
},
"required": [
"from_cut_id",
"to_cut_id",
"mode",
"reason"
],
"additionalProperties": false
}
},
"preview": {
"anyOf": [
{
"type": "null"
},
{
"type": "object",
"properties": {
"scene_file": {
"$ref": "#/$defs/BlendFile"
},
"render_profile": {
"$ref": "#/$defs/RenderProfile"
},
"samples": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"minLength": 1
},
"cut_ids": {
"type": "array",
"items": {
"type": "string",
"minLength": 1
},
"minItems": 1,
"uniqueItems": true
},
"media": {
"allOf": [
{
"$ref": "#/$defs/media"
},
{
"properties": {
"kind": {
"enum": [
"image",
"video"
]
}
}
}
]
}
},
"required": [
"id",
"cut_ids",
"media"
],
"additionalProperties": false
}
}
},
"required": [
"scene_file",
"render_profile",
"samples"
],
"additionalProperties": false
}
]
}
},
"required": [
"scenes",
"connections",
"preview"
],
"additionalProperties": false
},
"10-references-1.1": {
"type": "object",
"properties": {
"request": {
"type": "object",
"properties": {
"style_reference": {
"const": "references/1.png"
},
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"kind": {
"enum": [
"style",
"character",
"background",
"object"
]
},
"entity_id": {
"anyOf": [
{
"type": "null"
},
{
"type": "string"
}
]
},
"prompt": {
"type": "string"
}
},
"required": [
"id",
"kind",
"entity_id",
"prompt"
],
"additionalProperties": false,
"allOf": [
{
"if": {
"properties": {
"kind": {
"enum": [
"style",
"object"
]
}
}
},
"then": {
"properties": {
"entity_id": {
"type": "null"
}
}
},
"else": {
"properties": {
"entity_id": {
"type": "string"
}
}
}
}
]
}
},
"engine": {
"const": "Blender"
},
"render_profile": {
"$ref": "#/$defs/RenderProfile"
}
},
"required": [
"style_reference",
"items",
"engine",
"render_profile"
],
"additionalProperties": false
},
"result": {
"anyOf": [
{
"type": "null"
},
{
"type": "object",
"properties": {
"scene_file": {
"$ref": "#/$defs/BlendFile"
},
"items": {
"type": "array",
"items": {
"type": "object",
"properties": {
"reference_id": {
"type": "string"
},
"object_name": {
"type": "string",
"minLength": 1
},
"media": {
"allOf": [
{
"$ref": "#/$defs/media"
},
{
"properties": {
"kind": {
"const": "image"
}
}
}
]
}
},
"required": [
"reference_id",
"object_name",
"media"
],
"additionalProperties": false
}
}
},
"required": [
"scene_file",
"items"
],
"additionalProperties": false
}
]
}
},
"required": [
"request",
"result"
],
"additionalProperties": false
},
"11-images-1.1": {
"type": "object",
"properties": {
"request": {
"type": "object",
"properties": {
"frames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string"
},
"cut_id": {
"type": "string"
},
"position": {
"enum": [
"start",
"end"
]
},
"prompt": {
"type": "string"
},
"reference_ids": {
"type": "array",
"items": {
"type": "string"
}
},
"scene_name": {
"type": "string",
"minLength": 1
},
"frame_index": {
"type": "integer",
"minimum": 0
}
},
"required": [
"id",
"cut_id",
"position",
"prompt",
"reference_ids",
"scene_name",
"frame_index"
],
"additionalProperties": false
}
},
"engine": {
"const": "Blender"
},
"scene_path": {
"type": "string"
},
"render_profile": {
"$ref": "#/$defs/RenderProfile"
}
},
"required": [
"frames",
"engine",
"scene_path",
"render_profile"
],
"additionalProperties": false
},
"result": {
"anyOf": [
{
"type": "null"
},
{
"type": "object",
"properties": {
"frames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"frame_id": {
"type": "string"
},
"media": {
"allOf": [
{
"$ref": "#/$defs/media"
},
{
"properties": {
"kind": {
"const": "image"
}
}
}
]
}
},
"required": [
"frame_id",
"media"
],
"additionalProperties": false
}
},
"scene_file": {
"$ref": "#/$defs/BlendFile"
}
},
"required": [
"frames",
"scene_file"
],
"additionalProperties": false
}
]
}
},
"required": [
"request",
"result"
],
"additionalProperties": false
},
"12-motion-1.1": {
"type": "object",
"properties": {
"request": {
"type": "object",
"properties": {
"clips": {
"type": "array",
"items": {
"type": "object",
"properties": {
"cut_id": {
"type": "string"
},
"start_frame_id": {
"type": "string"
},
"end_frame_id": {
"type": "string"
},
"duration_ms": {
"type": [
"integer",
"null"
],
"minimum": 1,
"maximum": 5000
},
"motion_prompt": {
"type": "string"
},
"scene_name": {
"type": "string",
"minLength": 1
},
"start_frame": {
"type": "integer",
"minimum": 0
},
"end_frame": {
"type": "integer",
"minimum": 0
}
},
"required": [
"cut_id",
"start_frame_id",
"end_frame_id",
"duration_ms",
"motion_prompt",
"scene_name",
"start_frame",
"end_frame"
],
"additionalProperties": false
}
},
"engine": {
"const": "Blender"
},
"scene_path": {
"type": "string"
},
"render_profile": {
"$ref": "#/$defs/RenderProfile"
}
},
"required": [
"clips",
"engine",
"scene_path",
"render_profile"
],
"additionalProperties": false
},
"result": {
"anyOf": [
{
"type": "null"
},
{
"type": "object",
"properties": {
"clips": {
"type": "array",
"items": {
"type": "object",
"properties": {
"cut_id": {
"type": "string"
},
"media": {
"allOf": [
{
"$ref": "#/$defs/media"
},
{
"properties": {
"kind": {
"const": "video"
}
}
}
]
}
},
"required": [
"cut_id",
"media"
],
"additionalProperties": false
}
}
},
"required": [
"clips"
],
"additionalProperties": false
}
]
}
},
"required": [
"request",
"result"
],
"additionalProperties": false
}
},
"oneOf": [
@@ -1699,9 +2383,43 @@
"const": "08-scenes"
},
"payload": {
"$ref": "#/$defs/08-scenes"
"type": "object"
}
}
},
"allOf": [
{
"if": {
"properties": {
"schema_version": {
"const": "1.0"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/08-scenes"
}
}
}
},
{
"if": {
"properties": {
"schema_version": {
"const": "1.1"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/08-scenes-1.1"
}
}
}
}
]
},
{
"properties": {
@@ -1719,9 +2437,43 @@
"const": "10-references"
},
"payload": {
"$ref": "#/$defs/10-references"
"type": "object"
}
}
},
"allOf": [
{
"if": {
"properties": {
"schema_version": {
"const": "1.0"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/10-references"
}
}
}
},
{
"if": {
"properties": {
"schema_version": {
"const": "1.1"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/10-references-1.1"
}
}
}
}
]
},
{
"properties": {
@@ -1729,9 +2481,43 @@
"const": "11-images"
},
"payload": {
"$ref": "#/$defs/11-images"
"type": "object"
}
}
},
"allOf": [
{
"if": {
"properties": {
"schema_version": {
"const": "1.0"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/11-images"
}
}
}
},
{
"if": {
"properties": {
"schema_version": {
"const": "1.1"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/11-images-1.1"
}
}
}
}
]
},
{
"properties": {
@@ -1739,9 +2525,43 @@
"const": "12-motion"
},
"payload": {
"$ref": "#/$defs/12-motion"
"type": "object"
}
}
},
"allOf": [
{
"if": {
"properties": {
"schema_version": {
"const": "1.0"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/12-motion"
}
}
}
},
{
"if": {
"properties": {
"schema_version": {
"const": "1.1"
}
}
},
"then": {
"properties": {
"payload": {
"$ref": "#/$defs/12-motion-1.1"
}
}
}
}
]
},
{
"properties": {