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:135

Properties

embedModel

embedModel: BaseEmbedding

Inherited from

VectorStoreBase.embedModel

Defined in

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


storesText

storesText: boolean = false

Implementation of

VectorStoreNoEmbedModel.storesText

Defined in

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

Accessors

client

get client(): any

Returns

any

Implementation of

VectorStoreNoEmbedModel.client

Defined in

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

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:156


delete()

delete(refDocId): Promise<void>

Parameters

refDocId: string

Returns

Promise<void>

Implementation of

VectorStoreNoEmbedModel.delete

Defined in

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


get()

get(textId): Promise<number[]>

Parameters

textId: string

Returns

Promise<number[]>

Defined in

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


persist()

persist(persistPath): Promise<void>

Parameters

persistPath: string = ...

Returns

Promise<void>

Defined in

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


query()

query(query): Promise<VectorStoreQueryResult>

Parameters

query: VectorStoreQuery

Returns

Promise<VectorStoreQueryResult>

Implementation of

VectorStoreNoEmbedModel.query

Defined in

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


toDict()

toDict(): SimpleVectorStoreData

Returns

SimpleVectorStoreData

Defined in

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


fromDict()

static fromDict(saveDict, embedModel?): SimpleVectorStore

Parameters

saveDict: SimpleVectorStoreData

embedModel?: BaseEmbedding

Returns

SimpleVectorStore

Defined in

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


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:140


fromPersistPath()

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

Parameters

persistPath: string

embedModel?: BaseEmbedding

Returns

Promise<SimpleVectorStore>

Defined in

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


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:262