Skip to content

Commit 5639a91

Browse files
authored
fix: nebula reset bug (#323)
* feat: update nebula to nebula 5.1.1 * fix: bug in nebula and manager * feat: update product * test: update * fix: bug in finding reorganize node * fix: duplicate bug * chore: delelte useless annotation * feat: update nebula init * feat: update reorganize * fix: nebula reset bug
1 parent 301178d commit 5639a91

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

src/memos/graph_dbs/nebular.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -228,12 +228,9 @@ def _get_or_create_shared_client(cls, cfg: NebulaGraphDBConfig) -> tuple[str, "N
228228
admin._ensure_database_exists()
229229
admin._create_basic_property_indexes()
230230
admin._create_vector_index(
231-
label="Memory",
232-
vector_property=admin.dim_field,
233231
dimensions=int(
234232
admin.embedding_dimension or admin.default_memory_dimension
235233
),
236-
index_name="memory_vector_index",
237234
)
238235
cls._CLIENT_INIT_DONE.add(key)
239236
logger.info("[NebulaGraphDBSync] One-time init done")
@@ -1546,7 +1543,11 @@ def _ensure_database_exists(self):
15461543

15471544
@timed
15481545
def _create_vector_index(
1549-
self, label: str, vector_property: str, dimensions: int, index_name: str
1546+
self,
1547+
label: str = "Memory",
1548+
vector_property: str = "embedding",
1549+
dimensions: int = 3072,
1550+
index_name: str = "memory_vector_index",
15501551
) -> None:
15511552
"""
15521553
Create a vector index for the specified property in the label.

0 commit comments

Comments
 (0)