AI-Powered Journaling Platform
Life AI
An AI-powered journaling platform with PostgreSQL query optimization and a RAG pipeline for personalized insights.
Problem
The platform needed fast data retrieval across multiple schemas and AI-generated personalized insights without high latency.
Solution
Built a PostgreSQL backend with GIN indexes across 5+ schemas to speed up array and tag-based queries. Built a RAG pipeline that embeds journal entries and retrieves relevant context by cosine similarity to auto-generate daily insights.
System Architecture & Data Pipeline
RAG Pipeline: Audio transcribed via Groq Whisper Large V3, embedded into 384d vector space with all-MiniLM-L6-v2, and stored in PostgreSQL pgvector alongside GIN-indexed life aspects for fast semantic search and Llama 3.3 companion coaching.
Highlights
- Reduced array/tag-query latency from 800ms to 110ms (86% improvement) through GIN indexing across 5+ schemas.
- Built a RAG pipeline that embeds journal entries and retrieves relevant context by cosine similarity to auto-generate personalized daily insights.
- Vector similarity search (pgvector/ivfflat) is planned for the retrieval layer but not yet shipped. Current retrieval runs on the GIN-indexed relational schema.
Impact
Reduced array/tag-query latency from 800ms to 110ms through GIN indexing across 5+ schemas. Built a RAG pipeline using vector embeddings to auto-generate personalized daily insights from journal entries.