Skip to content

Commit aad5eda

Browse files
Merge branch 'main' into feat/issue_137
2 parents b3ddb02 + ee64135 commit aad5eda

File tree

11 files changed

+390
-51
lines changed

11 files changed

+390
-51
lines changed

.husky/commit-msg

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
#!/usr/bin/env sh
2+
. "$(dirname -- "$0")/_/husky.sh"
3+
4+
npx --no -- commitlint --edit "$1"

.projen/deps.json

Lines changed: 16 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.projen/tasks.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

.projenrc.ts

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
* OR CONDITIONS OF ANY KIND, express or implied. See the License for the specific language governing permissions
1111
* and limitations under the License.
1212
*/
13-
import { awscdk } from 'projen';
13+
import { JsonPatch, awscdk } from 'projen';
1414
import { NpmAccess } from 'projen/lib/javascript';
1515
import {
1616
buildMeritBadgerWorkflow,
@@ -45,7 +45,13 @@ const project = new awscdk.AwsCdkConstructLibrary({
4545

4646
// description: undefined, /* The description is just a string that helps people understand the purpose of the package. */
4747
keywords: ['constructs', 'aws-cdk', 'generative-ai', 'emerging-tech'],
48-
devDeps: ['eslint-plugin-header'],
48+
devDeps: [
49+
'@commitlint/config-conventional',
50+
'commitlint',
51+
'eslint-plugin-header',
52+
'husky',
53+
'pinst',
54+
],
4955
deps: ['cdk-nag'],
5056

5157
// Keep synchronized with https://github.com/nodejs/release#release-schedule
@@ -151,6 +157,12 @@ project.eslint?.addRules({
151157
'header/header': [2, 'header.js'],
152158
});
153159

160+
const packageJson = project.tryFindObjectFile('package.json');
161+
packageJson?.patch(JsonPatch.add('/scripts/prepare', 'husky install')); // yarn 1
162+
packageJson?.patch(JsonPatch.add('/scripts/postinstall', 'husky install')); // yarn 2
163+
packageJson?.patch(JsonPatch.add('/scripts/prepack', 'pinst --disable'));
164+
packageJson?.patch(JsonPatch.add('/scripts/postpack', 'pinst --enable'));
165+
154166
// Add generation of new available models for constructs
155167
project.addTask('generate-models-containers', {
156168
description: 'Generate new list of models available from Jumpstart and DLC containers',
@@ -163,5 +175,4 @@ project.addTask('generate-models-containers', {
163175
],
164176
});
165177

166-
167178
project.synth();

README.md

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -90,13 +90,6 @@ The official samples repository https://github.com/aws-samples/generative-ai-cdk
9090
| [AWS re:Invent 2023 - Keynote with Dr. Werner Vogels](https://youtu.be/UTRBVPvzt9w?t=6252) | Dr. Werner Vogels, Amazon.com's VP and CTO, announces the AWS Generative AI CDK Constructs during his AWS re:Invent 2023 keynote. |
9191
| [aws-cdk-stack-builder-tool](https://github.com/aws-samples/aws-cdk-stack-builder-tool) | AWS CDK Builder is a browser-based tool designed to streamline bootstrapping of Infrastructure as Code (IaC) projects using the AWS Cloud Development Kit (CDK). |
9292

93-
# Additional Resources
94-
95-
| Resource |Description|
96-
|:-------------|:-------------|
97-
| [AWS re:Invent 2023 - Keynote with Dr. Werner Vogels](https://youtu.be/UTRBVPvzt9w?t=6252) | Dr. Werner Vogels, Amazon.com's VP and CTO, announces the AWS Generative AI CDK Constructs during his AWS re:Invent 2023 keynote. |
98-
| [aws-cdk-stack-builder-tool](https://github.com/aws-samples/aws-cdk-stack-builder-tool) | AWS CDK Builder is a browser-based tool designed to streamline bootstrapping of Infrastructure as Code (IaC) projects using the AWS Cloud Development Kit (CDK). |
99-
10093
# Operational Metrics Collection
10194

10295
Provided CDK constructs collect anonymous operational metrics to help AWS improve the quality and features of the constructs. Data collection is subject to the AWS Privacy Policy (https://aws.amazon.com/privacy/). To opt out of this feature, simply disable it by setting the construct property "enableOperationalMetric" to false for each construct used. Defaults to true.

package.json

Lines changed: 10 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/patterns/gen-ai/aws-model-deployment-sagemaker/README_custom_sagemaker_endpoint.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,7 @@ Parameters
123123

124124

125125
## Architecture
126-
![Architecture Diagram](architecture_CustomSageMakerEndpoint.png.png)
126+
![Architecture Diagram](architecture_CustomSageMakerEndpoint.png)
127127

128128
## Cost
129129

src/patterns/gen-ai/aws-qa-appsync-opensearch/index.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -295,7 +295,7 @@ export class QaAppsyncOpensearch extends Construct {
295295
'questionAnsweringGraphqlApi',
296296
{
297297
name: 'questionAnsweringGraphqlApi' + stage,
298-
schema: appsync.SchemaFile.fromAsset(
298+
definition: appsync.Definition.fromFile(
299299
path.join(
300300
__dirname,
301301
'../../../../resources/gen-ai/aws-qa-appsync-opensearch/schema.graphql',

src/patterns/gen-ai/aws-rag-appsync-stepfn-opensearch/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -347,7 +347,9 @@ export class RagAppsyncStepfnOpensearch extends Construct {
347347
'ingestionGraphqlApi',
348348
{
349349
name: 'ingestionGraphqlApi'+stage,
350-
schema: appsync.SchemaFile.fromAsset(path.join(__dirname, '../../../../resources/gen-ai/aws-rag-appsync-stepfn-opensearch/schema.graphql')),
350+
definition: appsync.Definition.fromFile(
351+
path.join(__dirname, '../../../../resources/gen-ai/aws-rag-appsync-stepfn-opensearch/schema.graphql'),
352+
),
351353
authorizationConfig: {
352354
defaultAuthorization: {
353355
authorizationType: appsync.AuthorizationType.USER_POOL,

src/patterns/gen-ai/aws-summarization-appsync-stepfn/index.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -415,7 +415,9 @@ export class SummarizationAppsyncStepfn extends Construct {
415415
{
416416
name: apiName+stage,
417417
logConfig: api_log_config,
418-
schema: appsync.SchemaFile.fromAsset(path.join(__dirname, '../../../../resources/gen-ai/aws-summarization-appsync-stepfn/schema.graphql')),
418+
definition: appsync.Definition.fromFile(
419+
path.join(__dirname, '../../../../resources/gen-ai/aws-summarization-appsync-stepfn/schema.graphql'),
420+
),
419421
authorizationConfig: authorizationConfig,
420422
xrayEnabled: enable_xray,
421423
});

0 commit comments

Comments
 (0)