Skip to main content

Class: SimpleVectorStore

Extends

Implements

Constructors

new SimpleVectorStore()

new SimpleVectorStore(init?): SimpleVectorStore

Parameters

init?: object & Partial<IEmbedModel>

Returns

SimpleVectorStore

Overrides

VectorStoreBase.constructor

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:122

Properties

embedModel

embedModel: BaseEmbedding

Inherited from

VectorStoreBase.embedModel

Defined in

packages/llamaindex/src/storage/vectorStore/types.ts:103


storesText

storesText: boolean = false

Implementation of

VectorStoreNoEmbedModel.storesText

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:118

Accessors

client

get client(): any

Returns

any

Implementation of

VectorStoreNoEmbedModel.client

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:135

Methods

add()

add(embeddingResults): Promise<string[]>

Parameters

embeddingResults: BaseNode<Metadata>[]

Returns

Promise<string[]>

Implementation of

VectorStoreNoEmbedModel.add

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:143


delete()

delete(refDocId): Promise<void>

Parameters

refDocId: string

Returns

Promise<void>

Implementation of

VectorStoreNoEmbedModel.delete

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:166


get()

get(textId): Promise<number[]>

Parameters

textId: string

Returns

Promise<number[]>

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:139


persist()

persist(persistPath): Promise<void>

Parameters

persistPath: string = ...

Returns

Promise<void>

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:243


query()

query(query): Promise<VectorStoreQueryResult>

Parameters

query: VectorStoreQuery

Returns

Promise<VectorStoreQueryResult>

Implementation of

VectorStoreNoEmbedModel.query

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:206


toDict()

toDict(): SimpleVectorStoreData

Returns

SimpleVectorStoreData

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:305


fromDict()

static fromDict(saveDict, embedModel?): SimpleVectorStore

Parameters

saveDict: SimpleVectorStoreData

embedModel?: BaseEmbedding

Returns

SimpleVectorStore

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:294


fromPersistDir()

static fromPersistDir(persistDir, embedModel?): Promise<SimpleVectorStore>

Parameters

persistDir: string = DEFAULT_PERSIST_DIR

embedModel?: BaseEmbedding

Returns

Promise<SimpleVectorStore>

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:127


fromPersistPath()

static fromPersistPath(persistPath, embedModel?): Promise<SimpleVectorStore>

Parameters

persistPath: string

embedModel?: BaseEmbedding

Returns

Promise<SimpleVectorStore>

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:261


persistData()

protected static persistData(persistPath, data): Promise<void>

Parameters

persistPath: string

data: SimpleVectorStoreData

Returns

Promise<void>

Defined in

packages/llamaindex/src/storage/vectorStore/SimpleVectorStore.ts:249