Re:Introduction to logic programming with Prolog
by maxxxxx on Tuesday December 05, 2017 @01:49PM
(#15854476)
How does Prolog relate to ML systems? It seems they work in a similar way. Input some learning data and then the system produces output based on these.
[ Parent
| on HN ]
Re:Introduction to logic programming with Prolog
by lou1306 on Tuesday December 05, 2017 @02:04PM
(#15854653)
Eh, they are quite different under the hood. To put it real simple (and probably quite sloppy): Prolog determines the output by applying logic. ML uses mathematics to analyze the input and "guesses" the output, based on the training set.
As a corollary: Prolog will negate anything that can't be proven true from the rules you give it. A ML algorithm will always give you some answer, though the quality depends on the learning data.
Re:Introduction to logic programming with Prolog
by maxxxxx on Tuesday December 05, 2017 @02:08PM
(#15854698)
Cool. Thanks! I am watching these trends from the outside and it's hard to keep up if you don't work directly with the tools.
Re:Introduction to logic programming with Prolog
by gregdeveloper on Tuesday December 05, 2017 @06:20PM
(#15857086)
I think he meant ML as the family of meta programming languages?
He did say systems though so you are probably right
Re:Introduction to logic programming with Prolog
by lou1306 on Wednesday December 06, 2017 @06:32AM
(#15860310)
Also, the part about "Input some learning data" makes me think to Machine Learning rather than Meta Language.
Btw, Prolog and ML might look like distant cousins: e.g. you use recursion and pattern matching in both. But under the hood there are big differences that arise from Prolog's logic programming paradigm: for instance, you can use append(L1, L2, L3) both to concatenate and split a list, depending on the variables you set:
append([1,2], [3,4], X) % ==> X=[1,2,3,4]
append([1,2], Y, [1,2,3,4]) % ==> Y=[3,4]