This reasoning, in the case of optics, can be found in Categories of Optics (Riley, 2018). Tags: Monoidal contexts, Category