This module provides Prolog dict access and modification. Unlike
a JSON term, a Prolog dict accepts arbitrary Prolog terms as keys
and values. The predicate dict_current/3 allows accessing a value
from a Prolog dict by a key. The predicates dict_set/4 and
dict_remove/4 are non-destructive and create a new Prolog dict.
In reflection of how dicts typcially behave in other programming languages such as JavaScript and Python, our realization preserves the input order of modifications. The input order is also reflected in the bi-directional predicate dict_pairs/2 as well. This behaviour is unlike SWI-Prolog which keeps Prolog dicts key sorted.
The following Prolog dict predicates are provided: