[CLI] Boolean flags with `action="store_true", default=True` cannot be disabled
Problem
Several CLI flags are declared as action="store_true" with default=True, so they are always True and there is no way to turn them off from the command line:
llmsql/_cli/inference.py—--trust-remote-code(transformers & vLLM),--use-chat-template(vLLM),--do-samplefor vLLM (defaultTrue)llmsql/_cli/evaluate.py—--show-mismatches
Consequences: e.g. greedy decoding can't be requested for the vLLM CLI via --do-sample (only by passing --temperature 0), and remote code is always trusted.
Proposal
Use argparse.BooleanOptionalAction (Python ≥3.9) so both --flag and --no-flag exist, and add CLI tests for both forms.
Related: trust_remote_code=True by default is a security footgun (executes arbitrary code from the Hub). Consider defaulting to False in a minor release with a deprecation note.
Also: vLLM --do-sample uses add_common_generation_args(..., 1.0, True), and default_sample is typed int. The root parser's set_defaults(func=print_help) can never run, because subcommands are required=True. tests/cli/test_cli.py mocks the synchronous backends with AsyncMock, which causes "coroutine was never awaited" warnings; use MagicMock.
Hi @DzmitryPihulski , I’m a first-time contributor and I’d like to work on this issue. Would it be okay if I picked it up?
Thanks!
Hi! I'd like to work on this issue as my first contribution to LLMSQL. I plan to update the boolean CLI flags to support explicit enable/disable behavior and add/adjust CLI tests for both forms. Please assign the issue to me if appropriate.
@satheesh142002 hi, sure, go ahead. @pradeep14012004 , sorry, first in first out
Hi @DzmitryPihulski , thank you for assigning this issue to me. I noticed that @pradeep14012004 has already opened a PR for this issue. Since he have already completed the work, could you please consider reviewing their PR first? I’m happy to contribute to another issue if needed.
Thanks for your consideration!
Yes @satheesh142002 , since you was first (and you was assigned), go ahead and submit your PR