Logic programming as a service