DrishtiSharma commited on
Commit
5023810
Β·
verified Β·
1 Parent(s): 3a09537

Create tab_layout.py

Browse files
Files changed (1) hide show
  1. tab_layout.py +31 -0
tab_layout.py ADDED
@@ -0,0 +1,31 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import streamlit as st
2
+
3
+ # App Title
4
+ st.title("πŸš€ Streamlit Tabs Example")
5
+
6
+ # Create tab layout
7
+ tab1, tab2, tab3 = st.tabs(["πŸ’‘ Final Answer", "πŸ“Œ Relevance Analysis", "πŸ“š Retrieved Contexts"])
8
+
9
+ # Tab 1: Final Answer
10
+ with tab1:
11
+ st.markdown("## πŸ’‘ **Final Answer**")
12
+ st.success("This is the final response generated from the system.")
13
+
14
+ # Tab 2: Relevance Analysis
15
+ with tab2:
16
+ st.markdown("### πŸ“Œ **Relevance Analysis**")
17
+ st.write("βœ… **Context 1 - Score: 0**")
18
+ st.write("**Reasoning:** This context contains sufficient information to answer the query.")
19
+
20
+ st.write("βœ… **Context 2 - Score: 1**")
21
+ st.write("**Reasoning:** This context lacks clarity and does not fully address the query.")
22
+
23
+ # Tab 3: Retrieved Contexts
24
+ with tab3:
25
+ st.markdown("### πŸ“š **Retrieved Contexts**")
26
+ st.write("πŸ”Ή **Context 1:** This is a relevant passage from the document.")
27
+ st.write("πŸ”Ή **Context 2:** This is another relevant passage.")
28
+
29
+ # Footer
30
+ st.markdown("---")
31
+ st.markdown("πŸ’‘ **Switch between tabs to explore different sections!**")