Make api_version=v1.1 default and version bump -> 0.1.59 (#2278)

Co-authored-by: Deshraj Yadav <deshrajdry@gmail.com>
This commit is contained in:
Dev Khant
2025-03-01 11:36:20 +05:30
committed by GitHub
parent 5606c3ffb8
commit 4318663697
8 changed files with 45 additions and 61 deletions

View File

@@ -28,8 +28,7 @@ config = {
"password": "xxx"
},
"custom_prompt": "Please only extract entities containing sports related relationships and nothing else.",
},
"version": "v1.1"
}
}
m = Memory.from_config(config_dict=config)

View File

@@ -38,8 +38,7 @@ allowfullscreen
## Initialize Graph Memory
To initialize Graph Memory you'll need to set up your configuration with graph store providers.
Currently, we support Neo4j as a graph store provider. You can setup [Neo4j](https://neo4j.com/) locally or use the hosted [Neo4j AuraDB](https://neo4j.com/product/auradb/).
Moreover, you also need to set the version to `v1.1` (*prior versions are not supported*).
Currently, we support Neo4j as a graph store provider. You can setup [Neo4j](https://neo4j.com/) locally or use the hosted [Neo4j AuraDB](https://neo4j.com/product/auradb/).
<Note>If you are using Neo4j locally, then you need to install [APOC plugins](https://neo4j.com/labs/apoc/4.1/installation/).</Note>
@@ -65,8 +64,7 @@ config = {
"username": "neo4j",
"password": "xxx"
}
},
"version": "v1.1"
}
}
m = Memory.from_config(config_dict=config)
@@ -98,8 +96,7 @@ config = {
"temperature": 0.0,
}
}
},
"version": "v1.1"
}
}
m = Memory.from_config(config_dict=config)

View File

@@ -71,8 +71,7 @@ config = {
"username": "neo4j",
"password": "---"
}
},
"version": "v1.1"
}
}
m = Memory.from_config(config_dict=config)
@@ -100,10 +99,6 @@ result = m.add("Likes to play cricket on weekends", user_id="alice", metadata={"
{
"results": [
{"id": "bf4d4092-cf91-4181-bfeb-b6fa2ed3061b", "memory": "Likes to play cricket on weekends", "event": "ADD"}
],
"relations": [
{"source": "alice", "relationship": "likes_to_play", "target": "cricket"},
{"source": "alice", "relationship": "plays_on", "target": "weekends"}
]
}
```
@@ -129,10 +124,6 @@ all_memories = m.get_all(user_id="alice")
"updated_at": None,
"user_id": "alice"
}
],
"relations": [
{"source": "alice", "relationship": "likes_to_play", "target": "cricket"},
{"source": "alice", "relationship": "plays_on", "target": "weekends"}
]
}
```
@@ -180,10 +171,6 @@ related_memories = m.search(query="What are Alice's hobbies?", user_id="alice")
"updated_at": None,
"user_id": "alice"
}
],
"relations": [
{"source": "alice", "relationship": "plays_on", "target": "weekends"},
{"source": "alice", "relationship": "likes_to_play", "target": "cricket"}
]
}
```
@@ -303,7 +290,7 @@ Mem0 offers extensive configuration options to customize its behavior according
| Parameter | Description | Default |
|------------------|--------------------------------------|----------------------------|
| `history_db_path` | Path to the history database | "{mem0_dir}/history.db" |
| `version` | API version | "v1.0" |
| `version` | API version | "v1.1" |
| `custom_prompt` | Custom prompt for memory processing | None |
</Accordion>