Prolog is a well-known logic programming language. A Prolog program is essentially a set of knowledge predicates. A query can be executed on the knowledge set by the Prolog engine, which searches and matches the query against the knowledge set automatically by conducting a depth-first search (DFS). While deterministic, DFS does not always produce the best efficiency in Prolog execution. UCT, based on UCB algorithms, is a machine learning algorithm for solving multi-stage Markov Decision Process (MDP) problems, with a good balance between exploitation and exploration. This paper introduces a UCB gauge for each of the predicates, which can be used as a heuristic measurement for selection of predicate search. This results in a best-first search strategy for Prolog execution, which is referred to as Adaptive Prolog. Adaptive Prolog enhance its execution engine by adjusting its search path to reflect current machine learning results, and as such produce better execution efficiency than traditional Prolog.
['Benjie Lu', 'Zhiqing Liu', 'Hui Gao']
An adaptive prolog programming language with machine learning