Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

community[patch]: Default embeddingNodeProperty value #5510

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions libs/langchain-community/src/vectorstores/neo4j_vector.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
const DEFAULT_SEARCH_TYPE = "vector";
const DEFAULT_INDEX_TYPE = "NODE";
const DEFAULT_DISTANCE_STRATEGY = "cosine";
const DEFAULT_NODE_EMBEDDING_PROPERTY = "embedding";

/**
* @security *Security note*: Make sure that the database connection uses credentials
Expand Down Expand Up @@ -102,7 +103,7 @@
preDeleteCollection = false,
nodeLabel = "Chunk",
textNodeProperty = "text",
embeddingNodeProperty = "embedding",
embeddingNodeProperty = DEFAULT_NODE_EMBEDDING_PROPERTY,
keywordIndexName = "keyword",
indexName = "vector",
retrievalQuery = "",
Expand Down Expand Up @@ -333,7 +334,7 @@
) {
const {
textNodeProperties = [],
embeddingNodeProperty,
embeddingNodeProperty = DEFAULT_NODE_EMBEDDING_PROPERTY,
searchType = DEFAULT_SEARCH_TYPE,
retrievalQuery = "",
nodeLabel,
Expand Down Expand Up @@ -1026,7 +1027,7 @@
return [querySnippet, queryParam];
} else if (["$in", "$nin", "$like", "$ilike"].includes(operator)) {
if (["$in", "$nin"].includes(operator)) {
filterValue.forEach((val: any) => {

Check warning on line 1030 in libs/langchain-community/src/vectorstores/neo4j_vector.ts

View workflow job for this annotation

GitHub Actions / Check linting

Unexpected any. Specify a different type
if (
typeof val !== "string" &&
typeof val !== "number" &&
Expand Down
Loading