Skip to content

Commit

Permalink
Replace hardcoded default value for model and use instead DEFAULT_MODEL
Browse files Browse the repository at this point in the history
  • Loading branch information
meirm committed Jun 1, 2023
1 parent 8a98a26 commit fab9398
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions debugger_no_modal.py
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ def walk_directory(directory):
return code_contents


def main(prompt, directory=DEFAULT_DIR, model="gpt-3.5-turbo"):
def main(prompt, directory=DEFAULT_DIR, model=DEFAULT_MODEL):
code_contents = walk_directory(directory)

# Now, `code_contents` is a dictionary that contains the content of all your non-image files
Expand All @@ -62,7 +62,7 @@ def main(prompt, directory=DEFAULT_DIR, model="gpt-3.5-turbo"):
print("\033[96m" + res + "\033[0m")


def generate_response(system_prompt, user_prompt, model="gpt-3.5-turbo", *args):
def generate_response(system_prompt, user_prompt, model=DEFAULT_MODEL, *args):
import openai

# Set up your OpenAI API credentials
Expand Down Expand Up @@ -98,5 +98,5 @@ def generate_response(system_prompt, user_prompt, model="gpt-3.5-turbo", *args):
print("Please provide a prompt")
sys.exit(1)
prompt = sys.argv[1]
model = sys.argv[2] if len(sys.argv) > 2 else "gpt-3.5-turbo"
model = sys.argv[2] if len(sys.argv) > 2 else DEFAULT_MODEL
main(prompt, model)

0 comments on commit fab9398

Please sign in to comment.