Databases have a long history in computer science, from the early days of relational algebra and SQL to more recent "NoSQL" incarnations such as document stores and graph databases. One family often left out of this story includes RDF databases and their more academic cousin, Datalog. The idea behind Datalog is simple yet allows for great flexibility when modeling data, especially compared to relational databases.
Storing facts
The idea behind Datalog is simple: we store facts about the world. A fact consists of an entity, an attribute and a value. This closely corresponds to the subject-predicate-object triples of the Resource Description Framework (RDF), which explains why these systems are often called triplestores. For example, if we want to model repositories in a Git forge like GitHub, we might store facts like this: