Android RAG Local

Implement local Retrieval-Augmented Generation using Room and Vector embeddings.

prasad-vennam Updated

File contents

Android Local RAG & Vector Databases 🔎

Retrieval-Augmented Generation (RAG) on Edge devices provides privacy-first, low-latency contextual intelligence. Instead of using cloud Pinecone/Weaviate, this skill enforces local vector embeddings via Room or SQLite.

⚡ When to Use

  • When tasked with "RAG", "semantic search", or "vector embeddings".
  • Building highly private AI features.

🏗️ Core Rules / Pillars

1. Vector Search in Room

  • Pattern: Standard Room does not have native vector similarity out of the box in stable. Use L2 distance extensions or sqlite-vss.
  • Implementation: Avoid pulling unmaintained third-party vector DBs. Use SQLite virtual tables with FTS or simple cosine similarity functions if embeddings are small.

🚧 Critical Anti-Hallucination Guards

  • Trap: Do NOT hallucinate that Room natively supports SELECT * FROM tbl ORDER BY VECTOR_DISTANCE() securely out of the box without specific extensions.

prasad-vennam/Awesome-Android-AI-Agent-Skills/tree/main/skills/android-rag-local commit 12fe3fd39d

Frequently asked questions

npx skillmds@latest add prasad-vennam/android-rag-local