Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -34,13 +34,13 @@ st.write("Choose your move:")
|
|
| 34 |
col1, col2, col3 = st.columns(3)
|
| 35 |
|
| 36 |
with col1:
|
| 37 |
-
if st.button("
|
| 38 |
player_move = "Rock"
|
| 39 |
with col2:
|
| 40 |
-
if st.button("
|
| 41 |
player_move = "Paper"
|
| 42 |
with col3:
|
| 43 |
-
if st.button("
|
| 44 |
player_move = "Scissors"
|
| 45 |
|
| 46 |
# Ensure player_move is defined
|
|
@@ -62,7 +62,7 @@ if "chat" not in st.session_state:
|
|
| 62 |
st.session_state.chat = model.start_chat(history = [
|
| 63 |
{
|
| 64 |
"role": 'user',
|
| 65 |
-
"parts": 'You are playing a random rock paper
|
| 66 |
},
|
| 67 |
{
|
| 68 |
"role": 'model',
|
|
|
|
| 34 |
col1, col2, col3 = st.columns(3)
|
| 35 |
|
| 36 |
with col1:
|
| 37 |
+
if st.button("✊"):
|
| 38 |
player_move = "Rock"
|
| 39 |
with col2:
|
| 40 |
+
if st.button("✋"):
|
| 41 |
player_move = "Paper"
|
| 42 |
with col3:
|
| 43 |
+
if st.button("✌️"):
|
| 44 |
player_move = "Scissors"
|
| 45 |
|
| 46 |
# Ensure player_move is defined
|
|
|
|
| 62 |
st.session_state.chat = model.start_chat(history = [
|
| 63 |
{
|
| 64 |
"role": 'user',
|
| 65 |
+
"parts": 'You are playing a random rock paper scissors game. For rock will say "Rock", for paper will say "Paper" and for scissors will say "Scissors". Pick a random word out of three and reply in single word once I do my move.'
|
| 66 |
},
|
| 67 |
{
|
| 68 |
"role": 'model',
|