I want to run a script but it should not be listed at any step in the history state. would be best if it were just a step visible, so for example, there is a frequency separation are performed. In the history state then should "frequency separation" are.

However, there is a nasty bug in Photoshop that can do strange thing if you set a selection and it is active and you resize a layer Photoshop will back up one history state after the resize. If you have suspended recording history states you will be backed up one state before the script was started. For example If you paste in a new image layer than run the script to process that new image layer. If the script suspends recording history states then hits the bug the layer that was pasted in will be deleted. What was current resized layer will not longer be around after it is resized it will be deleted when Photoshop back up one history state. Who can tell what the script will do next. Photoshop most likely did something before the resize that it thought would be recorded in history but was not because history recording was suspended by the script. So when Photoshop tried to delete the history state it deleted a state recorder before the script was started,

This bug is in every Photoshop version I have tested. Adobe acknowledge my bug report is a bug but has not bothered to fix it.