I Built a Private, Local-First AI Assistant with Flask

Published: (April 24, 2026 at 07:23 AM EDT)
2 min read
Source: Dev.to

Source: Dev.to

Goal

I wanted an AI assistant that doesn’t save my logs to the cloud and utilizes my own hardware. Though it’s quite slow at the moment, I believe that with further optimization and advances in local silicon, edge AI will soon become the next big thing.

Technology

  • Framework: Flask
  • Model: TinyLlama 1.1B
  • Security: python‑dotenv for environment variables
  • Assistance: Claude and GitHub Copilot were used for repetitive code and advanced Python concepts.

Repository

Web-Based-Edge-AI- on GitHub

Y Assistant

A privacy‑focused local AI chatbot powered by TinyLlama. Y is a lightweight web‑based AI assistant that runs entirely on your machine. It includes a custom architecture demo, a secure login system, and per‑session memory, ensuring that conversations stay private and contextual. Created by S (pseudonym).

Features

  • No data leaves your machine – runs locally on TinyLlama 1.1B.
  • Contextual Memory: Remembers the last 10 messages for natural conversation flow.
  • Secure Access: Protected by a customizable password system.
  • Privacy‑First: No permanent logs are stored; session data can be cleared on request.
  • Architecture Demo: Includes a raw GPT‑2 initialization script to illustrate LLM structure.

Installation

# Clone the repository
git clone https://github.com/sounak1410/Web-Based-Edge-AI-.git

# Enter the directory
cd Web-Based-Edge-AI-

# Install Python dependencies
pip install -r requirements.txt

# Run the application
python Edge.py

Running the Assistant

  1. Open your browser and navigate to http://127.0.0.1:5000.
  2. Log in using the password you set in the environment variables.
  3. Start chatting—conversations are kept in‑memory only for the current session.
0 views
Back to Blog

Related posts

Read more »