@autobe/agent 0.25.0 → 0.25.1

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.
Files changed (184) hide show
  1. package/lib/AutoBeAgent.js +11 -1
  2. package/lib/AutoBeAgent.js.map +1 -1
  3. package/lib/AutoBeMockAgent.js +1 -0
  4. package/lib/AutoBeMockAgent.js.map +1 -1
  5. package/lib/constants/AutoBeSystemPromptConstant.d.ts +13 -13
  6. package/lib/factory/createAutoBeContext.js +1 -0
  7. package/lib/factory/createAutoBeContext.js.map +1 -1
  8. package/lib/index.mjs +2250 -806
  9. package/lib/index.mjs.map +1 -1
  10. package/lib/orchestrate/common/histories/transformCommonCorrectCastingHistories.js +1 -1
  11. package/lib/orchestrate/common/histories/transformCommonCorrectCastingHistories.js.map +1 -1
  12. package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js +36 -23
  13. package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js.map +1 -1
  14. package/lib/orchestrate/common/structures/IAutoBeCommonCorrectCastingApplication.d.ts +22 -42
  15. package/lib/orchestrate/interface/histories/transformInterfaceCommonPrerequisiteHistories.d.ts +3 -0
  16. package/lib/orchestrate/interface/histories/{transformInterfacePrerequisiteHistories.js → transformInterfaceCommonPrerequisiteHistories.js} +4 -4
  17. package/lib/orchestrate/interface/histories/transformInterfaceCommonPrerequisiteHistories.js.map +1 -0
  18. package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.js +2 -2
  19. package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.js.map +1 -1
  20. package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.js +3 -3
  21. package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.js.map +1 -1
  22. package/lib/orchestrate/interface/histories/transformInterfacePrerequisitesHistories.d.ts +3 -0
  23. package/lib/orchestrate/interface/histories/transformInterfacePrerequisitesHistories.js +102 -0
  24. package/lib/orchestrate/interface/histories/transformInterfacePrerequisitesHistories.js.map +1 -0
  25. package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.js +1 -1
  26. package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.js.map +1 -1
  27. package/lib/orchestrate/interface/histories/transformInterfaceSchemasReviewHistories.js +2 -2
  28. package/lib/orchestrate/interface/histories/transformInterfaceSchemasReviewHistories.js.map +1 -1
  29. package/lib/orchestrate/interface/orchestrateInterface.js +25 -9
  30. package/lib/orchestrate/interface/orchestrateInterface.js.map +1 -1
  31. package/lib/orchestrate/interface/orchestrateInterfaceAuthorizations.js +260 -29
  32. package/lib/orchestrate/interface/orchestrateInterfaceAuthorizations.js.map +1 -1
  33. package/lib/orchestrate/interface/orchestrateInterfaceComplement.js +56 -64
  34. package/lib/orchestrate/interface/orchestrateInterfaceComplement.js.map +1 -1
  35. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js +3 -3
  36. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js.map +1 -1
  37. package/lib/orchestrate/interface/orchestrateInterfaceGroups.js +2 -2
  38. package/lib/orchestrate/interface/orchestrateInterfaceOperations.js +4 -5
  39. package/lib/orchestrate/interface/orchestrateInterfaceOperations.js.map +1 -1
  40. package/lib/orchestrate/interface/orchestrateInterfaceOperationsReview.js +260 -29
  41. package/lib/orchestrate/interface/orchestrateInterfaceOperationsReview.js.map +1 -1
  42. package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.d.ts +5 -0
  43. package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.js +713 -0
  44. package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.js.map +1 -0
  45. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js +47 -35
  46. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js.map +1 -1
  47. package/lib/orchestrate/interface/orchestrateInterfaceSchemasReview.js +41 -7
  48. package/lib/orchestrate/interface/orchestrateInterfaceSchemasReview.js.map +1 -1
  49. package/lib/orchestrate/interface/structures/IAutoBeInterfaceComplementApplication.d.ts +0 -38
  50. package/lib/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.d.ts +6 -10
  51. package/lib/orchestrate/interface/structures/IAutoBeInterfacePrerequisitesApplication.d.ts +52 -0
  52. package/lib/orchestrate/interface/structures/IAutoBeInterfacePrerequisitesApplication.js +3 -0
  53. package/lib/orchestrate/interface/structures/IAutoBeInterfacePrerequisitesApplication.js.map +1 -0
  54. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.d.ts +0 -33
  55. package/lib/orchestrate/interface/utils/JsonSchemaFactory.d.ts +6 -2
  56. package/lib/orchestrate/interface/utils/JsonSchemaFactory.js +105 -5
  57. package/lib/orchestrate/interface/utils/JsonSchemaFactory.js.map +1 -1
  58. package/lib/orchestrate/interface/utils/JsonSchemaValidator.js +20 -1
  59. package/lib/orchestrate/interface/utils/JsonSchemaValidator.js.map +1 -1
  60. package/lib/orchestrate/interface/utils/OperationValidator.d.ts +3 -4
  61. package/lib/orchestrate/interface/utils/OperationValidator.js +1 -1
  62. package/lib/orchestrate/interface/utils/OperationValidator.js.map +1 -1
  63. package/lib/orchestrate/realize/histories/transformRealizeCorrectCastingHistories.js +9 -10
  64. package/lib/orchestrate/realize/histories/transformRealizeCorrectCastingHistories.js.map +1 -1
  65. package/lib/orchestrate/realize/histories/transformRealizeCorrectHistories.js +14 -22
  66. package/lib/orchestrate/realize/histories/transformRealizeCorrectHistories.js.map +1 -1
  67. package/lib/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.js +6 -6
  68. package/lib/orchestrate/realize/histories/transformRealizeWriteHistories.js +8 -2
  69. package/lib/orchestrate/realize/histories/transformRealizeWriteHistories.js.map +1 -1
  70. package/lib/orchestrate/realize/internal/compileRealizeFiles.js +1 -2
  71. package/lib/orchestrate/realize/internal/compileRealizeFiles.js.map +1 -1
  72. package/lib/orchestrate/realize/orchestRateRealizeCorrectCasting.d.ts +2 -1
  73. package/lib/orchestrate/realize/orchestRateRealizeCorrectCasting.js +103 -40
  74. package/lib/orchestrate/realize/orchestRateRealizeCorrectCasting.js.map +1 -1
  75. package/lib/orchestrate/realize/orchestrateRealize.js +81 -45
  76. package/lib/orchestrate/realize/orchestrateRealize.js.map +1 -1
  77. package/lib/orchestrate/realize/orchestrateRealizeCorrect.js +117 -87
  78. package/lib/orchestrate/realize/orchestrateRealizeCorrect.js.map +1 -1
  79. package/lib/orchestrate/realize/orchestrateRealizeWrite.d.ts +2 -1
  80. package/lib/orchestrate/realize/orchestrateRealizeWrite.js +117 -54
  81. package/lib/orchestrate/realize/orchestrateRealizeWrite.js.map +1 -1
  82. package/lib/orchestrate/realize/structures/IAutoBeRealizeCorrectApplication.d.ts +52 -26
  83. package/lib/orchestrate/realize/structures/IAutoBeRealizeWriteApplication.d.ts +44 -34
  84. package/lib/orchestrate/realize/utils/InternalFileSystem.js +1 -1
  85. package/lib/orchestrate/realize/utils/InternalFileSystem.js.map +1 -1
  86. package/lib/orchestrate/realize/utils/getRealizeWriteCodeTemplate.d.ts +8 -3
  87. package/lib/orchestrate/realize/utils/getRealizeWriteCodeTemplate.js +44 -17
  88. package/lib/orchestrate/realize/utils/getRealizeWriteCodeTemplate.js.map +1 -1
  89. package/lib/orchestrate/realize/utils/getRealizeWriteImportStatements.d.ts +4 -1
  90. package/lib/orchestrate/realize/utils/getRealizeWriteImportStatements.js +24 -9
  91. package/lib/orchestrate/realize/utils/getRealizeWriteImportStatements.js.map +1 -1
  92. package/lib/orchestrate/realize/utils/printErrorHints.d.ts +8 -0
  93. package/lib/orchestrate/realize/utils/printErrorHints.js +48 -0
  94. package/lib/orchestrate/realize/utils/printErrorHints.js.map +1 -0
  95. package/lib/orchestrate/realize/utils/replaceImportStatements.d.ts +1 -0
  96. package/lib/orchestrate/realize/utils/replaceImportStatements.js +93 -55
  97. package/lib/orchestrate/realize/utils/replaceImportStatements.js.map +1 -1
  98. package/lib/orchestrate/test/histories/transformTestCorrectHistories.js +1 -1
  99. package/lib/orchestrate/test/histories/transformTestCorrectHistories.js.map +1 -1
  100. package/lib/orchestrate/test/histories/transformTestCorrectInvalidRequestHistories.js +1 -1
  101. package/lib/orchestrate/test/histories/transformTestCorrectInvalidRequestHistories.js.map +1 -1
  102. package/lib/orchestrate/test/histories/transformTestScenarioHistories.js +10 -79
  103. package/lib/orchestrate/test/histories/transformTestScenarioHistories.js.map +1 -1
  104. package/lib/orchestrate/test/histories/transformTestScenarioReviewHistories.js +15 -65
  105. package/lib/orchestrate/test/histories/transformTestScenarioReviewHistories.js.map +1 -1
  106. package/lib/orchestrate/test/histories/transformTestWriteHistories.js +1 -1
  107. package/lib/orchestrate/test/histories/transformTestWriteHistories.js.map +1 -1
  108. package/lib/orchestrate/test/orchestrateTestCorrect.js +32 -17
  109. package/lib/orchestrate/test/orchestrateTestCorrect.js.map +1 -1
  110. package/lib/orchestrate/test/orchestrateTestCorrectInvalidRequest.js +31 -13
  111. package/lib/orchestrate/test/orchestrateTestCorrectInvalidRequest.js.map +1 -1
  112. package/lib/orchestrate/test/orchestrateTestScenario.d.ts +1 -1
  113. package/lib/orchestrate/test/orchestrateTestScenario.js +5 -5
  114. package/lib/orchestrate/test/orchestrateTestScenario.js.map +1 -1
  115. package/lib/orchestrate/test/orchestrateTestScenarioReview.js +1 -1
  116. package/lib/orchestrate/test/orchestrateTestScenarioReview.js.map +1 -1
  117. package/lib/orchestrate/test/orchestrateTestWrite.js +37 -21
  118. package/lib/orchestrate/test/orchestrateTestWrite.js.map +1 -1
  119. package/lib/orchestrate/test/structures/IAutoBeTestCorrectApplication.d.ts +9 -5
  120. package/lib/orchestrate/test/structures/IAutoBeTestCorrectInvalidRequestApplication.d.ts +8 -2
  121. package/lib/orchestrate/test/structures/IAutoBeTestWriteApplication.d.ts +11 -7
  122. package/lib/orchestrate/test/utils/getPrerequisites.d.ts +5 -0
  123. package/lib/orchestrate/test/utils/getPrerequisites.js +36 -0
  124. package/lib/orchestrate/test/utils/getPrerequisites.js.map +1 -0
  125. package/lib/orchestrate/test/utils/getReferenceIds.js +1 -1
  126. package/lib/orchestrate/test/utils/getReferenceIds.js.map +1 -1
  127. package/package.json +5 -5
  128. package/src/AutoBeAgent.ts +17 -1
  129. package/src/AutoBeMockAgent.ts +1 -0
  130. package/src/constants/AutoBeSystemPromptConstant.ts +13 -13
  131. package/src/factory/createAutoBeContext.ts +1 -0
  132. package/src/orchestrate/common/orchestrateCommonCorrectCasting.ts +2 -2
  133. package/src/orchestrate/common/structures/IAutoBeCommonCorrectCastingApplication.ts +25 -45
  134. package/src/orchestrate/interface/histories/{transformInterfacePrerequisiteHistories.ts → transformInterfaceCommonPrerequisiteHistories.ts} +1 -1
  135. package/src/orchestrate/interface/histories/transformInterfaceGroupHistories.ts +4 -2
  136. package/src/orchestrate/interface/histories/transformInterfacePrerequisitesHistories.ts +118 -0
  137. package/src/orchestrate/interface/orchestrateInterface.ts +43 -17
  138. package/src/orchestrate/interface/orchestrateInterfaceComplement.ts +12 -33
  139. package/src/orchestrate/interface/orchestrateInterfaceEndpoints.ts +5 -5
  140. package/src/orchestrate/interface/orchestrateInterfaceOperations.ts +7 -6
  141. package/src/orchestrate/interface/orchestrateInterfacePrerequisites.ts +274 -0
  142. package/src/orchestrate/interface/orchestrateInterfaceSchemas.ts +1 -1
  143. package/src/orchestrate/interface/orchestrateInterfaceSchemasReview.ts +1 -1
  144. package/src/orchestrate/interface/structures/IAutoBeInterfaceComplementApplication.ts +0 -39
  145. package/src/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.ts +6 -10
  146. package/src/orchestrate/interface/structures/IAutoBeInterfacePrerequisitesApplication.ts +58 -0
  147. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.ts +0 -34
  148. package/src/orchestrate/interface/utils/JsonSchemaFactory.ts +92 -4
  149. package/src/orchestrate/interface/utils/JsonSchemaValidator.ts +19 -1
  150. package/src/orchestrate/interface/utils/OperationValidator.ts +9 -7
  151. package/src/orchestrate/realize/histories/transformRealizeCorrectCastingHistories.ts +9 -10
  152. package/src/orchestrate/realize/histories/transformRealizeCorrectHistories.ts +13 -24
  153. package/src/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.ts +6 -6
  154. package/src/orchestrate/realize/histories/transformRealizeWriteHistories.ts +6 -4
  155. package/src/orchestrate/realize/internal/compileRealizeFiles.ts +1 -5
  156. package/src/orchestrate/realize/orchestRateRealizeCorrectCasting.ts +84 -17
  157. package/src/orchestrate/realize/orchestrateRealize.ts +125 -74
  158. package/src/orchestrate/realize/orchestrateRealizeCorrect.ts +33 -6
  159. package/src/orchestrate/realize/orchestrateRealizeWrite.ts +14 -4
  160. package/src/orchestrate/realize/structures/IAutoBeRealizeCorrectApplication.ts +54 -29
  161. package/src/orchestrate/realize/structures/IAutoBeRealizeWriteApplication.ts +46 -35
  162. package/src/orchestrate/realize/utils/InternalFileSystem.ts +1 -1
  163. package/src/orchestrate/realize/utils/getRealizeWriteCodeTemplate.ts +54 -22
  164. package/src/orchestrate/realize/utils/getRealizeWriteImportStatements.ts +28 -16
  165. package/src/orchestrate/realize/utils/printErrorHints.ts +55 -0
  166. package/src/orchestrate/realize/utils/replaceImportStatements.ts +99 -102
  167. package/src/orchestrate/test/histories/transformTestScenarioHistories.ts +18 -91
  168. package/src/orchestrate/test/histories/transformTestScenarioReviewHistories.ts +17 -90
  169. package/src/orchestrate/test/orchestrateTestCorrect.ts +7 -6
  170. package/src/orchestrate/test/orchestrateTestCorrectInvalidRequest.ts +13 -1
  171. package/src/orchestrate/test/orchestrateTestScenario.ts +12 -6
  172. package/src/orchestrate/test/orchestrateTestScenarioReview.ts +3 -3
  173. package/src/orchestrate/test/orchestrateTestWrite.ts +7 -6
  174. package/src/orchestrate/test/structures/IAutoBeTestCorrectApplication.ts +9 -228
  175. package/src/orchestrate/test/structures/IAutoBeTestCorrectInvalidRequestApplication.ts +8 -2
  176. package/src/orchestrate/test/structures/IAutoBeTestWriteApplication.ts +11 -78
  177. package/src/orchestrate/test/utils/getPrerequisites.ts +51 -0
  178. package/src/orchestrate/test/utils/getReferenceIds.ts +2 -1
  179. package/lib/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.d.ts +0 -3
  180. package/lib/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.js.map +0 -1
  181. package/lib/orchestrate/interface/utils/OpenApiEndpointComparator.d.ts +0 -6
  182. package/lib/orchestrate/interface/utils/OpenApiEndpointComparator.js +0 -22
  183. package/lib/orchestrate/interface/utils/OpenApiEndpointComparator.js.map +0 -1
  184. package/src/orchestrate/interface/utils/OpenApiEndpointComparator.ts +0 -23
@@ -55,6 +55,7 @@ const executeCachedBatch_1 = require("../../utils/executeCachedBatch");
55
55
  const transformRealizeCorrectHistories_1 = require("./histories/transformRealizeCorrectHistories");
56
56
  const compileRealizeFiles_1 = require("./internal/compileRealizeFiles");
57
57
  const filterDiagnostics_1 = require("./utils/filterDiagnostics");
58
+ const getRealizeWriteCodeTemplate_1 = require("./utils/getRealizeWriteCodeTemplate");
58
59
  const getRealizeWriteDto_1 = require("./utils/getRealizeWriteDto");
59
60
  const replaceImportStatements_1 = require("./utils/replaceImportStatements");
60
61
  function orchestrateRealizeCorrect(ctx_1, scenarios_1, authorizations_1, functions_1, failures_1, progress_1) {
@@ -69,7 +70,7 @@ function orchestrateRealizeCorrect(ctx_1, scenarios_1, authorizations_1, functio
69
70
  return functions;
70
71
  // Extract and process diagnostics
71
72
  const diagnostics = event.result.diagnostics;
72
- if (event.result.diagnostics.every((d) => { var _a; return !((_a = d.file) === null || _a === void 0 ? void 0 : _a.startsWith("src/providers")); })) {
73
+ if (event.result.diagnostics.every((d) => { var _a; return !((_a = d.file) === null || _a === void 0 ? void 0 : _a.startsWith("src/providers")); }) === true) {
73
74
  // No diagnostics related to provider functions, stop correcting
74
75
  return functions;
75
76
  }
@@ -146,7 +147,7 @@ function correct(ctx, locations, scenarios, authorizations, functions, failures,
146
147
  }
147
148
  function step(ctx, props) {
148
149
  return __awaiter(this, void 0, void 0, function* () {
149
- var _a, _b, _c;
150
+ var _a, _b, _c, _d, _e, _f;
150
151
  const pointer = {
151
152
  value: null,
152
153
  };
@@ -171,25 +172,50 @@ function step(ctx, props) {
171
172
  enforceFunctionCall: true,
172
173
  message: utils_1.StringUtil.trim `
173
174
  Correct the TypeScript code implementation.
175
+
176
+ The instruction to write at first was as follows, and the code you received is the code you wrote according to this instruction.
177
+ When modifying, modify the entire code, but not the import statement.
178
+
179
+ Below is template code you wrote:
180
+
181
+ ${(0, getRealizeWriteCodeTemplate_1.getRealizeWriteCodeTemplate)({
182
+ scenario: props.scenario,
183
+ schemas: ctx.state().interface.document.components.schemas,
184
+ operation: props.scenario.operation,
185
+ authorization: (_a = props.authorization) !== null && _a !== void 0 ? _a : null,
186
+ })}
187
+
188
+ Current code is as follows:
189
+ \`\`\`typescript
190
+ ${props.function.content}
191
+ \`\`\`
174
192
  `,
175
193
  });
176
194
  if (pointer.value === null) {
177
195
  return null;
178
196
  }
179
- pointer.value.revise.final = yield (0, replaceImportStatements_1.replaceImportStatements)(ctx, {
197
+ pointer.value.draft = yield (0, replaceImportStatements_1.replaceImportStatements)(ctx, {
180
198
  operation: props.scenario.operation,
181
- code: pointer.value.revise.final,
182
- decoratorType: (_a = props.authorization) === null || _a === void 0 ? void 0 : _a.payload.name,
199
+ schemas: ctx.state().interface.document.components.schemas,
200
+ code: pointer.value.draft,
201
+ decoratorType: (_b = props.authorization) === null || _b === void 0 ? void 0 : _b.payload.name,
183
202
  });
203
+ if (pointer.value.revise.final)
204
+ pointer.value.revise.final = yield (0, replaceImportStatements_1.replaceImportStatements)(ctx, {
205
+ operation: props.scenario.operation,
206
+ schemas: ctx.state().interface.document.components.schemas,
207
+ code: pointer.value.revise.final,
208
+ decoratorType: (_c = props.authorization) === null || _c === void 0 ? void 0 : _c.payload.name,
209
+ });
184
210
  const event = {
185
211
  type: "realizeCorrect",
186
212
  id: (0, uuid_1.v7)(),
187
213
  location: props.scenario.location,
188
- content: pointer.value.revise.final,
214
+ content: (_d = pointer.value.revise.final) !== null && _d !== void 0 ? _d : pointer.value.draft,
189
215
  tokenUsage,
190
216
  completed: ++props.progress.completed,
191
217
  total: props.progress.total,
192
- step: (_c = (_b = ctx.state().analyze) === null || _b === void 0 ? void 0 : _b.step) !== null && _c !== void 0 ? _c : 0,
218
+ step: (_f = (_e = ctx.state().analyze) === null || _e === void 0 ? void 0 : _e.step) !== null && _f !== void 0 ? _f : 0,
193
219
  created_at: new Date().toISOString(),
194
220
  };
195
221
  ctx.dispatch(event);
@@ -204,7 +230,7 @@ function createController(props) {
204
230
  name: "Write code",
205
231
  application,
206
232
  execute: {
207
- review: (next) => {
233
+ correct: (next) => {
208
234
  props.build(next);
209
235
  },
210
236
  },
@@ -218,79 +244,81 @@ const claude = {
218
244
  },
219
245
  functions: [
220
246
  {
221
- name: "review",
247
+ name: "correct",
222
248
  parameters: {
223
- description: " Properties containing the multi-phase error correction process\n\n------------------------------\n\nDescription of the current {@link IAutoBeRealizeCorrectApplication.IProps} type:\n\n> Properties for error correction following Chain of Thinking (CoT).\n> \n> All phases are wrapped in a `revise` object for systematic error\n> resolution.",
249
+ description: " Three-phase correction properties\n\n------------------------------\n\nCurrent Type: {@link IAutoBeRealizeCorrectApplication.IProps}",
224
250
  type: "object",
225
251
  properties: {
252
+ think: {
253
+ description: "Initial error analysis and correction strategy.\n\nAnalyzes TypeScript compilation errors to understand:\n\n- Error patterns and root causes\n- Required fixes and their impact\n- Whether quick fixes or deep refactoring is needed\n- Prisma schema and API contract constraints",
254
+ type: "string"
255
+ },
256
+ draft: {
257
+ description: "First correction attempt.\n\nImplements the initial fixes identified in the think phase. For simple\nerrors (typos, missing imports), this may be the final solution. Complex\nerrors may require further refinement.",
258
+ type: "string"
259
+ },
226
260
  revise: {
227
- description: "Revision process containing all error correction phases.",
228
- $ref: "#/$defs/IAutoBeRealizeCorrectApplication.IRevise"
261
+ description: "Revision and finalization phase.\n\nReviews the draft corrections and produces the final, error-free code\nthat maintains all business requirements.",
262
+ $ref: "#/$defs/IAutoBeRealizeCorrectApplication.IReviseProps"
229
263
  }
230
264
  },
231
265
  required: [
266
+ "think",
267
+ "draft",
232
268
  "revise"
233
269
  ],
234
270
  additionalProperties: false,
235
271
  $defs: {
236
- "IAutoBeRealizeCorrectApplication.IRevise": {
272
+ "IAutoBeRealizeCorrectApplication.IReviseProps": {
237
273
  type: "object",
238
274
  properties: {
239
- errorAnalysis: {
240
- description: "Step 1: TypeScript compilation error analysis and resolution strategy.\nAnalyzes TypeScript compiler diagnostics (error codes, messages) to understand\ntype mismatches, missing properties, nullable conflicts, and other compilation issues.",
241
- type: "string"
242
- },
243
- plan: {
244
- description: "Step 2: Provider function implementation plan.",
245
- type: "string"
246
- },
247
- prismaSchemas: {
248
- description: "Step 3: Relevant Prisma schema definitions.",
249
- type: "string"
250
- },
251
275
  review: {
252
- description: "Step 4: Refined version with improved completeness.",
276
+ description: "Correction review and validation.\n\nAnalyzes the draft corrections to ensure:\n\n- All TypeScript errors are resolved\n- Business logic remains intact\n- AutoBE coding standards are maintained\n- No new errors are introduced\n- Performance and security are preserved",
253
277
  type: "string"
254
278
  },
255
279
  final: {
256
- description: "Step 5: Final complete TypeScript function implementation.",
257
- type: "string"
280
+ description: "Final error-free implementation.\n\nThe complete, corrected code that passes all TypeScript compilation\nchecks.\n\nReturns `null` if the draft corrections are sufficient and need no\nfurther changes.",
281
+ oneOf: [
282
+ {
283
+ type: "null"
284
+ },
285
+ {
286
+ type: "string"
287
+ }
288
+ ]
258
289
  }
259
290
  },
260
291
  required: [
292
+ "review",
261
293
  "final"
262
294
  ]
263
295
  }
264
296
  }
265
297
  },
266
- description: "Reviews and corrects TypeScript compilation errors.\n\nFixes TypeScript compilation errors while preserving original business\nlogic, applying minimal intervention principle.",
267
- validate: (() => { const _io0 = input => "object" === typeof input.revise && null !== input.revise && _io1(input.revise); const _io1 = input => (undefined === input.errorAnalysis || "string" === typeof input.errorAnalysis) && (undefined === input.plan || "string" === typeof input.plan) && (undefined === input.prismaSchemas || "string" === typeof input.prismaSchemas) && (undefined === input.review || "string" === typeof input.review) && "string" === typeof input.final; const _vo0 = (input, _path, _exceptionable = true) => [("object" === typeof input.revise && null !== input.revise || _report(_exceptionable, {
298
+ description: "Systematically analyze and correct TypeScript compilation errors.\n\nImplements a three-phase workflow (think \u2192 draft \u2192 revise) that balances\nefficiency for simple errors with thoroughness for complex problems.",
299
+ validate: (() => { const _io0 = input => "string" === typeof input.think && "string" === typeof input.draft && ("object" === typeof input.revise && null !== input.revise && _io1(input.revise)); const _io1 = input => "string" === typeof input.review && (null === input.final || "string" === typeof input.final); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.think || _report(_exceptionable, {
300
+ path: _path + ".think",
301
+ expected: "string",
302
+ value: input.think
303
+ }), "string" === typeof input.draft || _report(_exceptionable, {
304
+ path: _path + ".draft",
305
+ expected: "string",
306
+ value: input.draft
307
+ }), ("object" === typeof input.revise && null !== input.revise || _report(_exceptionable, {
268
308
  path: _path + ".revise",
269
- expected: "IAutoBeRealizeCorrectApplication.IRevise",
309
+ expected: "IAutoBeRealizeCorrectApplication.IReviseProps",
270
310
  value: input.revise
271
311
  })) && _vo1(input.revise, _path + ".revise", true && _exceptionable) || _report(_exceptionable, {
272
312
  path: _path + ".revise",
273
- expected: "IAutoBeRealizeCorrectApplication.IRevise",
313
+ expected: "IAutoBeRealizeCorrectApplication.IReviseProps",
274
314
  value: input.revise
275
- })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => [undefined === input.errorAnalysis || "string" === typeof input.errorAnalysis || _report(_exceptionable, {
276
- path: _path + ".errorAnalysis",
277
- expected: "(string | undefined)",
278
- value: input.errorAnalysis
279
- }), undefined === input.plan || "string" === typeof input.plan || _report(_exceptionable, {
280
- path: _path + ".plan",
281
- expected: "(string | undefined)",
282
- value: input.plan
283
- }), undefined === input.prismaSchemas || "string" === typeof input.prismaSchemas || _report(_exceptionable, {
284
- path: _path + ".prismaSchemas",
285
- expected: "(string | undefined)",
286
- value: input.prismaSchemas
287
- }), undefined === input.review || "string" === typeof input.review || _report(_exceptionable, {
315
+ })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.review || _report(_exceptionable, {
288
316
  path: _path + ".review",
289
- expected: "(string | undefined)",
317
+ expected: "string",
290
318
  value: input.review
291
- }), "string" === typeof input.final || _report(_exceptionable, {
319
+ }), null === input.final || "string" === typeof input.final || _report(_exceptionable, {
292
320
  path: _path + ".final",
293
- expected: "string",
321
+ expected: "(null | string)",
294
322
  value: input.final
295
323
  })].every(flag => flag); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
296
324
  if (false === __is(input)) {
@@ -333,78 +361,80 @@ const collection = {
333
361
  },
334
362
  functions: [
335
363
  {
336
- name: "review",
364
+ name: "correct",
337
365
  parameters: {
338
- description: " Properties containing the multi-phase error correction process\n\n------------------------------\n\nDescription of the current {@link IAutoBeRealizeCorrectApplication.IProps} type:\n\n> Properties for error correction following Chain of Thinking (CoT).\n> \n> All phases are wrapped in a `revise` object for systematic error\n> resolution.\n\n### Description of {@link revise} property:\n\n> Revision process containing all error correction phases.",
366
+ description: " Three-phase correction properties\n\n------------------------------\n\nCurrent Type: {@link IAutoBeRealizeCorrectApplication.IProps}\n\n### Description of {@link revise} property:\n\n> Revision and finalization phase.\n> \n> Reviews the draft corrections and produces the final, error-free code\n> that maintains all business requirements.",
339
367
  type: "object",
340
368
  properties: {
369
+ think: {
370
+ description: "Initial error analysis and correction strategy.\n\nAnalyzes TypeScript compilation errors to understand:\n\n- Error patterns and root causes\n- Required fixes and their impact\n- Whether quick fixes or deep refactoring is needed\n- Prisma schema and API contract constraints",
371
+ type: "string"
372
+ },
373
+ draft: {
374
+ description: "First correction attempt.\n\nImplements the initial fixes identified in the think phase. For simple\nerrors (typos, missing imports), this may be the final solution. Complex\nerrors may require further refinement.",
375
+ type: "string"
376
+ },
341
377
  revise: {
342
- $ref: "#/$defs/IAutoBeRealizeCorrectApplication.IRevise"
378
+ $ref: "#/$defs/IAutoBeRealizeCorrectApplication.IReviseProps"
343
379
  }
344
380
  },
345
381
  required: [
382
+ "think",
383
+ "draft",
346
384
  "revise"
347
385
  ],
348
386
  additionalProperties: false,
349
387
  $defs: {
350
- "IAutoBeRealizeCorrectApplication.IRevise": {
388
+ "IAutoBeRealizeCorrectApplication.IReviseProps": {
351
389
  type: "object",
352
390
  properties: {
353
- errorAnalysis: {
354
- description: "Step 1: TypeScript compilation error analysis and resolution strategy.\nAnalyzes TypeScript compiler diagnostics (error codes, messages) to understand\ntype mismatches, missing properties, nullable conflicts, and other compilation issues.",
355
- type: "string"
356
- },
357
- plan: {
358
- description: "Step 2: Provider function implementation plan.",
359
- type: "string"
360
- },
361
- prismaSchemas: {
362
- description: "Step 3: Relevant Prisma schema definitions.",
363
- type: "string"
364
- },
365
391
  review: {
366
- description: "Step 4: Refined version with improved completeness.",
392
+ description: "Correction review and validation.\n\nAnalyzes the draft corrections to ensure:\n\n- All TypeScript errors are resolved\n- Business logic remains intact\n- AutoBE coding standards are maintained\n- No new errors are introduced\n- Performance and security are preserved",
367
393
  type: "string"
368
394
  },
369
395
  final: {
370
- description: "Step 5: Final complete TypeScript function implementation.",
371
- type: "string"
396
+ description: "Final error-free implementation.\n\nThe complete, corrected code that passes all TypeScript compilation\nchecks.\n\nReturns `null` if the draft corrections are sufficient and need no\nfurther changes.",
397
+ anyOf: [
398
+ {
399
+ type: "null"
400
+ },
401
+ {
402
+ type: "string"
403
+ }
404
+ ]
372
405
  }
373
406
  },
374
407
  required: [
408
+ "review",
375
409
  "final"
376
410
  ]
377
411
  }
378
412
  }
379
413
  },
380
- description: "Reviews and corrects TypeScript compilation errors.\n\nFixes TypeScript compilation errors while preserving original business\nlogic, applying minimal intervention principle.",
381
- validate: (() => { const _io0 = input => "object" === typeof input.revise && null !== input.revise && _io1(input.revise); const _io1 = input => (undefined === input.errorAnalysis || "string" === typeof input.errorAnalysis) && (undefined === input.plan || "string" === typeof input.plan) && (undefined === input.prismaSchemas || "string" === typeof input.prismaSchemas) && (undefined === input.review || "string" === typeof input.review) && "string" === typeof input.final; const _vo0 = (input, _path, _exceptionable = true) => [("object" === typeof input.revise && null !== input.revise || _report(_exceptionable, {
414
+ description: "Systematically analyze and correct TypeScript compilation errors.\n\nImplements a three-phase workflow (think \u2192 draft \u2192 revise) that balances\nefficiency for simple errors with thoroughness for complex problems.",
415
+ validate: (() => { const _io0 = input => "string" === typeof input.think && "string" === typeof input.draft && ("object" === typeof input.revise && null !== input.revise && _io1(input.revise)); const _io1 = input => "string" === typeof input.review && (null === input.final || "string" === typeof input.final); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.think || _report(_exceptionable, {
416
+ path: _path + ".think",
417
+ expected: "string",
418
+ value: input.think
419
+ }), "string" === typeof input.draft || _report(_exceptionable, {
420
+ path: _path + ".draft",
421
+ expected: "string",
422
+ value: input.draft
423
+ }), ("object" === typeof input.revise && null !== input.revise || _report(_exceptionable, {
382
424
  path: _path + ".revise",
383
- expected: "IAutoBeRealizeCorrectApplication.IRevise",
425
+ expected: "IAutoBeRealizeCorrectApplication.IReviseProps",
384
426
  value: input.revise
385
427
  })) && _vo1(input.revise, _path + ".revise", true && _exceptionable) || _report(_exceptionable, {
386
428
  path: _path + ".revise",
387
- expected: "IAutoBeRealizeCorrectApplication.IRevise",
429
+ expected: "IAutoBeRealizeCorrectApplication.IReviseProps",
388
430
  value: input.revise
389
- })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => [undefined === input.errorAnalysis || "string" === typeof input.errorAnalysis || _report(_exceptionable, {
390
- path: _path + ".errorAnalysis",
391
- expected: "(string | undefined)",
392
- value: input.errorAnalysis
393
- }), undefined === input.plan || "string" === typeof input.plan || _report(_exceptionable, {
394
- path: _path + ".plan",
395
- expected: "(string | undefined)",
396
- value: input.plan
397
- }), undefined === input.prismaSchemas || "string" === typeof input.prismaSchemas || _report(_exceptionable, {
398
- path: _path + ".prismaSchemas",
399
- expected: "(string | undefined)",
400
- value: input.prismaSchemas
401
- }), undefined === input.review || "string" === typeof input.review || _report(_exceptionable, {
431
+ })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.review || _report(_exceptionable, {
402
432
  path: _path + ".review",
403
- expected: "(string | undefined)",
433
+ expected: "string",
404
434
  value: input.review
405
- }), "string" === typeof input.final || _report(_exceptionable, {
435
+ }), null === input.final || "string" === typeof input.final || _report(_exceptionable, {
406
436
  path: _path + ".final",
407
- expected: "string",
437
+ expected: "(null | string)",
408
438
  value: input.final
409
439
  })].every(flag => flag); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
410
440
  if (false === __is(input)) {
@@ -1 +1 @@
1
- {"version":3,"file":"orchestrateRealizeCorrect.js","sourceRoot":"","sources":["../../../src/orchestrate/realize/orchestrateRealizeCorrect.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAwBA,8DA0FC;;AA5GD,yCAA2C;AAG3C,kDAA0B;AAC1B,+BAA0B;AAG1B,uEAAoE;AACpE,uEAAoE;AACpE,mGAAgG;AAChG,wEAAqE;AAIrE,iEAA8D;AAC9D,mEAAgE;AAChE,6EAA0E;AAE1E,SAAsB,yBAAyB;yDAC7C,GAAyB,EACzB,SAAyC,EACzC,cAA4C,EAC5C,SAAkC,EAClC,QAAyC,EACzC,QAAiC,EACjC,OAAe,GAAG,CAAC,KAAK;QAExB,MAAM,KAAK,GAAG,MAAM,IAAA,yCAAmB,EAAC,GAAG,EAAE;YAC3C,cAAc;YACd,SAAS;SACV,CAAC,CAAC;QACH,IAAI,KAAK,CAAC,MAAM,CAAC,IAAI,KAAK,SAAS;YAAE,OAAO,SAAS,CAAC;aACjD,IAAI,IAAI,GAAG,CAAC;YAAE,OAAO,SAAS,CAAC;QAEpC,kCAAkC;QAClC,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC,WAAW,CAAC;QAE7C,IACE,KAAK,CAAC,MAAM,CAAC,WAAW,CAA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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGT,CAAC;AACJ,MAAM,UAAU,GAAG;IACjB,OAAO;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAAsE;IAC7E,MAAM;IACN,KAAK,EAAE,MAAM;IACb,QAAQ,EAAE,MAAM;IAChB,KAAK,EAAE,MAAM;CACd,CAAC"}
1
+ {"version":3,"file":"orchestrateRealizeCorrect.js","sourceRoot":"","sources":["../../../src/orchestrate/realize/orchestrateRealizeCorrect.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyBA,8DA2FC;;AA9GD,yCAA2C;AAG3C,kDAA0B;AAC1B,+BAA0B;AAG1B,uEAAoE;AACpE,uEAAoE;AACpE,mGAAgG;AAChG,wEAAqE;AAIrE,iEAA8D;AAC9D,qFAAkF;AAClF,mEAAgE;AAChE,6EAA0E;AAE1E,SAAsB,yBAAyB;yDAC7C,GAAyB,EACzB,SAAyC,EACzC,cAA4C,EAC5C,SAAkC,EAClC,QAAyC,EACzC,QAAiC,EACjC,OAAe,GAAG,CAAC,KAAK;QAExB,MAAM,KAAK,GAAG,MAAM,IAAA,yCAAmB,EAAC,GAAG,EAAE;YAC3C,cAAc;YACd,SAAS;SACV,CAAC,CAAC;QACH,IAAI,KAAK,CAAC,MAAM,CAAC,IAAI,KAAK,SAAS;YAAE,OAAO,SAAS,CAAC;aACjD,IAAI,IAAI,GAAG,CAAC;YAAE,OAAO,SAAS,CAAC;QAEpC,kCAAkC;QAClC,MAAM,WAAW,GAAG,KAAK,CAAC,MAAM,CAAC,WAAW,CAAC;QAE7C,IACE,KAAK,CAAC,MAAM,CAAC,WAAW,CAAC,KAAK,CAC5B,CAAC,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AAE,MAAM;CACd,CAAC"}
@@ -1,8 +1,9 @@
1
- import { AutoBeProgressEventBase, AutoBeRealizeAuthorization, AutoBeRealizeWriteEvent } from "@autobe/interface";
1
+ import { AutoBeOpenApi, AutoBeProgressEventBase, AutoBeRealizeAuthorization, AutoBeRealizeWriteEvent } from "@autobe/interface";
2
2
  import { ILlmSchema } from "@samchon/openapi";
3
3
  import { AutoBeContext } from "../../context/AutoBeContext";
4
4
  import { IAutoBeRealizeScenarioResult } from "./structures/IAutoBeRealizeScenarioResult";
5
5
  export declare function orchestrateRealizeWrite<Model extends ILlmSchema.Model>(ctx: AutoBeContext<Model>, props: {
6
+ document: AutoBeOpenApi.IDocument;
6
7
  totalAuthorizations: AutoBeRealizeAuthorization[];
7
8
  authorization: AutoBeRealizeAuthorization | null;
8
9
  scenario: IAutoBeRealizeScenarioResult;