Hello
The only reason I can think of why an sb3 file wouldn't open is if it contains references to a machine learning project that no longer exists.
I'm assuming that what you mean by "works for a few days but then the SB3 files stop working" is that the Scratch file works while the ML project exists, and then stops working after the ML project that it depends on is deleted.
And I'm assuming that the error dialog you're referring to is something like this one:
If my assumptions are wrong, please let me know and I'll take another look.
But if those are correct, then I think you have three options:
1) Don't include ML blocks in sb3 files that you want to reuse for a long time
If you make your template projects with everything except the ML blocks, then all you'll need to do to finish a demo is add in a couple of ML blocks. The template will be reusable across multiple ML projects/models, and will never be impacted by deleting an ML project
2) Don't delete your ML project if you want to keep using your sb3 file
If you have to include the ML blocks in your Scratch sb3 file, then just don't delete the ML project, and the sb3 file will still be usable
3) Remove references to the deleted ML project from the sb3 file
I'm mentioning this option mainly for the sake of completeness, as I don't think it's a reasonable suggestion.
But technically it is possible.
sb3 files are just zip files, you can unzip them. And if you unzip it, you'll find a project.json file that can be edited in any text editor. The list of registered extensions is at the top of the file, so you can delete that and then zip it all back up again.
Like I say, not something I'd necessarily recommend, but it's possible.
If you've got an sb3 file you'd like me to edit in this way for you, please feel free to send it to me.
Kind regards
D