Rooni commited on
Commit
05c35aa
1 Parent(s): c6b109e

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -0
app.py CHANGED
@@ -7,6 +7,9 @@ import os
7
 
8
  # functions
9
  def generate(description, model, max_tokens):
 
 
 
10
  headers = {
11
  'Content-Type': 'application/json',
12
  'Authorization': f'Bearer {os.getenv("API_KEY")}'
 
7
 
8
  # functions
9
  def generate(description, model, max_tokens):
10
+ if not description or not model:
11
+ return ""
12
+
13
  headers = {
14
  'Content-Type': 'application/json',
15
  'Authorization': f'Bearer {os.getenv("API_KEY")}'