langchain.graphs.memgraph_graph.MemgraphGraph¶
class langchain.graphs.memgraph_graph.MemgraphGraph(url: str, username: str, password: str, *, database: str = 'memgraph')[source]¶
Memgraph wrapper for graph operations.
Create a new Memgraph graph wrapper instance.
Methods
__init__(url, username, password, *[, database])
Create a new Memgraph graph wrapper instance.
add_graph_documents(graph_documents[, ...])
Take GraphDocument as input as uses it to construct a graph.
query(query[, params])
Query Neo4j database.
refresh_schema()
Refreshes the Memgraph graph schema information.
__init__(url: str, username: str, password: str, *, database: str = 'memgraph') → None[source]¶
Create a new Memgraph graph wrapper instance.
add_graph_documents(graph_documents: List[GraphDocument], include_source: bool = False) → None¶
Take GraphDocument as input as uses it to construct a graph.
query(query: str, params: dict = {}) → List[Dict[str, Any]]¶
Query Neo4j database.
refresh_schema() → None[source]¶
Refreshes the Memgraph graph schema information.
Examples using MemgraphGraph¶
Memgraph QA chain