FocusFlow Assistant commited on
Commit
77280d2
Β·
1 Parent(s): 740d386

docs: Comprehensive README update

Browse files

- Added features list and architecture diagram
- Documented cloud vs local deployment
- Added quick start guide
- Included environment variables reference
- Added links to live demo and docs

Files changed (1) hide show
  1. README.md +150 -4
README.md CHANGED
@@ -10,10 +10,156 @@ pinned: false
10
 
11
  # πŸ“š FocusFlow - AI Study Companion
12
 
13
- Intelligent study assistant with RAG-powered Q&A, adaptive quizzes, and personalized learning paths.
14
 
15
- > ⚠️ **Demo Limitation**: This cloud demo uses ephemeral storage. Your study plans and progress will reset when you refresh the page. For persistent data, use the local version.
16
 
17
- **Live Demo**: Running on Hugging Face Spaces with Llama-3-8B
 
 
 
 
 
 
 
18
 
19
- **Local Setup**: [GitHub Repository](https://github.com/thesivarohith/hack) - Fully offline with data persistence
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
10
 
11
  # πŸ“š FocusFlow - AI Study Companion
12
 
13
+ An intelligent study assistant powered by AI that transforms your learning materials into personalized, adaptive study experiences.
14
 
15
+ ## ✨ Features
16
 
17
+ - **πŸ“– Multi-Subject Study Planning**: Upload PDFs and get automated multi-day study plans
18
+ - **πŸ’¬ RAG-Powered Q&A**: Ask questions and get answers with source citations
19
+ - **πŸ“ Adaptive Quizzes**: Context-based quizzes that adapt to your performance
20
+ - **πŸ“Š Progress Tracking**: Track mastery levels and quiz history
21
+ - **🎯 Smart Day Progression**: Automatically unlocks new topics as you complete them
22
+ - **πŸ” Source Citations**: Every answer cites the exact source and page number
23
+ - **☁️ Cloud Persistence**: Study plans and progress persist across sessions (cloud demo only)
24
+ - **πŸ‘₯ Multi-User Support**: Each browser session maintains isolated data
25
 
26
+ ## πŸš€ Live Demo
27
+
28
+ **[Try FocusFlow on Hugging Face Spaces](https://huggingface.co/spaces/SivaRohith69/focusflow)**
29
+
30
+ > **Note**: The cloud demo uses ephemeral containers. Your data persists in Supabase but each browser tab is treated as a separate user. For true persistent local storage, use the local deployment below.
31
+
32
+ ## πŸ€– Models Used
33
+
34
+ ### Cloud Demo (HF Spaces)
35
+ - **LLM**: Meta-Llama-3-8B-Instruct (via Hugging Face Inference API)
36
+ - **Embeddings**: sentence-transformers/all-MiniLM-L6-v2
37
+
38
+ ### Local Deployment
39
+ - **LLM**: llama3.2:1b (via Ollama - offline)
40
+ - **Embeddings**: nomic-embed-text (offline)
41
+
42
+ ## πŸ’» Local Installation
43
+
44
+ ### Prerequisites
45
+ - Python 3.10+
46
+ - [Ollama](https://ollama.ai/) installed and running
47
+ - 8GB+ RAM recommended
48
+
49
+ ### Quick Start
50
+
51
+ ```bash
52
+ # Clone the repository
53
+ git clone https://github.com/thesivarohith/hack.git
54
+ cd hack
55
+
56
+ # Create virtual environment
57
+ python -m venv venv
58
+ source venv/bin/activate # On Windows: venv\Scripts\activate
59
+
60
+ # Install dependencies
61
+ pip install -r requirements.txt
62
+
63
+ # Pull required Ollama models
64
+ ollama pull llama3.2:1b
65
+ ollama pull nomic-embed-text
66
+
67
+ # Start the backend
68
+ uvicorn backend.main:app --reload &
69
+
70
+ # Start the frontend
71
+ streamlit run app.py
72
+ ```
73
+
74
+ Visit `http://localhost:8501` to use the app!
75
+
76
+ ## 🎯 How to Use
77
+
78
+ 1. **Upload PDFs**: Add your study materials in the Sources panel
79
+ 2. **Generate Plan**: Ask the Calendar to create a study plan (e.g., "Make a 5-day plan")
80
+ 3. **Study**: Click on topics to view lessons and ask questions
81
+ 4. **Take Quizzes**: Test your knowledge and unlock new topics
82
+ 5. **Track Progress**: View analytics and mastery levels
83
+
84
+ ## πŸ—οΈ Architecture
85
+
86
+ ```
87
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
88
+ β”‚ Streamlit Frontend β”‚
89
+ β”‚ (Material Design UI + Calendar) β”‚
90
+ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
91
+ β”‚
92
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”
93
+ β”‚ FastAPI β”‚
94
+ β”‚ Backend β”‚
95
+ β””β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜
96
+ β”‚
97
+ β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
98
+ β”‚ β”‚ β”‚
99
+ β”Œβ”€β”€β”€β–Όβ”€β”€β”€β”€β” β”Œβ”€β”€β–Όβ”€β”€β”€β”€β” β”Œβ”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”
100
+ β”‚ ChromaDBβ”‚ β”‚ LLM β”‚ β”‚ Supabase β”‚
101
+ β”‚ (RAG) β”‚ β”‚ β”‚ β”‚ (Cloud DB)β”‚
102
+ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”˜ β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
103
+ ```
104
+
105
+ ## πŸ› οΈ Tech Stack
106
+
107
+ - **Frontend**: Streamlit + Material Design
108
+ - **Backend**: FastAPI + LangChain
109
+ - **Vector DB**: ChromaDB
110
+ - **LLM**: Ollama (local) / HuggingFace (cloud)
111
+ - **Database**: Supabase PostgreSQL (cloud) / JSON files (local)
112
+
113
+ ## πŸŒ₯️ Cloud vs Local
114
+
115
+ | Feature | Local | Cloud (HF Spaces) |
116
+ |---------|-------|-------------------|
117
+ | **Privacy** | βœ… Fully offline | ⚠️ Data in cloud |
118
+ | **Cost** | βœ… Free | βœ… Free |
119
+ | **Speed** | ⚠️ Depends on hardware | βœ… Fast |
120
+ | **Persistence** | βœ… Local files | βœ… Supabase DB |
121
+ | **Setup** | ⚠️ Requires Ollama | βœ… Just click |
122
+ | **Multi-user** | ❌ Single user | βœ… Multi-user |
123
+
124
+ ## πŸ“ Configuration
125
+
126
+ ### Environment Variables
127
+
128
+ For cloud deployment, set these in Hugging Face Spaces Settings:
129
+
130
+ ```bash
131
+ # Required for cloud mode
132
+ HUGGINGFACE_API_TOKEN=your_hf_token
133
+ SUPABASE_URL=your_supabase_url
134
+ SUPABASE_KEY=your_supabase_key
135
+ USE_SUPABASE=true
136
+ LLM_PROVIDER=huggingface
137
+ ```
138
+
139
+ For local deployment, no configuration needed!
140
+
141
+ ## πŸ”’ Privacy
142
+
143
+ - **Local Mode**: All data stays on your machine. No internet required.
144
+ - **Cloud Mode**: Study plans stored in Supabase. PDFs processed in-memory, not stored.
145
+
146
+ ## πŸ“„ License
147
+
148
+ MIT License - See [LICENSE](LICENSE) for details.
149
+
150
+ ## 🀝 Contributing
151
+
152
+ Contributions welcome! Please feel free to submit a Pull Request.
153
+
154
+ ## πŸ“§ Contact
155
+
156
+ For questions or feedback, open an issue on [GitHub](https://github.com/thesivarohith/hack/issues).
157
+
158
+ ---
159
+
160
+ **Built with ❀️ for better learning experiences**
161
+
162
+ πŸ”— **Links:**
163
+ - [Live Demo](https://huggingface.co/spaces/SivaRohith69/focusflow)
164
+ - [GitHub Repository](https://github.com/thesivarohith/hack)
165
+ - [Documentation](https://github.com/thesivarohith/hack/blob/main/DEPLOYMENT.md)