Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,11 @@ For a local demo in your terminal, type :
$ python demo.py
```

To run the Streamlit chat app, type:
```
$ streamlit run streamlit_app.py
```

## To use it on another PDF file
Put the PDF file in the `data/` folder.
In `setup.py`, change the path to include the name of your file.
Expand All @@ -39,4 +44,4 @@ The database will be saved in the `db/` folder.
Langchain


Chroma
Chroma
1 change: 1 addition & 0 deletions requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -77,3 +77,4 @@ watchfiles==0.19.0
websockets==11.0.2
yarl==1.9.2
zstandard==0.21.0
streamlit
13 changes: 13 additions & 0 deletions streamlit_app.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import streamlit as st
import ask

st.title('Xassistant Chat')

st.sidebar.header('Instructions')
st.sidebar.write('Type your question about the Cycle Ingenieur of Ecole Polytechnique in the input box below and press enter to get an answer.')

user_input = st.text_input("Question:", "")

if user_input:
answer = ask.ask(user_input)
st.text_area("Answer:", value=answer, height=300, max_chars=None, help=None)