@autobe/agent 0.30.4 → 0.30.5

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 (210) hide show
  1. package/lib/constants/AutoBeSystemPromptConstant.d.ts +5 -4
  2. package/lib/constants/AutoBeSystemPromptConstant.js.map +1 -1
  3. package/lib/describe/image/orchestrateImageDescribeDraft.js +6 -6
  4. package/lib/describe/image/structures/IAutoBeImageDescribeDraftApplication.d.ts +12 -63
  5. package/lib/index.mjs +2918 -2842
  6. package/lib/index.mjs.map +1 -1
  7. package/lib/orchestrate/analyze/orchestrateAnalyzeExtractDecisions.js +8 -8
  8. package/lib/orchestrate/analyze/orchestrateAnalyzeScenario.js +36 -37
  9. package/lib/orchestrate/analyze/orchestrateAnalyzeScenario.js.map +1 -1
  10. package/lib/orchestrate/analyze/orchestrateAnalyzeScenarioReview.js +7 -7
  11. package/lib/orchestrate/analyze/orchestrateAnalyzeSectionCrossFileReview.js +55 -42
  12. package/lib/orchestrate/analyze/orchestrateAnalyzeSectionCrossFileReview.js.map +1 -1
  13. package/lib/orchestrate/analyze/orchestrateAnalyzeSectionReview.js +67 -54
  14. package/lib/orchestrate/analyze/orchestrateAnalyzeSectionReview.js.map +1 -1
  15. package/lib/orchestrate/analyze/orchestrateAnalyzeWriteSection.js +24 -25
  16. package/lib/orchestrate/analyze/orchestrateAnalyzeWriteSection.js.map +1 -1
  17. package/lib/orchestrate/analyze/orchestrateAnalyzeWriteSectionPatch.js +24 -25
  18. package/lib/orchestrate/analyze/orchestrateAnalyzeWriteSectionPatch.js.map +1 -1
  19. package/lib/orchestrate/analyze/orchestrateAnalyzeWriteUnit.js +30 -31
  20. package/lib/orchestrate/analyze/orchestrateAnalyzeWriteUnit.js.map +1 -1
  21. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeExtractDecisionsApplication.d.ts +14 -52
  22. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioApplication.d.ts +23 -96
  23. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioReviewApplication.d.ts +12 -40
  24. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeSectionCrossFileReviewApplication.d.ts +30 -88
  25. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeSectionReviewApplication.d.ts +35 -94
  26. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeWriteSectionApplication.d.ts +23 -93
  27. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeWriteUnitApplication.d.ts +15 -88
  28. package/lib/orchestrate/common/histories/transformPreviousAndLatestCorrectHistory.js +76 -31
  29. package/lib/orchestrate/common/histories/transformPreviousAndLatestCorrectHistory.js.map +1 -1
  30. package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js +7 -7
  31. package/lib/orchestrate/common/structures/IAnalysisSectionEntry.d.ts +2 -8
  32. package/lib/orchestrate/common/structures/IAutoBeCommonCorrectCastingApplication.d.ts +8 -50
  33. package/lib/orchestrate/common/structures/IAutoBePreliminaryCollection.d.ts +1 -9
  34. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetAnalysisSections.d.ts +4 -23
  35. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetDatabaseSchemas.d.ts +3 -21
  36. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetInterfaceOperations.d.ts +4 -22
  37. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetInterfaceSchemas.d.ts +4 -22
  38. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetPreviousAnalysisSections.d.ts +5 -17
  39. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetPreviousDatabaseSchemas.d.ts +7 -76
  40. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetPreviousInterfaceOperations.d.ts +6 -89
  41. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetPreviousInterfaceSchemas.d.ts +7 -93
  42. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetRealizeCollectors.d.ts +3 -22
  43. package/lib/orchestrate/common/structures/IAutoBePreliminaryGetRealizeTransformers.d.ts +3 -22
  44. package/lib/orchestrate/interface/orchestrateInterfaceAuthorization.js +114 -139
  45. package/lib/orchestrate/interface/orchestrateInterfaceAuthorization.js.map +1 -1
  46. package/lib/orchestrate/interface/orchestrateInterfaceEndpointReview.js +90 -91
  47. package/lib/orchestrate/interface/orchestrateInterfaceEndpointReview.js.map +1 -1
  48. package/lib/orchestrate/interface/orchestrateInterfaceEndpointWrite.js +58 -59
  49. package/lib/orchestrate/interface/orchestrateInterfaceEndpointWrite.js.map +1 -1
  50. package/lib/orchestrate/interface/orchestrateInterfaceGroup.js +58 -59
  51. package/lib/orchestrate/interface/orchestrateInterfaceGroup.js.map +1 -1
  52. package/lib/orchestrate/interface/orchestrateInterfaceOperation.js +108 -132
  53. package/lib/orchestrate/interface/orchestrateInterfaceOperation.js.map +1 -1
  54. package/lib/orchestrate/interface/orchestrateInterfaceOperationReview.js +72 -72
  55. package/lib/orchestrate/interface/orchestrateInterfacePrerequisite.js +76 -77
  56. package/lib/orchestrate/interface/orchestrateInterfacePrerequisite.js.map +1 -1
  57. package/lib/orchestrate/interface/orchestrateInterfaceSchemaCasting.js +130 -159
  58. package/lib/orchestrate/interface/orchestrateInterfaceSchemaCasting.js.map +1 -1
  59. package/lib/orchestrate/interface/orchestrateInterfaceSchemaComplement.js +126 -155
  60. package/lib/orchestrate/interface/orchestrateInterfaceSchemaComplement.js.map +1 -1
  61. package/lib/orchestrate/interface/orchestrateInterfaceSchemaRefine.js +114 -142
  62. package/lib/orchestrate/interface/orchestrateInterfaceSchemaRefine.js.map +1 -1
  63. package/lib/orchestrate/interface/orchestrateInterfaceSchemaRename.js +5 -5
  64. package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.js +100 -129
  65. package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.js.map +1 -1
  66. package/lib/orchestrate/interface/orchestrateInterfaceSchemaWrite.js +120 -149
  67. package/lib/orchestrate/interface/orchestrateInterfaceSchemaWrite.js.map +1 -1
  68. package/lib/orchestrate/interface/structures/IAutoBeInterfaceAuthorizationApplication.d.ts +10 -97
  69. package/lib/orchestrate/interface/structures/IAutoBeInterfaceEndpointReviewApplication.d.ts +14 -83
  70. package/lib/orchestrate/interface/structures/IAutoBeInterfaceEndpointWriteApplication.d.ts +12 -90
  71. package/lib/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.d.ts +12 -80
  72. package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.d.ts +21 -116
  73. package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationReviewApplication.d.ts +24 -112
  74. package/lib/orchestrate/interface/structures/IAutoBeInterfacePrerequisiteApplication.d.ts +11 -83
  75. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.d.ts +11 -76
  76. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaCastingApplication.d.ts +18 -96
  77. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaComplementApplication.d.ts +11 -76
  78. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaRefineApplication.d.ts +25 -107
  79. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaRenameApplication.d.ts +5 -31
  80. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaReviewApplication.d.ts +6 -42
  81. package/lib/orchestrate/prisma/orchestratePrismaAuthorization.js +41 -41
  82. package/lib/orchestrate/prisma/orchestratePrismaAuthorizationReview.js +62 -63
  83. package/lib/orchestrate/prisma/orchestratePrismaAuthorizationReview.js.map +1 -1
  84. package/lib/orchestrate/prisma/orchestratePrismaComponent.js +40 -41
  85. package/lib/orchestrate/prisma/orchestratePrismaComponent.js.map +1 -1
  86. package/lib/orchestrate/prisma/orchestratePrismaComponentReview.js +60 -61
  87. package/lib/orchestrate/prisma/orchestratePrismaComponentReview.js.map +1 -1
  88. package/lib/orchestrate/prisma/orchestratePrismaCorrect.js +112 -116
  89. package/lib/orchestrate/prisma/orchestratePrismaCorrect.js.map +1 -1
  90. package/lib/orchestrate/prisma/orchestratePrismaGroup.js +48 -49
  91. package/lib/orchestrate/prisma/orchestratePrismaGroup.js.map +1 -1
  92. package/lib/orchestrate/prisma/orchestratePrismaGroupReview.js +70 -71
  93. package/lib/orchestrate/prisma/orchestratePrismaGroupReview.js.map +1 -1
  94. package/lib/orchestrate/prisma/orchestratePrismaSchema.js +118 -122
  95. package/lib/orchestrate/prisma/orchestratePrismaSchema.js.map +1 -1
  96. package/lib/orchestrate/prisma/orchestratePrismaSchemaReview.js +126 -131
  97. package/lib/orchestrate/prisma/orchestratePrismaSchemaReview.js.map +1 -1
  98. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseAuthorizationApplication.d.ts +22 -99
  99. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseAuthorizationReviewApplication.d.ts +12 -109
  100. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseComponentApplication.d.ts +14 -100
  101. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseComponentReviewApplication.d.ts +15 -108
  102. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseCorrectApplication.d.ts +24 -106
  103. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseGroupApplication.d.ts +13 -76
  104. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseGroupReviewApplication.d.ts +13 -111
  105. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseSchemaApplication.d.ts +26 -97
  106. package/lib/orchestrate/prisma/structures/IAutoBeDatabaseSchemaReviewApplication.d.ts +16 -93
  107. package/lib/orchestrate/realize/histories/transformRealizeOperationCorrectHistory.js +1 -1
  108. package/lib/orchestrate/realize/histories/transformRealizeOperationCorrectHistory.js.map +1 -1
  109. package/lib/orchestrate/realize/histories/transformRealizeOperationWriteHistory.js +1 -1
  110. package/lib/orchestrate/realize/histories/transformRealizeOperationWriteHistory.js.map +1 -1
  111. package/lib/orchestrate/realize/histories/transformRealizeTransformerCorrectHistory.js +20 -2
  112. package/lib/orchestrate/realize/histories/transformRealizeTransformerCorrectHistory.js.map +1 -1
  113. package/lib/orchestrate/realize/histories/transformRealizeTransformerWriteHistory.js +22 -2
  114. package/lib/orchestrate/realize/histories/transformRealizeTransformerWriteHistory.js.map +1 -1
  115. package/lib/orchestrate/realize/internal/orchestrateRealizeCorrectCasting.js +7 -7
  116. package/lib/orchestrate/realize/internal/orchestrateRealizeCorrectOverall.js +86 -6
  117. package/lib/orchestrate/realize/internal/orchestrateRealizeCorrectOverall.js.map +1 -1
  118. package/lib/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js +38 -38
  119. package/lib/orchestrate/realize/orchestrateRealizeAuthorizationWrite.js +34 -34
  120. package/lib/orchestrate/realize/orchestrateRealizeCollectorCorrectOverall.js +38 -38
  121. package/lib/orchestrate/realize/orchestrateRealizeCollectorPlan.js +54 -54
  122. package/lib/orchestrate/realize/orchestrateRealizeCollectorWrite.js +36 -36
  123. package/lib/orchestrate/realize/orchestrateRealizeOperationCorrectOverall.js +44 -44
  124. package/lib/orchestrate/realize/orchestrateRealizeOperationWrite.js +42 -42
  125. package/lib/orchestrate/realize/orchestrateRealizeTransformerCorrectCasting.js +1 -0
  126. package/lib/orchestrate/realize/orchestrateRealizeTransformerCorrectCasting.js.map +1 -1
  127. package/lib/orchestrate/realize/orchestrateRealizeTransformerCorrectOverall.js +46 -46
  128. package/lib/orchestrate/realize/orchestrateRealizeTransformerPlan.js +36 -36
  129. package/lib/orchestrate/realize/orchestrateRealizeTransformerWrite.js +44 -44
  130. package/lib/orchestrate/realize/programmers/AutoBeRealizeTransformerProgrammer.d.ts +18 -0
  131. package/lib/orchestrate/realize/programmers/AutoBeRealizeTransformerProgrammer.js +167 -8
  132. package/lib/orchestrate/realize/programmers/AutoBeRealizeTransformerProgrammer.js.map +1 -1
  133. package/lib/orchestrate/realize/structures/IAutoBeRealizeAuthorizationCorrectApplication.d.ts +17 -71
  134. package/lib/orchestrate/realize/structures/IAutoBeRealizeAuthorizationWriteApplication.d.ts +32 -92
  135. package/lib/orchestrate/realize/structures/IAutoBeRealizeCollectorCorrectApplication.d.ts +32 -114
  136. package/lib/orchestrate/realize/structures/IAutoBeRealizeCollectorPlanApplication.d.ts +29 -106
  137. package/lib/orchestrate/realize/structures/IAutoBeRealizeCollectorWriteApplication.d.ts +38 -131
  138. package/lib/orchestrate/realize/structures/IAutoBeRealizeOperationCorrectApplication.d.ts +16 -71
  139. package/lib/orchestrate/realize/structures/IAutoBeRealizeOperationWriteApplication.d.ts +16 -73
  140. package/lib/orchestrate/realize/structures/IAutoBeRealizeTransformerCorrectApplication.d.ts +37 -155
  141. package/lib/orchestrate/realize/structures/IAutoBeRealizeTransformerPlanApplication.d.ts +25 -88
  142. package/lib/orchestrate/realize/structures/IAutoBeRealizeTransformerWriteApplication.d.ts +48 -181
  143. package/lib/orchestrate/realize/utils/generateTS2339Hints.d.ts +5 -3
  144. package/lib/orchestrate/realize/utils/generateTS2339Hints.js +37 -19
  145. package/lib/orchestrate/realize/utils/generateTS2339Hints.js.map +1 -1
  146. package/lib/orchestrate/test/histories/transformTestOperationWriteHistory.js +2 -2
  147. package/lib/orchestrate/test/orchestrateTestScenario.js +22 -22
  148. package/lib/orchestrate/test/orchestrateTestScenarioReview.js +22 -22
  149. package/package.json +5 -5
  150. package/src/constants/AutoBeSystemPromptConstant.ts +5 -4
  151. package/src/describe/image/structures/IAutoBeImageDescribeDraftApplication.ts +12 -63
  152. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeExtractDecisionsApplication.ts +14 -52
  153. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioApplication.ts +23 -96
  154. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioReviewApplication.ts +12 -40
  155. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeSectionCrossFileReviewApplication.ts +30 -88
  156. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeSectionReviewApplication.ts +35 -94
  157. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeWriteSectionApplication.ts +23 -93
  158. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeWriteUnitApplication.ts +15 -88
  159. package/src/orchestrate/common/histories/transformPreviousAndLatestCorrectHistory.ts +92 -31
  160. package/src/orchestrate/common/structures/IAnalysisSectionEntry.ts +2 -8
  161. package/src/orchestrate/common/structures/IAutoBeCommonCorrectCastingApplication.ts +8 -50
  162. package/src/orchestrate/common/structures/IAutoBePreliminaryCollection.ts +1 -9
  163. package/src/orchestrate/common/structures/IAutoBePreliminaryGetAnalysisSections.ts +4 -23
  164. package/src/orchestrate/common/structures/IAutoBePreliminaryGetDatabaseSchemas.ts +3 -21
  165. package/src/orchestrate/common/structures/IAutoBePreliminaryGetInterfaceOperations.ts +4 -22
  166. package/src/orchestrate/common/structures/IAutoBePreliminaryGetInterfaceSchemas.ts +4 -22
  167. package/src/orchestrate/common/structures/IAutoBePreliminaryGetPreviousAnalysisSections.ts +5 -17
  168. package/src/orchestrate/common/structures/IAutoBePreliminaryGetPreviousDatabaseSchemas.ts +7 -76
  169. package/src/orchestrate/common/structures/IAutoBePreliminaryGetPreviousInterfaceOperations.ts +6 -89
  170. package/src/orchestrate/common/structures/IAutoBePreliminaryGetPreviousInterfaceSchemas.ts +7 -93
  171. package/src/orchestrate/common/structures/IAutoBePreliminaryGetRealizeCollectors.ts +3 -22
  172. package/src/orchestrate/common/structures/IAutoBePreliminaryGetRealizeTransformers.ts +3 -22
  173. package/src/orchestrate/interface/structures/IAutoBeInterfaceAuthorizationApplication.ts +10 -97
  174. package/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointReviewApplication.ts +14 -83
  175. package/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointWriteApplication.ts +12 -90
  176. package/src/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.ts +12 -80
  177. package/src/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.ts +21 -116
  178. package/src/orchestrate/interface/structures/IAutoBeInterfaceOperationReviewApplication.ts +24 -112
  179. package/src/orchestrate/interface/structures/IAutoBeInterfacePrerequisiteApplication.ts +11 -83
  180. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.ts +11 -76
  181. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaCastingApplication.ts +18 -96
  182. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaComplementApplication.ts +11 -76
  183. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaRefineApplication.ts +25 -107
  184. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaRenameApplication.ts +5 -31
  185. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaReviewApplication.ts +6 -42
  186. package/src/orchestrate/prisma/structures/IAutoBeDatabaseAuthorizationApplication.ts +22 -99
  187. package/src/orchestrate/prisma/structures/IAutoBeDatabaseAuthorizationReviewApplication.ts +12 -109
  188. package/src/orchestrate/prisma/structures/IAutoBeDatabaseComponentApplication.ts +14 -100
  189. package/src/orchestrate/prisma/structures/IAutoBeDatabaseComponentReviewApplication.ts +15 -108
  190. package/src/orchestrate/prisma/structures/IAutoBeDatabaseCorrectApplication.ts +24 -106
  191. package/src/orchestrate/prisma/structures/IAutoBeDatabaseGroupApplication.ts +13 -76
  192. package/src/orchestrate/prisma/structures/IAutoBeDatabaseGroupReviewApplication.ts +13 -111
  193. package/src/orchestrate/prisma/structures/IAutoBeDatabaseSchemaApplication.ts +26 -97
  194. package/src/orchestrate/prisma/structures/IAutoBeDatabaseSchemaReviewApplication.ts +16 -93
  195. package/src/orchestrate/realize/histories/transformRealizeTransformerCorrectHistory.ts +21 -1
  196. package/src/orchestrate/realize/histories/transformRealizeTransformerWriteHistory.ts +26 -4
  197. package/src/orchestrate/realize/internal/orchestrateRealizeCorrectOverall.ts +125 -9
  198. package/src/orchestrate/realize/orchestrateRealizeTransformerCorrectCasting.ts +1 -0
  199. package/src/orchestrate/realize/programmers/AutoBeRealizeTransformerProgrammer.ts +210 -7
  200. package/src/orchestrate/realize/structures/IAutoBeRealizeAuthorizationCorrectApplication.ts +17 -71
  201. package/src/orchestrate/realize/structures/IAutoBeRealizeAuthorizationWriteApplication.ts +32 -92
  202. package/src/orchestrate/realize/structures/IAutoBeRealizeCollectorCorrectApplication.ts +32 -114
  203. package/src/orchestrate/realize/structures/IAutoBeRealizeCollectorPlanApplication.ts +29 -106
  204. package/src/orchestrate/realize/structures/IAutoBeRealizeCollectorWriteApplication.ts +38 -131
  205. package/src/orchestrate/realize/structures/IAutoBeRealizeOperationCorrectApplication.ts +16 -71
  206. package/src/orchestrate/realize/structures/IAutoBeRealizeOperationWriteApplication.ts +16 -73
  207. package/src/orchestrate/realize/structures/IAutoBeRealizeTransformerCorrectApplication.ts +37 -155
  208. package/src/orchestrate/realize/structures/IAutoBeRealizeTransformerPlanApplication.ts +25 -88
  209. package/src/orchestrate/realize/structures/IAutoBeRealizeTransformerWriteApplication.ts +48 -181
  210. package/src/orchestrate/realize/utils/generateTS2339Hints.ts +39 -19
@@ -10,65 +10,26 @@ import { IAutoBePreliminaryGetPreviousInterfaceOperations } from "../../common/s
10
10
  import { IAutoBePreliminaryGetPreviousInterfaceSchemas } from "../../common/structures/IAutoBePreliminaryGetPreviousInterfaceSchemas";
11
11
 
12
12
  /**
13
- * Application interface for the Schema Refine agent.
14
- *
15
- * The Schema Refine agent detects and corrects degenerate type aliases where
16
- * complex data structures have been incorrectly simplified to primitive types
17
- * (`string`, `number`, `boolean`, `integer`).
18
- *
19
- * This agent analyzes JSDoc descriptions, database schema hints, and naming
20
- * conventions to identify mismatches between documented semantics and actual
21
- * type definitions, then provides corrected object schema definitions.
13
+ * Detects and corrects degenerate type aliases (primitives that should be
14
+ * objects).
22
15
  */
23
16
  export interface IAutoBeInterfaceSchemaCastingApplication {
24
- /**
25
- * Process schema refinement task or preliminary data requests.
26
- *
27
- * Analyzes a potentially degenerate primitive type alias and determines
28
- * whether it should be refined into a proper object schema structure. Uses
29
- * Chain-of-Thought reasoning to systematically evaluate the type.
30
- *
31
- * @param props Request containing either preliminary data request or
32
- * refinement completion
33
- */
17
+ /** Process task or retrieve preliminary data. */
34
18
  process(props: IAutoBeInterfaceSchemaCastingApplication.IProps): void;
35
19
  }
36
20
 
37
21
  export namespace IAutoBeInterfaceSchemaCastingApplication {
38
- /** Properties for schema refinement processing. */
22
+ /** Properties for schema casting processing. */
39
23
  export interface IProps {
40
24
  /**
41
- * Think before you act.
42
- *
43
- * Before requesting preliminary data or completing your task, reflect on
44
- * your current state and explain your reasoning:
45
- *
46
- * For preliminary requests (getAnalysisSections, getDatabaseSchemas, etc.):
47
- *
48
- * - What critical information is missing that you don't already have?
49
- * - Why do you need it specifically right now?
50
- * - Be brief - state the gap, don't list everything you have.
51
- *
52
- * For completion (complete):
53
- *
54
- * - What key assets did you acquire?
55
- * - What did you accomplish?
56
- * - Why is it sufficient to complete?
57
- * - Summarize - don't enumerate every single item.
58
- *
59
- * This reflection helps you avoid duplicate requests and premature
60
- * completion.
25
+ * Reasoning about your current state: what's missing (preliminary) or what
26
+ * you accomplished (completion).
61
27
  */
62
28
  thinking: string;
63
29
 
64
30
  /**
65
- * Type discriminator for the request.
66
- *
67
- * Determines which action to perform: preliminary data retrieval
68
- * (getAnalysisSections, getDatabaseSchemas, getInterfaceOperations,
69
- * getInterfaceSchemas, etc.) or final refinement decision (complete). When
70
- * preliminary returns empty array, that type is removed from the union,
71
- * physically preventing repeated calls.
31
+ * Action to perform. Exhausted preliminary types are removed from the
32
+ * union.
72
33
  */
73
34
  request:
74
35
  | IComplete
@@ -83,70 +44,31 @@ export namespace IAutoBeInterfaceSchemaCastingApplication {
83
44
  }
84
45
 
85
46
  /**
86
- * Request to complete schema refinement analysis.
87
- *
88
- * Executes the final refinement decision after analyzing a potentially
89
- * degenerate primitive type. Uses structured Chain-of-Thought reasoning
90
- * through observation, reasoning, and verdict properties to ensure systematic
91
- * evaluation before making a decision.
47
+ * Complete schema casting analysis via Chain-of-Thought (observation,
48
+ * reasoning, verdict).
92
49
  */
93
50
  export interface IComplete {
94
- /**
95
- * Type discriminator for the request.
96
- *
97
- * Determines which action to perform: preliminary data retrieval or actual
98
- * task execution. Value "complete" indicates this is the final refinement
99
- * decision request.
100
- */
51
+ /** Type discriminator for completion request. */
101
52
  type: "complete";
102
53
 
103
54
  /**
104
- * Observation of the current type and its documentation.
105
- *
106
- * Describe what you observe about the type being analyzed:
107
- *
108
- * - What is the current type definition? (e.g., `type IFoo = number`)
109
- * - What does the JSDoc/description say about the type?
110
- * - Are there any database schema hints (JSON field, etc.)?
111
- * - What does the naming suggest? (e.g., "Distribution", "Preferences")
112
- *
113
- * This is purely descriptive - state facts without judgment.
55
+ * Factual observation of the current type definition, JSDoc, schema hints,
56
+ * and naming.
114
57
  */
115
58
  observation: string;
116
59
 
117
- /**
118
- * Reasoning about whether the type is degenerate.
119
- *
120
- * Analyze the observations and explain your reasoning:
121
- *
122
- * - Does the documentation describe a structure that contradicts the
123
- * primitive type?
124
- * - Are there keywords suggesting complex structure? (key/value, array, list,
125
- * contains, mapping)
126
- * - Is this a legitimate semantic alias? (e.g., `IUserId = string`)
127
- * - What type SHOULD this be based on the evidence?
128
- */
60
+ /** Reasoning about whether documentation contradicts the primitive type. */
129
61
  reasoning: string;
130
62
 
131
63
  /**
132
- * Final verdict on whether to refine the type.
133
- *
134
- * State your conclusion clearly:
135
- *
136
- * - Is this a degenerate type that needs refinement, or a valid primitive?
137
- * - Summarize the key evidence that led to this decision.
138
- * - If refining, briefly describe what the correct type should be.
64
+ * Final verdict: "degenerate" (needs casting to object) or "valid
65
+ * primitive".
139
66
  */
140
67
  verdict: string;
141
68
 
142
69
  /**
143
- * Casting design for the corrected object schema, or `null` if intentional.
144
- *
145
- * When the type is degenerate: provide the casting design with corrected
146
- * object schema containing `databaseSchema`, `specification`,
147
- * `description`, and `schema` fields.
148
- *
149
- * When the type is intentional (valid primitive alias): set to `null`.
70
+ * Corrected object schema casting design, or `null` if the primitive is
71
+ * intentional.
150
72
  */
151
73
  casting: AutoBeInterfaceSchemaCasting | null;
152
74
  }
@@ -10,54 +10,21 @@ import { IAutoBePreliminaryGetPreviousInterfaceOperations } from "../../common/s
10
10
  import { IAutoBePreliminaryGetPreviousInterfaceSchemas } from "../../common/structures/IAutoBePreliminaryGetPreviousInterfaceSchemas";
11
11
 
12
12
  export interface IAutoBeInterfaceSchemaComplementApplication {
13
- /**
14
- * Process schema complement task or preliminary data requests.
15
- *
16
- * Adds missing schema definitions to ensure OpenAPI document is complete and
17
- * all referenced schemas are properly defined.
18
- *
19
- * @param props Request containing either preliminary data request or complete
20
- * task
21
- */
13
+ /** Process task or retrieve preliminary data. */
22
14
  process(props: IAutoBeInterfaceSchemaComplementApplication.IProps): void;
23
15
  }
24
16
 
25
17
  export namespace IAutoBeInterfaceSchemaComplementApplication {
26
18
  export interface IProps {
27
19
  /**
28
- * Think before you act.
29
- *
30
- * Before requesting preliminary data or completing your task, reflect on
31
- * your current state and explain your reasoning:
32
- *
33
- * For preliminary requests (getAnalysisSections, getDatabaseSchemas, etc.):
34
- *
35
- * - What critical information is missing that you don't already have?
36
- * - Why do you need it specifically right now?
37
- * - Be brief - state the gap, don't list everything you have.
38
- *
39
- * For completion (complete):
40
- *
41
- * - What key assets did you acquire?
42
- * - What did you accomplish?
43
- * - Why is it sufficient to complete?
44
- * - Summarize - don't enumerate every single item.
45
- *
46
- * This reflection helps you avoid duplicate requests and premature
47
- * completion.
20
+ * Reasoning about your current state: what's missing (preliminary) or what
21
+ * you accomplished (completion).
48
22
  */
49
23
  thinking: string;
50
24
 
51
25
  /**
52
- * Type discriminator for the request.
53
- *
54
- * Determines which action to perform: preliminary data retrieval
55
- * (getAnalysisSections, getDatabaseSchemas, getInterfaceOperations,
56
- * getInterfaceSchemas, getPreviousAnalysisSections,
57
- * getPreviousDatabaseSchemas, getPreviousInterfaceOperations,
58
- * getPreviousInterfaceSchemas) or final schema complementation (complete).
59
- * When preliminary returns empty array, that type is removed from the
60
- * union, physically preventing repeated calls.
26
+ * Action to perform. Exhausted preliminary types are removed from the
27
+ * union.
61
28
  */
62
29
  request:
63
30
  | IComplete
@@ -71,52 +38,20 @@ export namespace IAutoBeInterfaceSchemaComplementApplication {
71
38
  | IAutoBePreliminaryGetPreviousInterfaceSchemas;
72
39
  }
73
40
 
74
- /**
75
- * Request to add a missing schema definition.
76
- *
77
- * Executes schema complementation to fill in a referenced but undefined
78
- * schema type in the OpenAPI document's components.schemas section. Ensures
79
- * the $ref reference resolves to a valid schema definition.
80
- */
41
+ /** Add a missing schema definition referenced by $ref in components.schemas. */
81
42
  export interface IComplete {
82
- /**
83
- * Type discriminator for the request.
84
- *
85
- * Determines which action to perform: preliminary data retrieval or actual
86
- * task execution. Value "complete" indicates this is the final task
87
- * execution request.
88
- */
43
+ /** Type discriminator for completion request. */
89
44
  type: "complete";
90
45
 
91
- /**
92
- * Analysis of the missing type's purpose and context.
93
- *
94
- * Before designing the schema, analyze what you know:
95
- *
96
- * - What is this missing type for? Why is it referenced?
97
- * - Where is it referenced from? ($ref in which schemas/operations?)
98
- * - What does the reference context tell us about its expected structure?
99
- * - Are there similar types that provide structural hints?
100
- */
46
+ /** Analysis of the missing type's purpose and reference context. */
101
47
  analysis: string;
102
48
 
103
- /**
104
- * Rationale for the schema design decisions.
105
- *
106
- * Explain why you designed the schema this way:
107
- *
108
- * - Which properties did you include and why?
109
- * - What is required vs optional, and why?
110
- * - Which types use $ref and why?
111
- * - What was excluded and why? (e.g., auto-generated fields for ICreate)
112
- */
49
+ /** Rationale for the schema design decisions. */
113
50
  rationale: string;
114
51
 
115
52
  /**
116
- * Design structure for the missing schema being complemented.
117
- *
118
- * Contains `databaseSchema`, `specification`, `description`, and `schema`
119
- * fields that together define a complete DTO type component.
53
+ * Schema design: database mapping, specification, description, and JSON
54
+ * Schema.
120
55
  */
121
56
  design: AutoBeInterfaceSchemaDesign;
122
57
  }
@@ -13,29 +13,13 @@ import { IAutoBePreliminaryGetPreviousInterfaceOperations } from "../../common/s
13
13
  import { IAutoBePreliminaryGetPreviousInterfaceSchemas } from "../../common/structures/IAutoBePreliminaryGetPreviousInterfaceSchemas";
14
14
 
15
15
  /**
16
- * Function calling interface for enriching pure JSON Schema with documentation
17
- * and metadata.
18
- *
19
- * Guides the AI agent through adding `databaseSchemaProperty`, `specification`,
20
- * and `description` to each property in a schema that was initially generated
21
- * with only type structure. The refinement process ensures complete and
22
- * accurate schema definitions that properly map to database entities.
23
- *
24
- * The refinement follows a structured RAG workflow: preliminary context
25
- * gathering (analysis sections, database schemas, interface operations)
26
- * followed by property-level enrichment operations.
27
- *
28
- * @author Samchon
16
+ * Enriches JSON Schema properties with databaseSchemaProperty, specification,
17
+ * and description.
29
18
  */
30
19
  export interface IAutoBeInterfaceSchemaRefineApplication {
31
20
  /**
32
21
  * Process schema refinement task or preliminary data requests.
33
22
  *
34
- * Enriches OpenAPI schema definitions with documentation and metadata that
35
- * were omitted during initial generation. Processes property-level additions
36
- * including database field mappings, implementation specifications, and API
37
- * consumer descriptions.
38
- *
39
23
  * @param props Request containing either preliminary data request or complete
40
24
  * task
41
25
  */
@@ -46,35 +30,17 @@ export namespace IAutoBeInterfaceSchemaRefineApplication {
46
30
  /**
47
31
  * Think before you act.
48
32
  *
49
- * Before requesting preliminary data or completing your task, reflect on
50
- * your current state and explain your reasoning:
51
- *
52
- * For preliminary requests (getAnalysisSections, getDatabaseSchemas, etc.):
53
- *
54
- * - What critical information is missing that you don't already have?
55
- * - Why do you need it specifically right now?
56
- * - Be brief - state the gap, don't list everything you have.
57
- *
58
- * For completion (complete):
33
+ * For preliminary requests: what critical information is missing and why?
34
+ * Be brief state the gap, don't list everything you have.
59
35
  *
60
- * - What key assets did you acquire?
61
- * - What did you accomplish?
62
- * - Why is it sufficient to complete?
63
- * - Summarize - don't enumerate every single item.
64
- *
65
- * This reflection helps you avoid duplicate requests and premature
66
- * completion.
36
+ * For completion: what key assets did you acquire, what did you accomplish,
37
+ * why is it sufficient? Summarize — don't enumerate every single item.
67
38
  */
68
39
  thinking: string;
69
40
 
70
41
  /**
71
- * Type discriminator for the request.
72
- *
73
- * Determines which action to perform: preliminary data retrieval
74
- * (getAnalysisSections, getDatabaseSchemas, getInterfaceOperations,
75
- * getInterfaceSchemas) or final schema refinement (complete). When
76
- * preliminary returns empty array, that type is removed from the union,
77
- * physically preventing repeated calls.
42
+ * Action to perform. Exhausted preliminary types are removed from the
43
+ * union, physically preventing repeated calls.
78
44
  */
79
45
  request:
80
46
  | IComplete
@@ -88,93 +54,45 @@ export namespace IAutoBeInterfaceSchemaRefineApplication {
88
54
  | IAutoBePreliminaryGetPreviousInterfaceSchemas;
89
55
  }
90
56
 
91
- /**
92
- * Complete schema refinement with object-level and property-level enrichment.
93
- *
94
- * Executes the refinement to add documentation and metadata to a schema.
95
- * Includes both object-level context (databaseSchema, specification,
96
- * description) and property-level operations (depict, create, update,
97
- * erase).
98
- */
57
+ /** Complete schema refinement with object-level and property-level enrichment. */
99
58
  export interface IComplete {
100
- /**
101
- * Type discriminator for the request.
102
- *
103
- * Value "complete" indicates this is the final task execution request after
104
- * all preliminary data has been gathered.
105
- */
59
+ /** Type discriminator for completion request. */
106
60
  type: "complete";
107
61
 
108
- /**
109
- * Summary of refinement analysis and actions taken.
110
- *
111
- * Documents the agent's analysis of the schema's current state, including
112
- * which properties need documentation, any structural issues discovered,
113
- * and the overall assessment of what enrichment was performed.
114
- */
62
+ /** Summary of refinement analysis and actions taken. */
115
63
  review: string;
116
64
 
117
65
  /**
118
- * Database schema context for the type.
119
- *
120
- * Specifies which database table or entity this schema maps to, providing
121
- * context for property-level database field mappings. This establishes the
122
- * source of truth for data validation and transformation logic.
123
- *
124
- * Set to `null` for schemas that don't directly map to a single database
125
- * table (e.g., computed aggregations, cross-table joins, utility types).
66
+ * Database table this schema maps to, or `null` for non-table types
67
+ * (aggregations, joins, utility).
126
68
  */
127
69
  databaseSchema: string | null;
128
70
 
129
71
  /**
130
- * Specification for the schema implementation.
131
- *
132
- * Documents HOW the schema should be implemented, including data source
133
- * mappings, transformation rules, and technical implementation details.
134
- *
135
- * **MANDATORY**: You must always provide this value, even if the existing
136
- * specification is correct. This forces explicit review and strengthens
137
- * reasoning about the implementation details.
72
+ * HOW the schema should be implemented (data source mappings,
73
+ * transformation rules). **MANDATORY**: Always provide, even if existing
74
+ * value is correct this forces explicit review of implementation
75
+ * details.
138
76
  */
139
77
  specification: string;
140
78
 
141
79
  /**
142
- * Description for API consumers.
143
- *
144
- * Documents WHAT the schema represents for API consumers, explaining the
145
- * purpose and usage of this data type in the API context.
146
- *
147
- * **MANDATORY**: You must always provide this value, even if the existing
148
- * description is correct. This forces explicit review and strengthens
149
- * reasoning about the API documentation.
80
+ * WHAT the schema represents for API consumers. **MANDATORY**: Always
81
+ * provide, even if existing value is correct — this forces explicit review
82
+ * of consumer-facing documentation.
150
83
  */
151
84
  description: string;
152
85
 
153
86
  /**
154
- * Database properties explicitly excluded from this DTO.
155
- *
156
- * Declare every database property that intentionally does not appear in
157
- * this DTO. Together with `revises`, this must cover every database
158
- * property — each one must appear in exactly one of the two arrays.
87
+ * Database properties explicitly excluded from this DTO. Together with
88
+ * `revises`, must cover every database property exactly once.
159
89
  */
160
90
  excludes: AutoBeInterfaceSchemaPropertyExclude[];
161
91
 
162
92
  /**
163
- * Property-level refinement operations for DTO properties.
164
- *
165
- * Every DTO property must appear exactly once with one of:
166
- *
167
- * - `depict`: Add documentation to existing property
168
- * - `create`: Add missing property with documentation
169
- * - `update`: Fix incorrect type and add documentation
170
- * - `erase`: Remove invalid property
171
- *
172
- * Each operation includes the property key, reason for the action, and
173
- * complete metadata including `databaseSchemaProperty`, `specification`,
174
- * and `description`.
175
- *
176
- * Database properties are addressed either here (via
177
- * `databaseSchemaProperty`) or in `excludes`. No property can be omitted.
93
+ * Property-level refinement operations (depict/create/update/erase). Every
94
+ * DTO property must appear exactly once. Database properties go here (via
95
+ * `databaseSchemaProperty`) or in `excludes`. No omissions allowed.
178
96
  */
179
97
  revises: AutoBeInterfaceSchemaPropertyRefine[];
180
98
  }
@@ -2,43 +2,17 @@ import { AutoBeInterfaceSchemaRefactor } from "@autobe/interface";
2
2
 
3
3
  export interface IAutoBeInterfaceSchemaRenameApplication {
4
4
  /**
5
- * Analyze DTO type names and identify naming violations.
6
- *
7
- * This method examines existing DTO type names to detect violations of the
8
- * CRITICAL naming rule: ALL words from the database table name MUST be
9
- * preserved in the DTO type name. Omitting intermediate words breaks
10
- * type-to-table traceability and causes system failures.
11
- *
12
- * The method receives a list of database table names and current DTO type
13
- * names, then identifies which type names incorrectly omit service prefixes
14
- * or intermediate components from their corresponding table names.
15
- *
16
- * @param props Properties containing refactoring operations to fix naming
17
- * violations.
5
+ * Identify DTO type names that violate the naming rule: ALL words from the
6
+ * database table name MUST be preserved in the DTO type name.
18
7
  */
19
8
  rename(props: IAutoBeInterfaceSchemaRenameApplication.IProps): void;
20
9
  }
21
10
  export namespace IAutoBeInterfaceSchemaRenameApplication {
22
11
  export interface IProps {
23
12
  /**
24
- * List of refactoring operations to rename incorrectly named DTO types.
25
- *
26
- * Each refactor specifies:
27
- *
28
- * - `from`: The current INCORRECT type name (e.g., "ISale", "IBbsComment")
29
- * - `to`: The CORRECT type name with all components preserved (e.g.,
30
- * "IShoppingSale", "IBbsArticleComment")
31
- *
32
- * IMPORTANT: Only include type names that violate the naming rules. If a
33
- * type name correctly preserves all components from the table name, do NOT
34
- * include it in the refactors list.
35
- *
36
- * The orchestrator will automatically handle:
37
- *
38
- * - Renaming the base type (e.g., ISale → IShoppingSale)
39
- * - Renaming all variants (e.g., ISale.ICreate → IShoppingSale.ICreate)
40
- * - Renaming page types (e.g., IPageISale → IPageIShoppingSale)
41
- * - Updating all $ref references throughout the OpenAPI document
13
+ * Refactoring operations for incorrectly named DTO types. Only include
14
+ * violations. Orchestrator auto-handles variants, page types, and $ref
15
+ * updates.
42
16
  */
43
17
  refactors: AutoBeInterfaceSchemaRefactor[];
44
18
  }
@@ -13,51 +13,20 @@ import { IAutoBePreliminaryGetPreviousInterfaceOperations } from "../../common/s
13
13
  import { IAutoBePreliminaryGetPreviousInterfaceSchemas } from "../../common/structures/IAutoBePreliminaryGetPreviousInterfaceSchemas";
14
14
 
15
15
  export interface IAutoBeInterfaceSchemaReviewApplication {
16
- /**
17
- * Process schema review task or preliminary data requests.
18
- *
19
- * Reviews and validates OpenAPI schema definitions to ensure quality,
20
- * correctness, and compliance with domain requirements and system policies.
21
- *
22
- * @param props Request containing either preliminary data request or complete
23
- * task
24
- */
16
+ /** Process task or retrieve preliminary data. */
25
17
  process(props: IAutoBeInterfaceSchemaReviewApplication.IProps): void;
26
18
  }
27
19
  export namespace IAutoBeInterfaceSchemaReviewApplication {
28
20
  export interface IProps {
29
21
  /**
30
- * Think before you act.
31
- *
32
- * Before requesting preliminary data or completing your task, reflect on
33
- * your current state and explain your reasoning:
34
- *
35
- * For preliminary requests (getAnalysisSections, getDatabaseSchemas, etc.):
36
- *
37
- * - What critical information is missing that you don't already have?
38
- * - Why do you need it specifically right now?
39
- * - Be brief - state the gap, don't list everything you have.
40
- *
41
- * For completion (complete):
42
- *
43
- * - What key assets did you acquire?
44
- * - What did you accomplish?
45
- * - Why is it sufficient to complete?
46
- * - Summarize - don't enumerate every single item.
47
- *
48
- * This reflection helps you avoid duplicate requests and premature
49
- * completion.
22
+ * Reasoning about your current state: what's missing (preliminary) or what
23
+ * you accomplished (completion).
50
24
  */
51
25
  thinking: string;
52
26
 
53
27
  /**
54
- * Type discriminator for the request.
55
- *
56
- * Determines which action to perform: preliminary data retrieval
57
- * (getAnalysisSections, getDatabaseSchemas, getInterfaceOperations,
58
- * getInterfaceSchemas) or final schema review (complete). When preliminary
59
- * returns empty array, that type is removed from the union, physically
60
- * preventing repeated calls.
28
+ * Action to perform. Exhausted preliminary types are removed from the
29
+ * union.
61
30
  */
62
31
  request:
63
32
  | IComplete
@@ -73,12 +42,7 @@ export namespace IAutoBeInterfaceSchemaReviewApplication {
73
42
 
74
43
  /** Complete schema review with property-level revisions. */
75
44
  export interface IComplete {
76
- /**
77
- * Type discriminator for the request.
78
- *
79
- * Value "complete" indicates this is the final review submission after all
80
- * preliminary data has been gathered.
81
- */
45
+ /** Type discriminator for completion request. */
82
46
  type: "complete";
83
47
 
84
48
  /** Summary of issues found and fixes applied. */