@sogni-ai/sogni-protocol 1.0.0-alpha.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +89 -0
- package/catalogs/audio-models.json +34 -0
- package/catalogs/quality-presets.json +30 -0
- package/catalogs/seedance-reference-limits.json +9 -0
- package/enums/chat-run-status.json +12 -0
- package/enums/chat-run-waiting-reasons.json +10 -0
- package/enums/token-types.json +7 -0
- package/enums/tool-names.json +85 -0
- package/manifests/app-tools.json +297 -0
- package/manifests/composition-tools.json +228 -0
- package/manifests/generation-tools.json +1275 -0
- package/manifests/openai-tools.json +1830 -0
- package/package.json +44 -0
- package/prompts/tools/add_subtitles.json +12 -0
- package/prompts/tools/analyze_image.json +12 -0
- package/prompts/tools/analyze_video.json +11 -0
- package/prompts/tools/animate_photo.json +13 -0
- package/prompts/tools/apply_style.json +11 -0
- package/prompts/tools/ask_clarifying_question.json +10 -0
- package/prompts/tools/change_angle.json +11 -0
- package/prompts/tools/compose_instrumental.json +11 -0
- package/prompts/tools/compose_lyrics.json +12 -0
- package/prompts/tools/compose_script.json +21 -0
- package/prompts/tools/compose_workflow.json +17 -0
- package/prompts/tools/compose_workflow_template.json +23 -0
- package/prompts/tools/create_asset_manifest.json +9 -0
- package/prompts/tools/dance_montage.json +9 -0
- package/prompts/tools/edit_image.json +11 -0
- package/prompts/tools/enhance_prompt.json +20 -0
- package/prompts/tools/extend_video.json +11 -0
- package/prompts/tools/extract_metadata.json +9 -0
- package/prompts/tools/finalize_response.json +10 -0
- package/prompts/tools/generate_image.json +11 -0
- package/prompts/tools/generate_music.json +7 -0
- package/prompts/tools/generate_video.json +10 -0
- package/prompts/tools/inspect_asset.json +10 -0
- package/prompts/tools/label_asset.json +13 -0
- package/prompts/tools/manage_memory.json +12 -0
- package/prompts/tools/map_assets_for_model.json +9 -0
- package/prompts/tools/orbit_video.json +13 -0
- package/prompts/tools/overlay_video.json +10 -0
- package/prompts/tools/refine_result.json +11 -0
- package/prompts/tools/replace_video_segment.json +14 -0
- package/prompts/tools/resolve_personas.json +9 -0
- package/prompts/tools/restore_photo.json +12 -0
- package/prompts/tools/set_content_filter.json +9 -0
- package/prompts/tools/sound_to_video.json +9 -0
- package/prompts/tools/stitch_video.json +9 -0
- package/prompts/tools/validate_asset_references.json +10 -0
- package/prompts/tools/video_to_video.json +13 -0
- package/schemas/agent/intent-input.schema.json +128 -0
- package/schemas/agent/turn-analysis.schema.json +75 -0
- package/schemas/artifacts/artifact-graph.schema.json +42 -0
- package/schemas/artifacts/artifact-node.schema.json +137 -0
- package/schemas/billing/spend-gate.schema.json +151 -0
- package/schemas/billing/workflow-authorization.schema.json +83 -0
- package/schemas/errors/error.schema.json +21 -0
- package/schemas/errors/repair-control.schema.json +40 -0
- package/schemas/events/artifact-reference.schema.json +22 -0
- package/schemas/events/progress-event.schema.json +28 -0
- package/schemas/events/run-event.schema.json +122 -0
- package/schemas/events/workflow-event.schema.json +22 -0
- package/schemas/prompt-contract.schema.json +42 -0
- package/schemas/storyboards/storyboard-planning-contract.schema.json +108 -0
- package/schemas/tools/add_subtitles.schema.json +77 -0
- package/schemas/tools/animate_photo.schema.json +104 -0
- package/schemas/tools/apply_style.schema.json +37 -0
- package/schemas/tools/change_angle.schema.json +30 -0
- package/schemas/tools/compose_instrumental.schema.json +24 -0
- package/schemas/tools/compose_lyrics.schema.json +28 -0
- package/schemas/tools/compose_script.schema.json +68 -0
- package/schemas/tools/compose_workflow.schema.json +67 -0
- package/schemas/tools/compose_workflow_template.schema.json +156 -0
- package/schemas/tools/dance_montage.schema.json +47 -0
- package/schemas/tools/edit_image.schema.json +76 -0
- package/schemas/tools/enhance_prompt.schema.json +76 -0
- package/schemas/tools/extend_video.schema.json +43 -0
- package/schemas/tools/generate_image.schema.json +109 -0
- package/schemas/tools/generate_music.schema.json +62 -0
- package/schemas/tools/generate_video.schema.json +98 -0
- package/schemas/tools/manage_memory.schema.json +28 -0
- package/schemas/tools/orbit_video.schema.json +70 -0
- package/schemas/tools/overlay_video.schema.json +126 -0
- package/schemas/tools/refine_result.schema.json +43 -0
- package/schemas/tools/replace_video_segment.schema.json +61 -0
- package/schemas/tools/resolve_personas.schema.json +15 -0
- package/schemas/tools/restore_photo.schema.json +47 -0
- package/schemas/tools/set_content_filter.schema.json +14 -0
- package/schemas/tools/sound_to_video.schema.json +71 -0
- package/schemas/tools/stitch_video.schema.json +52 -0
- package/schemas/tools/tool-metadata.schema.json +78 -0
- package/schemas/tools/video_to_video.schema.json +78 -0
- package/schemas/workflows/durable-workflow-run.schema.json +165 -0
- package/schemas/workflows/durable-workflow-step.schema.json +141 -0
- package/version.json +4 -0
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.sogni.ai/creative-agent/2026-05-20.1/tools/tool-metadata.schema.json",
|
|
4
|
+
"title": "Tool catalog metadata",
|
|
5
|
+
"schemaVersion": "2026-05-20.1",
|
|
6
|
+
"description": "Metadata that accompanies each tool definition in the v2 catalog. Drives tool surfacing decisions (which family/execution mode is visible this turn), spend gating (costClass + requiresConfirmation), retry behavior (retrySafety), and durable-run observability (mutatesData, producesArtifacts). Input/output schema refs point at sogni-protocol argument and result contracts so the validator and the planner share one source of truth.",
|
|
7
|
+
"type": "object",
|
|
8
|
+
"additionalProperties": false,
|
|
9
|
+
"properties": {
|
|
10
|
+
"name": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"description": "Canonical tool name (snake_case, matches the OpenAI-format tool definition exposed to the LLM)."
|
|
13
|
+
},
|
|
14
|
+
"family": {
|
|
15
|
+
"type": "string",
|
|
16
|
+
"enum": ["creative", "composition", "artifact", "memory", "settings", "analysis", "control"],
|
|
17
|
+
"description": "Coarse grouping used by the planner to pick a minimal visible tool subset."
|
|
18
|
+
},
|
|
19
|
+
"executionMode": {
|
|
20
|
+
"type": "string",
|
|
21
|
+
"enum": ["hosted", "client", "app", "workflow", "internal"],
|
|
22
|
+
"description": "Where the tool runs. 'hosted' = sogni-api durable runner. 'client' = browser tool dispatch. 'app' = native shell. 'workflow' = synthetic tool that creates a WorkflowRun. 'internal' = runtime-only (e.g. L1 hidden resolver) — never surfaced to the LLM directly."
|
|
23
|
+
},
|
|
24
|
+
"inputSchemaRef": {
|
|
25
|
+
"type": "string",
|
|
26
|
+
"description": "URI or repo-relative path. MUST resolve to a sogni-protocol tool argument JSON Schema (e.g. schemas/tools/generate_image.schema.json)."
|
|
27
|
+
},
|
|
28
|
+
"outputSchemaRef": {
|
|
29
|
+
"type": "string",
|
|
30
|
+
"description": "URI or repo-relative path. MUST resolve to a sogni-protocol tool result envelope schema."
|
|
31
|
+
},
|
|
32
|
+
"costClass": {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"enum": ["free", "low", "medium", "high", "variable"],
|
|
35
|
+
"description": "Indicative cost tier. Concrete unit estimates live on the SpendGate request, not here."
|
|
36
|
+
},
|
|
37
|
+
"latencyClass": {
|
|
38
|
+
"type": "string",
|
|
39
|
+
"enum": ["inline", "interactive", "long_running"],
|
|
40
|
+
"description": "Indicative wall-clock tier. 'long_running' tools generally belong inside a Workflow Template, not a synchronous chat turn."
|
|
41
|
+
},
|
|
42
|
+
"mutatesData": {
|
|
43
|
+
"type": "boolean",
|
|
44
|
+
"description": "True when the tool changes persisted user state (e.g. manage_memory write, settings update)."
|
|
45
|
+
},
|
|
46
|
+
"producesArtifacts": {
|
|
47
|
+
"type": "boolean",
|
|
48
|
+
"description": "True when the tool emits one or more ArtifactNodes that must be registered in the ArtifactGraph."
|
|
49
|
+
},
|
|
50
|
+
"requiresConfirmation": {
|
|
51
|
+
"type": "string",
|
|
52
|
+
"enum": ["never", "paid", "destructive", "always"],
|
|
53
|
+
"description": "Confirmation policy. 'paid' defers to SpendGate. 'destructive' requires an explicit user yes regardless of cost. 'always' is reserved for atomic operations with no other gate."
|
|
54
|
+
},
|
|
55
|
+
"retrySafety": {
|
|
56
|
+
"type": "string",
|
|
57
|
+
"enum": ["idempotent", "dedupe_key_required", "not_safe"],
|
|
58
|
+
"description": "Whether the runner may retry the tool call on a transient failure. 'dedupe_key_required' tools must be called with a stable dedupe token (e.g. sogni-socket project id)."
|
|
59
|
+
},
|
|
60
|
+
"hiddenFromModel": {
|
|
61
|
+
"type": "boolean",
|
|
62
|
+
"description": "Optional. L1 hidden context tools (resolve_*, inspect_*) set this true so the runner can call them directly without surfacing them to the LLM."
|
|
63
|
+
}
|
|
64
|
+
},
|
|
65
|
+
"required": [
|
|
66
|
+
"name",
|
|
67
|
+
"family",
|
|
68
|
+
"executionMode",
|
|
69
|
+
"inputSchemaRef",
|
|
70
|
+
"outputSchemaRef",
|
|
71
|
+
"costClass",
|
|
72
|
+
"latencyClass",
|
|
73
|
+
"mutatesData",
|
|
74
|
+
"producesArtifacts",
|
|
75
|
+
"requiresConfirmation",
|
|
76
|
+
"retrySafety"
|
|
77
|
+
]
|
|
78
|
+
}
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.sogni.ai/creative-agent/2026-04-27.1/tools/video_to_video.schema.json",
|
|
4
|
+
"title": "video_to_video arguments",
|
|
5
|
+
"schemaVersion": "2026-04-27.1",
|
|
6
|
+
"description": "Transform an existing video using AI. Uses WAN 2.2 Animate (move/replace) with a reference image to animate a photo with the video's motion or swap the video's subject, LTX-2.3 V2V ControlNet (canny/pose/depth/detailer) for video-only transforms, or Seedance V2V when the user explicitly asks to transform, upscale, enhance, restyle, or remaster an uploaded video with Seedance. Requires an uploaded video file. Use when the user wants to animate a photo with video motion, replace subjects in a video, restyle an existing video, or enhance video quality.",
|
|
7
|
+
"type": "object",
|
|
8
|
+
"additionalProperties": false,
|
|
9
|
+
"properties": {
|
|
10
|
+
"prompt": {
|
|
11
|
+
"type": "string",
|
|
12
|
+
"description": "Describe the TARGET appearance (not the transformation process). 2-4 present-tense sentences.\n\nLITERAL PROMPT OVERRIDE: If the user explicitly says not to modify the prompt, or to use it exactly/verbatim/as-is, copy the identified prompt text verbatim instead of applying these construction rules unless a hard requirement is missing. For Seedance, set expandPrompt=false.\n\nFor LTX-2.3 canny/depth/pose modes, the source video preserves composition, depth, or motion. Spend prompt detail on style, atmosphere, lighting, surface texture, color palette, scale, and pacing.\n\nExamples by mode:\n- animate-move (DEFAULT — WAN 2.2 Animate Move: applies camera/motion from source video to reference image): \"Smooth cinematic camera movement following the subject through the scene.\"\n- animate-replace (WAN 2.2 Animate Replace: replaces the subject in the source video with the reference image): \"The person from the reference photo performing the actions from the video.\"\n- canny (LTX-2.3 — edge-detection restyle): \"Hand-drawn watercolor anime style with soft ink edges, muted teal and coral palette, rain mist, neon reflections, warm rim light, preserving original silhouettes and composition.\"\n- pose (LTX-2.3 — tracks skeleton, replace person): \"A glossy cartoon robot with exaggerated proportions, brushed metal texture, glowing cyan joints, energetic stage lighting, preserving the original dance timing and pose.\"\n- depth (LTX-2.3 — depth-map restyle): \"A misty alpine valley at golden hour, expansive scale, volumetric haze, cool blue shadows, warm rim light, cinematic depth, lingering continuous shot.\"\n- detailer (LTX-2.3 — enhance quality): DESCRIBE THE SOURCE, do not request changes. Append quality qualifiers only. E.g. \"The same scene, ultra-sharp and clean, crisp high-resolution detail, preserving all original content, composition, and color.\" Avoid words like \"enhanced textures\", \"restyled\", or any new subjects/objects — they cause drift.\n- seedance-v2v (BytePlus Dreamina Seedance 2.0 V2V): \"Restyle the source clip in a watercolor look with soft ink edges, while preserving its motion and composition.\" Use natural prose; Seedance reads the reference video holistically rather than via control-net constraints, so describe target style/mood/dialogue rather than control strength.\n\nPresent tense. Positive phrasing. Concrete visual details.\n\nBATCH VARIATIONS: When numberOfVariations > 1, use Dynamic Prompt syntax to vary the artistic treatment while keeping control mode and structural intent consistent. Example: \"transform to {watercolor with soft edges|oil painting with bold strokes|anime with clean lines} style\"."
|
|
13
|
+
},
|
|
14
|
+
"expandPrompt": {
|
|
15
|
+
"type": "boolean",
|
|
16
|
+
"description": "Seedance only. Whether to run the shared Seedance prompt shaper before dispatch. Defaults to true; set false only when the user explicitly asks to submit the compact prompt directly or not modify the prompt."
|
|
17
|
+
},
|
|
18
|
+
"videoSourceIndex": {
|
|
19
|
+
"type": "number",
|
|
20
|
+
"description": "Which uploaded video to transform. OMIT this field when there is only one uploaded video — the tool auto-selects it. Only pass when you need to pick among multiple uploaded videos. Indexing: 0-based (0 = first uploaded video, 1 = second). Note: this differs from analyze_video which uses negative indices; this tool also tolerates the negative form (-1 = first uploaded) for convenience."
|
|
21
|
+
},
|
|
22
|
+
"controlMode": {
|
|
23
|
+
"type": "string",
|
|
24
|
+
"enum": [
|
|
25
|
+
"animate-move",
|
|
26
|
+
"animate-replace",
|
|
27
|
+
"canny",
|
|
28
|
+
"pose",
|
|
29
|
+
"depth",
|
|
30
|
+
"detailer",
|
|
31
|
+
"seedance-v2v"
|
|
32
|
+
],
|
|
33
|
+
"description": "How the source video and (optional) reference image interact. Pick by user intent:\n• \"animate-move\" (DEFAULT) — WAN 2.2 Animate Move. Applies camera movement and motion from the source video to the reference image, bringing a still photo to life. Requires sourceImageIndex.\n• \"animate-replace\" — WAN 2.2 Animate Replace. Replaces the subject in the source video with the person/character from the reference image, keeping the video's background and motion. Requires sourceImageIndex.\n• \"canny\" — LTX-2.3 edge-detection control. Best for restyling while preserving exact composition and silhouettes (e.g. \"make this footage look like anime / oil painting / watercolor\"). Use for subjects with crisp edges — people, objects, graphics. Video-only; no reference image needed.\n• \"pose\" — LTX-2.3 skeletal tracking. Best for replacing a person while keeping their motion (e.g. \"turn this dancer into a robot\"). Image optional — if provided, controls appearance; otherwise the prompt drives appearance. Requires person-centric motion.\n• \"depth\" — LTX-2.3 depth-map control. Best for restyling scenes with perspective, camera movement, or volumetric content (landscapes, interiors, camera pans). Preserves 3D spatial layout rather than 2D edges; more forgiving than canny when edges are noisy. Video-only.\n• \"detailer\" — LTX-2.3 quality enhancement. Sharpens detail and texture WITHOUT restyling. The prompt must DESCRIBE THE ORIGINAL scene with quality qualifiers (sharp, clean, high-resolution) — never request content changes, new textures, or a new look. Pick this when the user asks to \"improve quality\", \"enhance\", \"upscale\", or \"sharpen\" without a creative transformation.\n• \"seedance-v2v\" — BytePlus Dreamina Seedance 2.0 video-to-video. Use only when the user explicitly asks for Seedance on the uploaded source video, such as Seedance Fast upscale, enhance, remaster, restyle, or transform. High-fidelity quality, native audio, time-coded scene control. Seedance V2V reads @Video1 holistically. Use it for restyling, motion transfer, extension, subject replacement, or scene transformation, and assign @Video1 a clear role such as source clip, camera movement, action timing, edit rhythm, or continuation anchor. Distinct from canny/depth/pose which use control-net constraints — Seedance treats the reference video holistically.\nCanny vs depth: canny preserves silhouettes and fine outlines — pick it for subject-led scenes and graphic restyles. Depth preserves 3D structure — pick it for scenes where the camera moves or spatial layout matters more than edge fidelity. Default: \"animate-move\"."
|
|
34
|
+
},
|
|
35
|
+
"negativePrompt": {
|
|
36
|
+
"type": "string",
|
|
37
|
+
"description": "Non-Seedance only. Optional negative prompt for LTX/Wan video-to-video models. Do not set when controlMode is seedance-v2v or videoModel is seedance2/seedance2-mini/seedance2-fast; rewrite user-provided Seedance avoid/ban/no-X requests as positive prompt instructions."
|
|
38
|
+
},
|
|
39
|
+
"videoModel": {
|
|
40
|
+
"type": "string",
|
|
41
|
+
"enum": [
|
|
42
|
+
"ltx23-v2v",
|
|
43
|
+
"wan22-animate",
|
|
44
|
+
"seedance2",
|
|
45
|
+
"seedance2-mini",
|
|
46
|
+
"seedance2-fast"
|
|
47
|
+
],
|
|
48
|
+
"description": "Model selector for this video-to-video request. Usually omit; controlMode chooses the non-Seedance model. For controlMode=\"seedance-v2v\", Seedance quality is selected only by model: use \"seedance2-mini\" for fast, lower-cost 720p Seedance V2V unless the user explicitly asks for legacy Fast, use \"seedance2-fast\" when the user asks for Seedance Fast / seedance-fast, and use \"seedance2\" for full/non-fast Seedance or 1080p/4K. Do not infer the Seedance model from Default Media Quality Fast/HQ/Pro or from 480p/720p resolution requests alone."
|
|
49
|
+
},
|
|
50
|
+
"generateAudio": {
|
|
51
|
+
"type": "boolean",
|
|
52
|
+
"description": "Seedance V2V only. Whether Seedance should generate/retain a native audio track. Omit by default; set false only when the user explicitly asks for silent output or no audio. Use only with controlMode=\"seedance-v2v\"."
|
|
53
|
+
},
|
|
54
|
+
"targetResolution": {
|
|
55
|
+
"type": "number",
|
|
56
|
+
"description": "Seedance V2V only. Short-side output resolution target in pixels. Use when the user asks for a bare named resolution such as \"480p\", \"720p\", \"1080p\", \"2160p\", or \"4K\" without exact dimensions. Seedance V2V full supports 4K; Seedance V2V Mini and Fast support 480p and 720p. Preserve the source video shape instead of forcing landscape pixels."
|
|
57
|
+
},
|
|
58
|
+
"sourceImageIndex": {
|
|
59
|
+
"type": "number",
|
|
60
|
+
"description": "Optional index of a reference image (0-based). Required for \"animate-move\" and \"animate-replace\". Optional for \"pose\" (controls appearance if provided). Ignored by \"canny\", \"depth\", and \"detailer\"."
|
|
61
|
+
},
|
|
62
|
+
"duration": {
|
|
63
|
+
"type": "number",
|
|
64
|
+
"description": "Output video duration in seconds. Range: 2-20 for WAN/LTX modes and 4-15 for controlMode=\"seedance-v2v\". If omitted, the tool matches the uploaded source video duration when available (capped to the selected model range); otherwise it falls back to 10s for WAN Animate Move/Replace and 5s for LTX-2.3/Seedance modes. For long stitched/bulk WAN Animate Move/Replace work with no explicit per-clip length, prefer about 10s clips rather than 5s chunks. Only pass this when the user explicitly requests a different length.",
|
|
65
|
+
"minimum": 2,
|
|
66
|
+
"maximum": 20
|
|
67
|
+
},
|
|
68
|
+
"numberOfVariations": {
|
|
69
|
+
"type": "number",
|
|
70
|
+
"description": "Number of video variations to generate (1-16). Default: 1.",
|
|
71
|
+
"minimum": 1,
|
|
72
|
+
"maximum": 16
|
|
73
|
+
}
|
|
74
|
+
},
|
|
75
|
+
"required": [
|
|
76
|
+
"prompt"
|
|
77
|
+
]
|
|
78
|
+
}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.sogni.ai/creative-agent/2026-04-27.1/workflows/durable-workflow-run.schema.json",
|
|
4
|
+
"title": "Creative agent durable workflow run contract",
|
|
5
|
+
"schemaVersion": "2026-04-27.1",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"properties": {
|
|
9
|
+
"workflowId": { "type": "string" },
|
|
10
|
+
"status": { "type": "string", "enum": ["queued", "running", "completed", "partial_failure", "waiting_for_user", "failed", "cancelled"] },
|
|
11
|
+
"backbone": {
|
|
12
|
+
"type": "object",
|
|
13
|
+
"additionalProperties": false,
|
|
14
|
+
"properties": {
|
|
15
|
+
"schemaVersion": { "type": "string" },
|
|
16
|
+
"modelKnowledgeVersion": { "type": "string" },
|
|
17
|
+
"routingPolicyVersion": { "type": "string" }
|
|
18
|
+
},
|
|
19
|
+
"required": ["schemaVersion", "modelKnowledgeVersion", "routingPolicyVersion"]
|
|
20
|
+
},
|
|
21
|
+
"title": { "type": "string" },
|
|
22
|
+
"input": { "type": "object", "additionalProperties": true },
|
|
23
|
+
"steps": {
|
|
24
|
+
"type": "array",
|
|
25
|
+
"minItems": 1,
|
|
26
|
+
"items": {
|
|
27
|
+
"type": "object",
|
|
28
|
+
"additionalProperties": false,
|
|
29
|
+
"properties": {
|
|
30
|
+
"id": { "type": "string" },
|
|
31
|
+
"sequence": { "type": "integer", "minimum": 0 },
|
|
32
|
+
"toolName": {
|
|
33
|
+
"type": "string",
|
|
34
|
+
"enum": [
|
|
35
|
+
"generate_image",
|
|
36
|
+
"generate_video",
|
|
37
|
+
"generate_music",
|
|
38
|
+
"edit_image",
|
|
39
|
+
"apply_style",
|
|
40
|
+
"restore_photo",
|
|
41
|
+
"refine_result",
|
|
42
|
+
"animate_photo",
|
|
43
|
+
"change_angle",
|
|
44
|
+
"video_to_video",
|
|
45
|
+
"stitch_video",
|
|
46
|
+
"orbit_video",
|
|
47
|
+
"dance_montage",
|
|
48
|
+
"sound_to_video",
|
|
49
|
+
"extend_video",
|
|
50
|
+
"replace_video_segment",
|
|
51
|
+
"overlay_video",
|
|
52
|
+
"add_subtitles",
|
|
53
|
+
"analyze_image",
|
|
54
|
+
"analyze_video",
|
|
55
|
+
"extract_metadata",
|
|
56
|
+
"ask_clarifying_question",
|
|
57
|
+
"finalize_response",
|
|
58
|
+
"create_asset_manifest",
|
|
59
|
+
"inspect_asset",
|
|
60
|
+
"label_asset",
|
|
61
|
+
"map_assets_for_model",
|
|
62
|
+
"validate_asset_references"
|
|
63
|
+
]
|
|
64
|
+
},
|
|
65
|
+
"arguments": { "type": "object", "additionalProperties": true },
|
|
66
|
+
"dependsOn": {
|
|
67
|
+
"type": "array",
|
|
68
|
+
"items": {
|
|
69
|
+
"type": "object",
|
|
70
|
+
"additionalProperties": false,
|
|
71
|
+
"properties": {
|
|
72
|
+
"sourceStepId": { "type": "string" },
|
|
73
|
+
"targetArgument": { "type": "string" },
|
|
74
|
+
"transform": {
|
|
75
|
+
"type": "string",
|
|
76
|
+
"enum": [
|
|
77
|
+
"artifact_url",
|
|
78
|
+
"artifact_data_uri",
|
|
79
|
+
"image_url",
|
|
80
|
+
"video_url",
|
|
81
|
+
"audio_url",
|
|
82
|
+
"image_index",
|
|
83
|
+
"video_index",
|
|
84
|
+
"audio_index",
|
|
85
|
+
"subtitle_cues",
|
|
86
|
+
"subtitle_srt",
|
|
87
|
+
"overlay_items",
|
|
88
|
+
"asset_ref"
|
|
89
|
+
]
|
|
90
|
+
},
|
|
91
|
+
"sourceArtifactId": { "type": "string" },
|
|
92
|
+
"sourceArtifactIndex": { "type": "integer", "minimum": 0 },
|
|
93
|
+
"mediaType": { "type": "string", "enum": ["image", "video", "audio"] },
|
|
94
|
+
"required": { "type": "boolean" }
|
|
95
|
+
},
|
|
96
|
+
"required": ["sourceStepId", "targetArgument", "transform"]
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
},
|
|
100
|
+
"required": ["id", "sequence", "toolName", "arguments"]
|
|
101
|
+
}
|
|
102
|
+
},
|
|
103
|
+
"events": {
|
|
104
|
+
"type": "array",
|
|
105
|
+
"items": { "type": "object", "additionalProperties": true }
|
|
106
|
+
},
|
|
107
|
+
"artifacts": {
|
|
108
|
+
"type": "array",
|
|
109
|
+
"items": { "type": "object", "additionalProperties": true }
|
|
110
|
+
},
|
|
111
|
+
"lease": {
|
|
112
|
+
"type": "object",
|
|
113
|
+
"additionalProperties": false,
|
|
114
|
+
"properties": {
|
|
115
|
+
"leaseId": { "type": "string" },
|
|
116
|
+
"ownerId": { "type": "string" },
|
|
117
|
+
"acquiredAt": { "type": "string", "format": "date-time" },
|
|
118
|
+
"heartbeatAt": { "type": "string", "format": "date-time" },
|
|
119
|
+
"expiresAt": { "type": "string", "format": "date-time" }
|
|
120
|
+
},
|
|
121
|
+
"required": ["leaseId", "ownerId", "acquiredAt", "heartbeatAt", "expiresAt"]
|
|
122
|
+
},
|
|
123
|
+
"recovery": {
|
|
124
|
+
"type": "object",
|
|
125
|
+
"additionalProperties": false,
|
|
126
|
+
"properties": {
|
|
127
|
+
"resumeCount": { "type": "integer", "minimum": 0 },
|
|
128
|
+
"lastResumeAt": { "type": "string", "format": "date-time" },
|
|
129
|
+
"lastRecoveredAt": { "type": "string", "format": "date-time" },
|
|
130
|
+
"reason": { "type": "string" }
|
|
131
|
+
},
|
|
132
|
+
"required": ["resumeCount"]
|
|
133
|
+
},
|
|
134
|
+
"quality": {
|
|
135
|
+
"type": "object",
|
|
136
|
+
"additionalProperties": true,
|
|
137
|
+
"properties": {
|
|
138
|
+
"postflightAudits": {
|
|
139
|
+
"type": "array",
|
|
140
|
+
"items": { "type": "object", "additionalProperties": true }
|
|
141
|
+
}
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
"timestamps": {
|
|
145
|
+
"type": "object",
|
|
146
|
+
"additionalProperties": false,
|
|
147
|
+
"properties": {
|
|
148
|
+
"createdAt": { "type": "string", "format": "date-time" },
|
|
149
|
+
"updatedAt": { "type": "string", "format": "date-time" },
|
|
150
|
+
"completedAt": { "type": "string", "format": "date-time" }
|
|
151
|
+
},
|
|
152
|
+
"required": ["createdAt", "updatedAt"]
|
|
153
|
+
}
|
|
154
|
+
},
|
|
155
|
+
"required": [
|
|
156
|
+
"workflowId",
|
|
157
|
+
"status",
|
|
158
|
+
"backbone",
|
|
159
|
+
"input",
|
|
160
|
+
"steps",
|
|
161
|
+
"events",
|
|
162
|
+
"artifacts",
|
|
163
|
+
"timestamps"
|
|
164
|
+
]
|
|
165
|
+
}
|
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://schemas.sogni.ai/creative-agent/2026-04-27.1/workflows/durable-workflow-step.schema.json",
|
|
4
|
+
"title": "Creative agent durable workflow step metadata",
|
|
5
|
+
"schemaVersion": "2026-04-27.1",
|
|
6
|
+
"type": "object",
|
|
7
|
+
"additionalProperties": false,
|
|
8
|
+
"properties": {
|
|
9
|
+
"id": { "type": "string" },
|
|
10
|
+
"workflowId": { "type": "string" },
|
|
11
|
+
"sequence": { "type": "integer", "minimum": 0 },
|
|
12
|
+
"status": { "type": "string", "enum": ["queued", "running", "completed", "partial_failure", "waiting_for_user", "failed", "cancelled"] },
|
|
13
|
+
"backbone": {
|
|
14
|
+
"type": "object",
|
|
15
|
+
"additionalProperties": false,
|
|
16
|
+
"properties": {
|
|
17
|
+
"schemaVersion": { "type": "string" },
|
|
18
|
+
"modelKnowledgeVersion": { "type": "string" },
|
|
19
|
+
"routingPolicyVersion": { "type": "string" }
|
|
20
|
+
},
|
|
21
|
+
"required": ["schemaVersion", "modelKnowledgeVersion", "routingPolicyVersion"]
|
|
22
|
+
},
|
|
23
|
+
"implementation": {
|
|
24
|
+
"type": "object",
|
|
25
|
+
"additionalProperties": false,
|
|
26
|
+
"properties": {
|
|
27
|
+
"runtime": { "type": "string", "enum": ["sogni-chat", "sogni-api", "sogni-client", "creative-agent", "other"] },
|
|
28
|
+
"version": { "type": "string" }
|
|
29
|
+
},
|
|
30
|
+
"required": ["runtime", "version"]
|
|
31
|
+
},
|
|
32
|
+
"tool": {
|
|
33
|
+
"type": "object",
|
|
34
|
+
"additionalProperties": false,
|
|
35
|
+
"properties": {
|
|
36
|
+
"name": { "type": "string" },
|
|
37
|
+
"schemaVersion": { "type": "string" }
|
|
38
|
+
},
|
|
39
|
+
"required": ["name", "schemaVersion"]
|
|
40
|
+
},
|
|
41
|
+
"input": {
|
|
42
|
+
"type": "object",
|
|
43
|
+
"additionalProperties": false,
|
|
44
|
+
"properties": {
|
|
45
|
+
"arguments": { "type": "object", "additionalProperties": true },
|
|
46
|
+
"normalizedArguments": { "type": "object", "additionalProperties": true }
|
|
47
|
+
},
|
|
48
|
+
"required": ["arguments", "normalizedArguments"]
|
|
49
|
+
},
|
|
50
|
+
"generation": {
|
|
51
|
+
"type": "object",
|
|
52
|
+
"additionalProperties": false,
|
|
53
|
+
"properties": {
|
|
54
|
+
"selectedModel": { "type": "string" },
|
|
55
|
+
"params": { "type": "object", "additionalProperties": true }
|
|
56
|
+
},
|
|
57
|
+
"required": ["selectedModel", "params"]
|
|
58
|
+
},
|
|
59
|
+
"routing": {
|
|
60
|
+
"type": "object",
|
|
61
|
+
"additionalProperties": false,
|
|
62
|
+
"properties": {
|
|
63
|
+
"selectedBy": { "type": "string" },
|
|
64
|
+
"reasons": { "type": "array", "items": { "type": "string" } },
|
|
65
|
+
"alternatives": {
|
|
66
|
+
"type": "array",
|
|
67
|
+
"items": {
|
|
68
|
+
"type": "object",
|
|
69
|
+
"additionalProperties": false,
|
|
70
|
+
"properties": {
|
|
71
|
+
"modelId": { "type": "string" },
|
|
72
|
+
"available": { "type": "boolean" },
|
|
73
|
+
"reason": { "type": "string" }
|
|
74
|
+
},
|
|
75
|
+
"required": ["modelId"]
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
},
|
|
79
|
+
"required": ["selectedBy", "reasons", "alternatives"]
|
|
80
|
+
},
|
|
81
|
+
"cost": {
|
|
82
|
+
"type": "object",
|
|
83
|
+
"additionalProperties": false,
|
|
84
|
+
"properties": {
|
|
85
|
+
"estimate": {
|
|
86
|
+
"type": "object",
|
|
87
|
+
"additionalProperties": false,
|
|
88
|
+
"properties": {
|
|
89
|
+
"costClass": { "type": "string" },
|
|
90
|
+
"unit": { "type": "string", "enum": ["image", "second", "operation"] },
|
|
91
|
+
"quantity": { "type": "number", "minimum": 0 }
|
|
92
|
+
},
|
|
93
|
+
"required": ["costClass", "unit", "quantity"]
|
|
94
|
+
},
|
|
95
|
+
"actual": { "type": "object", "additionalProperties": true }
|
|
96
|
+
},
|
|
97
|
+
"required": ["estimate"]
|
|
98
|
+
},
|
|
99
|
+
"artifacts": {
|
|
100
|
+
"type": "array",
|
|
101
|
+
"items": { "type": "object", "additionalProperties": true }
|
|
102
|
+
},
|
|
103
|
+
"idempotencyKey": { "type": "string" },
|
|
104
|
+
"retry": {
|
|
105
|
+
"type": "object",
|
|
106
|
+
"additionalProperties": false,
|
|
107
|
+
"properties": {
|
|
108
|
+
"count": { "type": "integer", "minimum": 0 },
|
|
109
|
+
"classification": { "type": "string", "enum": ["none", "transient", "permanent", "unknown"] }
|
|
110
|
+
},
|
|
111
|
+
"required": ["count", "classification"]
|
|
112
|
+
},
|
|
113
|
+
"timestamps": {
|
|
114
|
+
"type": "object",
|
|
115
|
+
"additionalProperties": false,
|
|
116
|
+
"properties": {
|
|
117
|
+
"createdAt": { "type": "string", "format": "date-time" },
|
|
118
|
+
"updatedAt": { "type": "string", "format": "date-time" },
|
|
119
|
+
"completedAt": { "type": "string", "format": "date-time" }
|
|
120
|
+
},
|
|
121
|
+
"required": ["createdAt", "updatedAt"]
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
"required": [
|
|
125
|
+
"id",
|
|
126
|
+
"workflowId",
|
|
127
|
+
"sequence",
|
|
128
|
+
"status",
|
|
129
|
+
"backbone",
|
|
130
|
+
"implementation",
|
|
131
|
+
"tool",
|
|
132
|
+
"input",
|
|
133
|
+
"generation",
|
|
134
|
+
"routing",
|
|
135
|
+
"cost",
|
|
136
|
+
"artifacts",
|
|
137
|
+
"idempotencyKey",
|
|
138
|
+
"retry",
|
|
139
|
+
"timestamps"
|
|
140
|
+
]
|
|
141
|
+
}
|
package/version.json
ADDED
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
{
|
|
2
|
+
"protocolVersion": "1.5.0",
|
|
3
|
+
"description": "Sogni protocol artifact version. SDKs may refuse to operate against a protocolVersion they were not built for. Bump the major when removing or renaming any schema / enum / manifest field; bump the minor when adding new optional fields or new tools; bump the patch for description / prose changes only."
|
|
4
|
+
}
|