Skip to content

How do I pass the input prompt as args when calling the generated .py file #118

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
AIExplorer25 opened this issue May 8, 2025 · 0 comments

Comments

@AIExplorer25
Copy link

AIExplorer25 commented May 8, 2025

Hello There,
I have converted one of my workflow to .py file, lets say, imagegen.py file and I kept it inside ComfyUI folder, I am able to call it and get the output image, now I want to pass the prompt text as parameter while calling the py file - like: python imagegen.py --input_prompt "a tiger in a jungle", and it always says argument not recognized, although I have defined the args using argparse lib, creating parser , it always says args not recognized.
and says it is expecting arguments of comfyui cli args, it seems the comfyui cli is not allowing me to add my own argument/parameter, how do I achieve that, I want to change the prompt before calling the python file.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant