The efficient characterization of quantum systems, the verification of the operations of quantum devices and the validation of underpinning physical models are central challenges for quantum technologies and fundamental physics. The computational cost of such studies could be improved by machine learning enhanced by quantum simulators. Here researchers interface two different quantum systems through a classical channel—a silicon-photonics quantum simulator and an electron spin in a diamond nitrogen–vacancy centre—and use the former to learn the Hamiltonian of the latter via Bayesian inference. Researchers learn the salient Hamiltonian parameter with an uncertainty of approximately. Furthermore, an observed saturation in the learning algorithm suggests deficiencies in the underlying Hamiltonian model, which we exploit to further improve the model. They implement an interactive version of the protocol and experimentally show its ability to characterize the operation of the quantum photonic device.