Spaces:
Running
on
T4
Running
on
T4
RAG changes
Browse files- pages/Semantic_Search.py +5 -5
pages/Semantic_Search.py
CHANGED
@@ -605,7 +605,7 @@ def write_top_bar():
|
|
605 |
# st.write("")
|
606 |
col1, col2,col3,col4 = st.columns([2.5,35,8,7])
|
607 |
with col1:
|
608 |
-
st.image(TEXT_ICON,
|
609 |
with col2:
|
610 |
#st.markdown("")
|
611 |
input = st.text_input( "Ask here",label_visibility = "collapsed",key="input_text",placeholder = "Type your query")
|
@@ -618,7 +618,7 @@ def write_top_bar():
|
|
618 |
col5, col6 = st.columns([4.5,95])
|
619 |
|
620 |
with col5:
|
621 |
-
st.image(IMAGE_ICON,
|
622 |
with col6:
|
623 |
with st.expander(':green[Search by using an image]'):
|
624 |
tab2, tab1 = st.tabs(["Upload Image","Generate Image by AI"])
|
@@ -949,7 +949,7 @@ def write_user_message(md,ans):
|
|
949 |
col1, col2, col3 = st.columns([3,40,20])
|
950 |
|
951 |
with col1:
|
952 |
-
st.image(USER_ICON,
|
953 |
with col2:
|
954 |
#st.warning(md['question'])
|
955 |
st.markdown("<div style='fontSize:15px;padding:3px 7px 3px 7px;borderWidth: 0px;borderColor: red;borderStyle: solid;width: fit-content;height: fit-content;border-radius: 10px;'>Input Text: </div><div style='fontSize:25px;padding:3px 7px 3px 7px;borderWidth: 0px;borderColor: red;borderStyle: solid;width: fit-content;height: fit-content;border-radius: 10px;font-style: italic;color:#e28743'>"+md['question']+"</div>", unsafe_allow_html = True)
|
@@ -1001,7 +1001,7 @@ def write_user_message(md,ans):
|
|
1001 |
def render_answer(answer,index):
|
1002 |
column1, column2 = st.columns([6,90])
|
1003 |
with column1:
|
1004 |
-
st.image(AI_ICON,
|
1005 |
with column2:
|
1006 |
st.markdown("<div style='fontSize:25px;padding:3px 7px 3px 7px;borderWidth: 0px;borderColor: red;borderStyle: solid;width: fit-content;height: fit-content;border-radius: 10px;'>Results </div>", unsafe_allow_html = True)
|
1007 |
if(st.session_state.input_evaluate == "enabled" and st.session_state.input_ndcg > 0):
|
@@ -1175,7 +1175,7 @@ def render_answer(answer,index):
|
|
1175 |
|
1176 |
placeholder__ = st.empty()
|
1177 |
|
1178 |
-
placeholder__.button("🔄",key=rdn_key,on_click=on_button_click, help = "This will regenerate the responses with new settings that you entered, Note: To see difference in responses, you should change any of the applicable settings")#,type="primary",
|
1179 |
|
1180 |
if(filter_out > 0):
|
1181 |
placeholder_no_results.text(str(filter_out)+" result(s) removed due to missing or in-appropriate content")
|
|
|
605 |
# st.write("")
|
606 |
col1, col2,col3,col4 = st.columns([2.5,35,8,7])
|
607 |
with col1:
|
608 |
+
st.image(TEXT_ICON, use_column_width='always')
|
609 |
with col2:
|
610 |
#st.markdown("")
|
611 |
input = st.text_input( "Ask here",label_visibility = "collapsed",key="input_text",placeholder = "Type your query")
|
|
|
618 |
col5, col6 = st.columns([4.5,95])
|
619 |
|
620 |
with col5:
|
621 |
+
st.image(IMAGE_ICON, use_column_width='always')
|
622 |
with col6:
|
623 |
with st.expander(':green[Search by using an image]'):
|
624 |
tab2, tab1 = st.tabs(["Upload Image","Generate Image by AI"])
|
|
|
949 |
col1, col2, col3 = st.columns([3,40,20])
|
950 |
|
951 |
with col1:
|
952 |
+
st.image(USER_ICON, use_column_width='always')
|
953 |
with col2:
|
954 |
#st.warning(md['question'])
|
955 |
st.markdown("<div style='fontSize:15px;padding:3px 7px 3px 7px;borderWidth: 0px;borderColor: red;borderStyle: solid;width: fit-content;height: fit-content;border-radius: 10px;'>Input Text: </div><div style='fontSize:25px;padding:3px 7px 3px 7px;borderWidth: 0px;borderColor: red;borderStyle: solid;width: fit-content;height: fit-content;border-radius: 10px;font-style: italic;color:#e28743'>"+md['question']+"</div>", unsafe_allow_html = True)
|
|
|
1001 |
def render_answer(answer,index):
|
1002 |
column1, column2 = st.columns([6,90])
|
1003 |
with column1:
|
1004 |
+
st.image(AI_ICON, use_column_width='always')
|
1005 |
with column2:
|
1006 |
st.markdown("<div style='fontSize:25px;padding:3px 7px 3px 7px;borderWidth: 0px;borderColor: red;borderStyle: solid;width: fit-content;height: fit-content;border-radius: 10px;'>Results </div>", unsafe_allow_html = True)
|
1007 |
if(st.session_state.input_evaluate == "enabled" and st.session_state.input_ndcg > 0):
|
|
|
1175 |
|
1176 |
placeholder__ = st.empty()
|
1177 |
|
1178 |
+
placeholder__.button("🔄",key=rdn_key,on_click=on_button_click, help = "This will regenerate the responses with new settings that you entered, Note: To see difference in responses, you should change any of the applicable settings")#,type="primary",use_column_width=True)
|
1179 |
|
1180 |
if(filter_out > 0):
|
1181 |
placeholder_no_results.text(str(filter_out)+" result(s) removed due to missing or in-appropriate content")
|