Skip to main contentü¶úÔ∏èüîó LangChainDocsUse casesIntegrationsAPICommunityChat our docsLangSmithJS/TS DocsSearchCTRLKQA over structured dataSQLRetrieval-augmented generation (RAG)Interacting with APIsChatbotsExtractionSummarizationTaggingWeb scrapingSynthetic data generationGraph queryingDiffbot Graph TransformerArangoDB QA chainNeo4j DB QA chainFalkorDBQAChainHugeGraph QA ChainKuzuQAChainMemgraph QA chainNebulaGraphQAChainNetworkX Graph QAGraphSparqlQAChainNeptune Open Cypher QA ChainGraph queryingKuzuQAChainOn this pageKuzuQAChainThis notebook shows how to use LLMs to provide a natural language interface to K√πzu database.K√πzu is an in-process property graph database management system. You can simply install it with pip:pip install kuzuOnce installed, you can simply import it and start creating a database on the local machine and connect to it:import kuzudb = kuzu.Database("test_db")conn = kuzu.Connection(db)First, we create the schema for a simple movie database:conn.execute("CREATE NODE TABLE Movie (name STRING, PRIMARY KEY(name))")conn.execute(    "CREATE NODE TABLE Person (name STRING, birthDate STRING, PRIMARY KEY(name))")conn.execute("CREATE REL TABLE ActedIn (FROM Person TO Movie)")    <kuzu.query_result.QueryResult at 0x1066ff410>Then we can insert some data.conn.execute("CREATE (:Person {name: 'Al Pacino', birthDate: '1940-04-25'})")conn.execute("CREATE (:Person {name: 'Robert De Niro', birthDate: '1943-08-17'})")conn.execute("CREATE (:Movie {name: 'The Godfather'})")conn.execute("CREATE (:Movie {name: 'The Godfather: Part II'})")conn.execute(    "CREATE (:Movie {name: 'The Godfather Coda: The Death of Michael Corleone'})")conn.execute(    "MATCH (p:Person), (m:Movie) WHERE p.name = 'Al Pacino' AND m.name = 'The Godfather' CREATE (p)-[:ActedIn]->(m)")conn.execute(    "MATCH (p:Person), (m:Movie) WHERE p.name = 'Al Pacino' AND m.name = 'The Godfather: Part II' CREATE (p)-[:ActedIn]->(m)")conn.execute(    "MATCH (p:Person), (m:Movie) WHERE p.name =
This notebook shows how to use LLMs to provide a natural language interface to K√πzu database.
This notebook shows how to use LLMs to provide a natural language interface to K√πzu database. ->: Skip to main contentü¶úÔ∏èüîó LangChainDocsUse casesIntegrationsAPICommunityChat our docsLangSmithJS/TS DocsSearchCTRLKQA over structured dataSQLRetrieval-augmented generation (RAG)Interacting with APIsChatbotsExtractionSummarizationTaggingWeb scrapingSynthetic data generationGraph queryingDiffbot Graph TransformerArangoDB QA chainNeo4j DB QA chainFalkorDBQAChainHugeGraph QA ChainKuzuQAChainMemgraph QA chainNebulaGraphQAChainNetworkX Graph QAGraphSparqlQAChainNeptune Open Cypher QA ChainGraph queryingKuzuQAChainOn this pageKuzuQAChainThis notebook shows how to use LLMs to provide a natural language interface to K√πzu database.K√πzu is an in-process property graph database management system. You can simply install it with pip:pip install kuzuOnce installed, you can simply import it and start creating a database on the local machine and connect to it:import kuzudb = kuzu.Database("test_db")conn = kuzu.Connection(db)First, we create the schema for a simple movie database:conn.execute("CREATE NODE TABLE Movie (name STRING, PRIMARY KEY(name))")conn.execute(    "CREATE NODE TABLE Person (name STRING, birthDate STRING, PRIMARY KEY(name))")conn.execute("CREATE REL TABLE ActedIn (FROM Person TO Movie)")    <kuzu.query_result.QueryResult at 0x1066ff410>Then we can insert some data.conn.execute("CREATE (:Person {name: 'Al Pacino', birthDate: '1940-04-25'})")conn.execute("CREATE (:Person {name: 'Robert De Niro', birthDate: '1943-08-17'})")conn.execute("CREATE (:Movie {name: 'The Godfather'})")conn.execute("CREATE (:Movie {name: 'The Godfather: Part II'})")conn.execute(    "CREATE (:Movie {name: 'The Godfather Coda: The Death of Michael Corleone'})")conn.execute(    "MATCH (p:Person), (m:Movie) WHERE p.name = 'Al Pacino' AND m.name = 'The Godfather' CREATE (p)-[:ActedIn]->(m)")conn.execute(    "MATCH (p:Person), (m:Movie) WHERE p.name = 'Al Pacino' AND m.name = 'The Godfather: Part II' CREATE (p)-[:ActedIn]->(m)")conn.execute(    "MATCH (p:Person), (m:Movie) WHERE p.name =