write python code that provides a pretty cli interface
- User
write python code that provides a pretty cli interface
Assistant
import click @click.group() def cli(): pass @cli.command() @click.option('--name', prompt='Your name', help='The person to greet.') def greet(name): click.echo(f"Hello, {name}!") @cli.command() @click.option('--number', prompt='Your number', help='The number to square.') def square(number): click.echo(f"The square of {number} is {number ** 2}.") if __name__ == '__main__': cli()
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.