You can do this by adding an attribute which holds this information and set it in the microflow where you commit your object. Example, add a string attribute with name 'source' and set this one in your microflow. Now you can do whatever you want with this attribute in your before commit.