kitrak-rev commited on
Commit
a8b730c
1 Parent(s): 1225f38

correct imports

Browse files
Files changed (1) hide show
  1. app.py +5 -2
app.py CHANGED
@@ -1,5 +1,7 @@
1
- import gradio as gr
2
-
 
 
3
  message_list = []
4
  response_list = []
5
  from transformers import pipeline
@@ -12,6 +14,7 @@ messages = [
12
  ]
13
  chatbot = pipeline("text-generation", model="mistralai/Mistral-7B-Instruct-v0.3",max_new_tokens=5000)
14
 
 
15
  def mini_chatbot(message, history):
16
  conversation = Conversation(text=message,
17
  past_user_inputs=message_list,
 
1
+ from transformers import Conversation
2
+ from huggingface_hub import login
3
+ import os
4
+ login(token = os.getenv("HF_TOKEN") )
5
  message_list = []
6
  response_list = []
7
  from transformers import pipeline
 
14
  ]
15
  chatbot = pipeline("text-generation", model="mistralai/Mistral-7B-Instruct-v0.3",max_new_tokens=5000)
16
 
17
+
18
  def mini_chatbot(message, history):
19
  conversation = Conversation(text=message,
20
  past_user_inputs=message_list,