@purpleschool/gptbot 0.5.36 → 0.5.38

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.
@@ -0,0 +1,8 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.AI_MODEL_STATUS = void 0;
4
+ var AI_MODEL_STATUS;
5
+ (function (AI_MODEL_STATUS) {
6
+ AI_MODEL_STATUS["ACTIVE"] = "active";
7
+ AI_MODEL_STATUS["INACTIVE"] = "inactive";
8
+ })(AI_MODEL_STATUS || (exports.AI_MODEL_STATUS = AI_MODEL_STATUS = {}));
@@ -16,4 +16,5 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./ai-model-content-type.enum"), exports);
18
18
  __exportStar(require("./ai-model-feature.enum"), exports);
19
+ __exportStar(require("./ai-model-status.enum"), exports);
19
20
  __exportStar(require("./ai-model-strategy.enum"), exports);
@@ -0,0 +1,6 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.VALID_MIMETYPES = exports.IMAGE_MIMETYPES = exports.MAX_UPLOAD_SIZE = void 0;
4
+ exports.MAX_UPLOAD_SIZE = 5 * 1024 * 1024; // 5MB
5
+ exports.IMAGE_MIMETYPES = ['image/jpeg', 'image/png', 'image/webp'];
6
+ exports.VALID_MIMETYPES = [...exports.IMAGE_MIMETYPES];
@@ -15,3 +15,4 @@ var __exportStar = (this && this.__exportStar) || function(m, exports) {
15
15
  };
16
16
  Object.defineProperty(exports, "__esModule", { value: true });
17
17
  __exportStar(require("./enums"), exports);
18
+ __exportStar(require("./file.constants"), exports);
@@ -13,6 +13,7 @@ exports.AiModelSchema = zod_1.z.object({
13
13
  order: zod_1.z.number(),
14
14
  canUse: zod_1.z.optional(zod_1.z.boolean()),
15
15
  icon: zod_1.z.nullable(zod_1.z.string()),
16
+ status: zod_1.z.nativeEnum(constants_1.AI_MODEL_STATUS),
16
17
  contentType: zod_1.z.enum(Object.values(constants_1.AI_MODEL_CONTENT_TYPE)),
17
18
  features: zod_1.z.array(zod_1.z.nativeEnum(constants_1.AI_MODEL_FEATURE)),
18
19
  createdAt: zod_1.z.date(),
@@ -0,0 +1,4 @@
1
+ export enum AI_MODEL_STATUS {
2
+ ACTIVE = 'active',
3
+ INACTIVE = 'inactive',
4
+ }
@@ -1,3 +1,4 @@
1
1
  export * from './ai-model-content-type.enum';
2
2
  export * from './ai-model-feature.enum';
3
+ export * from './ai-model-status.enum';
3
4
  export * from './ai-model-strategy.enum';
@@ -0,0 +1,5 @@
1
+ export const MAX_UPLOAD_SIZE = 5 * 1024 * 1024; // 5MB
2
+
3
+ export const IMAGE_MIMETYPES = ['image/jpeg', 'image/png', 'image/webp'];
4
+
5
+ export const VALID_MIMETYPES = [...IMAGE_MIMETYPES];
@@ -1 +1,2 @@
1
1
  export * from './enums';
2
+ export * from './file.constants';
@@ -1,5 +1,10 @@
1
1
  import { z } from 'zod';
2
- import { AI_MODEL_CONTENT_TYPE, AI_MODEL_FEATURE, TAIModelContentTypeEnum } from '../constants';
2
+ import {
3
+ AI_MODEL_CONTENT_TYPE,
4
+ AI_MODEL_FEATURE,
5
+ AI_MODEL_STATUS,
6
+ TAIModelContentTypeEnum,
7
+ } from '../constants';
3
8
 
4
9
  export const AiModelSchema = z.object({
5
10
  uuid: z.string().uuid(),
@@ -11,6 +16,7 @@ export const AiModelSchema = z.object({
11
16
  order: z.number(),
12
17
  canUse: z.optional(z.boolean()),
13
18
  icon: z.nullable(z.string()),
19
+ status: z.nativeEnum(AI_MODEL_STATUS),
14
20
  contentType: z.enum(Object.values(AI_MODEL_CONTENT_TYPE) as [TAIModelContentTypeEnum]),
15
21
  features: z.array(z.nativeEnum(AI_MODEL_FEATURE)),
16
22
  createdAt: z.date(),
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@purpleschool/gptbot",
3
- "version": "0.5.36",
3
+ "version": "0.5.38",
4
4
  "description": "",
5
5
  "main": "index.js",
6
6
  "scripts": {