In-sensor computing systems demonstrate significant potential for reducing system complexity and enhancing computational efficiency. However, current methodologies predominantly focus on monitoring and processing instantaneous sensor data, neglecting the crucial temporal aspects of sensor inputs. This limitation is particularly significant in healthcare applications, where the human body often exhibits delayed responses to external stimuli. Herein, we developed a synapse-based in-sensor computing system that comprises three retention-engineered synaptic devices connected in parallel to represent the temporal effects of external stimuli. In a proof-of-concept application, the synapse-based in-sensor computing system accurately evaluated the combined temporal risk of hazardous gases, presenting a novel method for assessing the synergistic hazardousness of multiple gases.