Stephen MarshCorrect answer
Community Expert
January 3, 2024
Just to be crystal clear, are you referring to the sequential numbers that are added, even if the prefix field is left blank:
Layer Names:
Layer 0
Layer 1
Exported File Names:
_0000_Layer 0.jpg
_0001_Layer 1.jpg
They are there as a safety to stop overwriting an existing file if there are multiple layers with the same name. I'm sure that the script could be modified, these Adobe default scripts are very complicated.
EDIT: If all you want is the layer name, then try changing the following as per the annotated screenshot and restart Photoshop:

This has no effect on the GUI, all it does is change the output filename.
