Can the foundation of computer science be implemented to include new rules of inference so that computer can do causal reasoning?
This is a hot topic at the moment. Read this recent paper by Judea Pearl for example. In general, ML and AI are not very good at causal inference at the moment, because it requires a symbolic representation to build causal graphs. Attempts are being made, however, see e.g. https://arxiv.org/abs/1711.08936 or https://arxiv.org/abs/1709.05321.