Skip to content

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

@AIExplorer25

Description

@AIExplorer25

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.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions