@@ -84,54 +84,54 @@ export class EpsAssistMeStack extends Stack {
8484 const endpoint = openSearchResources . collection . endpoint
8585
8686 // Create VectorKnowledgeBase construct with Bedrock execution role
87- const vectorKB = new VectorKnowledgeBaseResources ( this , "VectorKB" , {
88- stackName : props . stackName ,
89- docsBucket : storage . kbDocsBucket . bucket ,
90- bedrockExecutionRole : bedrockExecutionRole . role ,
91- collectionArn : openSearchResources . collection . collectionArn ,
92- vectorIndexName : VECTOR_INDEX_NAME ,
93- region,
94- account
95- } )
87+ // const vectorKB = new VectorKnowledgeBaseResources(this, "VectorKB", {
88+ // stackName: props.stackName,
89+ // docsBucket: storage.kbDocsBucket.bucket,
90+ // bedrockExecutionRole: bedrockExecutionRole.role,
91+ // collectionArn: openSearchResources.collection.collectionArn,
92+ // vectorIndexName: VECTOR_INDEX_NAME,
93+ // region,
94+ // account
95+ // })
9696
9797 // Create runtime policies with resource dependencies
98- const runtimePolicies = new RuntimePolicies ( this , "RuntimePolicies" , {
99- region,
100- account,
101- slackBotTokenParameterName : secrets . slackBotTokenParameter . parameterName ,
102- slackSigningSecretParameterName : secrets . slackSigningSecretParameter . parameterName ,
103- slackBotStateTableArn : tables . slackBotStateTable . table . tableArn ,
104- slackBotStateTableKmsKeyArn : tables . slackBotStateTable . kmsKey . keyArn ,
105- knowledgeBaseArn : vectorKB . knowledgeBase . attrKnowledgeBaseArn ,
106- guardrailArn : vectorKB . guardrail . attrGuardrailArn ,
107- dataSourceArn : vectorKB . dataSourceArn ,
108- promptName : bedrockPromptResources . queryReformulationPrompt . promptName
109- } )
98+ // const runtimePolicies = new RuntimePolicies(this, "RuntimePolicies", {
99+ // region,
100+ // account,
101+ // slackBotTokenParameterName: secrets.slackBotTokenParameter.parameterName,
102+ // slackSigningSecretParameterName: secrets.slackSigningSecretParameter.parameterName,
103+ // slackBotStateTableArn: tables.slackBotStateTable.table.tableArn,
104+ // slackBotStateTableKmsKeyArn: tables.slackBotStateTable.kmsKey.keyArn,
105+ // knowledgeBaseArn: vectorKB.knowledgeBase.attrKnowledgeBaseArn,
106+ // guardrailArn: vectorKB.guardrail.attrGuardrailArn,
107+ // dataSourceArn: vectorKB.dataSourceArn,
108+ // promptName: bedrockPromptResources.queryReformulationPrompt.promptName
109+ // })
110110
111111 // Create Functions construct with actual values from VectorKB
112- const functions = new Functions ( this , "Functions" , {
113- stackName : props . stackName ,
114- version : props . version ,
115- commitId : props . commitId ,
116- logRetentionInDays,
117- logLevel,
118- createIndexManagedPolicy : runtimePolicies . createIndexPolicy ,
119- slackBotManagedPolicy : runtimePolicies . slackBotPolicy ,
120- syncKnowledgeBaseManagedPolicy : runtimePolicies . syncKnowledgeBasePolicy ,
121- slackBotTokenParameter : secrets . slackBotTokenParameter ,
122- slackSigningSecretParameter : secrets . slackSigningSecretParameter ,
123- guardrailId : vectorKB . guardrail . attrGuardrailId ,
124- guardrailVersion : vectorKB . guardrail . attrVersion ,
125- collectionId : openSearchResources . collection . collection . attrId ,
126- knowledgeBaseId : vectorKB . knowledgeBase . attrKnowledgeBaseId ,
127- dataSourceId : vectorKB . dataSource . attrDataSourceId ,
128- region,
129- account,
130- slackBotTokenSecret : secrets . slackBotTokenSecret ,
131- slackBotSigningSecret : secrets . slackBotSigningSecret ,
132- slackBotStateTable : tables . slackBotStateTable . table ,
133- promptName : bedrockPromptResources . queryReformulationPrompt . promptName
134- } )
112+ // const functions = new Functions(this, "Functions", {
113+ // stackName: props.stackName,
114+ // version: props.version,
115+ // commitId: props.commitId,
116+ // logRetentionInDays,
117+ // logLevel,
118+ // createIndexManagedPolicy: runtimePolicies.createIndexPolicy,
119+ // slackBotManagedPolicy: runtimePolicies.slackBotPolicy,
120+ // syncKnowledgeBaseManagedPolicy: runtimePolicies.syncKnowledgeBasePolicy,
121+ // slackBotTokenParameter: secrets.slackBotTokenParameter,
122+ // slackSigningSecretParameter: secrets.slackSigningSecretParameter,
123+ // guardrailId: vectorKB.guardrail.attrGuardrailId,
124+ // guardrailVersion: vectorKB.guardrail.attrVersion,
125+ // collectionId: openSearchResources.collection.collection.attrId,
126+ // knowledgeBaseId: vectorKB.knowledgeBase.attrKnowledgeBaseId,
127+ // dataSourceId: vectorKB.dataSource.attrDataSourceId,
128+ // region,
129+ // account,
130+ // slackBotTokenSecret: secrets.slackBotTokenSecret,
131+ // slackBotSigningSecret: secrets.slackBotSigningSecret,
132+ // slackBotStateTable: tables.slackBotStateTable.table,
133+ // promptName: bedrockPromptResources.queryReformulationPrompt.promptName
134+ // })
135135
136136 // Create vector index after Functions are created
137137 const vectorIndex = new VectorIndex ( this , "VectorIndex" , {
@@ -141,29 +141,29 @@ export class EpsAssistMeStack extends Stack {
141141 } )
142142
143143 // Ensure knowledge base waits for vector index
144- vectorKB . knowledgeBase . node . addDependency ( vectorIndex . cfnIndex )
144+ // vectorKB.knowledgeBase.node.addDependency(vectorIndex.cfnIndex)
145145
146146 // Add S3 notification to trigger sync Lambda function
147- new S3LambdaNotification ( this , "S3LambdaNotification" , {
148- bucket : storage . kbDocsBucket . bucket ,
149- lambdaFunction : functions . functions . syncKnowledgeBase . function
150- } )
147+ // new S3LambdaNotification(this, "S3LambdaNotification", {
148+ // bucket: storage.kbDocsBucket.bucket,
149+ // lambdaFunction: functions.functions.syncKnowledgeBase.function
150+ // })
151151
152152 // Create Apis and pass the Lambda function
153- const apis = new Apis ( this , "Apis" , {
154- stackName : props . stackName ,
155- logRetentionInDays,
156- enableMutalTls : false ,
157- functions : {
158- slackBot : functions . functions . slackBot
159- }
160- } )
153+ // const apis = new Apis(this, "Apis", {
154+ // stackName: props.stackName,
155+ // logRetentionInDays,
156+ // enableMutalTls: false,
157+ // functions: {
158+ // slackBot: functions.functions.slackBot
159+ // }
160+ // })
161161
162162 // Output: SlackBot Endpoint
163- new CfnOutput ( this , "SlackBotEventsEndpoint" , {
164- value : `https://${ apis . apis [ "api" ] . api . domainName ?. domainName } /slack/events` ,
165- description : "Slack Events API endpoint for @mentions and direct messages"
166- } )
163+ // new CfnOutput(this, "SlackBotEventsEndpoint", {
164+ // value: `https://${apis.apis["api"].api.domainName?.domainName}/slack/events`,
165+ // description: "Slack Events API endpoint for @mentions and direct messages"
166+ // })
167167
168168 // Output: Bedrock Prompt ARN
169169 new CfnOutput ( this , "QueryReformulationPromptArn" , {
0 commit comments