@purpleschool/gptbot 0.8.74 → 0.8.75
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/build/commands/tools/image-editor/retry-image-editor-job.command.js +1 -1
- package/build/commands/tools/image-generation/index.js +1 -0
- package/build/commands/tools/image-generation/retry-image-generation-job.command.js +28 -0
- package/commands/tools/image-editor/retry-image-editor-job.command.ts +2 -2
- package/commands/tools/image-generation/index.ts +1 -0
- package/commands/tools/image-generation/retry-image-generation-job.command.ts +30 -0
- package/package.json +1 -1
|
@@ -13,7 +13,7 @@ var RetryImageEditorJobCommand;
|
|
|
13
13
|
prompt: zod_1.z.string().optional(),
|
|
14
14
|
params: zod_1.z
|
|
15
15
|
.object({
|
|
16
|
-
attachedFiles: zod_1.z.
|
|
16
|
+
attachedFiles: zod_1.z.string().array(),
|
|
17
17
|
systemPromptId: zod_1.z.string().optional(),
|
|
18
18
|
})
|
|
19
19
|
.optional(),
|
|
@@ -22,3 +22,4 @@ __exportStar(require("./update-image-generation-job-title.command"), exports);
|
|
|
22
22
|
__exportStar(require("./delete-image-generation-job-by-uuid.command"), exports);
|
|
23
23
|
__exportStar(require("./delete-all-image-generation-jobs.command"), exports);
|
|
24
24
|
__exportStar(require("./get-image-generation-config.command"), exports);
|
|
25
|
+
__exportStar(require("./retry-image-generation-job.command"), exports);
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.RetryImageGenerationJobCommand = void 0;
|
|
4
|
+
const zod_1 = require("zod");
|
|
5
|
+
const constants_1 = require("../../../constants");
|
|
6
|
+
const models_1 = require("../../../models");
|
|
7
|
+
var RetryImageGenerationJobCommand;
|
|
8
|
+
(function (RetryImageGenerationJobCommand) {
|
|
9
|
+
RetryImageGenerationJobCommand.RequestParamsSchema = zod_1.z.object({
|
|
10
|
+
uuid: zod_1.z.string().uuid(),
|
|
11
|
+
});
|
|
12
|
+
RetryImageGenerationJobCommand.RequestBodySchema = zod_1.z.object({
|
|
13
|
+
modelId: zod_1.z.string().uuid(),
|
|
14
|
+
prompt: zod_1.z.string(),
|
|
15
|
+
params: zod_1.z
|
|
16
|
+
.object({
|
|
17
|
+
aspectRatio: zod_1.z.string(),
|
|
18
|
+
attachedFiles: zod_1.z.string().array(),
|
|
19
|
+
enhancePrompt: zod_1.z.boolean(),
|
|
20
|
+
resolution: zod_1.z.nativeEnum(constants_1.IMAGE_GENERATION_RESOLUTION).optional(),
|
|
21
|
+
})
|
|
22
|
+
.optional(),
|
|
23
|
+
presetId: zod_1.z.string().uuid().nullable().optional(),
|
|
24
|
+
});
|
|
25
|
+
RetryImageGenerationJobCommand.ResponseSchema = zod_1.z.object({
|
|
26
|
+
data: models_1.ImageGenerationJobSchema,
|
|
27
|
+
});
|
|
28
|
+
})(RetryImageGenerationJobCommand || (exports.RetryImageGenerationJobCommand = RetryImageGenerationJobCommand = {}));
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import {
|
|
2
|
+
import { 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
|
-
attachedFiles: z.
|
|
15
|
+
attachedFiles: z.string().array(),
|
|
16
16
|
systemPromptId: z.string().optional(),
|
|
17
17
|
})
|
|
18
18
|
.optional(),
|
|
@@ -6,3 +6,4 @@ export * from './update-image-generation-job-title.command';
|
|
|
6
6
|
export * from './delete-image-generation-job-by-uuid.command';
|
|
7
7
|
export * from './delete-all-image-generation-jobs.command';
|
|
8
8
|
export * from './get-image-generation-config.command';
|
|
9
|
+
export * from './retry-image-generation-job.command';
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { IMAGE_GENERATION_RESOLUTION } from '../../../constants';
|
|
3
|
+
import { ImageGenerationJobSchema } from '../../../models';
|
|
4
|
+
|
|
5
|
+
export namespace RetryImageGenerationJobCommand {
|
|
6
|
+
export const RequestParamsSchema = z.object({
|
|
7
|
+
uuid: z.string().uuid(),
|
|
8
|
+
});
|
|
9
|
+
export type RequestParams = z.infer<typeof RequestParamsSchema>;
|
|
10
|
+
|
|
11
|
+
export const RequestBodySchema = z.object({
|
|
12
|
+
modelId: z.string().uuid(),
|
|
13
|
+
prompt: z.string(),
|
|
14
|
+
params: z
|
|
15
|
+
.object({
|
|
16
|
+
aspectRatio: z.string(),
|
|
17
|
+
attachedFiles: z.string().array(),
|
|
18
|
+
enhancePrompt: z.boolean(),
|
|
19
|
+
resolution: z.nativeEnum(IMAGE_GENERATION_RESOLUTION).optional(),
|
|
20
|
+
})
|
|
21
|
+
.optional(),
|
|
22
|
+
presetId: z.string().uuid().nullable().optional(),
|
|
23
|
+
});
|
|
24
|
+
export type RequestBody = z.infer<typeof RequestBodySchema>;
|
|
25
|
+
|
|
26
|
+
export const ResponseSchema = z.object({
|
|
27
|
+
data: ImageGenerationJobSchema,
|
|
28
|
+
});
|
|
29
|
+
export type Response = z.infer<typeof ResponseSchema>;
|
|
30
|
+
}
|