As the field of artificial intelligence advances, the demand for algorithms that can learn quickly and efficiently increases. An important paradigm within artificial intelligence is reinforcement learning.sup.1, where decision-making entities called agents interact with environments and learn by updating their behaviour on the basis of the obtained feedback. The crucial question for practical applications is how fast agents learn.sup.2. Although various studies have made use of quantum mechanics to speed up the agent's decision-making process.sup.3,4, a reduction in learning time has not yet been demonstrated. Here we present a reinforcement learning experiment in which the learning process of an agent is sped up by using a quantum communication channel with the environment. We further show that combining this scenario with classical communication enables the evaluation of this improvement and allows optimal control of the learning progress. We implement this learning protocol on a compact and fully tunable integrated nanophotonic processor. The device interfaces with telecommunication-wavelength photons and features a fast active-feedback mechanism, demonstrating the agent's systematic quantum advantage in a setup that could readily be integrated within future large-scale quantum communication networks. A reinforcement learning experiment using a programmable integrated nanophotonic processor shows that a quantum communication channel with the environment speeds up the learning process of an agent.