diff --git a/databases/embedjs-lancedb/src/lance-db.ts b/databases/embedjs-lancedb/src/lance-db.ts index d4d42a5..28d7dce 100644 --- a/databases/embedjs-lancedb/src/lance-db.ts +++ b/databases/embedjs-lancedb/src/lance-db.ts @@ -29,7 +29,7 @@ export class LanceDb implements BaseVectorDatabase { const client = await connect(dir); const list = await client.tableNames(); - this.debug.log(`Table names found - [${list.join(',')}]`); + this.debug(`Table names found - [${list.join(',')}]`); if (list.indexOf(LanceDb.STATIC_DB_NAME) > -1) this.table = await client.openTable(LanceDb.STATIC_DB_NAME); else { //TODO: You can add a proper schema instead of a sample record now but it requires another package apache-arrow; another install on downstream as well @@ -61,14 +61,14 @@ export class LanceDb implements BaseVectorDatabase { }; }); - this.debug.log(`Executing insert of ${mapped.length} entries`); + this.debug(`Executing insert of ${mapped.length} entries`); await this.table.add(mapped); return mapped.length; //TODO: check if vectorDb has addressed the issue where add returns undefined } async similaritySearch(query: number[], k: number): Promise { const results = await this.table.search(query).limit(k).toArray(); - this.debug.log(`Query found ${results.length} entries`); + this.debug(`Query found ${results.length} entries`); return ( results diff --git a/databases/embedjs-libsql/src/libsql-db.ts b/databases/embedjs-libsql/src/libsql-db.ts index 88fb57e..b08125f 100644 --- a/databases/embedjs-libsql/src/libsql-db.ts +++ b/databases/embedjs-libsql/src/libsql-db.ts @@ -38,7 +38,7 @@ export class LibSqlDb implements BaseVectorDatabase { ${values.join(',')} );`; - this.debug.log(`Executing statement - ${statement}`); + this.debug(`Executing statement - ${statement}`); const result = await this.client.execute(statement); return result.rowsAffected; } @@ -51,7 +51,7 @@ export class LibSqlDb implements BaseVectorDatabase { TOP ${k} ASC;`; - this.debug.log(`Executing statement - ${statement}`); + this.debug(`Executing statement - ${statement}`); const results = await this.client.execute(statement); return results.rows.map((result) => { diff --git a/databases/embedjs-lmdb/src/lmdb-store.ts b/databases/embedjs-lmdb/src/lmdb-store.ts index d352481..84618bb 100644 --- a/databases/embedjs-lmdb/src/lmdb-store.ts +++ b/databases/embedjs-lmdb/src/lmdb-store.ts @@ -15,7 +15,7 @@ export class LmdbStore implements BaseStore { } async init(): Promise { - this.debug.log(`Opening LMDB connection with path - ${this.dataPath}`); + this.debug(`Opening LMDB connection with path - ${this.dataPath}`); this.database = lmdb.open({ path: this.dataPath, compression: true,