Spaces:
Running
Running
Commit
·
8fb7910
1
Parent(s):
8022880
加入readme
Browse files
README.md
CHANGED
@@ -12,3 +12,76 @@ pinned: false
|
|
12 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
13 |
|
14 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
12 |
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
|
13 |
|
14 |
|
15 |
+
## app links:
|
16 |
+
### https://huggingface.co/spaces/Siyuan0730/OmniTutor
|
17 |
+
|
18 |
+
## Introduction
|
19 |
+
|
20 |
+
OmniTutor v0.1.0 is an all-round teacher, combined with a personalized teaching assistant that specially designed for all learners. Skilled in creating customized courses from given knowledge materials, and answering course-related questions with trustable accuracy. Hopefully it helps reducing obstacles in your learning journey.
|
21 |
+
|
22 |
+
## Features
|
23 |
+
|
24 |
+
- 🌍 **Anytime, anywhere**
|
25 |
+
You no longer have to wait for a set class time or find an available teacher. OmniTutor is ready to provide you with answers and help you solve difficult problems.
|
26 |
+
|
27 |
+
- 📚 **All disciplines**
|
28 |
+
Whether it's math, physics, literature, history or coding, OmniTutor covers it all. It has a wide range of subject knowledge to meet your multi-faceted learning needs.
|
29 |
+
|
30 |
+
- 🌐 **All available**
|
31 |
+
You can interact with OmniTutor via text, *audio or video* (in the future). It provides you with real-time feedback and ensures that there are no obstacles in your learning process.
|
32 |
+
|
33 |
+
- ⚡ **Act now**
|
34 |
+
No need to wait a long time, your questions related to the course will be answered in an instant. The efficiency and speed of OmniTutor ensures that your learning process will not be interrupted.
|
35 |
+
|
36 |
+
- 🚀 **An experience, always accompany**
|
37 |
+
OmniTutor is like an all-round study companion, no matter where you are, it can help you to ensure that your learning journey is smooth and fun.
|
38 |
+
|
39 |
+
OmniTutor - An all-round teacher and a personalized teaching assistant who really knows the subject, to help you solve all your learning problems, Make learning so simple: anything, anywhere, all at once.
|
40 |
+
|
41 |
+
## How to Use
|
42 |
+
|
43 |
+
1. **Start the Application**: Execute the script to initiate the OmniTutor interface.
|
44 |
+
2. **Upload learning materials**: The upload widget in the sidebar supports PDF and .md files simutaenously.
|
45 |
+
3. **Customize your course**: By few clicks and swipes, adjusting teaching style, lesson count and language for your course.
|
46 |
+
4. **Start course generating**: Touch "Generate my course!" button in the sidebar, then watch how OmniTutor creates personal-customized course for you.
|
47 |
+
5. **Interactive learning**: Learn the course, and ask OmniTutor any questions related to this course whenever you encountered them.
|
48 |
+
|
49 |
+
## Setup and Running
|
50 |
+
|
51 |
+
Before running , ensure you have the following prerequisites installed:
|
52 |
+
|
53 |
+
- Python 3.x
|
54 |
+
- Streamlit
|
55 |
+
- FAISS
|
56 |
+
- NLTK
|
57 |
+
- OpenAI
|
58 |
+
|
59 |
+
1. **Clone the Repository**:
|
60 |
+
```bash
|
61 |
+
git clone ...
|
62 |
+
```
|
63 |
+
|
64 |
+
2. **Install Required Libraries**:
|
65 |
+
```bash
|
66 |
+
pip install -r requirements
|
67 |
+
```
|
68 |
+
|
69 |
+
3. **Set Up OpenAI API Key**:
|
70 |
+
Ensure you have your OpenAI API key set up. You can either set it as an environment variable or use Streamlit's secrets management.
|
71 |
+
|
72 |
+
4. **Run the Application**:
|
73 |
+
```bash
|
74 |
+
streamlit run <filename>.py
|
75 |
+
```
|
76 |
+
|
77 |
+
## Contributing
|
78 |
+
|
79 |
+
We welcome contributions from the community. If you'd like to improve the application, feel free to fork the repository, make your changes, and submit a pull request.
|
80 |
+
|
81 |
+
## License
|
82 |
+
|
83 |
+
This project is licensed under the MIT License. For more details, refer to the `LICENSE` file in the repository.
|
84 |
+
|
85 |
+
## Acknowledgements
|
86 |
+
|
87 |
+
Special thanks to the developers of Streamlit, FAISS, NLTK and OpenAI for their incredible tools that made this project possible.
|
app.py
CHANGED
@@ -363,13 +363,14 @@ def app():
|
|
363 |
st.session_state.course_outline_list = initialize_outline(temp_file_paths, num_lessons, language)
|
364 |
st.session_state.course_content_list = initialize_content(st.session_state.course_outline_list, st.session_state.embeddings_df, st.session_state.faiss_index, language)
|
365 |
|
366 |
-
|
367 |
-
|
368 |
-
|
369 |
-
|
370 |
-
|
371 |
-
|
372 |
-
|
|
|
373 |
|
374 |
col1, col2 = st.columns([0.6,0.4])
|
375 |
user_question = st.chat_input("Enter your questions when learning...")
|
|
|
363 |
st.session_state.course_outline_list = initialize_outline(temp_file_paths, num_lessons, language)
|
364 |
st.session_state.course_content_list = initialize_content(st.session_state.course_outline_list, st.session_state.embeddings_df, st.session_state.faiss_index, language)
|
365 |
|
366 |
+
st.markdown('''
|
367 |
+
> 🤔 <font color = 'grey'> Not satisfied with this course? Simply click "Generate my course!" button to regenerate a new one! </font>
|
368 |
+
>
|
369 |
+
> 😁 <font color = 'grey'> If the course is good enough for you, learn and enter questions related in the input box below 👇... </font>
|
370 |
+
|
371 |
+
:blue[Wish you all the best in your learning journey :)]
|
372 |
+
''', unsafe_allow_html=True)
|
373 |
+
|
374 |
|
375 |
col1, col2 = st.columns([0.6,0.4])
|
376 |
user_question = st.chat_input("Enter your questions when learning...")
|