Skip to content

VinayHanni/PIPO

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PIPO — Persistent Personal AI Assistant

A cloud-hosted, memory-powered personal AI assistant that remembers user preferences, facts, and interactions across sessions — delivering human-like continuity. Built with React, FastAPI, Supabase, Redis, ChromaDB, Ollama (Mistral 7B), and DistilBERT.

Overview

PIPO is a long-term memory AI assistant. Unlike normal chatbots, PIPO:

Remembers important facts about each user

Builds personal long-term memory

Retrieves past context before responding

Improves over time with memory consolidation

Uses a local LLM (Ollama Mistral 7B) for inference

The project follows a layered architecture including cloud components, local inference, and vector-based memory retrieval.

System Architecture Component Technology Purpose Frontend React User chat UI, authentication, routing Backend FastAPI Chat routing, memory logic, model orchestration Authentication Supabase Auth User login/signup, JWT tokens Database Supabase PostgreSQL User metadata + memory references Vector DB ChromaDB Long-term memory embeddings (per user) Session Cache Redis Short-term session memory buffer LLM Engine Ollama + Mistral 7B Local text generation model Memory Classifier DistilBERT Decides what to remember

Frontend + Backend run in the cloud. LLM runs locally on the developer’s laptop for privacy + compute control.

Memory Lifecycle

PIPO uses four stages of memory management:

  1. Formation

Stores each user message in short-term memory (Redis).

  1. Consolidation

DistilBERT decides whether the information is important. If yes → convert to embedding → store in ChromaDB.

  1. Recall

Before generating a response, FastAPI retrieves top-N relevant memories from Chroma.

4️. Forgetting

Background job removes or decays old, low-importance memories.

Deployment Model Component Deployment Frontend Google Cloud Hosting / Vercel Backend Google Cloud Run / Hugging Face Spaces Redis Local Docker (Cloud later) ChromaDB Local Docker or hosted LLM (Ollama) Local laptop API DistilBERT Classifier Cloud Run or Hugging Face Spaces

Development Phases PHASE 1 — Authentication & Routing (CURRENT)

Supabase login + signup

React routing

Backend JWT-protected routes

User profile creation

ChromaDB collection allocation per user

Goal: User can securely sign up, log in, and open chat.

PHASE 2 — Chat System + Memory Routing

React chat UI → FastAPI /chat endpoint

Route user messages → local Mistral 7B via Ollama

Redis buffer for session messages

ChromaDB integration for memory storage and retrieval

Memory passed to LLM before response

Goal: Fully working chat with memory recall.

PHASE 3 — Memory Intelligence (DistilBERT)

Replace heuristics with classifier

Store importance/strength/access_count

Memory decay system

PHASE 4 — Personality & Persistence

Store PIPO personality traits

Daily memory summarization

Long-term consolidation

PHASE 5 — Deployment & Scaling

Dockerize app

Host backend + frontend

Secure Redis, Supabase, Chroma connections

Tunnel/local network access for LLM

📁 Project Structure (Recommended) /pipo-frontend /src components/ pages/ context/ hooks/ utils/ package.json

/pipo-backend /app routers/ services/ memory/ models/ schemas/ main.py requirements.txt

/docker redis/ chromadb/

README.md

Tech Stack

React + Tailwind — UI

FastAPI — Backend

Supabase — Auth + DB

Redis — Short-term memory

ChromaDB — Vector memory

Ollama + Mistral 7B — LLM

DistilBERT — Memory classifier

Google Cloud Run / Vercel — Deployment

Running Locally (Dev Mode) Start Redis docker run -p 6379:6379 redis

Start ChromaDB docker run -p 8000:8000 chromadb/chroma

Start Backend uvicorn app.main:app --reload

Start Frontend npm install npm start

Start Mistral 7B (Ollama) ollama run mistral

Current Status

🛠 Building Phase 1 — Supabase Authentication + React Routing Next: Connect chat UI → FastAPI → Redis + Chroma.

🤝 Contributing

This project is currently a personal development project, but structured for future open-source contributions.

About

AI-powered personal memory assistant that remembers context across conversations using DistilBERT embeddings, ChromaDB vector storage, and a rolling summary system. Built with FastAPI, Redis, and Supabase.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors