ECUiVADE commited on
Commit
b1af726
1 Parent(s): aac9975

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -60,13 +60,14 @@ Age=""
60
  chat_log_name =""
61
 
62
  from llama_cpp import Llama
 
 
63
 
64
  def load_model():
 
65
  llm = Llama(model_path=model_file, model_type="mistral",n_gpu_layers=-1,n_ctx = 2048)
66
  return "Model loaded"
67
 
68
- load_model()
69
-
70
  def reset_chat():
71
  global chat_history, chat_log_history, isFirstRun, context, chat_log_name
72
  chat_history = []
 
60
  chat_log_name =""
61
 
62
  from llama_cpp import Llama
63
+ llm = Llama(model_path=model_file, model_type="mistral",n_gpu_layers=-1,n_ctx = 2048)
64
+
65
 
66
  def load_model():
67
+ global llm
68
  llm = Llama(model_path=model_file, model_type="mistral",n_gpu_layers=-1,n_ctx = 2048)
69
  return "Model loaded"
70
 
 
 
71
  def reset_chat():
72
  global chat_history, chat_log_history, isFirstRun, context, chat_log_name
73
  chat_history = []