You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I was following this video (https://www.youtube.com/watch?v=U6k7HnQiWzc) and tried to do the same in js.
While the nodejs API has ...params for nearly every function, it seems like named paramaters isn't a thing on the js side?
I couldn't get it working.
For example:
const result = await db.run(`SELECT a, b, array_cosine_similarity(
embedding, $searchVector::FLOAT[1024]) as score FROM x ORDER BY score DESC LIMIT $limit`, {"searchVector": await embeddingContext.getEmbeddingFor("test"), "limit": 10});
console.log(result);
Returns:
[Error: Invalid Input Error: Values were not provided for the following prepared statement parameters: limit, searchVector] {
errno: -1,
code: 'DUCKDB_NODEJS_ERROR',
errorType: 'Invalid Input'
}
It should be on par with what python does yet it is just not working. It is not implemented for the js side of things?
Sidenote, i'm running duckdb-async but it wraps this library so errors there probably originate here.
The text was updated successfully, but these errors were encountered:
Hi,
I was following this video (https://www.youtube.com/watch?v=U6k7HnQiWzc) and tried to do the same in js.
While the nodejs API has
...params
for nearly every function, it seems like named paramaters isn't a thing on the js side?I couldn't get it working.
For example:
Returns:
It should be on par with what python does yet it is just not working. It is not implemented for the js side of things?
Sidenote, i'm running duckdb-async but it wraps this library so errors there probably originate here.
The text was updated successfully, but these errors were encountered: