mongolog

The main purpose of mongolog is to run logic programs with facts that are stored in a mongo database. Logic programs are translated into aggregation pipelines and executed server-side. This keeps the IO troughput small as the data is transformed and combined server-side.

The current implementation has some limitations and does not support the full ISO standard. One of the limitations is that rules cannot be asserted into the mongo database, but are baked into the aggregation pipeline. Another limitation is that recursion in rules is not allowed. However, many other aspects are supported by mongolog:

Prolog files

__init__.pl
arithmetic.pl  -- Arithmetic predicates in mongolog programs.
atoms.pl  -- Analysing and constructing atoms in mongolog programs.
comparison.pl  -- Comparison of arbitrary terms in mongolog programs.
context.pl  -- Accessing compile-context in mongolog programs.
control.pl  -- Control structures in mongolog programs.
database.pl  -- Storage of predicates in mongolog programs.
mongolog_add_predicate/3Register a predicate that stores facts in the database.
mongolog_drop_predicate/1Delete all facts associated to predicate with given functor.
findall.pl  -- Finding all solutions to a goal in mongolog programs.
fluents.pl  -- Fluents in mongolog programs.
mongolog_add_fluent/3Same as mongolog_add_fluent/4 with empty options list.
mongolog_add_fluent/4Register a fluent predicate that stores facts in the database.
mongolog_drop_fluent/1Delete all facts associated to predicate with given functor.
lists.pl  -- List manipulation in mongolog programs.
meta.pl  -- Meta predicates in mongolog programs.
mongolog.pl  -- Compiling goals into aggregation pipelines.
is_mongolog_predicate/1True if PredicateIndicator corresponds to a known mongolog predicate.
mongolog_call/1Same as mongolog_call/2 with empty options list.
mongolog_call/2Call Goal by translating it into an aggregation pipeline.
projection.pl  -- Projecting the consequences of rules.
sgml.pl  -- XML namespaces in mongolog programs.
terms.pl  -- Analysing and constructing terms in mongolog programs.
typecheck.pl  -- Verify type of a term in mongolog programs.
unification.pl  -- Unification of terms in mongolog programs.