Spaces:
Runtime error
Runtime error
AlbertoFH98
commited on
Commit
·
121ee4b
1
Parent(s):
90e8e7a
Update app.py
Browse files
app.py
CHANGED
@@ -2,7 +2,7 @@
|
|
2 |
from langchain.prompts import PromptTemplate
|
3 |
from PIL import Image
|
4 |
from streamlit.logger import get_logger
|
5 |
-
from
|
6 |
import pandas as pd
|
7 |
import streamlit as st
|
8 |
import urllib.request
|
@@ -46,7 +46,6 @@ def get_basics_comp(emb_model, model, default_system_prompt_link, _logger, podca
|
|
46 |
r = requests.get("https://raw.githubusercontent.com/AlbertoUAH/Castena/main/media/castena-animated-icon.gif", stream=True)
|
47 |
icon = Image.open(r.raw)
|
48 |
icon = icon.resize((img_size, img_size))
|
49 |
-
#st.sidebar.image(icon)
|
50 |
|
51 |
with st.sidebar.container():
|
52 |
st.markdown(
|
@@ -69,6 +68,11 @@ def get_basics_comp(emb_model, model, default_system_prompt_link, _logger, podca
|
|
69 |
)
|
70 |
|
71 |
|
|
|
|
|
|
|
|
|
|
|
72 |
podcast_list = list(podcast_url_video_df['podcast_name_lit'].apply(lambda x: x.replace("'", "")))
|
73 |
video_option = st.sidebar.selectbox(
|
74 |
"Seleccione el podcast",
|
@@ -180,7 +184,6 @@ RESPUESTA: """
|
|
180 |
|
181 |
for message in st.session_state.messages:
|
182 |
with st.chat_message(message["role"]):
|
183 |
-
print("MUESTRO! " + message["content"])
|
184 |
st.markdown(message["content"])
|
185 |
|
186 |
if prompt := st.chat_input("¡Pregunta lo que quieras!"):
|
|
|
2 |
from langchain.prompts import PromptTemplate
|
3 |
from PIL import Image
|
4 |
from streamlit.logger import get_logger
|
5 |
+
from streamlit_player import st_player
|
6 |
import pandas as pd
|
7 |
import streamlit as st
|
8 |
import urllib.request
|
|
|
46 |
r = requests.get("https://raw.githubusercontent.com/AlbertoUAH/Castena/main/media/castena-animated-icon.gif", stream=True)
|
47 |
icon = Image.open(r.raw)
|
48 |
icon = icon.resize((img_size, img_size))
|
|
|
49 |
|
50 |
with st.sidebar.container():
|
51 |
st.markdown(
|
|
|
68 |
)
|
69 |
|
70 |
|
71 |
+
genre = st.sidebar.radio(
|
72 |
+
"Seleccione el LLM",
|
73 |
+
["LLAMA", "GPT (not available yet)"]
|
74 |
+
)
|
75 |
+
st.sidebar.info('Modelo LLAMA: ' + str(model).split('/')[-1] + '\nModelo GPT: gpt-3.5-turbo', icon="ℹ️")
|
76 |
podcast_list = list(podcast_url_video_df['podcast_name_lit'].apply(lambda x: x.replace("'", "")))
|
77 |
video_option = st.sidebar.selectbox(
|
78 |
"Seleccione el podcast",
|
|
|
184 |
|
185 |
for message in st.session_state.messages:
|
186 |
with st.chat_message(message["role"]):
|
|
|
187 |
st.markdown(message["content"])
|
188 |
|
189 |
if prompt := st.chat_input("¡Pregunta lo que quieras!"):
|