KittyCat00 commited on
Commit
6070819
·
verified ·
1 Parent(s): 8ba60a0

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -512,7 +512,7 @@ def main(input_text, max_new_tokens):
512
  encoded = torch.tensor(tokenizer.encode(input_text.strip())).unsqueeze(0).to(device)
513
 
514
  with torch.no_grad():
515
- token_ids = generate_text_simple(
516
  model=model, idx=encoded,
517
  max_new_tokens=max_new_tokens, context_size=context_size,
518
  top_k=25, temperature=1.4, text_to_token_ids=text_to_token_ids, tokenizer=tokenizer
 
512
  encoded = torch.tensor(tokenizer.encode(input_text.strip())).unsqueeze(0).to(device)
513
 
514
  with torch.no_grad():
515
+ token_ids = generate(
516
  model=model, idx=encoded,
517
  max_new_tokens=max_new_tokens, context_size=context_size,
518
  top_k=25, temperature=1.4, text_to_token_ids=text_to_token_ids, tokenizer=tokenizer