un-index commited on
Commit
62a9753
·
1 Parent(s): 127dd46
Files changed (1) hide show
  1. app.py +2 -1
app.py CHANGED
@@ -72,6 +72,7 @@ if not main_gpt_j_api_up:
72
 
73
  headers = {"Authorization": f"Bearer {os.environ['API_TOKEN']}"}
74
 
 
75
 
76
 
77
  def f(context, temperature, top_p, max_length, model_idx, SPACE_VERIFICATION_KEY):
@@ -141,7 +142,7 @@ def f(context, temperature, top_p, max_length, model_idx, SPACE_VERIFICATION_KEY
141
  # except:
142
  # generated_text = generator(context, max_length=max_length, top_p=top_p, temperature=temperature, num_return_sequences=1)[0]
143
 
144
- return generated_text
145
  # args found in the source: https://github.com/huggingface/transformers/blob/27b3031de2fb8195dec9bc2093e3e70bdb1c4bff/src/transformers/generation_tf_utils.py#L348-L376
146
 
147
  # TODO use fallback gpt-2 inference api for this as well
 
72
 
73
  headers = {"Authorization": f"Bearer {os.environ['API_TOKEN']}"}
74
 
75
+ # NOTE see build logs here: https://huggingface.co/spaces/un-index/textgen6b/logs/build
76
 
77
 
78
  def f(context, temperature, top_p, max_length, model_idx, SPACE_VERIFICATION_KEY):
 
142
  # except:
143
  # generated_text = generator(context, max_length=max_length, top_p=top_p, temperature=temperature, num_return_sequences=1)[0]
144
 
145
+ # return generated_text
146
  # args found in the source: https://github.com/huggingface/transformers/blob/27b3031de2fb8195dec9bc2093e3e70bdb1c4bff/src/transformers/generation_tf_utils.py#L348-L376
147
 
148
  # TODO use fallback gpt-2 inference api for this as well