Skip to content

fix: reenable arrow keys by importing readline #606

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

Closed

Conversation

ericrallen
Copy link
Collaborator

@ericrallen ericrallen commented Oct 8, 2023

Describe the changes you have made:

I've found the inability to easily edit the command I had entered to be a source of constant frustration, and propose adding readline back to the project as a quality of life improvement.

This adds import readline back to the interpreter/terminal_interface/terminal_interface.py to enable the use of the Arrow keys for navigating your cursor, exploring command history, etc.

OpenInterpreter-Readline

I've also added a second commit (which we can discard if we want to) that removes the y/n answer from the Do you want to scan this code? and Do you want to run this code? questions because it felt like it was just polluting the command history.

OpenInterpreter-Readline-NoYN

Reference any relevant issue (Fixes #000)

  • I have performed a self-review of my code:

I have tested the code on the following OS:

  • Windows
  • MacOS
  • Linux

AI Language Model (if applicable)

  • GPT4
  • GPT3
  • Llama 7B
  • Llama 13B
  • Llama 34B
  • Huggingface model (Please specify which one)

@ericrallen
Copy link
Collaborator Author

Closing in favor of #522

We can discuss the removal of y/n responses from the readline history after readline functionality is merged back in.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant