From c551606503bcab0de79e88f73d25a9225422593c Mon Sep 17 00:00:00 2001 From: Dave Hulbert Date: Sun, 3 Dec 2023 19:43:47 +0000 Subject: [PATCH] Whitespace in line with flake8y --- clipea/__init__.py | 2 +- clipea/clipea_llm.py | 2 +- clipea/commands.py | 4 ++-- clipea/utils.py | 1 + 4 files changed, 5 insertions(+), 4 deletions(-) diff --git a/clipea/__init__.py b/clipea/__init__.py index e9930aa..e4d96a5 100644 --- a/clipea/__init__.py +++ b/clipea/__init__.py @@ -1,5 +1,5 @@ """Clipea application -📎🟢 Like Clippy but for the CLI. A blazing fast AI helper for your command line +📎🟢 Like Clippy but for the CLI. A blazing fast AI helper for your command line """ import os from clipea import utils, cli diff --git a/clipea/clipea_llm.py b/clipea/clipea_llm.py index 144e4d2..2609f0b 100644 --- a/clipea/clipea_llm.py +++ b/clipea/clipea_llm.py @@ -57,7 +57,7 @@ def process_command(): current_command = command[2:new_line_pos] else: current_command = command[2:] - command = command[new_line_pos + 1 :] + command = command[new_line_pos + 1:] if output_file is not None: buffer += current_command + os.linesep diff --git a/clipea/commands.py b/clipea/commands.py index e049666..de8b26c 100644 --- a/clipea/commands.py +++ b/clipea/commands.py @@ -22,7 +22,7 @@ def setup(): ) else: print("An OpenAI key is already set-up, proceed if you want to change it.") - llm.cli.keys_set() + llm.cli.keys_set() def clipea_execute_prompt(user_prompt: str): @@ -43,7 +43,7 @@ def clipea_execute_prompt(user_prompt: str): from clipea import clipea_llm from llm import Model, Response - llm_name:str = '' + llm_name: str = '' if user_prompt.startswith('4 '): user_prompt = user_prompt[2:] llm_name = 'gpt-4' diff --git a/clipea/utils.py b/clipea/utils.py index 1fe54f2..5e7701a 100644 --- a/clipea/utils.py +++ b/clipea/utils.py @@ -16,6 +16,7 @@ def anystr_force_str(value: AnyStr) -> str: """ return value.decode("utf-8") if isinstance(value, bytes) else value + def read_file(file_path: str) -> str: """Reads a file