A decoupled, full-stack local generative AI application featuring a highly interactive chat interface powered by local inference.
This project serves as an architectural implementation blueprint, mirroring enterprise-grade AI deployment patterns while remaining lightweight and fully local.
The application implements a decoupled architectural pattern, separating presentation, routing, inference, and compute layers.
+---------------------------+
| Presentation Layer |
| (Streamlit Frontend) |
+---------------------------+
|
| Asynchronous HTTP Requests
v
+---------------------------+
| REST API Gateway |
| (OpenAI-Compatible Spec) |
+---------------------------+
|
| Internal Model Routing
v
+---------------------------+
| Inference Serving Engine |
| (Ollama Orchestration) |
+---------------------------+
|
| Hardware Acceleration
v
+---------------------------+
| Compute Environment |
| (Apple Silicon M4 Core) |
+---------------------------+
-
Presentation Layer (Streamlit)
A reactive Python interface that manages chat interactions and real-time token streaming. -
REST API Gateway
Standardized routing utilizing the OpenAI-compatible API specification. -
Inference Serving Engine (Ollama)
A lightweight background service managing local model execution and orchestration. -
Compute Layer (Apple Silicon)
Optimized for unified memory architecture and Metal acceleration.
- Frontend UI: Streamlit (Reactive Python-based UI with active token streaming)
- Inference Engine: Ollama CLI (Local model hosting and request orchestration)
- Model Architecture: Qwen 3.5 9B
Ensure you have Ollama installed on your system.
Pull and initialize the model:
ollama run qwen3.5:9bClone the repository:
git clone https://github.com/nerdsuryansh/QwenPulse-AI.gitNavigate to the project directory:
cd QwenPulse-AICreate and activate a virtual environment:
python3 -m venv venv
source venv/bin/activateInstall required dependencies:
pip install -r requirements.txtStart the Streamlit application:
streamlit run src/app.pyOnce launched, open:
http://localhost:8501
in your browser to interact with the application.
QwenPulse-AI/
├── .gitignore # Prevents tracking of environments and cache
├── README.md # System documentation and deployment guide
├── requirements.txt # Project dependency configuration
└── src/
└── app.py # Streamlit application and API connection logic
This project is open-source and available under the MIT License.