Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -1,23 +1,9 @@
|
|
1 |
import streamlit as st
|
2 |
-
from rag_engine import RAGEngine
|
3 |
|
4 |
-
st.title("
|
5 |
-
st.markdown("Ask me how to build any character, and I will tell you the **optimal setup**!")
|
6 |
-
|
7 |
-
# Initialize RAG
|
8 |
-
rag = RAGEngine()
|
9 |
|
10 |
# User Input
|
11 |
-
query = st.text_input("Enter your build question
|
12 |
|
13 |
if query:
|
14 |
-
st.write("
|
15 |
-
with st.spinner("Consulting the Stellaron Hunters..."):
|
16 |
-
stream = rag.stream_answer(query)
|
17 |
-
response = st.empty() # Create a container for streamed content
|
18 |
-
text = ""
|
19 |
-
|
20 |
-
# Stream and display each chunk as it comes in
|
21 |
-
for chunk in stream:
|
22 |
-
text += chunk # Add the chunk to the accumulated text
|
23 |
-
response.markdown(text) # Update the Streamlit app with the current text
|
|
|
1 |
import streamlit as st
|
|
|
2 |
|
3 |
+
st.title("Test App")
|
|
|
|
|
|
|
|
|
4 |
|
5 |
# User Input
|
6 |
+
query = st.text_input("Enter your build question:")
|
7 |
|
8 |
if query:
|
9 |
+
st.write(f"You asked: {query}")
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|