Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -238,18 +238,18 @@ def main():
|
|
238 |
message(st.session_state['past'][i], is_user=True, key=str(i) + '_user', logo="https://i.pinimg.com/originals/d5/b2/13/d5b21384ccaaa6f9ef32986f17c50638.png")
|
239 |
message(st.session_state["generated"][i], key=str(i), logo= "https://emojiisland.com/cdn/shop/products/Robot_Emoji_Icon_7070a254-26f7-4a54-8131-560e38e34c2e_large.png?v=1571606114")
|
240 |
|
241 |
-
|
242 |
-
|
243 |
-
|
244 |
-
|
245 |
-
|
246 |
-
|
247 |
-
|
248 |
-
|
249 |
-
|
250 |
-
|
251 |
-
|
252 |
-
|
253 |
|
254 |
if __name__ == "__main__":
|
255 |
main()
|
|
|
238 |
message(st.session_state['past'][i], is_user=True, key=str(i) + '_user', logo="https://i.pinimg.com/originals/d5/b2/13/d5b21384ccaaa6f9ef32986f17c50638.png")
|
239 |
message(st.session_state["generated"][i], key=str(i), logo= "https://emojiisland.com/cdn/shop/products/Robot_Emoji_Icon_7070a254-26f7-4a54-8131-560e38e34c2e_large.png?v=1571606114")
|
240 |
|
241 |
+
# Add Google icon button to retrieve links
|
242 |
+
if st.button(f"Double-Check Response", key=f"google_button_{i}"):
|
243 |
+
search_query = get_search_query(st.session_state['generated'][i])
|
244 |
+
retrieved_links = search_url(search_query)
|
245 |
+
if retrieved_links:
|
246 |
+
st.markdown("**Google Search Results:**")
|
247 |
+
for j, link in enumerate(retrieved_links):
|
248 |
+
st.markdown(f"{j + 1}. [{link['title']}]({link['link']})")
|
249 |
+
|
250 |
+
# Display Google logo
|
251 |
+
google_logo_url = "https://companieslogo.com/img/orig/GOOG-0ed88f7c.png"
|
252 |
+
st.image(google_logo_url, width=50, caption="Google Logo")
|
253 |
|
254 |
if __name__ == "__main__":
|
255 |
main()
|