Hacker News new | ask | show | jobs
by patkai 3476 days ago
"distributed Prolog on the global scale. Systems would exchange constraints until they reach a mutually agreeable solution" - wow, I'm impressed, but not sure I fully get this. Any pointers or writeups on this or something similar?
1 comments

I simply verbalized something that I think is imminently possible. Prolog operates on rules and facts, both of which involve symbols. If you fix the meaning of some symbols globally, you can run queries that will (potentially) derive semantically meaningful information. There is nothing stopping two systems from exchanging rules. If you keep track of which symbol belongs to which machine (or the global repository) you can do distributed derivation by querying the other machine when you run into something global that you don't know or into other machine's symbols you can't resolve/unify yourself.

This is not a bullet proof concept. There can be infinite loops and it can have really bad performance in some cases. But at least it's something that would be able to do simple corrections and lookups automatically. (E.g. you need temperature in Celsius, but the server stores it Fahrenheit. This is not something that should force you to write code, because we know what temperature means and there are globally available conversions.)

...

Here is something related: https://fenix.tecnico.ulisboa.pt/downloadFile/395145629051/e...

Something like Clojure's spec would allow you to fix the meaning of symbols across one or more cooperating processes without requiring them to actually be global. With an appropriate mechanism for coercions you could even have three cooperating processes work on a solution together where process A and B agree on different (but equivalent) definitions than processes B and C. That sounds really awesome.