feat(ts-sdk): add AWS Neptune Analytics vector store (#5797)

Co-authored-by: kartik-mem0 <kartik.labhshetwar@mem0.ai>
This commit is contained in:
Rod Boev
2026-07-10 19:51:05 +05:30
committed by GitHub
co-authored by kartik-mem0
parent ba9054e0c8
commit 33a0ed7559
12 changed files with 2886 additions and 33 deletions
@@ -183,6 +183,12 @@ jest.mock("../src/vector_stores/pgvector", () => ({
.fn()
.mockImplementation((config) => ({ type: "pgvector", config })),
}));
jest.mock("../src/vector_stores/neptune_analytics", () => ({
NeptuneAnalyticsVectorStore: jest.fn().mockImplementation((config) => ({
type: "neptune-analytics",
config,
})),
}));
jest.mock("../src/vector_stores/upstash_vector", () => ({
UpstashVector: jest
.fn()
@@ -340,6 +346,8 @@ describe("VectorStoreFactory", () => {
["vectorize"],
["azure-ai-search"],
["pgvector"],
["neptune"],
["neptune-analytics"],
["upstash_vector"],
["azure_mysql"],
["cassandra"],
@@ -351,6 +359,30 @@ describe("VectorStoreFactory", () => {
expect(result.config).toBe(dummyVSConfig);
});
test("passes Neptune endpoint URI config through the factory", () => {
const config = {
collectionName: "test",
dimension: 4,
endpoint: "neptune-graph://g-1234567890",
region: "us-east-1",
};
const store = VectorStoreFactory.create("neptune", config) as any;
expect(store.config).toEqual(config);
});
test("keeps neptune-analytics as a compatibility alias", () => {
const config = {
collectionName: "test",
dimension: 4,
endpoint: "neptune-graph://g-1234567890",
region: "us-east-1",
};
const store = VectorStoreFactory.create("neptune-analytics", config) as any;
expect(store.config).toEqual(config);
});
test("throws for unsupported provider", () => {
expect(() =>
VectorStoreFactory.create("nonexistent", dummyVSConfig),