aquibmoin commited on
Commit
29720b6
1 Parent(s): 5fd49df

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -37,7 +37,7 @@ def generate_response(user_input, relevant_context="", max_tokens=150, temperatu
37
  combined_input = f"Question: {user_input}\nAnswer:"
38
 
39
  response = client.chat.completions.create(
40
- model="gpt-4",
41
  messages=[
42
  {"role": "system", "content": system_message},
43
  {"role": "user", "content": combined_input}
@@ -66,7 +66,7 @@ iface = gr.Interface(
66
  gr.Textbox(lines=2, placeholder="Enter your message here...", label="Your Question"),
67
  gr.Textbox(lines=5, placeholder="Enter context here, separated by new lines...", label="Context"),
68
  gr.Checkbox(label="Use NASA SMD Bi-Encoder for Context"),
69
- gr.Slider(50, 500, value=150, step=10, label="Max Tokens"),
70
  gr.Slider(0.0, 1.0, value=0.7, step=0.1, label="Temperature"),
71
  gr.Slider(0.0, 1.0, value=0.9, step=0.1, label="Top-p"),
72
  gr.Slider(0.0, 1.0, value=0.5, step=0.1, label="Frequency Penalty"),
 
37
  combined_input = f"Question: {user_input}\nAnswer:"
38
 
39
  response = client.chat.completions.create(
40
+ model="gpt-4-turbo",
41
  messages=[
42
  {"role": "system", "content": system_message},
43
  {"role": "user", "content": combined_input}
 
66
  gr.Textbox(lines=2, placeholder="Enter your message here...", label="Your Question"),
67
  gr.Textbox(lines=5, placeholder="Enter context here, separated by new lines...", label="Context"),
68
  gr.Checkbox(label="Use NASA SMD Bi-Encoder for Context"),
69
+ gr.Slider(50, 1000, value=150, step=10, label="Max Tokens"),
70
  gr.Slider(0.0, 1.0, value=0.7, step=0.1, label="Temperature"),
71
  gr.Slider(0.0, 1.0, value=0.9, step=0.1, label="Top-p"),
72
  gr.Slider(0.0, 1.0, value=0.5, step=0.1, label="Frequency Penalty"),