Skip to content

Commit 2e8d5cc

Browse files
chore(knowledgebase): add support for vector type (#949)
* chore(knowledgebase): add support for vector type --------- Co-authored-by: mergify[bot] <37929162+mergify[bot]@users.noreply.github.com>
1 parent 7b717aa commit 2e8d5cc

File tree

21 files changed

+542
-217
lines changed

21 files changed

+542
-217
lines changed

.projen/deps.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: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ import {
2929
const GITHUB_USER = 'awslabs';
3030
const PUBLICATION_NAMESPACE = 'cdklabs';
3131
const PROJECT_NAME = 'generative-ai-cdk-constructs';
32-
const CDK_VERSION: string = '2.177.0';
32+
const CDK_VERSION: string = '2.178.0';
3333

3434
function camelCaseIt(input: string): string {
3535
// Hypens and dashes to spaces and then CamelCase...

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
# CDK Generative AI Constructs V0.1.293 (2025-02-10)
2+
3+
Based on CDK library version 2.178.0
4+
15
# CDK Generative AI Constructs V0.1.291 (2025-01-26)
26

37
Based on CDK library version 2.177.0

DEVELOPER_GUIDE.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ Default output format [None]: json
1616
```
1717

1818
- [Node](https://nodejs.org/en) >= v20.9.0
19-
- [AWS CDK](https://github.com/aws/aws-cdk/releases/tag/v2.177.0) >= 2.177.0
19+
- [AWS CDK](https://github.com/aws/aws-cdk/releases/tag/v2.178.0) >= 2.178.0
2020
- [Python](https://www.python.org/downloads/) >=3.9
2121
- [Projen](https://github.com/projen/projen) >= 0.91.5
2222
- [Yarn](https://classic.yarnpkg.com/lang/en/docs/cli/install/) >= 1.22.19

apidocs/namespaces/bedrock/README.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,7 @@
3535
- [SharePointDataSourceAuthType](enumerations/SharePointDataSourceAuthType.md)
3636
- [SharePointObjectType](enumerations/SharePointObjectType.md)
3737
- [TransformationStep](enumerations/TransformationStep.md)
38+
- [VectorType](enumerations/VectorType.md)
3839

3940
## Classes
4041

apidocs/namespaces/bedrock/classes/BedrockFoundationModel.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -65,6 +65,12 @@ The ARN of the Bedrock invokable abstraction.
6565

6666
***
6767

68+
### supportedVectorType?
69+
70+
> `readonly` `optional` **supportedVectorType**: [`VectorType`](../enumerations/VectorType.md)[]
71+
72+
***
73+
6874
### supportsAgents
6975

7076
> `readonly` **supportsAgents**: `boolean`
Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
[**@cdklabs/generative-ai-cdk-constructs**](../../../README.md)
2+
3+
***
4+
5+
[@cdklabs/generative-ai-cdk-constructs](../../../README.md) / [bedrock](../README.md) / VectorType
6+
7+
# Enumeration: VectorType
8+
9+
The data type for the vectors when using a model to convert text into vector embeddings.
10+
The model must support the specified data type for vector embeddings. Floating-point (float32)
11+
is the default data type, and is supported by most models for vector embeddings. See Supported
12+
embeddings models for information on the available models and their vector data types.
13+
14+
## Enumeration Members
15+
16+
### BINARY
17+
18+
> **BINARY**: `"BINARY"`
19+
20+
`BINARY` convert the data to binary vector embeddings (less precise, but less costly).
21+
22+
***
23+
24+
### FLOATING\_POINT
25+
26+
> **FLOATING\_POINT**: `"FLOAT32"`
27+
28+
`FLOATING_POINT` convert the data to floating-point (float32) vector embeddings (more precise, but more costly).

apidocs/namespaces/bedrock/interfaces/BedrockFoundationModelProps.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,14 @@
88

99
## Properties
1010

11+
### supportedVectorType?
12+
13+
> `readonly` `optional` **supportedVectorType**: [`VectorType`](../enumerations/VectorType.md)[]
14+
15+
Embeddings models have different supported vector types
16+
17+
***
18+
1119
### supportsAgents?
1220

1321
> `readonly` `optional` **supportsAgents**: `boolean`

apidocs/namespaces/bedrock/interfaces/VectorKnowledgeBaseProps.md

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,3 +149,17 @@ type `VectorCollection`, `RedisEnterpriseVectorStore`,
149149
```ts
150150
- A new OpenSearch Serverless vector collection is created.
151151
```
152+
153+
***
154+
155+
### vectorType?
156+
157+
> `readonly` `optional` **vectorType**: [`VectorType`](../enumerations/VectorType.md)
158+
159+
The vector type to store vector embeddings.
160+
161+
#### Default
162+
163+
```ts
164+
- VectorType.FLOATING_POINT
165+
```

apidocs/namespaces/opensearch_vectorindex/interfaces/VectorIndexProps.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,12 @@ The OpenSearch Vector Collection.
3232

3333
***
3434

35+
### distanceType
36+
37+
> `readonly` **distanceType**: `string`
38+
39+
***
40+
3541
### indexName
3642

3743
> `readonly` **indexName**: `string`
@@ -48,6 +54,12 @@ The metadata management fields.
4854

4955
***
5056

57+
### precision
58+
59+
> `readonly` **precision**: `string`
60+
61+
***
62+
5163
### vectorDimensions
5264

5365
> `readonly` **vectorDimensions**: `number`

0 commit comments

Comments
 (0)