diff --git a/packages/core/src/indices/BaseIndex.ts b/packages/core/src/indices/BaseIndex.ts index 63f29fe779db2161564cf3cc2f526415fccbde9a..db9867ea43de48d2aa4b304c055399ad3cff6a14 100644 --- a/packages/core/src/indices/BaseIndex.ts +++ b/packages/core/src/indices/BaseIndex.ts @@ -130,7 +130,7 @@ export abstract class BaseIndex<T> { export interface VectorIndexOptions { nodes?: BaseNode[]; indexStruct?: IndexDict; - indexID?: string; + indexId?: string; serviceContext?: ServiceContext; storageContext?: StorageContext; } diff --git a/packages/core/src/indices/list/ListIndex.ts b/packages/core/src/indices/list/ListIndex.ts index 74271d3487145f98bfb9014f6168f304d2d6cd43..1c8f1809926d1017f576d6106e58898c1aedb291 100644 --- a/packages/core/src/indices/list/ListIndex.ts +++ b/packages/core/src/indices/list/ListIndex.ts @@ -31,7 +31,7 @@ export enum ListRetrieverMode { export interface ListIndexOptions { nodes?: BaseNode[]; indexStruct?: IndexList; - indexID?: string; + indexId?: string; serviceContext?: ServiceContext; storageContext?: StorageContext; } @@ -63,8 +63,8 @@ export class ListIndex extends BaseIndex<IndexList> { indexStruct = options.indexStruct; } else if (indexStructs.length == 1) { indexStruct = indexStructs[0]; - } else if (indexStructs.length > 1 && options.indexID) { - indexStruct = await indexStore.getIndexStruct(options.indexID) as IndexList; + } else if (indexStructs.length > 1 && options.indexId) { + indexStruct = await indexStore.getIndexStruct(options.indexId) as IndexList; } else { indexStruct = null; } diff --git a/packages/core/src/indices/vectorStore/VectorStoreIndex.ts b/packages/core/src/indices/vectorStore/VectorStoreIndex.ts index 9b2c57bba04283dfd05a3b61c80b52cfad976b78..a5a6c8938e6aa6435da1a94e4676885151c19bc8 100644 --- a/packages/core/src/indices/vectorStore/VectorStoreIndex.ts +++ b/packages/core/src/indices/vectorStore/VectorStoreIndex.ts @@ -65,8 +65,8 @@ export class VectorStoreIndex extends BaseIndex<IndexDict> { indexStruct = options.indexStruct; } else if (indexStructs.length == 1) { indexStruct = indexStructs[0]; - } else if (indexStructs.length > 1 && options.indexID) { - indexStruct = await indexStore.getIndexStruct(options.indexID) as IndexDict; + } else if (indexStructs.length > 1 && options.indexId) { + indexStruct = await indexStore.getIndexStruct(options.indexId) as IndexDict; } else { indexStruct = null; }