beriond commited on
Commit
90407c8
路
verified 路
1 Parent(s): 9d738b9

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +3 -2
app.py CHANGED
@@ -26,7 +26,8 @@ def carregar_documento_pdf(path):
26
  # 鈿欙笍 Pipeline com Mistral-7B (贸timo para chat)
27
  pipe = pipeline(
28
  "text-generation",
29
- model="mistralai/Mistral-7B-Instruct",
 
30
  max_new_tokens=512,
31
  do_sample=True,
32
  temperature=0.7,
@@ -64,7 +65,7 @@ chat_chain = ConversationalRetrievalChain.from_llm(
64
 
65
  # 馃挰 Interface Gradio
66
  with gr.Blocks() as demo:
67
- gr.Markdown("## 馃馃捈 Chat com Documento T茅cnico (Mistral 7B + RAG)")
68
 
69
  chatbot = gr.Chatbot(label="Assistente T茅cnico")
70
  entrada = gr.Textbox(placeholder="Pergunte sobre os projetos do documento...", show_label=False)
 
26
  # 鈿欙笍 Pipeline com Mistral-7B (贸timo para chat)
27
  pipe = pipeline(
28
  "text-generation",
29
+ model="mistralai/Mistral-7B-Instruct-v0.2",
30
+ model.to("cuda"),
31
  max_new_tokens=512,
32
  do_sample=True,
33
  temperature=0.7,
 
65
 
66
  # 馃挰 Interface Gradio
67
  with gr.Blocks() as demo:
68
+ gr.Markdown("## 馃馃捈 CS Search Engine")
69
 
70
  chatbot = gr.Chatbot(label="Assistente T茅cnico")
71
  entrada = gr.Textbox(placeholder="Pergunte sobre os projetos do documento...", show_label=False)