Update src/streamlit_app.py
Browse files- src/streamlit_app.py +10 -1
src/streamlit_app.py
CHANGED
|
@@ -48,6 +48,11 @@ prompt = PromptTemplate(
|
|
| 48 |
)
|
| 49 |
)
|
| 50 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 51 |
|
| 52 |
# Initialize embeddings & documents
|
| 53 |
@st.cache_resource
|
|
@@ -86,7 +91,11 @@ def setup_qa():
|
|
| 86 |
|
| 87 |
# Streamlit App UI
|
| 88 |
st.title("🌾 AgriQuery: RAG-Based Research Assistant")
|
| 89 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
| 90 |
query = st.text_input("Ask a question related to agriculture:")
|
| 91 |
|
| 92 |
if query:
|
|
|
|
| 48 |
)
|
| 49 |
)
|
| 50 |
|
| 51 |
+
EXAMPLE_QUESTIONS = [
|
| 52 |
+
"What is agriculture?",
|
| 53 |
+
"Why is crop rotation important?",
|
| 54 |
+
"How does composting help farming?",
|
| 55 |
+
]
|
| 56 |
|
| 57 |
# Initialize embeddings & documents
|
| 58 |
@st.cache_resource
|
|
|
|
| 91 |
|
| 92 |
# Streamlit App UI
|
| 93 |
st.title("🌾 AgriQuery: RAG-Based Research Assistant")
|
| 94 |
+
# Show example questions
|
| 95 |
+
with st.expander("💡 Try example questions"):
|
| 96 |
+
for q in EXAMPLE_QUESTIONS:
|
| 97 |
+
st.markdown(f"- {q}")
|
| 98 |
+
|
| 99 |
query = st.text_input("Ask a question related to agriculture:")
|
| 100 |
|
| 101 |
if query:
|