M17idd commited on
Commit
0bcc41f
·
verified ·
1 Parent(s): 3b8436b

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +2 -2
app.py CHANGED
@@ -97,7 +97,7 @@ with col2:
97
  st.markdown("""
98
  <div class="header-text">
99
  <h1>چت‌ بات توانا</h1>
100
- <div class="subtitle">دستیار هوشمند برای تصمیم‌گیری در میدان نبرد</div>
101
  </div>
102
  """, unsafe_allow_html=True)
103
 
@@ -106,7 +106,7 @@ st.markdown("""
106
  def get_pdf_index():
107
  with st.spinner('📄 در حال پردازش فایل PDF...'):
108
  pdf_reader = [PyPDFLoader('test1.pdf')]
109
- embeddings = HuggingFaceInstructEmbeddings(model_name="universitytehran/PersianMind-v1.0")
110
  index = VectorstoreIndexCreator( embedding=embeddings, text_splitter=RecursiveCharacterTextSplitter(chunk_size=1000, chunk_overlap=128)).from_loaders(pdf_reader)
111
  return index
112
 
 
97
  st.markdown("""
98
  <div class="header-text">
99
  <h1>چت‌ بات توانا</h1>
100
+ <div class="subtitle">دستیار هوشمند</div>
101
  </div>
102
  """, unsafe_allow_html=True)
103
 
 
106
  def get_pdf_index():
107
  with st.spinner('📄 در حال پردازش فایل PDF...'):
108
  pdf_reader = [PyPDFLoader('test1.pdf')]
109
+ embeddings = HuggingFaceInstructEmbeddings(model_name="HooshvareLab/gpt2-fa")
110
  index = VectorstoreIndexCreator( embedding=embeddings, text_splitter=RecursiveCharacterTextSplitter(chunk_size=1000, chunk_overlap=128)).from_loaders(pdf_reader)
111
  return index
112