@decartai/sdk 0.0.54 → 0.0.55

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.
@@ -82,16 +82,15 @@ interface VideoEditInputs {
82
82
  }
83
83
  /**
84
84
  * Model-specific input documentation for lucy-2-v2v.
85
- * Requires at least one of prompt or reference_image. Both can be provided together.
85
+ * Requires prompt (can be empty string). Optional reference_image can also be provided.
86
86
  */
87
87
  interface VideoEdit2Inputs {
88
88
  /**
89
- * Text description to use for the video editing.
90
- * At least one of prompt or reference_image must be provided.
89
+ * Text prompt for the video editing. Send an empty string if you want no text prompt.
91
90
  *
92
91
  * See our [Prompt Engineering](https://docs.platform.decart.ai/models/video/video-generation#prompt-engineering) guide for how to write prompt for Decart video models effectively.
93
92
  */
94
- prompt?: string;
93
+ prompt: string;
95
94
  /**
96
95
  * Video file to process.
97
96
  * Can be a File, Blob, ReadableStream, URL, or string URL.
@@ -99,7 +98,6 @@ interface VideoEdit2Inputs {
99
98
  data: FileInput;
100
99
  /**
101
100
  * Optional reference image to guide what to add to the video.
102
- * At least one of prompt or reference_image must be provided.
103
101
  * Can be a File, Blob, ReadableStream, URL, or string URL.
104
102
  */
105
103
  reference_image?: FileInput;
@@ -144,7 +144,7 @@ declare const modelInputSchemas: {
144
144
  enhance_prompt: z.ZodOptional<z.ZodBoolean>;
145
145
  }, z.core.$strip>;
146
146
  readonly "lucy-2-v2v": z.ZodObject<{
147
- prompt: z.ZodOptional<z.ZodString>;
147
+ prompt: z.ZodString;
148
148
  reference_image: z.ZodOptional<z.ZodUnion<readonly [z.ZodCustom<File, File>, z.ZodCustom<Blob, Blob>, z.ZodCustom<ReadableStream<unknown>, ReadableStream<unknown>>, z.ZodCustom<URL, URL>, z.ZodURL, z.ZodObject<{
149
149
  uri: z.ZodString;
150
150
  type: z.ZodString;
@@ -139,13 +139,13 @@ const modelInputSchemas = {
139
139
  enhance_prompt: z.boolean().optional().describe("Whether to enhance the prompt (only valid with text prompt, defaults to true on backend)")
140
140
  }).refine((data) => data.prompt !== void 0 !== (data.reference_image !== void 0), { message: "Must provide either 'prompt' or 'reference_image', but not both" }).refine((data) => !(data.reference_image !== void 0 && data.enhance_prompt !== void 0), { message: "'enhance_prompt' is only valid when using 'prompt', not 'reference_image'" }),
141
141
  "lucy-2-v2v": z.object({
142
- prompt: z.string().min(1).max(1e3).optional().describe("Text prompt for the video editing"),
142
+ prompt: z.string().max(1e3).describe("Text prompt for the video editing. Send an empty string if you want no text prompt."),
143
143
  reference_image: fileInputSchema.optional().describe("Optional reference image to guide the edit (File, Blob, ReadableStream, URL, or string URL)"),
144
144
  data: fileInputSchema.describe("Video file to process (File, Blob, ReadableStream, URL, or string URL)"),
145
145
  seed: z.number().optional().describe("The seed to use for the generation"),
146
146
  resolution: proV2vResolutionSchema,
147
147
  enhance_prompt: z.boolean().optional().describe("Whether to enhance the prompt")
148
- }).refine((data) => data.prompt !== void 0 || data.reference_image !== void 0, { message: "Must provide at least one of 'prompt' or 'reference_image'" })
148
+ })
149
149
  };
150
150
  const modelDefinitionSchema = z.object({
151
151
  name: z.string(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@decartai/sdk",
3
- "version": "0.0.54",
3
+ "version": "0.0.55",
4
4
  "description": "Decart's JavaScript SDK",
5
5
  "type": "module",
6
6
  "license": "MIT",