Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -73,9 +73,10 @@ if prompt := st.chat_input("Type your message..."):
|
|
73 |
try:
|
74 |
# Generate response using the model
|
75 |
with st.spinner("Generating response..."):
|
|
|
76 |
response = demo(
|
77 |
-
|
78 |
-
max_length=max_tokens, #
|
79 |
temperature=temperature,
|
80 |
top_p=top_p
|
81 |
)
|
|
|
73 |
try:
|
74 |
# Generate response using the model
|
75 |
with st.spinner("Generating response..."):
|
76 |
+
# Pass inputs as positional arguments to the Gradio model
|
77 |
response = demo(
|
78 |
+
f"{system_message}\n\nUser: {prompt}\nAssistant:",
|
79 |
+
max_length=max_tokens, # Gradio parameter
|
80 |
temperature=temperature,
|
81 |
top_p=top_p
|
82 |
)
|