TejAndrewsACC commited on
Commit
d7f92d5
·
verified ·
1 Parent(s): 4f68e05

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -42,7 +42,7 @@ def load_memory(filename='chat_memory.pkl'):
42
  session_memory = load_memory()
43
 
44
  # ---- Response Generation ----
45
- def generate_response(prompt, max_length=25):
46
  inputs = tokenizer(prompt, return_tensors='pt', padding=True, truncation=True, max_length=max_length)
47
  input_ids = inputs['input_ids'].to(device)
48
  attention_mask = inputs['attention_mask'].to(device)
 
42
  session_memory = load_memory()
43
 
44
  # ---- Response Generation ----
45
+ def generate_response(prompt, max_length=50):
46
  inputs = tokenizer(prompt, return_tensors='pt', padding=True, truncation=True, max_length=max_length)
47
  input_ids = inputs['input_ids'].to(device)
48
  attention_mask = inputs['attention_mask'].to(device)