Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -31,9 +31,9 @@ if user_input:
|
|
| 31 |
st.warning("❌ Sorry, I can only answer Python programming questions.")
|
| 32 |
else:
|
| 33 |
system_prompt = (
|
| 34 |
-
"You are
|
| 35 |
-
"
|
| 36 |
-
"
|
| 37 |
)
|
| 38 |
prompt = f"<|system|>\n{system_prompt}</s>\n<|user|>\n{user_input}</s>\n<|assistant|>"
|
| 39 |
|
|
|
|
| 31 |
st.warning("❌ Sorry, I can only answer Python programming questions.")
|
| 32 |
else:
|
| 33 |
system_prompt = (
|
| 34 |
+
"You are an expert Python tutor. Provide clear, concise, and accurate explanations with examples. "
|
| 35 |
+
"If the user's question is not related to Python programming, respond with: "
|
| 36 |
+
"'Sorry, I can only help with Python programming questions.'"
|
| 37 |
)
|
| 38 |
prompt = f"<|system|>\n{system_prompt}</s>\n<|user|>\n{user_input}</s>\n<|assistant|>"
|
| 39 |
|