typedb is a free, open source documentation & knowledge base project written in Rust and released under MPL-2.0. It has 4,454 GitHub stars, 373 forks and 310 open issues, and was last pushed 5 hours ago. On this registry it ranks #25 of 40 tracked projects in Documentation & Knowledge Base, with 5 head-to-head comparisons available. It gained 1 stars over the last 3 tracked days.

What is typedb?

What it is

TypeDB is an open-source database project written in Rust and licensed under MPL-2.0. It lives in the database and knowledge-representation ecosystem, and its registry category covers content, documentation, and knowledge bases. The project introduces TypeQL as its query language and targets nested, interconnected data expressed through a strongly-typed schema rather than only through tables, documents, or graph edges.

The problem it addresses is modeling and querying complex relationships while keeping data handling and logic declarative and type-safe. TypeDB aims to combine relational, document, and graph capabilities in one model, using entities, relations, and attributes as root concepts. This lets a team define a schema with inheritance and interfaces, then query interconnected datasets through composable TypeQL patterns. The project also positions itself for reasoning, inference, logic, and polymorphic data handling.

Key capabilities

  • It models data with entities, relations, and attributes as root types, where relations depend on role interfaces and attributes can be owned by entities or relations.
  • It supports a schema language in which user-defined types subtype the root types and combine inheritance and interfaces.
  • It provides TypeQL, a declarative, functional, and strongly-typed query language with fully variablizable syntax.
  • It supports polymorphic queries and composable query patterns for related data that can appear in multiple roles or types.
  • It supports knowledge representation, logic, inference, and reasoning as listed project topics.
  • It includes language drivers and TypeDB Studio, a graphical user interface for working with the database.

Who uses it and how

  • Data application developers use TypeDB when they need one model for entities, relationships, and attributes instead of separating relational, document, and graph concerns.
  • Schema designers use the type system to define domain types such as users, employees, identifiers, emails, and mentorship relations.
  • Teams use TypeQL to write declarative queries over nested and interconnected datasets, especially where polymorphism and role-based relations matter.
  • Knowledge-base and documentation-oriented projects can use TypeDB for knowledge representation and reasoning, as suggested by its topics and registry category.

Getting started

The README says users can deploy TypeDB in the cloud or download and install TypeDB Community Edition, then follow the Get Started Guide and concept documentation. It also points to TypeDB Studio and Discord for interface use and community support.

When to use it — and when not to

TypeDB is a good fit when a project needs a strongly-typed, declarative model for interconnected data, schema inheritance, interfaces, relations, attributes, and reasoning-oriented queries. It is less suitable for teams that only need a conventional table, document, or graph store and do not want to learn a separate schema and query paradigm. The provided facts do not list a paid replacement or required external storage, SMTP, or database dependencies, but they do show 310 open issues and no contributor count, so a self-hoster should review maintenance activity before adoption.

project readme (upstream, from github) — read inline

TypeDB

Factory CircleCI GitHub release Discord Hosted By: Cloudsmith

Introducing TypeDB

TypeDB is a next-gen database with a modern programming paradigm that lets you build data applications faster, safer, and more elegantly. Its intuitive and powerful data model unifies the strengths of relational, document and graph databases without their shortcomings. TypeQL, its groundbreaking query language, is declarative, functional, and strongly-typed, drastically simplifying data handling and logic. So now, even the most nested and interconnected datasets can be managed with ease. With TypeDB, we’ve reinvented the database for the modern programming era.

Getting started

Why TypeDB?

  • TypeDB was crafted to natively express and combine diverse data features, allowing users to build advanced data models from a set of simple and intuitive building blocks.
  • TypeDB's type system provides safety and flexibility at the same time, which makes both prototyping and building performant, production-ready data applications fast, elegant, and enjoyable.
  • With TypeDB, and its query language TypeQL, we envision databases catching up with modern typed programming languages, allowing users to write clear, intuitive, and easy to maintain code.
  • TypeDB comes with a mature ecosystem including language drivers and a graphical user interface: TypeDB Studio!

Database Fundamentals

The schema

TypeDB schemas are based on a modern type system that natively supports inheritance and interfaces, and follows a conceptual data modeling approach, in which user-defined types subtype (based on their function) three root types: entities, relations, and attributes.

  • Entities are independent objects,
  • Relations depend on their role interfaces played by either entities or relations,
  • Attributes are properties with a value that can be owned by entities or relations.

Interface and inheritance for these types can be combined in many ways, resulting in highly expressive ways of modeling data.

define

attribute full-name, value string;
attribute id, value string;
attribute email, sub id;
attribute employee-id, sub id;

entity user,
    owns full-name,
    owns email @unique,
    plays mentorship:trainee;
entity employee,
    owns employee-id @key,
    plays mentorship:mentor;

relation mentorship,
    relates mentor,
    relates trainee;

The query language

The query language of TypeDB is TypeQL. The syntax of TypeQL is fully variablizable and provides native support for polymorphic queries. The language is based on fully declarative and composable patterns, mirroring the structure of natural language.

match $user isa user,
    has full-name $name,
    has email $email;
# This returns all users of any type

match $user isa employee,
    has full-name $name,
    has email $email,
    has employee-id $id;
# This returns only users who are employees

match $user-type sub user;
$user isa $user-type,
    has full-name $name,
    has email $email;
# This returns all users and their type

Functions

Functions, a new concept in TypeDB 3.0 and a cornerstone of TypeQL's query model, are like modularizable subqueries you can re-use and invoke whenever you want. You can learn more about them from the TypeQL Functions Documentation.

Effective database engineering

TypeDB breaks down the patchwork of existing database paradigms into three fundamental ingredients: types, inheritance, and interfaces. This provides a unified way of working with data across all database applications, that directly impacts development:

Installation and editions

TypeDB editions

  • TypeDB Cloud — multi-cloud DBaaS
  • TypeDB Enterprise — allows you to deploy TypeDB Cloud in your own environment
  • TypeDB Community Edition (CE) — Open-source edition of TypeDB ← This repository

For a comparison of all three editions, see the Deploy page on our website.

Download and run TypeDB CE

You can download TypeDB from the GitHub Releases.

Or check our Installation documentation.

Compiling TypeDB CE from source using Bazel

Note: You DO NOT NEED to compile TypeDB from the source if you just want to use TypeDB. See the "Download and Run TypeDB CE" section above.

  1. Make sure you have the following dependencies installed on your machine:

  2. You can build TypeDB server with TypeDB Console included with this command:

    $ bazel build //:assemble-typedb-all
    

    or either one of the following commands, depending on the targeted architecture and operating system:

    $ bazel build //:assemble-all-mac-x86_64-zip
    $ bazel build //:assemble-all-mac-arm64-zip
    $ bazel build //:assemble-all-linux-x86_64-targz
    $ bazel build //:assemble-all-linux-arm64-targz
    $ bazel build //:assemble-all-windows-x86_64-zip
    

    To build only TypeDB server, use for your corresponding platform:

    $ bazel build //:assemble-server-mac-x86_64-zip
    $ bazel build //:assemble-server-mac-arm64-zip
    $ bazel build //:assemble-server-linux-x86_64-targz
    $ bazel build //:assemble-server-linux-arm64-targz
    $ bazel build //:assemble-server-windows-x86_64-zip
    

    The commands above output to: bazel-bin/.

  3. If you're on a Mac and would like to run any bazel test commands, you will need to install:

    • snappy: brew install snappy
    • jemalloc: brew install jemalloc

Compiling TypeDB CE from source using Cargo

For macs:

Install prerequisites:

  1. Rustup
  2. brew install protoc

Resources

Developer resources

Useful links

If you want to begin your journey with TypeDB, you can explore the following resources:

readme truncated — read the full docs on github

Frequently asked questions

Is typedb free to use?

typedb is open source under the MPL-2.0 licence. There is no licence fee and no seat count — you can self-host it or, where the project offers one, pay a vendor for a managed version instead.

What does typedb do?

TypeDB: Built for systems, not records

What is typedb written in?

typedb is primarily written in Rust. Its source is publicly available at https://github.com/typedb/typedb, and it has 4,454 GitHub stars.