Awesome Open Source
Awesome Open Source

Grabl GitHub release Discord Discussion Forum Stack Overflow Stack Overflow

TypeDB is a distributed knowledge graph: a logical database to organise large and complex networks of data as one body of knowledge.

Get Started Documentation Discussion
Whether you are new to coding or an experienced developer, it’s easy to learn and use TypeDB. Get set up quickly with quickstart tutorial. Documentation for TypeDB’s development library and TypeQL language API, along with tutorials and guides, are available online. Visit our documentation portal. When you’re stuck on a problem, collaborating helps. Ask your question on StackOverflow or discuss it on our Discussion Forum.

Meet TypeDB and TypeQL

TypeDB is a distributed knowledge graph: a logical database to organise large and complex networks of data as one body of knowledge. TypeDB provides the knowledge engineering tools for developers to easily leverage the power of Knowledge Representation and Automated Reasoning when building complex systems. Ultimately, TypeDB serves as the knowledge-base foundation for intelligent systems.

TypeQL is TypeDB's reasoning and analytics query language. It provides an expressive knowledge schema language through an enhanced entity-relationship model, transactional queries that perform deductive reasoning in real-time, and analytical queries* with native distributed Pregel and MapReduce algorithms. TypeQL provides a strong abstraction over low-level data constructs and complex relationships. (* analytics queries are temporarily unavailable in 2.0.0)

TypeQL is distributed as an open-source technology, while TypeDB comes in two forms: TypeDB - open-source, and TypeDB Cluster - our enterprise distributed knowledge graph.

Knowledge Schema

TypeDB provides an enhanced entity-relationship schema to model complex datasets. The schema allows users to model type hierarchies, hyper-entities, hyper-relationships, and rules. The schema can be updated and extended at any time in the database lifecycle. Hyper-entities are entities with multiple instances of a given attribute, and hyper-relationships are nested relationships, cardinality-restricted relationships, or relationships between any number of entities. This enables the creation of complex knowledge models very easily and allows them to evolve flexibly.

Under the hood, TypeDB has an expressive knowledge representation system based on hypergraph data structures (that generalises an edge to be a set of vertices - non-binary). TypeQL is TypeDB’s reasoning (through OLTP) and analytics (through OLAP) declarative query language.

Logical Inference

TypeDB’s query language performs logical inference through deductive reasoning of entity types and relationships, to infer implicit facts, associations, and conclusions in real-time, during runtime of OLTP queries. The inference is performed through entity and relationship type reasoning, as well as rule-based reasoning. This allows the discovery of facts that would otherwise be too hard to find, the abstraction of complex relationships into its simpler conclusion, as well as translation of higher-level queries into the lower level and more complex data representation.

Distributed Analytics (temporarily unavailable in 2.0.0)

TypeDB’s query language performs distributed Pregel and MapReduce (BSP) algorithms abstracted as OLAP queries. These types of queries usually require custom development of distributed algorithms for every use case. However, TypeDB creates an abstraction of these distributed algorithms and incorporates them as part of the language API. This enables large scale computation of BSP algorithms through a declarative language without the need of implementing the algorithms.

Higher-Level Language

With the expressivity of the schema, inference through OLTP, and distributed algorithms through OLAP, TypeDB provides a strong abstraction over low-level data constructs and complicated relationships through its query language. The language provides a higher-level schema, OLTP, and OLAP query language, which makes working with complex data a lot easier. When developers can achieve more by writing less code, the productivity rate increases by orders of magnitude.

Importing TypeQL through Maven (for Java)



Replace {version} with the version number, in which you can find the latest on TypeQL's Maven Repository. Further documentation:

Importing TypeQL through PyPi (for Python)

Available through

pip install typeql-grammar=={version}

Replace {version} with the version number, in which you can find the latest on TypeQL's PyPi Page.


TypeDB & TypeQL has been built using various open-source Graph and Distributed Computing frameworks throughout its evolution. Today TypeDB & TypeQL is built using RocksDB, ANTLR, SCIP, Bazel, GRPC, and ZeroMQ, and Caffeine. In the past, TypeDB was enabled by various open-source technologies and communities that we are hugely thankful to: Apache Cassandra, Apache Hadoop, Apache Spark, Apache TinkerPop, and JanusGraph. Thank you!


The TypeQL language and related materials are distributed under the terms GNU Affero General Public License v3.0 ("AGPL 3.0") as published by the Free Software Foundation, but with the following special exception.

Exception to AGPL 3.0: Any TypeQL language library that is based on material or materials in the Vaticle TypeQL repository, and that is used to communicate or interact (in each case) with a database created or managed or accessed (in each case) using a version of the TypeQL software that is made available by or on behalf of Vaticle Limited (UK Company Number 08766237) or any successor entity (but excluding any forked version of that software), may be distributed under one of the following licences:

As used above "successor entity" means any entity then owning copyrights in the TypeDB software that were previously owned by Vaticle Limited.

If you make any change to, or contribute to, (in each case) the TypeQL code or related materials, then this exception will apply to any TypeQL language library that uses or implements that change/contribution.

Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
database (1,239
inference (103
query (99
antlr (30
logic (25
query-language (19
reasoning (18
type-system (18