@autobe/agent 0.26.0 → 0.28.0
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/lib/AutoBeAgent.d.ts +2 -1
- package/lib/AutoBeAgent.js +27 -7
- package/lib/AutoBeAgent.js.map +1 -1
- package/lib/AutoBeMockAgent.js +2 -4
- package/lib/AutoBeMockAgent.js.map +1 -1
- package/lib/constants/AutoBeSystemPromptConstant.d.ts +11 -11
- package/lib/context/AutoBeContext.d.ts +4 -1
- package/lib/context/AutoBeTokenUsage.d.ts +1 -1
- package/lib/context/AutoBeTokenUsage.js.map +1 -1
- package/lib/context/assertSchemaModel.d.ts +1 -1
- package/lib/context/assertSchemaModel.js +4 -7
- package/lib/context/assertSchemaModel.js.map +1 -1
- package/lib/factory/AutoBeFunctionCallingMetricFactory.d.ts +7 -0
- package/lib/factory/AutoBeFunctionCallingMetricFactory.js +35 -0
- package/lib/factory/AutoBeFunctionCallingMetricFactory.js.map +1 -0
- package/lib/factory/AutoBeProcessAggregateFactory.d.ts +13 -0
- package/lib/factory/AutoBeProcessAggregateFactory.js +100 -0
- package/lib/factory/AutoBeProcessAggregateFactory.js.map +1 -0
- package/lib/factory/createAutoBeContext.d.ts +2 -1
- package/lib/factory/createAutoBeContext.js +78 -27
- package/lib/factory/createAutoBeContext.js.map +1 -1
- package/lib/index.mjs +24065 -12997
- package/lib/index.mjs.map +1 -1
- package/lib/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.js +1 -1
- package/lib/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.js.map +1 -1
- package/lib/orchestrate/analyze/orchestrateAnalyze.js +1 -0
- package/lib/orchestrate/analyze/orchestrateAnalyze.js.map +1 -1
- package/lib/orchestrate/analyze/orchestrateAnalyzeReview.js +166 -87
- package/lib/orchestrate/analyze/orchestrateAnalyzeReview.js.map +1 -1
- package/lib/orchestrate/analyze/orchestrateAnalyzeScenario.js +639 -322
- package/lib/orchestrate/analyze/orchestrateAnalyzeScenario.js.map +1 -1
- package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.js +146 -76
- package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.js.map +1 -1
- package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeReviewApplication.d.ts +17 -52
- package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioApplication.d.ts +25 -22
- package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeWriteApplication.d.ts +7 -23
- package/lib/orchestrate/common/orchestrateCommonCorrectCasting.d.ts +2 -1
- package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js +168 -4
- package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js.map +1 -1
- package/lib/{factory/createAutoBeApplication.d.ts → orchestrate/facade/createAutoBeFacadeController.d.ts} +2 -2
- package/lib/orchestrate/facade/createAutoBeFacadeController.js +1308 -0
- package/lib/orchestrate/facade/createAutoBeFacadeController.js.map +1 -0
- package/lib/orchestrate/facade/histories/IAutoBeFacadeApplication.js.map +1 -0
- package/lib/orchestrate/facade/histories/IAutoBeFacadeApplicationProps.js.map +1 -0
- package/lib/orchestrate/facade/histories/IAutoBeFacadeApplicationResult.js.map +1 -0
- package/lib/orchestrate/facade/{transformFacadeStateMessage.d.ts → structures/transformFacadeStateMessage.d.ts} +1 -1
- package/lib/orchestrate/facade/structures/transformFacadeStateMessage.js.map +1 -0
- package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.js +2 -2
- package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.js.map +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceEndpointHistories.js +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceEndpointHistories.js.map +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.js +3 -2
- package/lib/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.js.map +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.js +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.js.map +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceOperationHistories.js +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceOperationHistories.js.map +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceOperationsReviewHistories.js +2 -2
- package/lib/orchestrate/interface/histories/transformInterfaceOperationsReviewHistories.js.map +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.js +1 -1
- package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterface.d.ts +1 -1
- package/lib/orchestrate/interface/orchestrateInterface.js +15 -8
- package/lib/orchestrate/interface/orchestrateInterface.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceAuthorizations.js +874 -49
- package/lib/orchestrate/interface/orchestrateInterfaceAuthorizations.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceComplement.js +1858 -67
- package/lib/orchestrate/interface/orchestrateInterfaceComplement.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js +251 -133
- package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceEndpointsReview.d.ts +0 -6
- package/lib/orchestrate/interface/orchestrateInterfaceEndpointsReview.js +257 -135
- package/lib/orchestrate/interface/orchestrateInterfaceEndpointsReview.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceGroups.js +341 -227
- package/lib/orchestrate/interface/orchestrateInterfaceGroups.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceOperations.js +761 -49
- package/lib/orchestrate/interface/orchestrateInterfaceOperations.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceOperationsReview.js +911 -50
- package/lib/orchestrate/interface/orchestrateInterfaceOperationsReview.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.js +207 -4
- package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceSchemaRename.js +109 -2
- package/lib/orchestrate/interface/orchestrateInterfaceSchemaRename.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.d.ts +5 -3
- package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.js +1904 -77
- package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.js.map +1 -1
- package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js +1858 -67
- package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js.map +1 -1
- package/lib/orchestrate/interface/utils/JsonSchemaFactory.js +23 -23
- package/lib/orchestrate/prisma/orchestratePrisma.d.ts +1 -1
- package/lib/orchestrate/prisma/orchestratePrisma.js +1 -0
- package/lib/orchestrate/prisma/orchestratePrisma.js.map +1 -1
- package/lib/orchestrate/prisma/orchestratePrismaComponent.js +391 -197
- package/lib/orchestrate/prisma/orchestratePrismaComponent.js.map +1 -1
- package/lib/orchestrate/prisma/orchestratePrismaCorrect.js +1168 -591
- package/lib/orchestrate/prisma/orchestratePrismaCorrect.js.map +1 -1
- package/lib/orchestrate/prisma/orchestratePrismaReview.js +1186 -600
- package/lib/orchestrate/prisma/orchestratePrismaReview.js.map +1 -1
- package/lib/orchestrate/prisma/orchestratePrismaSchemas.js +6 -3
- package/lib/orchestrate/prisma/orchestratePrismaSchemas.js.map +1 -1
- package/lib/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.js +2 -2
- package/lib/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealize.d.ts +1 -1
- package/lib/orchestrate/realize/orchestrateRealize.js +2 -1
- package/lib/orchestrate/realize/orchestrateRealize.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js +362 -180
- package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js +399 -199
- package/lib/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealizeCorrect.js +133 -4
- package/lib/orchestrate/realize/orchestrateRealizeCorrect.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealizeCorrectCasting.js +171 -7
- package/lib/orchestrate/realize/orchestrateRealizeCorrectCasting.js.map +1 -1
- package/lib/orchestrate/realize/orchestrateRealizeWrite.js +132 -3
- package/lib/orchestrate/realize/orchestrateRealizeWrite.js.map +1 -1
- package/lib/orchestrate/realize/utils/replaceImportStatements.js +0 -85
- package/lib/orchestrate/realize/utils/replaceImportStatements.js.map +1 -1
- package/lib/orchestrate/test/histories/transformTestWriteHistories.js.map +1 -1
- package/lib/orchestrate/test/orchestrateTest.d.ts +1 -1
- package/lib/orchestrate/test/orchestrateTest.js +2 -1
- package/lib/orchestrate/test/orchestrateTest.js.map +1 -1
- package/lib/orchestrate/test/orchestrateTestCorrect.js +134 -3
- package/lib/orchestrate/test/orchestrateTestCorrect.js.map +1 -1
- package/lib/orchestrate/test/orchestrateTestCorrectInvalidRequest.js +169 -4
- package/lib/orchestrate/test/orchestrateTestCorrectInvalidRequest.js.map +1 -1
- package/lib/orchestrate/test/orchestrateTestScenario.js +257 -4
- package/lib/orchestrate/test/orchestrateTestScenario.js.map +1 -1
- package/lib/orchestrate/test/orchestrateTestScenarioReview.js +283 -4
- package/lib/orchestrate/test/orchestrateTestScenarioReview.js.map +1 -1
- package/lib/orchestrate/test/orchestrateTestWrite.js +141 -3
- package/lib/orchestrate/test/orchestrateTestWrite.js.map +1 -1
- package/lib/utils/TokenUsageComputer.d.ts +5 -0
- package/lib/utils/TokenUsageComputer.js +29 -0
- package/lib/utils/TokenUsageComputer.js.map +1 -0
- package/package.json +10 -10
- package/src/AutoBeAgent.ts +40 -6
- package/src/AutoBeMockAgent.ts +2 -4
- package/src/constants/AutoBeSystemPromptConstant.ts +11 -11
- package/src/context/AutoBeContext.ts +8 -0
- package/src/context/AutoBeTokenUsage.ts +1 -1
- package/src/context/assertSchemaModel.ts +5 -8
- package/src/factory/AutoBeFunctionCallingMetricFactory.ts +44 -0
- package/src/factory/AutoBeProcessAggregateFactory.ts +141 -0
- package/src/factory/createAutoBeContext.ts +96 -36
- package/src/orchestrate/analyze/orchestrateAnalyze.ts +1 -0
- package/src/orchestrate/analyze/orchestrateAnalyzeReview.ts +9 -10
- package/src/orchestrate/analyze/orchestrateAnalyzeScenario.ts +15 -10
- package/src/orchestrate/analyze/orchestrateAnalyzeWrite.ts +10 -11
- package/src/orchestrate/analyze/structures/IAutoBeAnalyzeReviewApplication.ts +19 -54
- package/src/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioApplication.ts +25 -22
- package/src/orchestrate/analyze/structures/IAutoBeAnalyzeWriteApplication.ts +8 -24
- package/src/orchestrate/common/orchestrateCommonCorrectCasting.ts +20 -3
- package/src/orchestrate/facade/createAutoBeFacadeController.ts +136 -0
- package/src/orchestrate/facade/{transformFacadeStateMessage.ts → structures/transformFacadeStateMessage.ts} +2 -2
- package/src/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.ts +1 -0
- package/src/orchestrate/interface/orchestrateInterface.ts +17 -6
- package/src/orchestrate/interface/orchestrateInterfaceAuthorizations.ts +13 -2
- package/src/orchestrate/interface/orchestrateInterfaceComplement.ts +13 -2
- package/src/orchestrate/interface/orchestrateInterfaceEndpoints.ts +16 -11
- package/src/orchestrate/interface/orchestrateInterfaceEndpointsReview.ts +16 -13
- package/src/orchestrate/interface/orchestrateInterfaceGroups.ts +19 -15
- package/src/orchestrate/interface/orchestrateInterfaceOperations.ts +13 -2
- package/src/orchestrate/interface/orchestrateInterfaceOperationsReview.ts +16 -2
- package/src/orchestrate/interface/orchestrateInterfacePrerequisites.ts +13 -2
- package/src/orchestrate/interface/orchestrateInterfaceSchemaRename.ts +11 -2
- package/src/orchestrate/interface/orchestrateInterfaceSchemaReview.ts +24 -16
- package/src/orchestrate/interface/orchestrateInterfaceSchemas.ts +13 -2
- package/src/orchestrate/prisma/orchestratePrisma.ts +2 -1
- package/src/orchestrate/prisma/orchestratePrismaComponent.ts +15 -10
- package/src/orchestrate/prisma/orchestratePrismaCorrect.ts +9 -10
- package/src/orchestrate/prisma/orchestratePrismaReview.ts +9 -11
- package/src/orchestrate/prisma/orchestratePrismaSchemas.ts +2 -1
- package/src/orchestrate/realize/orchestrateRealize.ts +3 -2
- package/src/orchestrate/realize/orchestrateRealizeAuthorization.ts +15 -10
- package/src/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.ts +15 -10
- package/src/orchestrate/realize/orchestrateRealizeCorrect.ts +14 -3
- package/src/orchestrate/realize/orchestrateRealizeCorrectCasting.ts +21 -6
- package/src/orchestrate/realize/orchestrateRealizeWrite.ts +13 -2
- package/src/orchestrate/realize/utils/replaceImportStatements.ts +0 -90
- package/src/orchestrate/test/experimental/orchestrateTestWrite.ast +5 -1
- package/src/orchestrate/test/histories/transformTestWriteHistories.ts +1 -1
- package/src/orchestrate/test/orchestrateTest.ts +3 -2
- package/src/orchestrate/test/orchestrateTestCorrect.ts +14 -2
- package/src/orchestrate/test/orchestrateTestCorrectInvalidRequest.ts +21 -3
- package/src/orchestrate/test/orchestrateTestScenario.ts +13 -2
- package/src/orchestrate/test/orchestrateTestScenarioReview.ts +13 -2
- package/src/orchestrate/test/orchestrateTestWrite.ts +13 -2
- package/src/utils/TokenUsageComputer.ts +35 -0
- package/lib/context/IAutoBeFacadeApplication.js.map +0 -1
- package/lib/context/IAutoBeFacadeApplicationProps.js.map +0 -1
- package/lib/context/IAutoBeFacadeApplicationResult.js.map +0 -1
- package/lib/factory/createAutoBeApplication.js +0 -942
- package/lib/factory/createAutoBeApplication.js.map +0 -1
- package/lib/orchestrate/facade/transformFacadeStateMessage.js.map +0 -1
- package/src/factory/createAutoBeApplication.ts +0 -123
- /package/lib/{context → orchestrate/facade/histories}/IAutoBeFacadeApplication.d.ts +0 -0
- /package/lib/{context → orchestrate/facade/histories}/IAutoBeFacadeApplication.js +0 -0
- /package/lib/{context → orchestrate/facade/histories}/IAutoBeFacadeApplicationProps.d.ts +0 -0
- /package/lib/{context → orchestrate/facade/histories}/IAutoBeFacadeApplicationProps.js +0 -0
- /package/lib/{context → orchestrate/facade/histories}/IAutoBeFacadeApplicationResult.d.ts +0 -0
- /package/lib/{context → orchestrate/facade/histories}/IAutoBeFacadeApplicationResult.js +0 -0
- /package/lib/orchestrate/facade/{transformFacadeStateMessage.js → structures/transformFacadeStateMessage.js} +0 -0
- /package/src/{context → orchestrate/facade/histories}/IAutoBeFacadeApplication.ts +0 -0
- /package/src/{context → orchestrate/facade/histories}/IAutoBeFacadeApplicationProps.ts +0 -0
- /package/src/{context → orchestrate/facade/histories}/IAutoBeFacadeApplicationResult.ts +0 -0
|
@@ -58,7 +58,7 @@ const orchestrateAnalyzeScenario = (ctx) => __awaiter(void 0, void 0, void 0, fu
|
|
|
58
58
|
const pointer = {
|
|
59
59
|
value: null,
|
|
60
60
|
};
|
|
61
|
-
const { histories, tokenUsage } = yield ctx.conversate({
|
|
61
|
+
const { histories, tokenUsage, metric } = yield ctx.conversate({
|
|
62
62
|
source: "analyzeScenario",
|
|
63
63
|
controller: createController({
|
|
64
64
|
model: ctx.model,
|
|
@@ -86,6 +86,7 @@ const orchestrateAnalyzeScenario = (ctx) => __awaiter(void 0, void 0, void 0, fu
|
|
|
86
86
|
language: pointer.value.language,
|
|
87
87
|
actors: pointer.value.actors,
|
|
88
88
|
files: pointer.value.files,
|
|
89
|
+
metric,
|
|
89
90
|
tokenUsage,
|
|
90
91
|
step: ((_c = (_b = ctx.state().analyze) === null || _b === void 0 ? void 0 : _b.step) !== null && _c !== void 0 ? _c : -1) + 1,
|
|
91
92
|
created_at: start.toISOString(),
|
|
@@ -94,7 +95,11 @@ const orchestrateAnalyzeScenario = (ctx) => __awaiter(void 0, void 0, void 0, fu
|
|
|
94
95
|
exports.orchestrateAnalyzeScenario = orchestrateAnalyzeScenario;
|
|
95
96
|
function createController(props) {
|
|
96
97
|
(0, assertSchemaModel_1.assertSchemaModel)(props.model);
|
|
97
|
-
const application = collection[props.model
|
|
98
|
+
const application = collection[props.model === "chatgpt"
|
|
99
|
+
? "chatgpt"
|
|
100
|
+
: props.model === "gemini"
|
|
101
|
+
? "gemini"
|
|
102
|
+
: "claude"];
|
|
98
103
|
return {
|
|
99
104
|
protocol: "class",
|
|
100
105
|
name: "Compose",
|
|
@@ -106,345 +111,661 @@ function createController(props) {
|
|
|
106
111
|
},
|
|
107
112
|
};
|
|
108
113
|
}
|
|
109
|
-
const
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
114
|
+
const collection = {
|
|
115
|
+
chatgpt: {
|
|
116
|
+
model: "chatgpt",
|
|
117
|
+
options: {
|
|
118
|
+
reference: true,
|
|
119
|
+
strict: false,
|
|
120
|
+
separate: null
|
|
121
|
+
},
|
|
122
|
+
functions: [
|
|
123
|
+
{
|
|
124
|
+
name: "compose",
|
|
125
|
+
parameters: {
|
|
126
|
+
description: " - Project prefix, actors, and file list\n\n------------------------------\n\nCurrent Type: {@link IAutoBeAnalyzeScenarioApplication.IProps}",
|
|
127
|
+
type: "object",
|
|
128
|
+
properties: {
|
|
129
|
+
reason: {
|
|
130
|
+
description: "Reason for the analysis and composition of the project structure.",
|
|
131
|
+
type: "string"
|
|
132
|
+
},
|
|
133
|
+
prefix: {
|
|
134
|
+
description: "Prefix for file names and variable names. This will be used for\norganizing documentation files.\n\nDO: Use camelCase naming convention.\n\n\n@pattern ^[a-z][a-zA-Z0-9]*$",
|
|
135
|
+
type: "string"
|
|
136
|
+
},
|
|
137
|
+
actors: {
|
|
138
|
+
description: "Actors to be assigned for the project.\n\nEach actor has:\n\n- `name`: Actor identifier (camelCase)\n- `kind`: \"guest\" | \"member\" | \"admin\"\n- `description`: Actor's permissions and capabilities",
|
|
139
|
+
type: "array",
|
|
140
|
+
items: {
|
|
141
|
+
$ref: "#/$defs/AutoBeAnalyzeActor"
|
|
142
|
+
}
|
|
143
|
+
},
|
|
144
|
+
language: {
|
|
145
|
+
description: "Language for document content. When specified by the user, this takes\nprecedence over the locale setting for determining document language.",
|
|
146
|
+
type: "string"
|
|
147
|
+
},
|
|
148
|
+
page: {
|
|
149
|
+
description: "If the user has requested a specific number of pages, enter that number.\nOtherwise, provide an appropriate number of documents needed to meet the\nuser's requirements. This number must always match the length of the\nfiles property, must be greater than 1, and must include the table of\ncontents. For example, if the user requests 3 pages, the total should be\n4, including the table of contents.",
|
|
150
|
+
type: "number"
|
|
151
|
+
},
|
|
152
|
+
files: {
|
|
153
|
+
description: "Array of document metadata objects defining files to be generated.\n\nEach array element is an AutoBeAnalyzeFile.Scenario object containing:\n- filename: The output file name (e.g., \"01-service-overview.md\")\n- reason: Why this document is being created\n- documentType, outline, constraints, etc.: Metadata guiding content generation\n\nThese documents represent business-focused planning documentation:\n- Business requirements and functional specifications in natural language\n- User journey mapping and use case scenarios\n- Business rules and workflow definitions\n- Service overview and business model description\n- User actors and permission requirements (described in natural language)\n- Business logic and validation rules\n- DO NOT: Include database schemas, ERD, or API specifications\n- DO: Write all requirements in natural language for clarity\n\nGenerate metadata objects based on actual requirements gathered from conversation.\nDo not create unnecessary documentation - only generate what is needed to\nproperly define the business requirements and system specifications.\n\n# Array Length Rules\n\nThe array length must match the user's requested page count plus one for ToC.\nFor example: user requests 3 pages \u2192 generate 4 objects (1 ToC + 3 content).\nIf user does not specify a number, generate sufficient objects to adequately\ndocument the service (typically 11+ objects including ToC).\n\n\n@minItems 1",
|
|
154
|
+
type: "array",
|
|
155
|
+
items: {
|
|
156
|
+
$ref: "#/$defs/AutoBeAnalyzeFile.Scenario"
|
|
157
|
+
}
|
|
136
158
|
}
|
|
137
159
|
},
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
name: {
|
|
169
|
-
description: "Unique identifier for the user actor.\n\nThis name will be used as a reference throughout the generated codebase,\nincluding Prisma schema model names, authorization decorator parameters,\nand API documentation.\n\nMUST use camelCase naming convention.",
|
|
170
|
-
type: "string",
|
|
171
|
-
pattern: "^[a-z][a-zA-Z0-9]*$",
|
|
172
|
-
minLength: 1
|
|
160
|
+
required: [
|
|
161
|
+
"reason",
|
|
162
|
+
"prefix",
|
|
163
|
+
"actors",
|
|
164
|
+
"page",
|
|
165
|
+
"files"
|
|
166
|
+
],
|
|
167
|
+
additionalProperties: false,
|
|
168
|
+
$defs: {
|
|
169
|
+
AutoBeAnalyzeActor: {
|
|
170
|
+
description: "Interface representing a user actor definition in the requirements analysis\nphase.\n\nThis interface defines authenticated user actors that will be used throughout\nthe application's authentication and authorization system. Each actor\nrepresents a distinct type of user who can register, authenticate, and\ninteract with the system based on their specific permissions and\ncapabilities.\n\nThe actors defined here serve as the foundation for generating:\n\n- Prisma schema models for user authentication tables\n- API endpoint access control decorators\n- Actor-based authorization logic in the business layer\n- Test scenarios for different user permission levels",
|
|
171
|
+
type: "object",
|
|
172
|
+
properties: {
|
|
173
|
+
name: {
|
|
174
|
+
description: "Unique identifier for the user actor.\n\nThis name will be used as a reference throughout the generated codebase,\nincluding Prisma schema model names, authorization decorator parameters,\nand API documentation.\n\nMUST use camelCase naming convention.\n\n\n@minLength 1\n@pattern ^[a-z][a-zA-Z0-9]*$",
|
|
175
|
+
type: "string"
|
|
176
|
+
},
|
|
177
|
+
kind: {
|
|
178
|
+
description: "Actor category classification for system-wide permission hierarchy.\n\nThis property categorizes actors into three fundamental permission levels,\nestablishing a clear hierarchy for authorization decisions throughout the\napplication. The kind determines baseline access patterns and security\nboundaries:\n\n- \"guest\": Unauthenticated users or those with minimal permissions. Typically\n limited to public resources and registration/login endpoints.\n- \"member\": Authenticated users with standard access permissions. Can access\n personal resources and participate in core application features.\n- \"admin\": System administrators with elevated permissions. Can manage other\n users, access administrative functions, and modify system-wide settings.",
|
|
179
|
+
type: "string",
|
|
180
|
+
"enum": [
|
|
181
|
+
"guest",
|
|
182
|
+
"member",
|
|
183
|
+
"admin"
|
|
184
|
+
]
|
|
185
|
+
},
|
|
186
|
+
description: {
|
|
187
|
+
description: "Human-readable description of the actor's permissions and capabilities.\n\nThis description helps the AI agents understand the business context and\naccess requirements for each actor, guiding the generation of appropriate\nauthorization rules and API endpoint restrictions.",
|
|
188
|
+
type: "string"
|
|
189
|
+
}
|
|
173
190
|
},
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
191
|
+
required: [
|
|
192
|
+
"name",
|
|
193
|
+
"kind",
|
|
194
|
+
"description"
|
|
195
|
+
]
|
|
196
|
+
},
|
|
197
|
+
"AutoBeAnalyzeFile.Scenario": {
|
|
198
|
+
type: "object",
|
|
199
|
+
properties: {
|
|
200
|
+
reason: {
|
|
201
|
+
description: "Describe briefly why you made this document, and if you have any plans\nfor the next one. This helps maintain context between documents and\nensures a logical flow in documentation creation. Example: \"To define the\ncore features and user needs for the e-commerce platform before moving on\nto detailed user flow documentation.\"",
|
|
202
|
+
type: "string"
|
|
203
|
+
},
|
|
204
|
+
filename: {
|
|
205
|
+
description: "Filename to generate or overwrite. Should be descriptive and follow a\nconsistent naming convention. Examples: \"01-service-overview.md\",\n\"02-user-requirements.md\", \"03-business-model.md\"\n\n\n@pattern ((.*)\\.md)$",
|
|
206
|
+
type: "string"
|
|
207
|
+
},
|
|
208
|
+
documentType: {
|
|
209
|
+
description: "Document type that determines the structure and content guidelines. This\nhelps the AI understand what kind of document to create and what sections\nor information should be included. Examples:\n\n- \"requirement\": Functional/non-functional requirements, acceptance\n criteria\n- \"user-story\": User personas, scenarios, and journey descriptions\n- \"user-flow\": Step-by-step user interactions and decision points\n- \"business-model\": Revenue streams, cost structure, value propositions\n- \"service-overview\": High-level service description, goals, and scope",
|
|
210
|
+
type: "string"
|
|
211
|
+
},
|
|
212
|
+
outline: {
|
|
213
|
+
description: "Outline or table of contents that guides the document structure. Each\nitem represents a main section to be covered in the document. The AI will\nexpand each section with appropriate content while maintaining the\nspecified structure. Example: [\"Executive Summary\", \"Problem Statement\",\n\"Target Users\", \"Core Features\", \"Success Metrics\", \"Implementation\nTimeline\"]",
|
|
214
|
+
type: "array",
|
|
215
|
+
items: {
|
|
216
|
+
type: "string"
|
|
217
|
+
}
|
|
218
|
+
},
|
|
219
|
+
audience: {
|
|
220
|
+
description: "Target audience for this document. Determines the language, technical\ndepth, and focus areas of the content. If not specified, the document\nwill be written for a general audience with balanced technical and\nbusiness perspectives. Examples:\n\n- \"development team\": More technical details, implementation considerations\n- \"business stakeholders\": Focus on ROI, business value, market opportunity\n- \"end users\": User-friendly language, benefits, and use cases\n- \"product managers\": Balance of user needs, business goals, and\n feasibility\n- \"general\": Accessible to all stakeholders (default if not specified)",
|
|
221
|
+
type: "string"
|
|
222
|
+
},
|
|
223
|
+
keyQuestions: {
|
|
224
|
+
description: "Key questions or concerns this document should address. Helps ensure the\ndocument covers all important aspects and doesn't miss critical\ninformation. The AI will make sure to answer these questions within the\ndocument content. Examples:\n\n- \"What problem does this service solve?\"\n- \"Who are the primary and secondary users?\"\n- \"What are the main competitive advantages?\"\n- \"How will we measure success?\"\n- \"What are the potential risks and mitigation strategies?\"",
|
|
225
|
+
type: "array",
|
|
226
|
+
items: {
|
|
227
|
+
type: "string"
|
|
228
|
+
}
|
|
229
|
+
},
|
|
230
|
+
detailLevel: {
|
|
231
|
+
description: "Level of detail expected in the document. Guides how deeply the AI should\nexplore each topic and how much information to include. Examples:\n\n- \"high-level overview\": Brief, conceptual, focusing on the big picture\n- \"detailed specification\": Comprehensive, with specific examples and edge\n cases\n- \"executive summary\": Concise, focusing on key points and decisions\n- \"moderate detail\": Balanced approach with essential details (default)",
|
|
232
|
+
type: "string"
|
|
233
|
+
},
|
|
234
|
+
relatedDocuments: {
|
|
235
|
+
description: "Related documents that this document references or builds upon. Helps\nmaintain consistency across documentation and allows the AI to understand\nthe broader context. These documents should already exist or be planned\nin the documentation roadmap. Examples: [\"00-project-charter.md\",\n\"01-market-analysis.md\", \"02-competitor-research.md\"]",
|
|
236
|
+
type: "array",
|
|
237
|
+
items: {
|
|
238
|
+
type: "string"
|
|
185
239
|
}
|
|
186
|
-
|
|
240
|
+
},
|
|
241
|
+
constraints: {
|
|
242
|
+
description: "Specific constraints or requirements for the document. These are\nmust-have elements or considerations that should be included regardless\nof other factors. The AI will ensure these constraints are met.\nExamples:\n\n- \"Must include cost-benefit analysis\"\n- \"Focus on mobile-first user experience\"\n- \"Include measurable KPIs and success metrics\"\n- \"Address data privacy and security concerns\"\n- \"Consider scalability for 1M+ users\"\n- \"Include timeline and milestone recommendations\"",
|
|
243
|
+
type: "array",
|
|
244
|
+
items: {
|
|
245
|
+
type: "string"
|
|
246
|
+
}
|
|
247
|
+
}
|
|
187
248
|
},
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
249
|
+
required: [
|
|
250
|
+
"reason",
|
|
251
|
+
"filename"
|
|
252
|
+
]
|
|
253
|
+
}
|
|
254
|
+
}
|
|
255
|
+
},
|
|
256
|
+
description: "Composes project structure with actors and documentation files.\n\nDetermines the list of user actors and documents to generate based on\nrequirements. If requirements are incomplete, returns empty arrays.",
|
|
257
|
+
validate: (() => { const _io0 = input => "string" === typeof input.reason && ("string" === typeof input.prefix && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.prefix)) && (Array.isArray(input.actors) && input.actors.every(elem => "object" === typeof elem && null !== elem && _io1(elem))) && (undefined === input.language || "string" === typeof input.language) && "number" === typeof input.page && (Array.isArray(input.files) && (1 <= input.files.length && input.files.every(elem => "object" === typeof elem && null !== elem && _io2(elem)))); const _io1 = input => "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && 1 <= input.name.length) && ("guest" === input.kind || "member" === input.kind || "admin" === input.kind) && "string" === typeof input.description; const _io2 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && (undefined === input.documentType || "string" === typeof input.documentType) && (undefined === input.outline || Array.isArray(input.outline) && input.outline.every(elem => "string" === typeof elem)) && (undefined === input.audience || "string" === typeof input.audience) && (undefined === input.keyQuestions || Array.isArray(input.keyQuestions) && input.keyQuestions.every(elem => "string" === typeof elem)) && (undefined === input.detailLevel || "string" === typeof input.detailLevel) && (undefined === input.relatedDocuments || Array.isArray(input.relatedDocuments) && input.relatedDocuments.every(elem => "string" === typeof elem)) && (undefined === input.constraints || Array.isArray(input.constraints) && input.constraints.every(elem => "string" === typeof elem)); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
|
|
258
|
+
path: _path + ".reason",
|
|
259
|
+
expected: "string",
|
|
260
|
+
value: input.reason
|
|
261
|
+
}), "string" === typeof input.prefix && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.prefix) || _report(_exceptionable, {
|
|
262
|
+
path: _path + ".prefix",
|
|
263
|
+
expected: "string & CamelCasePattern",
|
|
264
|
+
value: input.prefix
|
|
265
|
+
})) || _report(_exceptionable, {
|
|
266
|
+
path: _path + ".prefix",
|
|
267
|
+
expected: "(string & CamelCasePattern)",
|
|
268
|
+
value: input.prefix
|
|
269
|
+
}), (Array.isArray(input.actors) || _report(_exceptionable, {
|
|
270
|
+
path: _path + ".actors",
|
|
271
|
+
expected: "Array<AutoBeAnalyzeActor>",
|
|
272
|
+
value: input.actors
|
|
273
|
+
})) && input.actors.map((elem, _index7) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
274
|
+
path: _path + ".actors[" + _index7 + "]",
|
|
275
|
+
expected: "AutoBeAnalyzeActor",
|
|
276
|
+
value: elem
|
|
277
|
+
})) && _vo1(elem, _path + ".actors[" + _index7 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
278
|
+
path: _path + ".actors[" + _index7 + "]",
|
|
279
|
+
expected: "AutoBeAnalyzeActor",
|
|
280
|
+
value: elem
|
|
281
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
282
|
+
path: _path + ".actors",
|
|
283
|
+
expected: "Array<AutoBeAnalyzeActor>",
|
|
284
|
+
value: input.actors
|
|
285
|
+
}), undefined === input.language || "string" === typeof input.language || _report(_exceptionable, {
|
|
286
|
+
path: _path + ".language",
|
|
287
|
+
expected: "(string | undefined)",
|
|
288
|
+
value: input.language
|
|
289
|
+
}), "number" === typeof input.page || _report(_exceptionable, {
|
|
290
|
+
path: _path + ".page",
|
|
291
|
+
expected: "number",
|
|
292
|
+
value: input.page
|
|
293
|
+
}), (Array.isArray(input.files) || _report(_exceptionable, {
|
|
294
|
+
path: _path + ".files",
|
|
295
|
+
expected: "(Array<AutoBeAnalyzeFile.Scenario> & MinItems<1>)",
|
|
296
|
+
value: input.files
|
|
297
|
+
})) && ((1 <= input.files.length || _report(_exceptionable, {
|
|
298
|
+
path: _path + ".files",
|
|
299
|
+
expected: "Array<> & MinItems<1>",
|
|
300
|
+
value: input.files
|
|
301
|
+
})) && input.files.map((elem, _index8) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
302
|
+
path: _path + ".files[" + _index8 + "]",
|
|
303
|
+
expected: "AutoBeAnalyzeFile.Scenario",
|
|
304
|
+
value: elem
|
|
305
|
+
})) && _vo2(elem, _path + ".files[" + _index8 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
306
|
+
path: _path + ".files[" + _index8 + "]",
|
|
307
|
+
expected: "AutoBeAnalyzeFile.Scenario",
|
|
308
|
+
value: elem
|
|
309
|
+
})).every(flag => flag)) || _report(_exceptionable, {
|
|
310
|
+
path: _path + ".files",
|
|
311
|
+
expected: "(Array<AutoBeAnalyzeFile.Scenario> & MinItems<1>)",
|
|
312
|
+
value: input.files
|
|
313
|
+
})].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
314
|
+
path: _path + ".name",
|
|
315
|
+
expected: "string & CamelCasePattern",
|
|
316
|
+
value: input.name
|
|
317
|
+
})) && (1 <= input.name.length || _report(_exceptionable, {
|
|
318
|
+
path: _path + ".name",
|
|
319
|
+
expected: "string & MinLength<1>",
|
|
320
|
+
value: input.name
|
|
321
|
+
})) || _report(_exceptionable, {
|
|
322
|
+
path: _path + ".name",
|
|
323
|
+
expected: "(string & CamelCasePattern & MinLength<1>)",
|
|
324
|
+
value: input.name
|
|
325
|
+
}), "guest" === input.kind || "member" === input.kind || "admin" === input.kind || _report(_exceptionable, {
|
|
326
|
+
path: _path + ".kind",
|
|
327
|
+
expected: "(\"admin\" | \"guest\" | \"member\")",
|
|
328
|
+
value: input.kind
|
|
329
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
330
|
+
path: _path + ".description",
|
|
331
|
+
expected: "string",
|
|
332
|
+
value: input.description
|
|
333
|
+
})].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
|
|
334
|
+
path: _path + ".reason",
|
|
335
|
+
expected: "string",
|
|
336
|
+
value: input.reason
|
|
337
|
+
}), "string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename) || _report(_exceptionable, {
|
|
338
|
+
path: _path + ".filename",
|
|
339
|
+
expected: "`${string}.md`",
|
|
340
|
+
value: input.filename
|
|
341
|
+
}), undefined === input.documentType || "string" === typeof input.documentType || _report(_exceptionable, {
|
|
342
|
+
path: _path + ".documentType",
|
|
343
|
+
expected: "(string | undefined)",
|
|
344
|
+
value: input.documentType
|
|
345
|
+
}), undefined === input.outline || (Array.isArray(input.outline) || _report(_exceptionable, {
|
|
346
|
+
path: _path + ".outline",
|
|
347
|
+
expected: "(Array<string> | undefined)",
|
|
348
|
+
value: input.outline
|
|
349
|
+
})) && input.outline.map((elem, _index9) => "string" === typeof elem || _report(_exceptionable, {
|
|
350
|
+
path: _path + ".outline[" + _index9 + "]",
|
|
351
|
+
expected: "string",
|
|
352
|
+
value: elem
|
|
353
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
354
|
+
path: _path + ".outline",
|
|
355
|
+
expected: "(Array<string> | undefined)",
|
|
356
|
+
value: input.outline
|
|
357
|
+
}), undefined === input.audience || "string" === typeof input.audience || _report(_exceptionable, {
|
|
358
|
+
path: _path + ".audience",
|
|
359
|
+
expected: "(string | undefined)",
|
|
360
|
+
value: input.audience
|
|
361
|
+
}), undefined === input.keyQuestions || (Array.isArray(input.keyQuestions) || _report(_exceptionable, {
|
|
362
|
+
path: _path + ".keyQuestions",
|
|
363
|
+
expected: "(Array<string> | undefined)",
|
|
364
|
+
value: input.keyQuestions
|
|
365
|
+
})) && input.keyQuestions.map((elem, _index10) => "string" === typeof elem || _report(_exceptionable, {
|
|
366
|
+
path: _path + ".keyQuestions[" + _index10 + "]",
|
|
367
|
+
expected: "string",
|
|
368
|
+
value: elem
|
|
369
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
370
|
+
path: _path + ".keyQuestions",
|
|
371
|
+
expected: "(Array<string> | undefined)",
|
|
372
|
+
value: input.keyQuestions
|
|
373
|
+
}), undefined === input.detailLevel || "string" === typeof input.detailLevel || _report(_exceptionable, {
|
|
374
|
+
path: _path + ".detailLevel",
|
|
375
|
+
expected: "(string | undefined)",
|
|
376
|
+
value: input.detailLevel
|
|
377
|
+
}), undefined === input.relatedDocuments || (Array.isArray(input.relatedDocuments) || _report(_exceptionable, {
|
|
378
|
+
path: _path + ".relatedDocuments",
|
|
379
|
+
expected: "(Array<string> | undefined)",
|
|
380
|
+
value: input.relatedDocuments
|
|
381
|
+
})) && input.relatedDocuments.map((elem, _index11) => "string" === typeof elem || _report(_exceptionable, {
|
|
382
|
+
path: _path + ".relatedDocuments[" + _index11 + "]",
|
|
383
|
+
expected: "string",
|
|
384
|
+
value: elem
|
|
385
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
386
|
+
path: _path + ".relatedDocuments",
|
|
387
|
+
expected: "(Array<string> | undefined)",
|
|
388
|
+
value: input.relatedDocuments
|
|
389
|
+
}), undefined === input.constraints || (Array.isArray(input.constraints) || _report(_exceptionable, {
|
|
390
|
+
path: _path + ".constraints",
|
|
391
|
+
expected: "(Array<string> | undefined)",
|
|
392
|
+
value: input.constraints
|
|
393
|
+
})) && input.constraints.map((elem, _index12) => "string" === typeof elem || _report(_exceptionable, {
|
|
394
|
+
path: _path + ".constraints[" + _index12 + "]",
|
|
395
|
+
expected: "string",
|
|
396
|
+
value: elem
|
|
397
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
398
|
+
path: _path + ".constraints",
|
|
399
|
+
expected: "(Array<string> | undefined)",
|
|
400
|
+
value: input.constraints
|
|
401
|
+
})].every(flag => flag); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
|
|
402
|
+
if (false === __is(input)) {
|
|
403
|
+
errors = [];
|
|
404
|
+
_report = __typia_transform__validateReport._validateReport(errors);
|
|
405
|
+
((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
|
|
406
|
+
path: _path + "",
|
|
407
|
+
expected: "IAutoBeAnalyzeScenarioApplication.IProps",
|
|
408
|
+
value: input
|
|
409
|
+
})) && _vo0(input, _path + "", true) || _report(true, {
|
|
410
|
+
path: _path + "",
|
|
411
|
+
expected: "IAutoBeAnalyzeScenarioApplication.IProps",
|
|
412
|
+
value: input
|
|
413
|
+
}))(input, "$input", true);
|
|
414
|
+
const success = 0 === errors.length;
|
|
415
|
+
return success ? {
|
|
416
|
+
success,
|
|
417
|
+
data: input
|
|
418
|
+
} : {
|
|
419
|
+
success,
|
|
420
|
+
errors,
|
|
421
|
+
data: input
|
|
422
|
+
};
|
|
423
|
+
}
|
|
424
|
+
return {
|
|
425
|
+
success: true,
|
|
426
|
+
data: input
|
|
427
|
+
};
|
|
428
|
+
}; })()
|
|
429
|
+
}
|
|
430
|
+
]
|
|
431
|
+
},
|
|
432
|
+
claude: {
|
|
433
|
+
model: "claude",
|
|
434
|
+
options: {
|
|
435
|
+
reference: true,
|
|
436
|
+
separate: null
|
|
437
|
+
},
|
|
438
|
+
functions: [
|
|
439
|
+
{
|
|
440
|
+
name: "compose",
|
|
441
|
+
parameters: {
|
|
442
|
+
description: " - Project prefix, actors, and file list\n\n------------------------------\n\nCurrent Type: {@link IAutoBeAnalyzeScenarioApplication.IProps}",
|
|
443
|
+
type: "object",
|
|
444
|
+
properties: {
|
|
445
|
+
reason: {
|
|
446
|
+
description: "Reason for the analysis and composition of the project structure.",
|
|
447
|
+
type: "string"
|
|
448
|
+
},
|
|
449
|
+
prefix: {
|
|
450
|
+
description: "Prefix for file names and variable names. This will be used for\norganizing documentation files.\n\nDO: Use camelCase naming convention.",
|
|
451
|
+
type: "string",
|
|
452
|
+
pattern: "^[a-z][a-zA-Z0-9]*$"
|
|
453
|
+
},
|
|
454
|
+
actors: {
|
|
455
|
+
description: "Actors to be assigned for the project.\n\nEach actor has:\n\n- `name`: Actor identifier (camelCase)\n- `kind`: \"guest\" | \"member\" | \"admin\"\n- `description`: Actor's permissions and capabilities",
|
|
456
|
+
type: "array",
|
|
457
|
+
items: {
|
|
458
|
+
$ref: "#/$defs/AutoBeAnalyzeActor"
|
|
191
459
|
}
|
|
192
460
|
},
|
|
193
|
-
|
|
194
|
-
"
|
|
195
|
-
"
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
reason:
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
filename: {
|
|
207
|
-
description: "Filename to generate or overwrite. Should be descriptive and follow a\nconsistent naming convention. Examples: \"01-service-overview.md\",\n\"02-user-requirements.md\", \"03-business-model.md\"",
|
|
208
|
-
type: "string",
|
|
209
|
-
pattern: "((.*)\\.md)$"
|
|
210
|
-
},
|
|
211
|
-
documentType: {
|
|
212
|
-
description: "Document type that determines the structure and content guidelines. This\nhelps the AI understand what kind of document to create and what sections\nor information should be included. Examples:\n\n- \"requirement\": Functional/non-functional requirements, acceptance\n criteria\n- \"user-story\": User personas, scenarios, and journey descriptions\n- \"user-flow\": Step-by-step user interactions and decision points\n- \"business-model\": Revenue streams, cost structure, value propositions\n- \"service-overview\": High-level service description, goals, and scope",
|
|
213
|
-
type: "string"
|
|
461
|
+
language: {
|
|
462
|
+
description: "Language for document content. When specified by the user, this takes\nprecedence over the locale setting for determining document language.",
|
|
463
|
+
type: "string"
|
|
464
|
+
},
|
|
465
|
+
page: {
|
|
466
|
+
description: "If the user has requested a specific number of pages, enter that number.\nOtherwise, provide an appropriate number of documents needed to meet the\nuser's requirements. This number must always match the length of the\nfiles property, must be greater than 1, and must include the table of\ncontents. For example, if the user requests 3 pages, the total should be\n4, including the table of contents.",
|
|
467
|
+
type: "number"
|
|
468
|
+
},
|
|
469
|
+
files: {
|
|
470
|
+
description: "Array of document metadata objects defining files to be generated.\n\nEach array element is an AutoBeAnalyzeFile.Scenario object containing:\n- filename: The output file name (e.g., \"01-service-overview.md\")\n- reason: Why this document is being created\n- documentType, outline, constraints, etc.: Metadata guiding content generation\n\nThese documents represent business-focused planning documentation:\n- Business requirements and functional specifications in natural language\n- User journey mapping and use case scenarios\n- Business rules and workflow definitions\n- Service overview and business model description\n- User actors and permission requirements (described in natural language)\n- Business logic and validation rules\n- DO NOT: Include database schemas, ERD, or API specifications\n- DO: Write all requirements in natural language for clarity\n\nGenerate metadata objects based on actual requirements gathered from conversation.\nDo not create unnecessary documentation - only generate what is needed to\nproperly define the business requirements and system specifications.\n\n# Array Length Rules\n\nThe array length must match the user's requested page count plus one for ToC.\nFor example: user requests 3 pages \u2192 generate 4 objects (1 ToC + 3 content).\nIf user does not specify a number, generate sufficient objects to adequately\ndocument the service (typically 11+ objects including ToC).",
|
|
471
|
+
type: "array",
|
|
472
|
+
items: {
|
|
473
|
+
$ref: "#/$defs/AutoBeAnalyzeFile.Scenario"
|
|
214
474
|
},
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
475
|
+
minItems: 1
|
|
476
|
+
}
|
|
477
|
+
},
|
|
478
|
+
required: [
|
|
479
|
+
"reason",
|
|
480
|
+
"prefix",
|
|
481
|
+
"actors",
|
|
482
|
+
"page",
|
|
483
|
+
"files"
|
|
484
|
+
],
|
|
485
|
+
additionalProperties: false,
|
|
486
|
+
$defs: {
|
|
487
|
+
AutoBeAnalyzeActor: {
|
|
488
|
+
description: "Interface representing a user actor definition in the requirements analysis\nphase.\n\nThis interface defines authenticated user actors that will be used throughout\nthe application's authentication and authorization system. Each actor\nrepresents a distinct type of user who can register, authenticate, and\ninteract with the system based on their specific permissions and\ncapabilities.\n\nThe actors defined here serve as the foundation for generating:\n\n- Prisma schema models for user authentication tables\n- API endpoint access control decorators\n- Actor-based authorization logic in the business layer\n- Test scenarios for different user permission levels",
|
|
489
|
+
type: "object",
|
|
490
|
+
properties: {
|
|
491
|
+
name: {
|
|
492
|
+
description: "Unique identifier for the user actor.\n\nThis name will be used as a reference throughout the generated codebase,\nincluding Prisma schema model names, authorization decorator parameters,\nand API documentation.\n\nMUST use camelCase naming convention.",
|
|
493
|
+
type: "string",
|
|
494
|
+
pattern: "^[a-z][a-zA-Z0-9]*$",
|
|
495
|
+
minLength: 1
|
|
496
|
+
},
|
|
497
|
+
kind: {
|
|
498
|
+
description: "Actor category classification for system-wide permission hierarchy.\n\nThis property categorizes actors into three fundamental permission levels,\nestablishing a clear hierarchy for authorization decisions throughout the\napplication. The kind determines baseline access patterns and security\nboundaries:\n\n- \"guest\": Unauthenticated users or those with minimal permissions. Typically\n limited to public resources and registration/login endpoints.\n- \"member\": Authenticated users with standard access permissions. Can access\n personal resources and participate in core application features.\n- \"admin\": System administrators with elevated permissions. Can manage other\n users, access administrative functions, and modify system-wide settings.",
|
|
499
|
+
oneOf: [
|
|
500
|
+
{
|
|
501
|
+
"const": "guest"
|
|
502
|
+
},
|
|
503
|
+
{
|
|
504
|
+
"const": "member"
|
|
505
|
+
},
|
|
506
|
+
{
|
|
507
|
+
"const": "admin"
|
|
508
|
+
}
|
|
509
|
+
]
|
|
510
|
+
},
|
|
511
|
+
description: {
|
|
512
|
+
description: "Human-readable description of the actor's permissions and capabilities.\n\nThis description helps the AI agents understand the business context and\naccess requirements for each actor, guiding the generation of appropriate\nauthorization rules and API endpoint restrictions.",
|
|
219
513
|
type: "string"
|
|
220
514
|
}
|
|
221
515
|
},
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
516
|
+
required: [
|
|
517
|
+
"name",
|
|
518
|
+
"kind",
|
|
519
|
+
"description"
|
|
520
|
+
]
|
|
521
|
+
},
|
|
522
|
+
"AutoBeAnalyzeFile.Scenario": {
|
|
523
|
+
type: "object",
|
|
524
|
+
properties: {
|
|
525
|
+
reason: {
|
|
526
|
+
description: "Describe briefly why you made this document, and if you have any plans\nfor the next one. This helps maintain context between documents and\nensures a logical flow in documentation creation. Example: \"To define the\ncore features and user needs for the e-commerce platform before moving on\nto detailed user flow documentation.\"",
|
|
230
527
|
type: "string"
|
|
231
|
-
}
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
type: "array",
|
|
240
|
-
items: {
|
|
528
|
+
},
|
|
529
|
+
filename: {
|
|
530
|
+
description: "Filename to generate or overwrite. Should be descriptive and follow a\nconsistent naming convention. Examples: \"01-service-overview.md\",\n\"02-user-requirements.md\", \"03-business-model.md\"",
|
|
531
|
+
type: "string",
|
|
532
|
+
pattern: "((.*)\\.md)$"
|
|
533
|
+
},
|
|
534
|
+
documentType: {
|
|
535
|
+
description: "Document type that determines the structure and content guidelines. This\nhelps the AI understand what kind of document to create and what sections\nor information should be included. Examples:\n\n- \"requirement\": Functional/non-functional requirements, acceptance\n criteria\n- \"user-story\": User personas, scenarios, and journey descriptions\n- \"user-flow\": Step-by-step user interactions and decision points\n- \"business-model\": Revenue streams, cost structure, value propositions\n- \"service-overview\": High-level service description, goals, and scope",
|
|
241
536
|
type: "string"
|
|
242
|
-
}
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
537
|
+
},
|
|
538
|
+
outline: {
|
|
539
|
+
description: "Outline or table of contents that guides the document structure. Each\nitem represents a main section to be covered in the document. The AI will\nexpand each section with appropriate content while maintaining the\nspecified structure. Example: [\"Executive Summary\", \"Problem Statement\",\n\"Target Users\", \"Core Features\", \"Success Metrics\", \"Implementation\nTimeline\"]",
|
|
540
|
+
type: "array",
|
|
541
|
+
items: {
|
|
542
|
+
type: "string"
|
|
543
|
+
}
|
|
544
|
+
},
|
|
545
|
+
audience: {
|
|
546
|
+
description: "Target audience for this document. Determines the language, technical\ndepth, and focus areas of the content. If not specified, the document\nwill be written for a general audience with balanced technical and\nbusiness perspectives. Examples:\n\n- \"development team\": More technical details, implementation considerations\n- \"business stakeholders\": Focus on ROI, business value, market opportunity\n- \"end users\": User-friendly language, benefits, and use cases\n- \"product managers\": Balance of user needs, business goals, and\n feasibility\n- \"general\": Accessible to all stakeholders (default if not specified)",
|
|
547
|
+
type: "string"
|
|
548
|
+
},
|
|
549
|
+
keyQuestions: {
|
|
550
|
+
description: "Key questions or concerns this document should address. Helps ensure the\ndocument covers all important aspects and doesn't miss critical\ninformation. The AI will make sure to answer these questions within the\ndocument content. Examples:\n\n- \"What problem does this service solve?\"\n- \"Who are the primary and secondary users?\"\n- \"What are the main competitive advantages?\"\n- \"How will we measure success?\"\n- \"What are the potential risks and mitigation strategies?\"",
|
|
551
|
+
type: "array",
|
|
552
|
+
items: {
|
|
553
|
+
type: "string"
|
|
554
|
+
}
|
|
555
|
+
},
|
|
556
|
+
detailLevel: {
|
|
557
|
+
description: "Level of detail expected in the document. Guides how deeply the AI should\nexplore each topic and how much information to include. Examples:\n\n- \"high-level overview\": Brief, conceptual, focusing on the big picture\n- \"detailed specification\": Comprehensive, with specific examples and edge\n cases\n- \"executive summary\": Concise, focusing on key points and decisions\n- \"moderate detail\": Balanced approach with essential details (default)",
|
|
248
558
|
type: "string"
|
|
559
|
+
},
|
|
560
|
+
relatedDocuments: {
|
|
561
|
+
description: "Related documents that this document references or builds upon. Helps\nmaintain consistency across documentation and allows the AI to understand\nthe broader context. These documents should already exist or be planned\nin the documentation roadmap. Examples: [\"00-project-charter.md\",\n\"01-market-analysis.md\", \"02-competitor-research.md\"]",
|
|
562
|
+
type: "array",
|
|
563
|
+
items: {
|
|
564
|
+
type: "string"
|
|
565
|
+
}
|
|
566
|
+
},
|
|
567
|
+
constraints: {
|
|
568
|
+
description: "Specific constraints or requirements for the document. These are\nmust-have elements or considerations that should be included regardless\nof other factors. The AI will ensure these constraints are met.\nExamples:\n\n- \"Must include cost-benefit analysis\"\n- \"Focus on mobile-first user experience\"\n- \"Include measurable KPIs and success metrics\"\n- \"Address data privacy and security concerns\"\n- \"Consider scalability for 1M+ users\"\n- \"Include timeline and milestone recommendations\"",
|
|
569
|
+
type: "array",
|
|
570
|
+
items: {
|
|
571
|
+
type: "string"
|
|
572
|
+
}
|
|
249
573
|
}
|
|
250
|
-
}
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
574
|
+
},
|
|
575
|
+
required: [
|
|
576
|
+
"reason",
|
|
577
|
+
"filename"
|
|
578
|
+
]
|
|
579
|
+
}
|
|
256
580
|
}
|
|
257
|
-
}
|
|
258
|
-
|
|
259
|
-
|
|
260
|
-
|
|
261
|
-
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
339
|
-
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
383
|
-
|
|
384
|
-
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
418
|
-
|
|
419
|
-
|
|
420
|
-
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
581
|
+
},
|
|
582
|
+
description: "Composes project structure with actors and documentation files.\n\nDetermines the list of user actors and documents to generate based on\nrequirements. If requirements are incomplete, returns empty arrays.",
|
|
583
|
+
validate: (() => { const _io0 = input => "string" === typeof input.reason && ("string" === typeof input.prefix && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.prefix)) && (Array.isArray(input.actors) && input.actors.every(elem => "object" === typeof elem && null !== elem && _io1(elem))) && (undefined === input.language || "string" === typeof input.language) && "number" === typeof input.page && (Array.isArray(input.files) && (1 <= input.files.length && input.files.every(elem => "object" === typeof elem && null !== elem && _io2(elem)))); const _io1 = input => "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && 1 <= input.name.length) && ("guest" === input.kind || "member" === input.kind || "admin" === input.kind) && "string" === typeof input.description; const _io2 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && (undefined === input.documentType || "string" === typeof input.documentType) && (undefined === input.outline || Array.isArray(input.outline) && input.outline.every(elem => "string" === typeof elem)) && (undefined === input.audience || "string" === typeof input.audience) && (undefined === input.keyQuestions || Array.isArray(input.keyQuestions) && input.keyQuestions.every(elem => "string" === typeof elem)) && (undefined === input.detailLevel || "string" === typeof input.detailLevel) && (undefined === input.relatedDocuments || Array.isArray(input.relatedDocuments) && input.relatedDocuments.every(elem => "string" === typeof elem)) && (undefined === input.constraints || Array.isArray(input.constraints) && input.constraints.every(elem => "string" === typeof elem)); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
|
|
584
|
+
path: _path + ".reason",
|
|
585
|
+
expected: "string",
|
|
586
|
+
value: input.reason
|
|
587
|
+
}), "string" === typeof input.prefix && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.prefix) || _report(_exceptionable, {
|
|
588
|
+
path: _path + ".prefix",
|
|
589
|
+
expected: "string & CamelCasePattern",
|
|
590
|
+
value: input.prefix
|
|
591
|
+
})) || _report(_exceptionable, {
|
|
592
|
+
path: _path + ".prefix",
|
|
593
|
+
expected: "(string & CamelCasePattern)",
|
|
594
|
+
value: input.prefix
|
|
595
|
+
}), (Array.isArray(input.actors) || _report(_exceptionable, {
|
|
596
|
+
path: _path + ".actors",
|
|
597
|
+
expected: "Array<AutoBeAnalyzeActor>",
|
|
598
|
+
value: input.actors
|
|
599
|
+
})) && input.actors.map((elem, _index7) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
600
|
+
path: _path + ".actors[" + _index7 + "]",
|
|
601
|
+
expected: "AutoBeAnalyzeActor",
|
|
602
|
+
value: elem
|
|
603
|
+
})) && _vo1(elem, _path + ".actors[" + _index7 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
604
|
+
path: _path + ".actors[" + _index7 + "]",
|
|
605
|
+
expected: "AutoBeAnalyzeActor",
|
|
606
|
+
value: elem
|
|
607
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
608
|
+
path: _path + ".actors",
|
|
609
|
+
expected: "Array<AutoBeAnalyzeActor>",
|
|
610
|
+
value: input.actors
|
|
611
|
+
}), undefined === input.language || "string" === typeof input.language || _report(_exceptionable, {
|
|
612
|
+
path: _path + ".language",
|
|
613
|
+
expected: "(string | undefined)",
|
|
614
|
+
value: input.language
|
|
615
|
+
}), "number" === typeof input.page || _report(_exceptionable, {
|
|
616
|
+
path: _path + ".page",
|
|
617
|
+
expected: "number",
|
|
618
|
+
value: input.page
|
|
619
|
+
}), (Array.isArray(input.files) || _report(_exceptionable, {
|
|
620
|
+
path: _path + ".files",
|
|
621
|
+
expected: "(Array<AutoBeAnalyzeFile.Scenario> & MinItems<1>)",
|
|
622
|
+
value: input.files
|
|
623
|
+
})) && ((1 <= input.files.length || _report(_exceptionable, {
|
|
624
|
+
path: _path + ".files",
|
|
625
|
+
expected: "Array<> & MinItems<1>",
|
|
626
|
+
value: input.files
|
|
627
|
+
})) && input.files.map((elem, _index8) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
628
|
+
path: _path + ".files[" + _index8 + "]",
|
|
629
|
+
expected: "AutoBeAnalyzeFile.Scenario",
|
|
630
|
+
value: elem
|
|
631
|
+
})) && _vo2(elem, _path + ".files[" + _index8 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
632
|
+
path: _path + ".files[" + _index8 + "]",
|
|
633
|
+
expected: "AutoBeAnalyzeFile.Scenario",
|
|
634
|
+
value: elem
|
|
635
|
+
})).every(flag => flag)) || _report(_exceptionable, {
|
|
636
|
+
path: _path + ".files",
|
|
637
|
+
expected: "(Array<AutoBeAnalyzeFile.Scenario> & MinItems<1>)",
|
|
638
|
+
value: input.files
|
|
639
|
+
})].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
640
|
+
path: _path + ".name",
|
|
641
|
+
expected: "string & CamelCasePattern",
|
|
642
|
+
value: input.name
|
|
643
|
+
})) && (1 <= input.name.length || _report(_exceptionable, {
|
|
644
|
+
path: _path + ".name",
|
|
645
|
+
expected: "string & MinLength<1>",
|
|
646
|
+
value: input.name
|
|
647
|
+
})) || _report(_exceptionable, {
|
|
648
|
+
path: _path + ".name",
|
|
649
|
+
expected: "(string & CamelCasePattern & MinLength<1>)",
|
|
650
|
+
value: input.name
|
|
651
|
+
}), "guest" === input.kind || "member" === input.kind || "admin" === input.kind || _report(_exceptionable, {
|
|
652
|
+
path: _path + ".kind",
|
|
653
|
+
expected: "(\"admin\" | \"guest\" | \"member\")",
|
|
654
|
+
value: input.kind
|
|
655
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
656
|
+
path: _path + ".description",
|
|
657
|
+
expected: "string",
|
|
658
|
+
value: input.description
|
|
659
|
+
})].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
|
|
660
|
+
path: _path + ".reason",
|
|
661
|
+
expected: "string",
|
|
662
|
+
value: input.reason
|
|
663
|
+
}), "string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename) || _report(_exceptionable, {
|
|
664
|
+
path: _path + ".filename",
|
|
665
|
+
expected: "`${string}.md`",
|
|
666
|
+
value: input.filename
|
|
667
|
+
}), undefined === input.documentType || "string" === typeof input.documentType || _report(_exceptionable, {
|
|
668
|
+
path: _path + ".documentType",
|
|
669
|
+
expected: "(string | undefined)",
|
|
670
|
+
value: input.documentType
|
|
671
|
+
}), undefined === input.outline || (Array.isArray(input.outline) || _report(_exceptionable, {
|
|
672
|
+
path: _path + ".outline",
|
|
673
|
+
expected: "(Array<string> | undefined)",
|
|
674
|
+
value: input.outline
|
|
675
|
+
})) && input.outline.map((elem, _index9) => "string" === typeof elem || _report(_exceptionable, {
|
|
676
|
+
path: _path + ".outline[" + _index9 + "]",
|
|
677
|
+
expected: "string",
|
|
678
|
+
value: elem
|
|
679
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
680
|
+
path: _path + ".outline",
|
|
681
|
+
expected: "(Array<string> | undefined)",
|
|
682
|
+
value: input.outline
|
|
683
|
+
}), undefined === input.audience || "string" === typeof input.audience || _report(_exceptionable, {
|
|
684
|
+
path: _path + ".audience",
|
|
685
|
+
expected: "(string | undefined)",
|
|
686
|
+
value: input.audience
|
|
687
|
+
}), undefined === input.keyQuestions || (Array.isArray(input.keyQuestions) || _report(_exceptionable, {
|
|
688
|
+
path: _path + ".keyQuestions",
|
|
689
|
+
expected: "(Array<string> | undefined)",
|
|
690
|
+
value: input.keyQuestions
|
|
691
|
+
})) && input.keyQuestions.map((elem, _index10) => "string" === typeof elem || _report(_exceptionable, {
|
|
692
|
+
path: _path + ".keyQuestions[" + _index10 + "]",
|
|
693
|
+
expected: "string",
|
|
694
|
+
value: elem
|
|
695
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
696
|
+
path: _path + ".keyQuestions",
|
|
697
|
+
expected: "(Array<string> | undefined)",
|
|
698
|
+
value: input.keyQuestions
|
|
699
|
+
}), undefined === input.detailLevel || "string" === typeof input.detailLevel || _report(_exceptionable, {
|
|
700
|
+
path: _path + ".detailLevel",
|
|
701
|
+
expected: "(string | undefined)",
|
|
702
|
+
value: input.detailLevel
|
|
703
|
+
}), undefined === input.relatedDocuments || (Array.isArray(input.relatedDocuments) || _report(_exceptionable, {
|
|
704
|
+
path: _path + ".relatedDocuments",
|
|
705
|
+
expected: "(Array<string> | undefined)",
|
|
706
|
+
value: input.relatedDocuments
|
|
707
|
+
})) && input.relatedDocuments.map((elem, _index11) => "string" === typeof elem || _report(_exceptionable, {
|
|
708
|
+
path: _path + ".relatedDocuments[" + _index11 + "]",
|
|
709
|
+
expected: "string",
|
|
710
|
+
value: elem
|
|
711
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
712
|
+
path: _path + ".relatedDocuments",
|
|
713
|
+
expected: "(Array<string> | undefined)",
|
|
714
|
+
value: input.relatedDocuments
|
|
715
|
+
}), undefined === input.constraints || (Array.isArray(input.constraints) || _report(_exceptionable, {
|
|
716
|
+
path: _path + ".constraints",
|
|
717
|
+
expected: "(Array<string> | undefined)",
|
|
718
|
+
value: input.constraints
|
|
719
|
+
})) && input.constraints.map((elem, _index12) => "string" === typeof elem || _report(_exceptionable, {
|
|
720
|
+
path: _path + ".constraints[" + _index12 + "]",
|
|
721
|
+
expected: "string",
|
|
722
|
+
value: elem
|
|
723
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
724
|
+
path: _path + ".constraints",
|
|
725
|
+
expected: "(Array<string> | undefined)",
|
|
726
|
+
value: input.constraints
|
|
727
|
+
})].every(flag => flag); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
|
|
728
|
+
if (false === __is(input)) {
|
|
729
|
+
errors = [];
|
|
730
|
+
_report = __typia_transform__validateReport._validateReport(errors);
|
|
731
|
+
((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
|
|
732
|
+
path: _path + "",
|
|
733
|
+
expected: "IAutoBeAnalyzeScenarioApplication.IProps",
|
|
734
|
+
value: input
|
|
735
|
+
})) && _vo0(input, _path + "", true) || _report(true, {
|
|
736
|
+
path: _path + "",
|
|
737
|
+
expected: "IAutoBeAnalyzeScenarioApplication.IProps",
|
|
738
|
+
value: input
|
|
739
|
+
}))(input, "$input", true);
|
|
740
|
+
const success = 0 === errors.length;
|
|
741
|
+
return success ? {
|
|
742
|
+
success,
|
|
743
|
+
data: input
|
|
744
|
+
} : {
|
|
745
|
+
success,
|
|
746
|
+
errors,
|
|
747
|
+
data: input
|
|
748
|
+
};
|
|
749
|
+
}
|
|
750
|
+
return {
|
|
751
|
+
success: true,
|
|
424
752
|
data: input
|
|
425
753
|
};
|
|
426
|
-
}
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
}
|
|
433
|
-
]
|
|
434
|
-
};
|
|
435
|
-
const collection = {
|
|
436
|
-
chatgpt: {
|
|
437
|
-
model: "chatgpt",
|
|
754
|
+
}; })()
|
|
755
|
+
}
|
|
756
|
+
]
|
|
757
|
+
},
|
|
758
|
+
gemini: {
|
|
759
|
+
model: "gemini",
|
|
438
760
|
options: {
|
|
439
761
|
reference: true,
|
|
440
|
-
strict: false,
|
|
441
762
|
separate: null
|
|
442
763
|
},
|
|
443
764
|
functions: [
|
|
444
765
|
{
|
|
445
766
|
name: "compose",
|
|
446
767
|
parameters: {
|
|
447
|
-
description: "
|
|
768
|
+
description: " - Project prefix, actors, and file list\n\n------------------------------\n\nCurrent Type: {@link IAutoBeAnalyzeScenarioApplication.IProps}",
|
|
448
769
|
type: "object",
|
|
449
770
|
properties: {
|
|
450
771
|
reason: {
|
|
@@ -456,7 +777,7 @@ const collection = {
|
|
|
456
777
|
type: "string"
|
|
457
778
|
},
|
|
458
779
|
actors: {
|
|
459
|
-
description: "Actors to be assigned for the project",
|
|
780
|
+
description: "Actors to be assigned for the project.\n\nEach actor has:\n\n- `name`: Actor identifier (camelCase)\n- `kind`: \"guest\" | \"member\" | \"admin\"\n- `description`: Actor's permissions and capabilities",
|
|
460
781
|
type: "array",
|
|
461
782
|
items: {
|
|
462
783
|
$ref: "#/$defs/AutoBeAnalyzeActor"
|
|
@@ -471,7 +792,7 @@ const collection = {
|
|
|
471
792
|
type: "number"
|
|
472
793
|
},
|
|
473
794
|
files: {
|
|
474
|
-
description: "
|
|
795
|
+
description: "Array of document metadata objects defining files to be generated.\n\nEach array element is an AutoBeAnalyzeFile.Scenario object containing:\n- filename: The output file name (e.g., \"01-service-overview.md\")\n- reason: Why this document is being created\n- documentType, outline, constraints, etc.: Metadata guiding content generation\n\nThese documents represent business-focused planning documentation:\n- Business requirements and functional specifications in natural language\n- User journey mapping and use case scenarios\n- Business rules and workflow definitions\n- Service overview and business model description\n- User actors and permission requirements (described in natural language)\n- Business logic and validation rules\n- DO NOT: Include database schemas, ERD, or API specifications\n- DO: Write all requirements in natural language for clarity\n\nGenerate metadata objects based on actual requirements gathered from conversation.\nDo not create unnecessary documentation - only generate what is needed to\nproperly define the business requirements and system specifications.\n\n# Array Length Rules\n\nThe array length must match the user's requested page count plus one for ToC.\nFor example: user requests 3 pages \u2192 generate 4 objects (1 ToC + 3 content).\nIf user does not specify a number, generate sufficient objects to adequately\ndocument the service (typically 11+ objects including ToC).\n\n\n@minItems 1",
|
|
475
796
|
type: "array",
|
|
476
797
|
items: {
|
|
477
798
|
$ref: "#/$defs/AutoBeAnalyzeFile.Scenario"
|
|
@@ -574,7 +895,7 @@ const collection = {
|
|
|
574
895
|
}
|
|
575
896
|
}
|
|
576
897
|
},
|
|
577
|
-
description: "
|
|
898
|
+
description: "Composes project structure with actors and documentation files.\n\nDetermines the list of user actors and documents to generate based on\nrequirements. If requirements are incomplete, returns empty arrays.",
|
|
578
899
|
validate: (() => { const _io0 = input => "string" === typeof input.reason && ("string" === typeof input.prefix && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.prefix)) && (Array.isArray(input.actors) && input.actors.every(elem => "object" === typeof elem && null !== elem && _io1(elem))) && (undefined === input.language || "string" === typeof input.language) && "number" === typeof input.page && (Array.isArray(input.files) && (1 <= input.files.length && input.files.every(elem => "object" === typeof elem && null !== elem && _io2(elem)))); const _io1 = input => "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && 1 <= input.name.length) && ("guest" === input.kind || "member" === input.kind || "admin" === input.kind) && "string" === typeof input.description; const _io2 = input => "string" === typeof input.reason && ("string" === typeof input.filename && RegExp(/(.*)\.md$/).test(input.filename)) && (undefined === input.documentType || "string" === typeof input.documentType) && (undefined === input.outline || Array.isArray(input.outline) && input.outline.every(elem => "string" === typeof elem)) && (undefined === input.audience || "string" === typeof input.audience) && (undefined === input.keyQuestions || Array.isArray(input.keyQuestions) && input.keyQuestions.every(elem => "string" === typeof elem)) && (undefined === input.detailLevel || "string" === typeof input.detailLevel) && (undefined === input.relatedDocuments || Array.isArray(input.relatedDocuments) && input.relatedDocuments.every(elem => "string" === typeof elem)) && (undefined === input.constraints || Array.isArray(input.constraints) && input.constraints.every(elem => "string" === typeof elem)); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.reason || _report(_exceptionable, {
|
|
579
900
|
path: _path + ".reason",
|
|
580
901
|
expected: "string",
|
|
@@ -750,9 +1071,5 @@ const collection = {
|
|
|
750
1071
|
}
|
|
751
1072
|
]
|
|
752
1073
|
},
|
|
753
|
-
claude,
|
|
754
|
-
llama: claude,
|
|
755
|
-
deepseek: claude,
|
|
756
|
-
"3.1": claude,
|
|
757
1074
|
};
|
|
758
1075
|
//# sourceMappingURL=orchestrateAnalyzeScenario.js.map
|