In the STELLAR project, we have performed excellent research in the field of hybrid optoelectronic devices based on heterostructures of switchable molecular systems and 2D materials. Switchable molecular systems include photochromic molecules (such as azobenzenes and diarylethenes) and electrochemically switchable molecules (such as ferrocene). In the library of 2D materials, the STELLAR project mainly focused on 2D semiconductors, for example MoS2, WSe2 and black phosphorus. The molecules undergo a reversible switching process upon exposure to external stimuli, i.e. azobenzene molecules switch between two (meta)stable states with markedly different properties under UV/visible light irradiation, resulting in a modification of the macroscopic properties of the adjacent 2D semiconductors. By combining these switchable molecular systems, 2D devices were constructed to respond to multiple external stimuli, including optical and electrochemical signals. These novel functions are embedded in 2D logic devices, which represents an insightful research direction for the development of electronic and optoelectronic devices.