feat(node): Improve concurrency (#376)

- Moved computation out of JS main thread by using a mpsc
- Removes the Arc/Mutex since Table is owned by JsTable now
- Moved table / query methods to their own files 
- Fixed js-transformers example
This commit is contained in:
gsilvestrin
2023-08-01 14:22:04 -07:00
committed by GitHub
parent f0e1290ae6
commit 593b5939be
7 changed files with 345 additions and 244 deletions

View File

@@ -50,7 +50,7 @@ async function example() {
{ id: 5, text: 'Banana', type: 'fruit' }
]
const table = await db.createTable('food_table', data, "create", embed_fun)
const table = await db.createTable('food_table', data, embed_fun)
// Query the table

View File

@@ -10,7 +10,7 @@
"license": "Apache-2.0",
"dependencies": {
"@xenova/transformers": "^2.4.1",
"vectordb": "^0.1.12"
"vectordb": "file:../.."
}
}