@purpleschool/gptbot 0.8.46 → 0.8.47

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.
@@ -13,7 +13,7 @@ var RetryImageEditorJobCommand;
13
13
  prompt: zod_1.z.string().optional(),
14
14
  params: zod_1.z
15
15
  .object({
16
- imageUrls: zod_1.z.array(zod_1.z.string()).optional(),
16
+ attachedFiles: zod_1.z.array(models_1.AttachedToolFileSchema).default([]),
17
17
  systemPromptId: zod_1.z.string().optional(),
18
18
  })
19
19
  .optional(),
@@ -0,0 +1,13 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AttachedToolFileSchema = void 0;
4
+ const zod_1 = require("zod");
5
+ exports.AttachedToolFileSchema = zod_1.z.object({
6
+ uuid: zod_1.z.string(),
7
+ url: zod_1.z.string(),
8
+ name: zod_1.z.string(),
9
+ mimeType: zod_1.z.string(),
10
+ type: zod_1.z.string(),
11
+ size: zod_1.z.number(),
12
+ duration: zod_1.z.number().optional().nullable(),
13
+ });
@@ -0,0 +1,17 @@
1
+ "use strict";
2
+ var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
3
+ if (k2 === undefined) k2 = k;
4
+ var desc = Object.getOwnPropertyDescriptor(m, k);
5
+ if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
6
+ desc = { enumerable: true, get: function() { return m[k]; } };
7
+ }
8
+ Object.defineProperty(o, k2, desc);
9
+ }) : (function(o, m, k, k2) {
10
+ if (k2 === undefined) k2 = k;
11
+ o[k2] = m[k];
12
+ }));
13
+ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
+ for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
+ };
16
+ Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./attached-tool-file.schema"), exports);
@@ -5,8 +5,9 @@ const zod_1 = require("zod");
5
5
  const constants_1 = require("../../../constants");
6
6
  const tool_job_schema_1 = require("../../tool-job.schema");
7
7
  const file_schema_1 = require("../../file.schema");
8
+ const common_1 = require("../common");
8
9
  exports.ImageEditorJobParamsSchema = zod_1.z.object({
9
- imageUrls: zod_1.z.array(zod_1.z.string()).optional(),
10
+ attachedFiles: zod_1.z.array(common_1.AttachedToolFileSchema),
10
11
  systemPromptId: zod_1.z.string().optional(),
11
12
  });
12
13
  exports.ImageEditorJobSchema = tool_job_schema_1.ToolJobSchema.extend({
@@ -14,6 +14,7 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
14
14
  for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
+ __exportStar(require("./common"), exports);
17
18
  __exportStar(require("./language"), exports);
18
19
  __exportStar(require("./paraphrase"), exports);
19
20
  __exportStar(require("./presentation"), exports);
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { ImageEditorJobSchema } from '../../../models';
2
+ import { AttachedToolFileSchema, ImageEditorJobSchema } from '../../../models';
3
3
 
4
4
  export namespace RetryImageEditorJobCommand {
5
5
  export const RequestParamsSchema = z.object({
@@ -12,7 +12,7 @@ export namespace RetryImageEditorJobCommand {
12
12
  prompt: z.string().optional(),
13
13
  params: z
14
14
  .object({
15
- imageUrls: z.array(z.string()).optional(),
15
+ attachedFiles: z.array(AttachedToolFileSchema).default([]),
16
16
  systemPromptId: z.string().optional(),
17
17
  })
18
18
  .optional(),
@@ -0,0 +1,13 @@
1
+ import { z } from 'zod';
2
+
3
+ export const AttachedToolFileSchema = z.object({
4
+ uuid: z.string(),
5
+ url: z.string(),
6
+ name: z.string(),
7
+ mimeType: z.string(),
8
+ type: z.string(),
9
+ size: z.number(),
10
+ duration: z.number().optional().nullable(),
11
+ });
12
+
13
+ export type AttachedToolFile = z.infer<typeof AttachedToolFileSchema>;
@@ -0,0 +1 @@
1
+ export * from './attached-tool-file.schema';
@@ -2,9 +2,10 @@ import { z } from 'zod';
2
2
  import { USER_REACTION } from '../../../constants';
3
3
  import { ToolJobSchema } from '../../tool-job.schema';
4
4
  import { FileSchema } from '../../file.schema';
5
+ import { AttachedToolFileSchema } from '../common';
5
6
 
6
7
  export const ImageEditorJobParamsSchema = z.object({
7
- imageUrls: z.array(z.string()).optional(),
8
+ attachedFiles: z.array(AttachedToolFileSchema),
8
9
  systemPromptId: z.string().optional(),
9
10
  });
10
11
 
@@ -1,3 +1,4 @@
1
+ export * from './common';
1
2
  export * from './language';
2
3
  export * from './paraphrase';
3
4
  export * from './presentation';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@purpleschool/gptbot",
3
- "version": "0.8.46",
3
+ "version": "0.8.47",
4
4
  "description": "",
5
5
  "main": "build/index.js",
6
6
  "types": "build/index.d.ts",