Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

(generative-ai-cdk-constructs): KnowledgeBase construct cannot create vector store #349

Closed
1 task done
InitialXW opened this issue Apr 1, 2024 · 0 comments · Fixed by #350
Closed
1 task done
Labels
bug Something isn't working needs-triage This issue or PR still needs to be triaged.

Comments

@InitialXW
Copy link

InitialXW commented Apr 1, 2024

Describe the bug

the below code returns error and the knowledge base (and the underlying vector store) cannot be created

this.knowledgeBase = new bedrock.KnowledgeBase(this, 'BedrockKnowledgeBase', {
embeddingsModel: bedrock.BedrockFoundationModel.TITAN_EMBED_TEXT_V1,
instruction: Use this knowledge base answer questions.,
});

error response: Received response status [FAILED] from custom resource. Message returned: Er
ror: An error occurred (ValidationException) when calling the CreateKnowledg
eBase operation: The knowledge base storage configuration provided is invali
d... The OpenSearch Serverless engine type associated with your vector index
is invalid. Recreate your vector index with one of the following valid engin
e types: FAISS. Then retry your request.

Expected Behavior

knowledge base is created and a default new serverless OpenSearch collection is created alongside

Current Behavior

reports error and resources cannot be created (Testing using us-west-2), the same code worked perfectly about 1 week ago

Reproduction Steps

import * as cdk from 'aws-cdk-lib';
import { bedrock } from '@cdklabs/generative-ai-cdk-constructs';
import { Construct } from 'constructs';

export interface KbStatefulProps extends cdk.StackProps {
}

export class KbStatefulStack extends cdk.Stack {

public readonly knowledgeBase: bedrock.KnowledgeBase

constructor(scope: Construct, id: string, props: KbStatefulProps) {
super(scope, id, props);

this.knowledgeBase = new bedrock.KnowledgeBase(this, 'BedrockKnowledgeBase', {
  embeddingsModel: bedrock.BedrockFoundationModel.TITAN_EMBED_TEXT_V1,
  instruction: `Use this knowledge base answer questions `,
});

}
}

Possible Solution

No response

Additional Information/Context

No response

CDK CLI Version

2.134.0

Framework Version

0.1.105

Node.js Version

v20.12.0

OS

Ubuntu 22.04

Language

Typescript

Language Version

No response

Region experiencing the issue

us-west-2

Code modification

no

Other information

No response

Service quota

  • I have reviewed the service quotas for this construct
@InitialXW InitialXW added bug Something isn't working needs-triage This issue or PR still needs to be triaged. labels Apr 1, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working needs-triage This issue or PR still needs to be triaged.
Development

Successfully merging a pull request may close this issue.

1 participant