Spaces:
Sleeping
Sleeping
Kushwanth Chowday Kandala
commited on
Commit
·
ab28d5b
1
Parent(s):
1296ca3
update chat app.py
Browse files
app.py
CHANGED
@@ -23,25 +23,26 @@ prompt = st.chat_input("Say something")
|
|
23 |
if prompt:
|
24 |
st.write(f"User has sent the following prompt: {prompt}")
|
25 |
response = model.generate_content(prompt)
|
26 |
-
st.chat_message(
|
|
|
27 |
|
28 |
-
# Define a function that will be called when the user clicks the button
|
29 |
-
def greet_user():
|
30 |
-
|
31 |
-
|
32 |
|
33 |
-
|
34 |
-
|
35 |
|
36 |
-
# Add a button to the app
|
37 |
-
st.button("Greet me!", greet_user)
|
38 |
|
39 |
|
40 |
|
41 |
-
st.title("Hello! Streamlit App")
|
42 |
|
43 |
-
x = st.slider('Select a value')
|
44 |
-
st.write(x, 'squared is', x * x)
|
45 |
|
46 |
|
47 |
# st.title('AI Fitness Trainer: Squats Analysis')
|
|
|
23 |
if prompt:
|
24 |
st.write(f"User has sent the following prompt: {prompt}")
|
25 |
response = model.generate_content(prompt)
|
26 |
+
message = st.chat_message("assistant")
|
27 |
+
message.write(response.text)
|
28 |
|
29 |
+
# # Define a function that will be called when the user clicks the button
|
30 |
+
# def greet_user():
|
31 |
+
# # Get the user's name from the text input
|
32 |
+
# name = st.text_input("Enter your name:")
|
33 |
|
34 |
+
# # Greet the user
|
35 |
+
# st.write(f"Hello, {name}!")
|
36 |
|
37 |
+
# # Add a button to the app
|
38 |
+
# st.button("Greet me!", greet_user)
|
39 |
|
40 |
|
41 |
|
42 |
+
# st.title("Hello! Streamlit App")
|
43 |
|
44 |
+
# x = st.slider('Select a value')
|
45 |
+
# st.write(x, 'squared is', x * x)
|
46 |
|
47 |
|
48 |
# st.title('AI Fitness Trainer: Squats Analysis')
|