@agentmedia/schema 0.2.1 → 0.2.2

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 CHANGED
@@ -3,7 +3,7 @@
3
3
  Single source of truth for the [agent-media](https://agent-media.ai) platform — enums, Zod validation schemas, TypeScript types, and the generator registry.
4
4
 
5
5
  [![npm version](https://img.shields.io/npm/v/@agentmedia/schema)](https://www.npmjs.com/package/@agentmedia/schema)
6
- [![license](https://img.shields.io/npm/l/@agentmedia/schema)](https://github.com/gitroomhq/agent-media/blob/main/LICENSE)
6
+ [![license](https://img.shields.io/npm/l/@agentmedia/schema)](https://github.com/yuvalsuede/agent-media/blob/main/LICENSE)
7
7
 
8
8
  ## Why This Package Exists
9
9
 
@@ -40,7 +40,7 @@ import type { Tone, SubtitleStyle, Template } from '@agentmedia/schema';
40
40
  ### Zod Validation Schemas
41
41
 
42
42
  ```typescript
43
- import { CreateVideoSchema, SubtitleSchema, ProductReviewSchema } from '@agentmedia/schema';
43
+ import { CreateVideoSchema, SubtitleSchema, ProductReviewSchema, ProductActingSchema } from '@agentmedia/schema';
44
44
 
45
45
  // Validate API input
46
46
  const result = CreateVideoSchema.safeParse(requestBody);
@@ -55,7 +55,7 @@ if (!result.success) {
55
55
  import { GENERATORS, GENERATOR_IDS } from '@agentmedia/schema';
56
56
 
57
57
  // Each generator is a black box: inputs -> [generator] -> output
58
- console.log(GENERATOR_IDS); // ['ugc_video', 'product_review', 'subtitle']
58
+ console.log(GENERATOR_IDS); // ['ugc_video', 'product_review', 'subtitle', 'show_your_app', 'product_acting_ugc']
59
59
 
60
60
  // Access a generator's Zod input schema
61
61
  const schema = GENERATORS.ugc_video.inputSchema;
@@ -287,6 +287,81 @@ export declare const GENERATORS: {
287
287
  }>;
288
288
  readonly output: "video_url";
289
289
  };
290
+ readonly product_acting_ugc: {
291
+ readonly description: "Generate a product-in-hand UGC video from a product image and actor reference";
292
+ readonly inputSchema: import("zod").ZodEffects<import("zod").ZodObject<{
293
+ product_image_url: import("zod").ZodString;
294
+ actor_slug: import("zod").ZodString;
295
+ actor_variant_id: import("zod").ZodOptional<import("zod").ZodString>;
296
+ product_name: import("zod").ZodOptional<import("zod").ZodString>;
297
+ product_description: import("zod").ZodOptional<import("zod").ZodString>;
298
+ script: import("zod").ZodOptional<import("zod").ZodString>;
299
+ template: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodEnum<["product-in-hand", "mirror-selfie", "bathroom-reaction", "kitchen-counter", "car-selfie", "couch-review", "expert-interview", "product-closeup"]>>>;
300
+ acting_style: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodEnum<["raw-selfie", "shocked", "angry", "excited", "dramatic", "weird-hook", "casual-demo", "honest-review"]>>>;
301
+ visual_style: import("zod").ZodOptional<import("zod").ZodString>;
302
+ duration: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodEffects<import("zod").ZodNumber, number, number>>>;
303
+ subtitles: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodBoolean>>;
304
+ subtitle_style: import("zod").ZodDefault<import("zod").ZodOptional<import("zod").ZodEnum<["hormozi", "none"]>>>;
305
+ webhook_url: import("zod").ZodOptional<import("zod").ZodString>;
306
+ }, "strip", import("zod").ZodTypeAny, {
307
+ duration: number;
308
+ actor_slug: string;
309
+ template: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup";
310
+ product_image_url: string;
311
+ subtitle_style: "hormozi" | "none";
312
+ acting_style: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review";
313
+ subtitles: boolean;
314
+ script?: string | undefined;
315
+ webhook_url?: string | undefined;
316
+ actor_variant_id?: string | undefined;
317
+ product_name?: string | undefined;
318
+ product_description?: string | undefined;
319
+ visual_style?: string | undefined;
320
+ }, {
321
+ actor_slug: string;
322
+ product_image_url: string;
323
+ duration?: number | undefined;
324
+ script?: string | undefined;
325
+ template?: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup" | undefined;
326
+ webhook_url?: string | undefined;
327
+ subtitle_style?: "hormozi" | "none" | undefined;
328
+ actor_variant_id?: string | undefined;
329
+ product_name?: string | undefined;
330
+ product_description?: string | undefined;
331
+ acting_style?: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review" | undefined;
332
+ visual_style?: string | undefined;
333
+ subtitles?: boolean | undefined;
334
+ }>, {
335
+ duration: number;
336
+ actor_slug: string;
337
+ template: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup";
338
+ product_image_url: string;
339
+ subtitle_style: "hormozi" | "none";
340
+ acting_style: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review";
341
+ subtitles: boolean;
342
+ script?: string | undefined;
343
+ webhook_url?: string | undefined;
344
+ actor_variant_id?: string | undefined;
345
+ product_name?: string | undefined;
346
+ product_description?: string | undefined;
347
+ visual_style?: string | undefined;
348
+ }, {
349
+ actor_slug: string;
350
+ product_image_url: string;
351
+ duration?: number | undefined;
352
+ script?: string | undefined;
353
+ template?: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup" | undefined;
354
+ webhook_url?: string | undefined;
355
+ subtitle_style?: "hormozi" | "none" | undefined;
356
+ actor_variant_id?: string | undefined;
357
+ product_name?: string | undefined;
358
+ product_description?: string | undefined;
359
+ acting_style?: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review" | undefined;
360
+ visual_style?: string | undefined;
361
+ subtitles?: boolean | undefined;
362
+ }>;
363
+ readonly output: "video_url";
364
+ };
290
365
  };
291
366
  export type GeneratorId = keyof typeof GENERATORS;
292
367
  export declare const GENERATOR_IDS: GeneratorId[];
@@ -1 +1 @@
1
- {"version":3,"file":"generators.d.ts","sourceRoot":"","sources":["../src/generators.ts"],"names":[],"mappings":"AAYA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAqBb,CAAC;AAEX,MAAM,MAAM,WAAW,GAAG,MAAM,OAAO,UAAU,CAAC;AAElD,eAAO,MAAM,aAAa,EAA8B,WAAW,EAAE,CAAC"}
1
+ {"version":3,"file":"generators.d.ts","sourceRoot":"","sources":["../src/generators.ts"],"names":[],"mappings":"AAkBA,eAAO,MAAM,UAAU;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA0Bb,CAAC;AAEX,MAAM,MAAM,WAAW,GAAG,MAAM,OAAO,UAAU,CAAC;AAElD,eAAO,MAAM,aAAa,EAA8B,WAAW,EAAE,CAAC"}
@@ -6,7 +6,7 @@
6
6
  * contract and a predictable output. Users and integrations never see
7
7
  * internals (models, pipelines, rendering).
8
8
  */
9
- import { CreateVideoSchema, ProductReviewSchema, SubtitleSchema, ShowYourAppSchema } from './video.js';
9
+ import { CreateVideoSchema, ProductActingSchema, ProductReviewSchema, ShowYourAppSchema, SubtitleSchema, } from './video.js';
10
10
  export const GENERATORS = {
11
11
  ugc_video: {
12
12
  description: 'Generate a UGC-style video from a script or prompt',
@@ -28,6 +28,11 @@ export const GENERATORS = {
28
28
  inputSchema: ShowYourAppSchema,
29
29
  output: 'video_url',
30
30
  },
31
+ product_acting_ugc: {
32
+ description: 'Generate a product-in-hand UGC video from a product image and actor reference',
33
+ inputSchema: ProductActingSchema,
34
+ output: 'video_url',
35
+ },
31
36
  };
32
37
  export const GENERATOR_IDS = Object.keys(GENERATORS);
33
38
  //# sourceMappingURL=generators.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"generators.js","sourceRoot":"","sources":["../src/generators.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAE/D;;;;;;GAMG;AAEH,OAAO,EAAE,iBAAiB,EAAE,mBAAmB,EAAE,cAAc,EAAE,iBAAiB,EAAE,MAAM,YAAY,CAAC;AAEvG,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,SAAS,EAAE;QACT,WAAW,EAAE,oDAAoD;QACjE,WAAW,EAAE,iBAAiB;QAC9B,MAAM,EAAE,WAAoB;KAC7B;IACD,cAAc,EAAE;QACd,WAAW,EAAE,oDAAoD;QACjE,WAAW,EAAE,mBAAmB;QAChC,MAAM,EAAE,WAAoB;KAC7B;IACD,QAAQ,EAAE;QACR,WAAW,EAAE,2CAA2C;QACxD,WAAW,EAAE,cAAc;QAC3B,MAAM,EAAE,WAAoB;KAC7B;IACD,aAAa,EAAE;QACb,WAAW,EAAE,oEAAoE;QACjF,WAAW,EAAE,iBAAiB;QAC9B,MAAM,EAAE,WAAoB;KAC7B;CACO,CAAC;AAIX,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,IAAI,CAAC,UAAU,CAAkB,CAAC"}
1
+ {"version":3,"file":"generators.js","sourceRoot":"","sources":["../src/generators.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAE/D;;;;;;GAMG;AAEH,OAAO,EACL,iBAAiB,EACjB,mBAAmB,EACnB,mBAAmB,EACnB,iBAAiB,EACjB,cAAc,GACf,MAAM,YAAY,CAAC;AAEpB,MAAM,CAAC,MAAM,UAAU,GAAG;IACxB,SAAS,EAAE;QACT,WAAW,EAAE,oDAAoD;QACjE,WAAW,EAAE,iBAAiB;QAC9B,MAAM,EAAE,WAAoB;KAC7B;IACD,cAAc,EAAE;QACd,WAAW,EAAE,oDAAoD;QACjE,WAAW,EAAE,mBAAmB;QAChC,MAAM,EAAE,WAAoB;KAC7B;IACD,QAAQ,EAAE;QACR,WAAW,EAAE,2CAA2C;QACxD,WAAW,EAAE,cAAc;QAC3B,MAAM,EAAE,WAAoB;KAC7B;IACD,aAAa,EAAE;QACb,WAAW,EAAE,oEAAoE;QACjF,WAAW,EAAE,iBAAiB;QAC9B,MAAM,EAAE,WAAoB;KAC7B;IACD,kBAAkB,EAAE;QAClB,WAAW,EAAE,+EAA+E;QAC5F,WAAW,EAAE,mBAAmB;QAChC,MAAM,EAAE,WAAoB;KAC7B;CACO,CAAC;AAIX,MAAM,CAAC,MAAM,aAAa,GAAG,MAAM,CAAC,IAAI,CAAC,UAAU,CAAkB,CAAC"}
package/dist/video.d.ts CHANGED
@@ -409,4 +409,80 @@ export declare const ShowYourAppSchema: z.ZodEffects<z.ZodObject<{
409
409
  subtitle_style?: "hormozi" | "none" | undefined;
410
410
  }>;
411
411
  export type ShowYourAppInput = z.infer<typeof ShowYourAppSchema>;
412
+ export declare const PRODUCT_ACTING_WORDS_PER_SECOND = 3;
413
+ export declare const PRODUCT_ACTING_DURATIONS: readonly [5, 10, 15];
414
+ export declare const PRODUCT_ACTING_TEMPLATES: readonly ["product-in-hand", "mirror-selfie", "bathroom-reaction", "kitchen-counter", "car-selfie", "couch-review", "expert-interview", "product-closeup"];
415
+ export declare const PRODUCT_ACTING_STYLES: readonly ["raw-selfie", "shocked", "angry", "excited", "dramatic", "weird-hook", "casual-demo", "honest-review"];
416
+ export declare const ProductActingSchema: z.ZodEffects<z.ZodObject<{
417
+ product_image_url: z.ZodString;
418
+ actor_slug: z.ZodString;
419
+ actor_variant_id: z.ZodOptional<z.ZodString>;
420
+ product_name: z.ZodOptional<z.ZodString>;
421
+ product_description: z.ZodOptional<z.ZodString>;
422
+ script: z.ZodOptional<z.ZodString>;
423
+ template: z.ZodDefault<z.ZodOptional<z.ZodEnum<["product-in-hand", "mirror-selfie", "bathroom-reaction", "kitchen-counter", "car-selfie", "couch-review", "expert-interview", "product-closeup"]>>>;
424
+ acting_style: z.ZodDefault<z.ZodOptional<z.ZodEnum<["raw-selfie", "shocked", "angry", "excited", "dramatic", "weird-hook", "casual-demo", "honest-review"]>>>;
425
+ visual_style: z.ZodOptional<z.ZodString>;
426
+ duration: z.ZodDefault<z.ZodOptional<z.ZodEffects<z.ZodNumber, number, number>>>;
427
+ subtitles: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
428
+ subtitle_style: z.ZodDefault<z.ZodOptional<z.ZodEnum<["hormozi", "none"]>>>;
429
+ webhook_url: z.ZodOptional<z.ZodString>;
430
+ }, "strip", z.ZodTypeAny, {
431
+ duration: number;
432
+ actor_slug: string;
433
+ template: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup";
434
+ product_image_url: string;
435
+ subtitle_style: "hormozi" | "none";
436
+ acting_style: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review";
437
+ subtitles: boolean;
438
+ script?: string | undefined;
439
+ webhook_url?: string | undefined;
440
+ actor_variant_id?: string | undefined;
441
+ product_name?: string | undefined;
442
+ product_description?: string | undefined;
443
+ visual_style?: string | undefined;
444
+ }, {
445
+ actor_slug: string;
446
+ product_image_url: string;
447
+ duration?: number | undefined;
448
+ script?: string | undefined;
449
+ template?: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup" | undefined;
450
+ webhook_url?: string | undefined;
451
+ subtitle_style?: "hormozi" | "none" | undefined;
452
+ actor_variant_id?: string | undefined;
453
+ product_name?: string | undefined;
454
+ product_description?: string | undefined;
455
+ acting_style?: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review" | undefined;
456
+ visual_style?: string | undefined;
457
+ subtitles?: boolean | undefined;
458
+ }>, {
459
+ duration: number;
460
+ actor_slug: string;
461
+ template: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup";
462
+ product_image_url: string;
463
+ subtitle_style: "hormozi" | "none";
464
+ acting_style: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review";
465
+ subtitles: boolean;
466
+ script?: string | undefined;
467
+ webhook_url?: string | undefined;
468
+ actor_variant_id?: string | undefined;
469
+ product_name?: string | undefined;
470
+ product_description?: string | undefined;
471
+ visual_style?: string | undefined;
472
+ }, {
473
+ actor_slug: string;
474
+ product_image_url: string;
475
+ duration?: number | undefined;
476
+ script?: string | undefined;
477
+ template?: "product-in-hand" | "mirror-selfie" | "bathroom-reaction" | "kitchen-counter" | "car-selfie" | "couch-review" | "expert-interview" | "product-closeup" | undefined;
478
+ webhook_url?: string | undefined;
479
+ subtitle_style?: "hormozi" | "none" | undefined;
480
+ actor_variant_id?: string | undefined;
481
+ product_name?: string | undefined;
482
+ product_description?: string | undefined;
483
+ acting_style?: "dramatic" | "raw-selfie" | "shocked" | "angry" | "excited" | "weird-hook" | "casual-demo" | "honest-review" | undefined;
484
+ visual_style?: string | undefined;
485
+ subtitles?: boolean | undefined;
486
+ }>;
487
+ export type ProductActingInput = z.infer<typeof ProductActingSchema>;
412
488
  //# sourceMappingURL=video.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"video.d.ts","sourceRoot":"","sources":["../src/video.ts"],"names":[],"mappings":"AAEA;;;;;;;;;GASG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAIxB,eAAO,MAAM,SAAS,sBAAuB,CAAC;AAC9C,MAAM,MAAM,QAAQ,GAAG,CAAC,OAAO,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC;AAElD,eAAO,MAAM,KAAK,yDAA0D,CAAC;AAC7E,MAAM,MAAM,IAAI,GAAG,CAAC,OAAO,KAAK,CAAC,CAAC,MAAM,CAAC,CAAC;AAE1C,eAAO,MAAM,YAAY,oEAAqE,CAAC;AAC/F,MAAM,MAAM,UAAU,GAAG,CAAC,OAAO,YAAY,CAAC,CAAC,MAAM,CAAC,CAAC;AAEvD,eAAO,MAAM,eAAe,qLAIlB,CAAC;AACX,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,eAAe,CAAC,CAAC,MAAM,CAAC,CAAC;AAE7D,eAAO,MAAM,aAAa,kCAAmC,CAAC;AAC9D,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,aAAa,CAAC,CAAC,MAAM,CAAC,CAAC;AAEzD;;;;GAIG;AACH,eAAO,MAAM,WAAW,oCAAqC,CAAC;AAC9D,MAAM,MAAM,SAAS,GAAG,CAAC,OAAO,WAAW,CAAC,CAAC,MAAM,CAAC,CAAC;AAErD,eAAO,MAAM,SAAS,wIAGZ,CAAC;AACX,MAAM,MAAM,QAAQ,GAAG,CAAC,OAAO,SAAS,CAAC,CAAC,MAAM,CAAC,CAAC;AAElD,eAAO,MAAM,MAAM,gEAAiE,CAAC;AACrF,MAAM,MAAM,KAAK,GAAG,CAAC,OAAO,MAAM,CAAC,CAAC,MAAM,CAAC,CAAC;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;WAmC5B,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAEjE,eAAO,MAAM,cAAc;;;;;;;;;EAGzB,CAAC;AAEH,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,cAAc,CAAC,CAAC;AAE3D,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;EAS9B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAErE,eAAO,MAAM,8BAA8B,IAAI,CAAC;AAChD,eAAO,MAAM,uBAAuB,sBAAuB,CAAC;AAE5D,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAqB5B,CAAC;AAEH,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,iBAAiB,CAAC,CAAC;AAEjE,eAAO,MAAM,+BAA+B,IAAI,CAAC;AACjD,eAAO,MAAM,wBAAwB,sBAAuB,CAAC;AAC7D,eAAO,MAAM,wBAAwB,4JAS3B,CAAC;AACX,eAAO,MAAM,qBAAqB,kHASxB,CAAC;AAEX,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAuC9B,CAAC;AAEH,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC"}
package/dist/video.js CHANGED
@@ -194,4 +194,62 @@ export const ShowYourAppSchema = z.object({
194
194
  });
195
195
  }
196
196
  });
197
+ export const PRODUCT_ACTING_WORDS_PER_SECOND = 3;
198
+ export const PRODUCT_ACTING_DURATIONS = [5, 10, 15];
199
+ export const PRODUCT_ACTING_TEMPLATES = [
200
+ 'product-in-hand',
201
+ 'mirror-selfie',
202
+ 'bathroom-reaction',
203
+ 'kitchen-counter',
204
+ 'car-selfie',
205
+ 'couch-review',
206
+ 'expert-interview',
207
+ 'product-closeup',
208
+ ];
209
+ export const PRODUCT_ACTING_STYLES = [
210
+ 'raw-selfie',
211
+ 'shocked',
212
+ 'angry',
213
+ 'excited',
214
+ 'dramatic',
215
+ 'weird-hook',
216
+ 'casual-demo',
217
+ 'honest-review',
218
+ ];
219
+ export const ProductActingSchema = z.object({
220
+ product_image_url: z.string().url().describe('Public URL of the product image to place in the actor scene. PNG, JPEG, or WebP recommended.'),
221
+ actor_slug: z.string().min(1).max(100).describe('Actor slug from GET /v1/actors. This actor is used as the creator reference.'),
222
+ actor_variant_id: z.string().uuid().optional().describe('Optional actor variant UUID for a specific outfit, framing, expression, or background.'),
223
+ product_name: z.string().min(1).max(120).optional().describe('Optional product name used for prompt/script context.'),
224
+ product_description: z.string().min(1).max(1000).optional().describe('Product context used to generate a short script when script is omitted. Required when script is omitted.'),
225
+ script: z.string().min(5).max(3000).optional().describe('Exact words the actor should say. If omitted, the API generates a short script from product_description.'),
226
+ template: z.enum(PRODUCT_ACTING_TEMPLATES).optional().default('product-in-hand').describe('UGC scenario template for the generated frame and motion.'),
227
+ acting_style: z.enum(PRODUCT_ACTING_STYLES).optional().default('raw-selfie').describe('Acting energy and delivery style.'),
228
+ visual_style: z.string().max(200).optional().describe('Extra camera, pose, environment, or framing direction.'),
229
+ duration: z.number().refine((v) => PRODUCT_ACTING_DURATIONS.includes(v), { message: 'duration must be 5, 10, or 15' }).optional().default(5).describe('Video duration in seconds. Valid values: 5, 10, or 15.'),
230
+ subtitles: z.boolean().optional().default(true).describe('Whether to burn word-level synced subtitles into the final video.'),
231
+ subtitle_style: z.enum(['hormozi', 'none']).optional().default('hormozi').describe('Subtitle style. Use none to disable subtitle rendering.'),
232
+ webhook_url: z.string().url().optional().describe('HTTPS URL to receive a callback when the job completes or fails.'),
233
+ }).superRefine((val, ctx) => {
234
+ if (!val.script && !val.product_description) {
235
+ ctx.addIssue({
236
+ code: z.ZodIssueCode.custom,
237
+ path: ['product_description'],
238
+ message: 'Either script or product_description is required',
239
+ });
240
+ return;
241
+ }
242
+ if (!val.script)
243
+ return;
244
+ const duration = val.duration ?? 5;
245
+ const maxWords = duration * PRODUCT_ACTING_WORDS_PER_SECOND;
246
+ const wordCount = val.script.trim().split(/\s+/).filter(Boolean).length;
247
+ if (wordCount > maxWords) {
248
+ ctx.addIssue({
249
+ code: z.ZodIssueCode.custom,
250
+ path: ['script'],
251
+ message: `Script has ${wordCount} words; max ${maxWords} for ${duration}s at ${PRODUCT_ACTING_WORDS_PER_SECOND} words/sec`,
252
+ });
253
+ }
254
+ });
197
255
  //# sourceMappingURL=video.js.map
package/dist/video.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"video.js","sourceRoot":"","sources":["../src/video.ts"],"names":[],"mappings":"AAAA,+DAA+D;AAE/D;;;;;;;;;GASG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,+EAA+E;AAE/E,MAAM,CAAC,MAAM,SAAS,GAAG,CAAC,CAAC,EAAE,EAAE,EAAE,EAAE,CAAU,CAAC;AAG9C,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,WAAW,EAAE,MAAM,EAAE,WAAW,EAAE,UAAU,CAAU,CAAC;AAG7E,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,UAAU,EAAE,QAAQ,CAAU,CAAC;AAG/F,MAAM,CAAC,MAAM,eAAe,GAAG;IAC7B,SAAS,EAAE,SAAS,EAAE,MAAM,EAAE,SAAS,EAAE,OAAO;IAChD,QAAQ,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,WAAW;IACpD,QAAQ,EAAE,QAAQ,EAA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.2.1",
3
+ "version": "0.2.2",
4
4
  "description": "Type-safe schema definitions for AI UGC video generation — enums, Zod validation, and generator registry. Single source of truth for the agent-media platform.",
5
5
  "type": "module",
6
6
  "license": "Apache-2.0",
7
7
  "homepage": "https://agent-media.ai/docs/api-reference",
8
8
  "repository": {
9
9
  "type": "git",
10
- "url": "git+https://github.com/gitroomhq/agent-media.git",
10
+ "url": "git+https://github.com/yuvalsuede/agent-media.git",
11
11
  "directory": "packages/schema"
12
12
  },
13
13
  "keywords": [
14
- "ugc",
15
- "video-generation",
16
- "ai",
17
- "schema",
18
- "zod",
19
- "validation",
20
- "typescript",
21
- "sdk",
22
- "developer-tools",
23
- "text-to-video",
24
- "talking-head",
25
- "openapi",
26
- "mcp",
27
- "agent-media"
14
+ "ugc", "video-generation", "ai", "schema", "zod", "validation",
15
+ "typescript", "sdk", "developer-tools", "text-to-video", "talking-head",
16
+ "product-video", "product-ugc", "openapi", "mcp", "agent-media"
28
17
  ],
29
- "publishConfig": {
30
- "access": "public"
31
- },
18
+ "publishConfig": { "access": "public" },
32
19
  "main": "./dist/index.js",
33
20
  "types": "./dist/index.d.ts",
34
21
  "exports": {
@@ -37,6 +24,15 @@
37
24
  "import": "./dist/index.js"
38
25
  }
39
26
  },
27
+ "scripts": {
28
+ "build": "tsc",
29
+ "typecheck": "tsc --noEmit",
30
+ "test": "vitest run",
31
+ "generate:edge-schema": "tsx scripts/generate-edge-schema.ts",
32
+ "generate:openapi": "tsx scripts/generate-openapi.ts",
33
+ "check:spec": "tsx scripts/check-spec-freshness.ts",
34
+ "check:sdk-types": "npx openapi-typescript ../../generated/openapi.json -o ../../generated/api-types.d.ts && echo '✓ SDK types generated'"
35
+ },
40
36
  "dependencies": {
41
37
  "zod": "^3.23.0",
42
38
  "zod-to-json-schema": "^3.25.2"
@@ -46,14 +42,5 @@
46
42
  "tsx": "^4.19.0",
47
43
  "typescript": "^5.7.3",
48
44
  "vitest": "^3.1.0"
49
- },
50
- "scripts": {
51
- "build": "tsc",
52
- "typecheck": "tsc --noEmit",
53
- "test": "vitest run",
54
- "generate:edge-schema": "tsx scripts/generate-edge-schema.ts",
55
- "generate:openapi": "tsx scripts/generate-openapi.ts",
56
- "check:spec": "tsx scripts/check-spec-freshness.ts",
57
- "check:sdk-types": "npx openapi-typescript generated/openapi.json -o generated/api-types.d.ts && echo '✓ SDK types generated'"
58
45
  }
59
- }
46
+ }
@@ -44,6 +44,16 @@ const FIELD_DESCRIPTIONS: Record<string, string> = {
44
44
  webhook_url: 'URL to receive a POST callback when the job completes or fails.',
45
45
  video_url: 'URL of the video to add subtitles to.',
46
46
  angle: 'Review angle/perspective.',
47
+ product_image_url: 'Public URL of the product image to place in the actor scene. PNG, JPEG, or WebP recommended.',
48
+ actor_variant_id: 'Optional actor variant UUID for a specific outfit, framing, expression, or background.',
49
+ product_name: 'Optional product name used for prompt/script context.',
50
+ product_description: 'Product context used to generate a short script when script is omitted.',
51
+ duration: 'Video duration in seconds. Must be 5, 10, or 15.',
52
+ subtitles: 'Whether to burn word-level synced subtitles into the final video.',
53
+ subtitle_style: 'Subtitle style. Use "none" to disable subtitle rendering.',
54
+ template: 'Product Acting UGC scenario template.',
55
+ acting_style: 'Product Acting UGC delivery style.',
56
+ visual_style: 'Extra camera, pose, environment, or framing direction.',
47
57
  };
48
58
 
49
59
  // ── Build spec ──────────────────────────────────────────────────────────────
@@ -100,6 +110,20 @@ for (const [id, gen] of Object.entries(GENERATORS)) {
100
110
  product_url: 'https://example.com/product',
101
111
  angle: 'honest',
102
112
  actor_slug: 'marcus',
113
+ } : id === 'show_your_app' ? {
114
+ app_screenshot_url: 'https://cdn.example.com/my-app.png',
115
+ script: 'You really need to try this',
116
+ duration: 5,
117
+ subtitle_style: 'hormozi',
118
+ } : id === 'product_acting_ugc' ? {
119
+ product_image_url: 'https://cdn.example.com/perfume.png',
120
+ actor_slug: 'sarah',
121
+ product_name: 'Rose Noir',
122
+ product_description: 'Premium rose perfume with a warm vanilla dry-down.',
123
+ template: 'product-in-hand',
124
+ acting_style: 'honest-review',
125
+ duration: 5,
126
+ subtitle_style: 'hormozi',
103
127
  } : undefined,
104
128
  },
105
129
  },
@@ -108,7 +132,7 @@ for (const [id, gen] of Object.entries(GENERATORS)) {
108
132
  {
109
133
  lang: 'curl',
110
134
  label: 'cURL',
111
- source: `curl -X POST https://api.agent-media.ai/v1/generate/ugc_video \\
135
+ source: `curl -X POST https://api-v2-production-2f24.up.railway.app/v1/generate/ugc_video \\
112
136
  -H "Authorization: Bearer ma_YOUR_KEY" \\
113
137
  -H "Content-Type: application/json" \\
114
138
  -d '{
@@ -296,7 +320,7 @@ Video generation is async. POST to /v1/generate/* returns a job_id immediately.
296
320
  termsOfService: 'https://agent-media.ai/terms',
297
321
  },
298
322
  servers: [
299
- { url: 'https://api.agent-media.ai', description: 'Production' },
323
+ { url: 'https://api-v2-production-2f24.up.railway.app', description: 'Production' },
300
324
  ],
301
325
  paths,
302
326
  components: {
package/src/generators.ts CHANGED
@@ -8,7 +8,13 @@
8
8
  * internals (models, pipelines, rendering).
9
9
  */
10
10
 
11
- import { CreateVideoSchema, ProductReviewSchema, SubtitleSchema, ShowYourAppSchema } from './video.js';
11
+ import {
12
+ CreateVideoSchema,
13
+ ProductActingSchema,
14
+ ProductReviewSchema,
15
+ ShowYourAppSchema,
16
+ SubtitleSchema,
17
+ } from './video.js';
12
18
 
13
19
  export const GENERATORS = {
14
20
  ugc_video: {
@@ -31,6 +37,11 @@ export const GENERATORS = {
31
37
  inputSchema: ShowYourAppSchema,
32
38
  output: 'video_url' as const,
33
39
  },
40
+ product_acting_ugc: {
41
+ description: 'Generate a product-in-hand UGC video from a product image and actor reference',
42
+ inputSchema: ProductActingSchema,
43
+ output: 'video_url' as const,
44
+ },
34
45
  } as const;
35
46
 
36
47
  export type GeneratorId = keyof typeof GENERATORS;
package/src/video.ts CHANGED
@@ -261,3 +261,69 @@ export const ShowYourAppSchema = z.object({
261
261
  });
262
262
 
263
263
  export type ShowYourAppInput = z.infer<typeof ShowYourAppSchema>;
264
+
265
+ export const PRODUCT_ACTING_WORDS_PER_SECOND = 3;
266
+ export const PRODUCT_ACTING_DURATIONS = [5, 10, 15] as const;
267
+ export const PRODUCT_ACTING_TEMPLATES = [
268
+ 'product-in-hand',
269
+ 'mirror-selfie',
270
+ 'bathroom-reaction',
271
+ 'kitchen-counter',
272
+ 'car-selfie',
273
+ 'couch-review',
274
+ 'expert-interview',
275
+ 'product-closeup',
276
+ ] as const;
277
+ export const PRODUCT_ACTING_STYLES = [
278
+ 'raw-selfie',
279
+ 'shocked',
280
+ 'angry',
281
+ 'excited',
282
+ 'dramatic',
283
+ 'weird-hook',
284
+ 'casual-demo',
285
+ 'honest-review',
286
+ ] as const;
287
+
288
+ export const ProductActingSchema = z.object({
289
+ product_image_url: z.string().url().describe('Public URL of the product image to place in the actor scene. PNG, JPEG, or WebP recommended.'),
290
+ actor_slug: z.string().min(1).max(100).describe('Actor slug from GET /v1/actors. This actor is used as the creator reference.'),
291
+ actor_variant_id: z.string().uuid().optional().describe('Optional actor variant UUID for a specific outfit, framing, expression, or background.'),
292
+ product_name: z.string().min(1).max(120).optional().describe('Optional product name used for prompt/script context.'),
293
+ product_description: z.string().min(1).max(1000).optional().describe('Product context used to generate a short script when script is omitted. Required when script is omitted.'),
294
+ script: z.string().min(5).max(3000).optional().describe('Exact words the actor should say. If omitted, the API generates a short script from product_description.'),
295
+ template: z.enum(PRODUCT_ACTING_TEMPLATES).optional().default('product-in-hand').describe('UGC scenario template for the generated frame and motion.'),
296
+ acting_style: z.enum(PRODUCT_ACTING_STYLES).optional().default('raw-selfie').describe('Acting energy and delivery style.'),
297
+ visual_style: z.string().max(200).optional().describe('Extra camera, pose, environment, or framing direction.'),
298
+ duration: z.number().refine(
299
+ (v) => (PRODUCT_ACTING_DURATIONS as readonly number[]).includes(v),
300
+ { message: 'duration must be 5, 10, or 15' },
301
+ ).optional().default(5).describe('Video duration in seconds. Valid values: 5, 10, or 15.'),
302
+ subtitles: z.boolean().optional().default(true).describe('Whether to burn word-level synced subtitles into the final video.'),
303
+ subtitle_style: z.enum(['hormozi', 'none']).optional().default('hormozi').describe('Subtitle style. Use none to disable subtitle rendering.'),
304
+ webhook_url: z.string().url().optional().describe('HTTPS URL to receive a callback when the job completes or fails.'),
305
+ }).superRefine((val, ctx) => {
306
+ if (!val.script && !val.product_description) {
307
+ ctx.addIssue({
308
+ code: z.ZodIssueCode.custom,
309
+ path: ['product_description'],
310
+ message: 'Either script or product_description is required',
311
+ });
312
+ return;
313
+ }
314
+
315
+ if (!val.script) return;
316
+
317
+ const duration = val.duration ?? 5;
318
+ const maxWords = duration * PRODUCT_ACTING_WORDS_PER_SECOND;
319
+ const wordCount = val.script.trim().split(/\s+/).filter(Boolean).length;
320
+ if (wordCount > maxWords) {
321
+ ctx.addIssue({
322
+ code: z.ZodIssueCode.custom,
323
+ path: ['script'],
324
+ message: `Script has ${wordCount} words; max ${maxWords} for ${duration}s at ${PRODUCT_ACTING_WORDS_PER_SECOND} words/sec`,
325
+ });
326
+ }
327
+ });
328
+
329
+ export type ProductActingInput = z.infer<typeof ProductActingSchema>;
package/LICENSE DELETED
@@ -1,199 +0,0 @@
1
-
2
- Apache License
3
- Version 2.0, January 2004
4
- http://www.apache.org/licenses/
5
-
6
- TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
7
-
8
- 1. Definitions.
9
-
10
- "License" shall mean the terms and conditions for use, reproduction,
11
- and distribution as defined by Sections 1 through 9 of this document.
12
-
13
- "Licensor" shall mean the copyright owner or entity authorized by
14
- the copyright owner that is granting the License.
15
-
16
- "Legal Entity" shall mean the union of the acting entity and all
17
- other entities that control, are controlled by, or are under common
18
- control with that entity. For the purposes of this definition,
19
- "control" means (i) the power, direct or indirect, to cause the
20
- direction or management of such entity, whether by contract or
21
- otherwise, or (ii) ownership of fifty percent (50%) or more of the
22
- outstanding shares, or (iii) beneficial ownership of such entity.
23
-
24
- "You" (or "Your") shall mean an individual or Legal Entity
25
- exercising permissions granted by this License.
26
-
27
- "Source" form shall mean the preferred form for making modifications,
28
- including but not limited to software source code, documentation
29
- source, and configuration files.
30
-
31
- "Object" form shall mean any form resulting from mechanical
32
- transformation or translation of a Source form, including but
33
- not limited to compiled object code, generated documentation,
34
- and conversions to other media types.
35
-
36
- "Work" shall mean the work of authorship, whether in Source or
37
- Object form, made available under the License, as indicated by a
38
- copyright notice that is included in or attached to the work
39
- (an example is provided in the Appendix below).
40
-
41
- "Derivative Works" shall mean any work, whether in Source or Object
42
- form, that is based on (or derived from) the Work and for which the
43
- editorial revisions, annotations, elaborations, or other modifications
44
- represent, as a whole, an original work of authorship. For the purposes
45
- of this License, Derivative Works shall not include works that remain
46
- separable from, or merely link (or bind by name) to the interfaces of,
47
- the Work and Derivative Works thereof.
48
-
49
- "Contribution" shall mean any work of authorship, including
50
- the original version of the Work and any modifications or additions
51
- to that Work or Derivative Works thereof, that is intentionally
52
- submitted to the Licensor for inclusion in the Work by the copyright owner
53
- or by an individual or Legal Entity authorized to submit on behalf of
54
- the copyright owner. For the purposes of this definition, "submitted"
55
- means any form of electronic, verbal, or written communication sent
56
- to the Licensor or its representatives, including but not limited to
57
- communication on electronic mailing lists, source code control systems,
58
- and issue tracking systems that are managed by, or on behalf of, the
59
- Licensor for the purpose of discussing and improving the Work, but
60
- excluding communication that is conspicuously marked or otherwise
61
- designated in writing by the copyright owner as "Not a Contribution."
62
-
63
- "Contributor" shall mean Licensor and any individual or Legal Entity
64
- on behalf of whom a Contribution has been received by the Licensor and
65
- subsequently incorporated within the Work.
66
-
67
- 2. Grant of Copyright License. Subject to the terms and conditions of
68
- this License, each Contributor hereby grants to You a perpetual,
69
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
70
- copyright license to reproduce, prepare Derivative Works of,
71
- publicly display, publicly perform, sublicense, and distribute the
72
- Work and such Derivative Works in Source or Object form.
73
-
74
- 3. Grant of Patent License. Subject to the terms and conditions of
75
- this License, each Contributor hereby grants to You a perpetual,
76
- worldwide, non-exclusive, no-charge, royalty-free, irrevocable
77
- (except as stated in this section) patent license to make, have made,
78
- use, offer to sell, sell, import, and otherwise transfer the Work,
79
- where such license applies only to those patent claims licensable
80
- by such Contributor that are necessarily infringed by their
81
- Contribution(s) alone or by combination of their Contribution(s)
82
- with the Work to which such Contribution(s) was submitted. If You
83
- institute patent litigation against any entity (including a
84
- cross-claim or counterclaim in a lawsuit) alleging that the Work
85
- or a Contribution incorporated within the Work constitutes direct
86
- or contributory patent infringement, then any patent licenses
87
- granted to You under this License for that Work shall terminate
88
- as of the date such litigation is filed.
89
-
90
- 4. Redistribution. You may reproduce and distribute copies of the
91
- Work or Derivative Works thereof in any medium, with or without
92
- modifications, and in Source or Object form, provided that You
93
- meet the following conditions:
94
-
95
- (a) You must give any other recipients of the Work or
96
- Derivative Works a copy of this License; and
97
-
98
- (b) You must cause any modified files to carry prominent notices
99
- stating that You changed the files; and
100
-
101
- (c) You must retain, in the Source form of any Derivative Works
102
- that You distribute, all copyright, patent, trademark, and
103
- attribution notices from the Source form of the Work,
104
- excluding those notices that do not pertain to any part of
105
- the Derivative Works; and
106
-
107
- (d) If the Work includes a "NOTICE" text file as part of its
108
- distribution, then any Derivative Works that You distribute must
109
- include a readable copy of the attribution notices contained
110
- within such NOTICE file, excluding any notices that do not
111
- pertain to any part of the Derivative Works, in at least one
112
- of the following places: within a NOTICE text file distributed
113
- as part of the Derivative Works; within the Source form or
114
- documentation, if provided along with the Derivative Works; or,
115
- within a display generated by the Derivative Works, if and
116
- wherever such third-party notices normally appear. The contents
117
- of the NOTICE file are for informational purposes only and
118
- do not modify the License. You may add Your own attribution
119
- notices within Derivative Works that You distribute, alongside
120
- or as an addendum to the NOTICE text from the Work, provided
121
- that such additional attribution notices cannot be construed
122
- as modifying the License.
123
-
124
- You may add Your own copyright statement to Your modifications and
125
- may provide additional or different license terms and conditions
126
- for use, reproduction, or distribution of Your modifications, or
127
- for any such Derivative Works as a whole, provided Your use,
128
- reproduction, and distribution of the Work otherwise complies with
129
- the conditions stated in this License.
130
-
131
- 5. Submission of Contributions. Unless You explicitly state otherwise,
132
- any Contribution intentionally submitted for inclusion in the Work
133
- by You to the Licensor shall be under the terms and conditions of
134
- this License, without any additional terms or conditions.
135
- Notwithstanding the above, nothing herein shall supersede or modify
136
- the terms of any separate license agreement you may have executed
137
- with Licensor regarding such Contributions.
138
-
139
- 6. Trademarks. This License does not grant permission to use the trade
140
- names, trademarks, service marks, or product names of the Licensor,
141
- except as required for reasonable and customary use in describing the
142
- origin of the Work and reproducing the content of the NOTICE file.
143
-
144
- 7. Disclaimer of Warranty. Unless required by applicable law or
145
- agreed to in writing, Licensor provides the Work (and each
146
- Contributor provides its Contributions) on an "AS IS" BASIS,
147
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
148
- implied, including, without limitation, any warranties or conditions
149
- of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
150
- PARTICULAR PURPOSE. You are solely responsible for determining the
151
- appropriateness of using or redistributing the Work and assume any
152
- risks associated with Your exercise of permissions under this License.
153
-
154
- 8. Limitation of Liability. In no event and under no legal theory,
155
- whether in tort (including negligence), contract, or otherwise,
156
- unless required by applicable law (such as deliberate and grossly
157
- negligent acts) or agreed to in writing, shall any Contributor be
158
- liable to You for damages, including any direct, indirect, special,
159
- incidental, or consequential damages of any character arising as a
160
- result of this License or out of the use or inability to use the
161
- Work (including but not limited to damages for loss of goodwill,
162
- work stoppage, computer failure or malfunction, or any and all
163
- other commercial damages or losses), even if such Contributor
164
- has been advised of the possibility of such damages.
165
-
166
- 9. Accepting Warranty or Additional Liability. While redistributing
167
- the Work or Derivative Works thereof, You may choose to offer,
168
- and charge a fee for, acceptance of support, warranty, indemnity,
169
- or other liability obligations and/or rights consistent with this
170
- License. However, in accepting such obligations, You may act only
171
- on Your own behalf and on Your sole responsibility, not on behalf
172
- of any other Contributor, and only if You agree to indemnify,
173
- defend, and hold each Contributor harmless for any liability
174
- incurred by, or claims asserted against, such Contributor by reason
175
- of your accepting any such warranty or additional liability.
176
-
177
- END OF TERMS AND CONDITIONS
178
-
179
- APPENDIX: How to apply the Apache License to your work.
180
-
181
- To apply the Apache License to your work, attach the following
182
- boilerplate notice, with the fields enclosed by brackets "[]"
183
- replaced with your own identifying information. (Don't include
184
- the brackets!) The text should be enclosed in the appropriate
185
- comment syntax for the file format.
186
-
187
- Copyright 2026 agent-media contributors
188
-
189
- Licensed under the Apache License, Version 2.0 (the "License");
190
- you may not use this file except in compliance with the License.
191
- You may obtain a copy of the License at
192
-
193
- http://www.apache.org/licenses/LICENSE-2.0
194
-
195
- Unless required by applicable law or agreed to in writing, software
196
- distributed under the License is distributed on an "AS IS" BASIS,
197
- WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
198
- See the License for the specific language governing permissions and
199
- limitations under the License.