  In optics and photonics, a small number of building blocks, like resonators,
waveguides, arbitrary couplings, and parametric interactions, allow the design
of a broad variety of devices and functionalities, distinguished by their
scattering properties. These include transducers, amplifiers, and nonreciprocal
devices, like isolators or circulators. Usually, the design of such a system is
handcrafted by an experienced scientist in a time-consuming process where it
remains uncertain whether the simplest possibility has indeed been found. In
our work, we develop a discovery algorithm that automates this challenge. By
optimizing the continuous and discrete system properties our automated search
identifies the minimal resources required to realize the requested scattering
behavior. In the spirit of artificial scientific discovery, it produces a
complete list of interpretable solutions and leads to generalizable insights,
as we illustrate in several examples. This now opens the door to rapid design
in areas like photonic and microwave architectures or optomechanics.
