aiex-cli 0.0.1-beta.12 → 0.0.1-beta.13

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/dist/cli.mjs CHANGED
@@ -1,4 +1,4 @@
1
- import { C as doctorDiagnosticsTableRows, a as writeAIConfig, b as toSnakeCase, c as PLACEHOLDER_TEXT, d as seedConfig, f as description, g as createMigrationConfig, h as version, i as readAIConfig, l as AIConfigSchema, m as package_default, n as getDefaultAIConfig, o as DEFAULT_PROMPT_CONFIG, p as name, r as maskApiKey, s as PLACEHOLDER_SCHEMA, t as collectDoctorDiagnostics, u as createConfig, v as JsonSchemaDefinitionSchema, w as formatDoctorDiagnosticsJson, x as generateDrizzleSchema, y as parseJsonSchema } from "./doctor-LwMDdfEV.mjs";
1
+ import { C as doctorDiagnosticsTableRows, a as writeAIConfig, b as toSnakeCase, c as PLACEHOLDER_TEXT, d as seedConfig, f as description, g as createMigrationConfig, h as version, i as readAIConfig, l as AIConfigSchema, m as package_default, n as getDefaultAIConfig, o as DEFAULT_PROMPT_CONFIG, p as name, r as maskApiKey, s as PLACEHOLDER_SCHEMA, t as collectDoctorDiagnostics, u as createConfig, v as JsonSchemaDefinitionSchema, w as formatDoctorDiagnosticsJson, x as generateDrizzleSchema, y as parseJsonSchema } from "./doctor-DUe9Ym10.mjs";
2
2
  import { createRequire } from "node:module";
3
3
  import path from "node:path";
4
4
  import process from "node:process";
@@ -13669,101 +13669,108 @@ const schemaCommand = defineCommand({
13669
13669
  await fs.mkdir(config.schemaPath, { recursive: true });
13670
13670
  await fs.mkdir(path.dirname(config.drizzleSchemaPath), { recursive: true });
13671
13671
  await fs.mkdir(config.migrationsPath, { recursive: true });
13672
- const userSchema = {
13672
+ const examReportSchema = {
13673
13673
  $schema: $id,
13674
- title: "User",
13674
+ title: "ExamScoreReport",
13675
13675
  type: "object",
13676
13676
  table: {
13677
- name: "users",
13678
- timestamps: true,
13679
- softDelete: true
13677
+ name: "exam_score_reports",
13678
+ timestamps: true
13680
13679
  },
13681
13680
  properties: {
13682
- id: {
13683
- type: "integer",
13684
- primary: true,
13685
- autoIncrement: true
13686
- },
13687
- email: {
13681
+ name: {
13688
13682
  type: "string",
13689
- format: "email",
13690
- unique: true
13683
+ description: "姓名"
13691
13684
  },
13692
- username: {
13685
+ reportNumber: {
13693
13686
  type: "string",
13694
- minLength: 3,
13695
- maxLength: 50,
13696
- unique: true
13687
+ description: "报告编号"
13697
13688
  },
13698
- displayName: {
13689
+ gender: {
13699
13690
  type: "string",
13700
- maxLength: 100
13691
+ description: "性别"
13701
13692
  },
13702
- bio: {
13693
+ printDate: {
13703
13694
  type: "string",
13704
- maxLength: 500
13695
+ format: "date-time",
13696
+ description: "打印日期"
13697
+ },
13698
+ examYear: {
13699
+ type: "integer",
13700
+ description: "考试年份"
13705
13701
  },
13706
- avatarUrl: {
13702
+ examType: {
13707
13703
  type: "string",
13708
- format: "uri"
13704
+ description: "考试类型,如全国统考"
13709
13705
  },
13710
- role: {
13706
+ examCategory: {
13711
13707
  type: "string",
13712
- default: "member"
13708
+ description: "考试类别,如普通高考"
13713
13709
  },
13714
- isActive: {
13715
- type: "boolean",
13716
- default: true
13710
+ province: {
13711
+ type: "string",
13712
+ description: "考试省份"
13717
13713
  },
13718
- lastLoginAt: {
13714
+ subjectCategory: {
13719
13715
  type: "string",
13720
- format: "date-time"
13716
+ description: "科类,如艺术(文)"
13721
13717
  },
13722
- profile: {
13723
- type: "object",
13724
- drizzle: { mode: "json" },
13725
- properties: {
13726
- website: { type: "string" },
13727
- location: { type: "string" },
13728
- socialLinks: {
13729
- type: "array",
13730
- items: {
13731
- type: "object",
13732
- properties: {
13733
- platform: { type: "string" },
13734
- url: { type: "string" }
13735
- }
13736
- }
13737
- }
13738
- }
13718
+ chinese: {
13719
+ type: "integer",
13720
+ description: "语文成绩"
13739
13721
  },
13740
- preferences: {
13741
- type: "object",
13742
- nested: {
13743
- enabled: true,
13744
- relation: "has-one"
13745
- },
13746
- properties: {
13747
- theme: {
13748
- type: "string",
13749
- default: "light"
13750
- },
13751
- language: {
13752
- type: "string",
13753
- default: "en"
13754
- },
13755
- emailNotifications: {
13756
- type: "boolean",
13757
- default: true
13758
- },
13759
- pushNotifications: {
13760
- type: "boolean",
13761
- default: false
13762
- }
13763
- }
13722
+ chineseFull: {
13723
+ type: "integer",
13724
+ description: "语文满分"
13725
+ },
13726
+ math: {
13727
+ type: "integer",
13728
+ description: "数学成绩"
13729
+ },
13730
+ mathFull: {
13731
+ type: "integer",
13732
+ description: "数学满分"
13733
+ },
13734
+ foreignLang: {
13735
+ type: "integer",
13736
+ description: "外语成绩"
13737
+ },
13738
+ foreignLangFull: {
13739
+ type: "integer",
13740
+ description: "外语满分"
13741
+ },
13742
+ comprehensive: {
13743
+ type: "integer",
13744
+ description: "综合成绩"
13745
+ },
13746
+ comprehensiveFull: {
13747
+ type: "integer",
13748
+ description: "综合满分"
13749
+ },
13750
+ totalScore: {
13751
+ type: "integer",
13752
+ description: "总分"
13753
+ },
13754
+ totalFullScore: {
13755
+ type: "integer",
13756
+ description: "总分满分"
13757
+ },
13758
+ batchLineFirst: {
13759
+ type: "integer",
13760
+ description: "本科第一批录取分数线"
13761
+ },
13762
+ batchLineSecond: {
13763
+ type: "integer",
13764
+ description: "本科第二批录取分数线"
13764
13765
  }
13765
13766
  },
13766
- required: ["email", "username"]
13767
+ required: [
13768
+ "name",
13769
+ "examYear",
13770
+ "examType",
13771
+ "province",
13772
+ "totalScore"
13773
+ ]
13767
13774
  };
13768
13775
  const postSchema = {
13769
13776
  $schema: $id,
@@ -13858,12 +13865,12 @@ const schemaCommand = defineCommand({
13858
13865
  "authorId"
13859
13866
  ]
13860
13867
  };
13861
- const userStatus = await writeJsonIfAbsent(path.join(config.schemaPath, "user.json"), userSchema);
13868
+ const examStatus = await writeJsonIfAbsent(path.join(config.schemaPath, "exam_score_report.json"), examReportSchema);
13862
13869
  const postStatus = await writeJsonIfAbsent(path.join(config.schemaPath, "post.json"), postSchema);
13863
13870
  consola.success(`Initialized ${pc.cyan(".aiex/")} with example schemas`);
13864
- if (userStatus === "skipped") consola.warn(`${pc.cyan(".aiex/schema/user.json")} already exists, skipped`);
13871
+ if (examStatus === "skipped") consola.warn(`${pc.cyan(".aiex/schema/exam_score_report.json")} already exists, skipped`);
13865
13872
  if (postStatus === "skipped") consola.warn(`${pc.cyan(".aiex/schema/post.json")} already exists, skipped`);
13866
- consola.info("Example includes: User (with preferences has-one), Post (with comments has-many)");
13873
+ consola.info("Example includes: ExamScoreReport (exam results), Post (blog with comments)");
13867
13874
  outro("Run: aiex schema");
13868
13875
  return;
13869
13876
  }
@@ -411,7 +411,7 @@ function generateDrizzleConfig() {
411
411
  //#endregion
412
412
  //#region package.json
413
413
  var name = "aiex-cli";
414
- var version = "0.0.1-beta.12";
414
+ var version = "0.0.1-beta.13";
415
415
  var description = "JSON Schema → SQLite with AI-powered data extraction";
416
416
  var package_default = {
417
417
  name,
package/dist/index.mjs CHANGED
@@ -1,3 +1,3 @@
1
- import { C as doctorDiagnosticsTableRows, S as buildDoctorDiagnostics, _ as generateDrizzleConfig, g as createMigrationConfig, t as collectDoctorDiagnostics, v as JsonSchemaDefinitionSchema, w as formatDoctorDiagnosticsJson, x as generateDrizzleSchema, y as parseJsonSchema } from "./doctor-LwMDdfEV.mjs";
1
+ import { C as doctorDiagnosticsTableRows, S as buildDoctorDiagnostics, _ as generateDrizzleConfig, g as createMigrationConfig, t as collectDoctorDiagnostics, v as JsonSchemaDefinitionSchema, w as formatDoctorDiagnosticsJson, x as generateDrizzleSchema, y as parseJsonSchema } from "./doctor-DUe9Ym10.mjs";
2
2
 
3
3
  export { JsonSchemaDefinitionSchema, buildDoctorDiagnostics, collectDoctorDiagnostics, createMigrationConfig, doctorDiagnosticsTableRows, formatDoctorDiagnosticsJson, generateDrizzleConfig, generateDrizzleSchema, parseJsonSchema };
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "aiex-cli",
3
3
  "type": "module",
4
- "version": "0.0.1-beta.12",
4
+ "version": "0.0.1-beta.13",
5
5
  "description": "JSON Schema → SQLite with AI-powered data extraction",
6
6
  "author": "OSpoon <zxin088@gmail.com>",
7
7
  "license": "MIT",