The Design and Implementation of Probabilistic Programming Languages
dippl.org
dippl.org
Do you think it's because of all the parentheses that people can't understand?
I played with it and you are somewhat limited right now. The first issues is that you quickly hit the top of the javascript stack because of the recursive style (remember: no loops). The most elegant solution to that would be for browsers to support tail call optimisations which is in the ES6 standard (Are you listening Mozilla or Google? If you implement this part of the spec sooner you could be leading the way for the most promising area of AI and maybe of computing in general). Although there are possible work around namely if the webppl compiler were to use trampolines or "promise" like structures. IMO, it would clutter the code and be much less elegant than native ES6 TCO.
The second limitation is that you are not allowed mutability. There is a git branch with support for mutability partly implemented. I'm not sure they should go that way though. I've never really been into functional programming style but in the case of probabilistic languages, I really see the value. It's much simpler and easier to follow what is going on when debugging. Supporting mutability also makes the compiler more complex and memory usage high as you have to copy the whole memory footprint of your program at each probabilistic sample you take. It is not that difficult to instead include something like mori http://swannodette.github.io/mori/ to manipulate arrays immutably.
The generality and power of the approach are, frankly, amazing.
In a sense, MCMC tries to solve #P complete problems, while MAP "only" tries to solve NP complete problems. The former are probably intrinsically harder than the latter.
However, it's quite possible that some clever implementation might yield results which are as good as MAP in the same amount of time, and progressively refine them with more time.
There are two free lunches with the curse of dimensionality: - the manifold hypothesis - Monte-Carlo integration
True, the dimension rears its head as an ugly multiplicative constant in the latter - still, there has to be something there.
I hope it's not an operating system that decides to run your thread based on the output of a random variable. And also I hope this is not a realtime operating system. That would probabilistically speaking be the lower depths of hell.