So I built Discomfort. It allows me to run Comfy 100% on Python. I can run partial workflows to load models, iterate over different prompts, do if/then clauses, run loops etc. It's FOSS (MIT license).
You can do a lot of stuff with it, especially if you hate spending hours dealing with spaghetti workflows and debugging un-debuggable megaworkflows.
Would love to hear the community's thoughts on it. I hope it helps you as much as it helps me.