Only one instance of scene.before appeared In Developer Tools> States and in Settings > Automations and Scenes > Scenes. The scene entity cannot be deleted but this is expected because it’s meant to exist until Home Assistant is restarted. I restarted and the one instance of scene.before was eliminated.
I don’t know why you’re seeing multiple instances of the scene.
Unless someone else knows the cause (give it at least a day or three), you may need to report this as an Issue in Home Assistant’s GitHub repository. However I don’t know if this should be reported in Frontend or Core repository; it may be either a UI bug (Frontend) or a Scene integration bug (Core). I suggest you start by posting the Issue in Core and wait for advice from a member of the development team.
I’ve been fiddling around with it and I think it’s because I have 4 automations, all of which are based on that same example, and they all use ‘before’ as the temporary scene. I’ve changed them to use different scene names, and now instead of hundreds of ‘before’ scenes, I just have a list of the 4 temporary scenes.
I’ve then removed these 4 unwanted scene names by adding a scene.reload to the end of each automation. This reloads my scenes (I dont have any), and wipes out the temporary scene after each run.