If you want to run a pump for 4 seconds every time a sensor is triggered, “delay” is probably the node you want to use rather than flip-flip. Unless you want time between triggers, you can tie the sensor output directly to delay-SET. delay-ACT can then be used to drive pump relay. I’m pretty sure the built in tutorial has an example just like this using button, delay, and led nodes.
If you don’t want the pump triggered again while it is running, or for a set time after each trigger, you can have delay-ACT trigger a second delay node for the time you want sensor disabled. This can be used to disable sensor if that is an option, or control a “gate” node between the sensor and delay node that runs the pump to block sensor output. Either way, you will probably need a “not” node to negate the output of the second delay node (you want sensor enabled when ACT is false).