Skip to content

Commit

Permalink
enable backslash in chat
Browse files Browse the repository at this point in the history
  • Loading branch information
grota committed Aug 27, 2024
1 parent 7d6ece2 commit e3801e7
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions llm/cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -345,6 +345,8 @@ def chat(
# Left and right arrow keys to move cursor:
readline.parse_and_bind("\\e[D: backward-char")
readline.parse_and_bind("\\e[C: forward-char")
# User must be able to use backslash.
readline.parse_and_bind("\\\\: self-insert")
log_path = logs_db_path()
(log_path.parent).mkdir(parents=True, exist_ok=True)
db = sqlite_utils.Database(log_path)
Expand Down

0 comments on commit e3801e7

Please sign in to comment.