lunarflu HF Staff commited on
Commit
9091fe3
·
1 Parent(s): a8332cf

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -3
app.py CHANGED
@@ -20,7 +20,7 @@ event = Event()
20
  DISCORD_TOKEN = os.getenv("DISCORD_TOKEN")
21
 
22
  HF_TOKEN = os.getenv("HF_TOKEN")
23
- codellama = Client("https://huggingface-projects-codellama-13b-chat.hf.space/", HF_TOKEN)
24
 
25
 
26
 
@@ -112,7 +112,7 @@ def codellama_initial_generation(prompt, thread):
112
  with open(chat_history, "w") as json_file:
113
  json.dump(conversation, json_file)
114
 
115
- job = codellama.submit(prompt, chat_history, fn_index=0)
116
 
117
  while job.done() is False:
118
  pass
@@ -173,7 +173,7 @@ async def continue_codellama(message):
173
  total_characters += len(string)
174
 
175
  if total_characters < 15000:
176
- job = codellama.submit(prompt, chat_history, fn_index=0)
177
  while job.done() is False:
178
  pass
179
  else:
 
20
  DISCORD_TOKEN = os.getenv("DISCORD_TOKEN")
21
 
22
  HF_TOKEN = os.getenv("HF_TOKEN")
23
+ codellama_client = Client("https://huggingface-projects-codellama-13b-chat.hf.space/", HF_TOKEN)
24
 
25
 
26
 
 
112
  with open(chat_history, "w") as json_file:
113
  json.dump(conversation, json_file)
114
 
115
+ job = codellama_client.submit(prompt, chat_history, fn_index=0)
116
 
117
  while job.done() is False:
118
  pass
 
173
  total_characters += len(string)
174
 
175
  if total_characters < 15000:
176
+ job = codellama_client.submit(prompt, chat_history, fn_index=0)
177
  while job.done() is False:
178
  pass
179
  else: