-
Notifications
You must be signed in to change notification settings - Fork 2.7k
add basic autocomplete functionality to node cli #3035
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
Conversation
lstein
commented
Mar 26, 2023
- Commands, invocations and their parameters will now autocomplete using introspection.
- Two types of parameter arguments will also autocomplete:
- --sampler_name will autocomplete the scheduler name
- --model will autocomplete the model name
- There don't seem to be commands for reading/writing image files yet, so path autocompletion is not implemented
- Commands, invocations and their parameters will now autocomplete using introspection. - Two types of parameter *arguments* will also autocomplete: - --sampler_name will autocomplete the scheduler name - --model will autocomplete the model name - There don't seem to be commands for reading/writing image files yet, so path autocompletion is not implemented
|
Very nice! |
psychedelicious
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Works great, thanks!
|
Is there an autocompleter for ArgParse we could just build on top of? I don't know if that would be worthwhile? e.g. https://github.com/kislyuk/argcomplete |
Kyle0654
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The model shouldn't be on the command line (since there's no concept of "current" model in nodes). Otherwise, everything looks fine.
1. Prompt has changed to "invoke> ". 2. Function to initialize the autocompleter has been renamed "set_autocompleter()"
Kyle0654
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Approving, but with one suggestion.