You can pass flow variables when running in batch mode.
See https://www.knime.com/faq#q12
It’s also possible to change the configuration of the workflow through workflow variables. If a variable is defined for a workflow, you can use it in batch mode by referring to it using a comma separated triplet to specify the name, value and type like this:
-workflow.variable=my_integer,5,int
Best,
Philipp