opensouls / terminal-copilot

A smart terminal assistant that helps you find the right command.
Apache License 2.0
573 stars 43 forks source link

Clarify transmission of directory listings? #36

Open rafpaf opened 1 year ago

rafpaf commented 1 year ago

Thank you for this fantastic piece of software!

I appreciated seeing the thoughtful note in your README about sensitive information. I saw this line:

If you are concerned about the potential for sensitive information to be sent to OpenAI, we recommend not using these flags [i.e. --alias, --git, --history, etc.].

This made me think that no sensitive information would be transmitted to OpenAI if I avoided those flags. However, when I run terminal-copilot with the -v flag, I can see that it transmits a listing of the current directory as part of the prompt. You could clarify that this transmission will happen, even if no special flags are used. It might also be useful to let users disable this transmission. Another reason it is sometimes useful to disable this feature is that if the directory listing is very long, it can lead to an unexpected openai.error.InvalidRequestError.

github-actions[bot] commented 1 year ago

Hey! Thanks for sharing feedback with the community!

JoelKronander commented 1 year ago

Good point, we should probably make this optional as some form of config setting.

rafpaf commented 1 year ago

For what it's worth, for now I'm using terminal-copilot via a script that always runs it from an empty directory in /tmp.

It's a very useful command. Thank you again.

JoelKronander commented 1 year ago

@rafpaf Want to try to make a small PR to make it more like you would prefer it to be? Eg. making the directory listing optional? or asking the user the first time to include it or not?

JoelKronander commented 1 year ago

@rafpaf Any other thoughts on how we can make the tool even better?

2mawi2 commented 1 year ago

@rafpaf Could you test for me if your script use-case works with #43 ?