nikunjcepatel commited on
Commit
305a1a4
·
verified ·
1 Parent(s): 33d5d58

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -0
app.py CHANGED
@@ -22,6 +22,9 @@ MODEL_OPTIONS = [
22
  ]
23
 
24
  def generate_text(input_text, selected_model, history):
 
 
 
25
  response = requests.post(
26
  url="https://openrouter.ai/api/v1/chat/completions",
27
  headers={
 
22
  ]
23
 
24
  def generate_text(input_text, selected_model, history):
25
+ if history is None:
26
+ history = "" # Initialize history if it's None
27
+
28
  response = requests.post(
29
  url="https://openrouter.ai/api/v1/chat/completions",
30
  headers={