Spaces:
Sleeping
Sleeping
Commit
·
874fc5b
1
Parent(s):
4b4013f
message
Browse files
app.py
CHANGED
|
@@ -9,10 +9,20 @@ genre = st.radio(
|
|
| 9 |
"Choose dataset to finetune", radioButtonList
|
| 10 |
)
|
| 11 |
|
|
|
|
| 12 |
if genre==radioButtonList[0]:
|
| 13 |
-
|
| 14 |
-
|
| 15 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 16 |
|
| 17 |
isCustomURL = genre==radioButtonList[4]
|
| 18 |
title = st.text_input('Enter your own URL', 'https://shorturl.at/csCK3', disabled=not isCustomURL)
|
|
@@ -36,3 +46,11 @@ if uploaded_file is not None:
|
|
| 36 |
# Can be used wherever a "file-like" object is accepted:
|
| 37 |
dataframe = pd.read_csv(uploaded_file)
|
| 38 |
st.write(dataframe)
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
"Choose dataset to finetune", radioButtonList
|
| 10 |
)
|
| 11 |
|
| 12 |
+
pdfCSVURLText = ""
|
| 13 |
if genre==radioButtonList[0]:
|
| 14 |
+
pdfCSVURLText = "CSV"
|
| 15 |
+
# st.write('You selected comedy.')
|
| 16 |
+
# else:
|
| 17 |
+
# st.write(f'''Password streamlit app: {st.secrets["PSWD"]}''')
|
| 18 |
+
elif genre==radioButtonList[1]:
|
| 19 |
+
pdfCSVURLText = "CSV"
|
| 20 |
+
elif genre==radioButtonList[2]:
|
| 21 |
+
pdfCSVURLText = "PDF"
|
| 22 |
+
elif genre==radioButtonList[3]:
|
| 23 |
+
pdfCSVURLText = "URL"
|
| 24 |
+
elif genre==radioButtonList[4]:
|
| 25 |
+
pdfCSVURLText = "URL"
|
| 26 |
|
| 27 |
isCustomURL = genre==radioButtonList[4]
|
| 28 |
title = st.text_input('Enter your own URL', 'https://shorturl.at/csCK3', disabled=not isCustomURL)
|
|
|
|
| 46 |
# Can be used wherever a "file-like" object is accepted:
|
| 47 |
dataframe = pd.read_csv(uploaded_file)
|
| 48 |
st.write(dataframe)
|
| 49 |
+
|
| 50 |
+
title = st.text_input(f'Ask me anything about this {pdfCSVURLText}', 'Type here', disabled=not isCustomURL)
|
| 51 |
+
chatWithPDFButton = "CLICK HERE TO START CHATTING"
|
| 52 |
+
st.button(chatWithPDFButton, type="primary")
|
| 53 |
+
if st.button(chatWithPDFButton):
|
| 54 |
+
pass
|
| 55 |
+
else:
|
| 56 |
+
pass
|