-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
1 changed file
with
93 additions
and
1 deletion.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,93 @@ | ||
# NST-AI | ||
# π NST AI - Your Personal Study Companion | ||
|
||
Welcome to **NST AI** β your AI-powered study buddy designed specifically for Newton School of Technologies! With NST AI, you can ask questions, summarize lectures, and interact with your notes offline using state-of-the-art language models like **Mistral 7b LLM** and **Nomic Embed Text**. Follow the steps below to set up NST AI on macOS. | ||
|
||
--- | ||
|
||
## π Features | ||
- π¬ **Ask AI Anything**: Get instant answers to questions about your lectures and notes. | ||
- π **Summarize Notes**: Automatically summarize classes, lectures, and key study topics. | ||
- π **Offline Access**: Access powerful LLM capabilities without an internet connection. | ||
|
||
--- | ||
|
||
## π Prerequisites | ||
Before you start, make sure the following are installed on your Mac: | ||
- π **Python 3.11** [Download here](https://www.python.org/downloads/) | ||
- πΊ **Homebrew** [Install Homebrew](https://brew.sh/) | ||
|
||
--- | ||
|
||
## βοΈ Installation Guide | ||
|
||
Follow these steps to install and set up NST AI: | ||
|
||
### Step 1: π Update Pip | ||
First, update `pip` to the latest version: | ||
|
||
``` | ||
pip install pip --upgrade | ||
``` | ||
|
||
### Step 2: π¦ Install Poetry | ||
|
||
Install Poetry to manage project dependencies: | ||
``` | ||
pip install poetry | ||
poetry --version # Verify installation | ||
``` | ||
### Step 3: π Install Ollama.ai | ||
|
||
1. Visit Ollamaβs official website and download the macOS version. | ||
2. After downloading, unzip the file, open it, and follow the instructions to move Ollama to your Applications folder. | ||
3. Important: Quit Ollama from the taskbar by selecting Quit Ollama. | ||
|
||
### Step 4: π₯ Download LLM Models | ||
|
||
NST AI uses Mistral 7b LLM and Nomic Embed Text models for offline functionality. Pull these models with: | ||
``` | ||
ollama pull mistral | ||
ollama pull nomic-embed-text | ||
``` | ||
### Step 5: π₯οΈ Start Ollama Service | ||
|
||
Start the Ollama service: | ||
``` | ||
ollama serve | ||
``` | ||
|
||
β οΈ Note: If you see Error: listen tcp 127.0.0.1:11434: bind: address already in use, Ollama is already running. Close it from the taskbar and try again. | ||
|
||
Step 6: π οΈ Install Ollama LLM with Poetry | ||
|
||
In a new terminal window, install NST AIβs dependencies: | ||
|
||
``` | ||
poetry install --extras "ui llms-ollama embeddings-ollama vector-stores-qdrant" | ||
``` | ||
|
||
### Step 7: π Run NST AI | ||
|
||
To start NST AI, use: | ||
|
||
``` | ||
PGPT_PROFILES=ollama make run | ||
``` | ||
|
||
Access NST AI in your browser at http://localhost:8001. | ||
|
||
π Troubleshooting | ||
|
||
β’ π’ Slow CPU or GPU Issues: | ||
If NST AI is slow or if you experience GPU issues, modify the timeout setting: | ||
Open ```components/llm/llm_component.py``` and add: | ||
|
||
```request_timeout=300``` | ||
|
||
|
||
|
||
π₯ Video Tutorial | ||
|
||
π Final Note | ||
|
||
NST AI is here to enhance student learning at NST, making studying easier and more efficient. If you have any questions or need assistance, feel free to reach out. Enjoy exploring the world of personalized AI learning! π |