awacke1 commited on
Commit
8f84cbd
·
verified ·
1 Parent(s): 58d011a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -4
app.py CHANGED
@@ -598,7 +598,7 @@ def main():
598
  total_docs = len(documents)
599
  # Add a slider to let the user choose how many documents to display
600
  num_docs_to_display = st.slider(
601
- "Select number of documents to display", 1, 100, 5
602
  )
603
  # Adjust the document display logic based on the slider value
604
  if total_docs > num_docs_to_display:
@@ -619,7 +619,7 @@ def main():
619
  st.markdown(Label)
620
  total_docs = len(documents)
621
  doc = documents[st.session_state.current_index]
622
- st.markdown(f"#### Document ID: {doc.get('id', '')}")
623
 
624
  # 🕵️ Value extraction - "Finding spaces in all the right places"
625
  values_with_space = []
@@ -662,7 +662,7 @@ def main():
662
  st.markdown(Label)
663
  total_docs = len(documents)
664
  doc = documents[st.session_state.current_index]
665
- st.markdown(f"#### Document ID: {doc.get('id', '')}")
666
  doc_str = st.text_area("Edit Document",
667
  value=json.dumps(doc, indent=2),
668
  height=300,
@@ -719,7 +719,7 @@ def main():
719
  for idx, (col, doc) in enumerate(zip(cols, documents_to_display)):
720
  with col:
721
 
722
- st.markdown(f"##### Document ID: {doc.get('id', '')}")
723
  editable_id = st.text_input("ID", value=doc.get('id', ''), key=f'edit_id_{idx}')
724
  editable_doc = doc.copy()
725
  editable_doc.pop('id', None)
 
598
  total_docs = len(documents)
599
  # Add a slider to let the user choose how many documents to display
600
  num_docs_to_display = st.slider(
601
+ "Select number of documents to display", 1, 20, 3
602
  )
603
  # Adjust the document display logic based on the slider value
604
  if total_docs > num_docs_to_display:
 
619
  st.markdown(Label)
620
  total_docs = len(documents)
621
  doc = documents[st.session_state.current_index]
622
+ # st.markdown(f"#### Document ID: {doc.get('id', '')}")
623
 
624
  # 🕵️ Value extraction - "Finding spaces in all the right places"
625
  values_with_space = []
 
662
  st.markdown(Label)
663
  total_docs = len(documents)
664
  doc = documents[st.session_state.current_index]
665
+ # st.markdown(f"#### Document ID: {doc.get('id', '')}")
666
  doc_str = st.text_area("Edit Document",
667
  value=json.dumps(doc, indent=2),
668
  height=300,
 
719
  for idx, (col, doc) in enumerate(zip(cols, documents_to_display)):
720
  with col:
721
 
722
+ # st.markdown(f"##### Document ID: {doc.get('id', '')}")
723
  editable_id = st.text_input("ID", value=doc.get('id', ''), key=f'edit_id_{idx}')
724
  editable_doc = doc.copy()
725
  editable_doc.pop('id', None)