%% Offline Developer AI Stack โ€“ Full Local First Ecosystem (No Cloud Required) graph TD %% ==== Root ==== Root[๐Ÿ–ฅ๏ธ Offline Developer AI Stack]:::entry %% ==== LLM Inference Engines ==== Root --> Inference[๐Ÿง  LLM Inference Engines]:::section Inference --> LMStudio[LM Studio]:::tool Inference --> Ollama[Ollama]:::tool Inference --> GGML[GGML / llama.cpp]:::tool Inference --> vLLM[vLLM (for local GPU)]:::tool %% ==== Local Embedding Models ==== Root --> Embedding[๐Ÿ”ก Embedding Engines]:::section Embedding --> BGE[BGE-M3 (local)]:::model Embedding --> MiniLM[MiniLM (int8)]:::model Embedding --> Gemma[Gemma 2B / 3n .task]:::model Embedding --> TFLite[TFLite converted models]:::model %% ==== Auto Indexing Pipeline ==== Root --> Indexing[๐Ÿ“š Auto Repo Indexing]:::section Indexing --> Watcher[๐Ÿ•ต๏ธ File Watcher (inotify/fswatch)]:::tool Indexing --> EmbedPipe[โš™๏ธ Embed + Store Pipeline]:::tool EmbedPipe --> LanceDB[LanceDB]:::vectordb EmbedPipe --> FAISS[FAISS (CPU)]:::vectordb %% ==== RAG Layer ==== Root --> RAG[RAG Context Assembly]:::section RAG --> Chunking[๐Ÿ“„ Smart Chunker (Markdown-aware)]:::tool RAG --> Retriever[๐Ÿ” Retriever: Top-k + rerank]:::tool RAG --> ContextBuilder[๐Ÿ“Ž Prompt Context Builder]:::tool RAG --> LocalChat[๐Ÿ—จ๏ธ Local Chat App]:::output %% ==== Frontend Interfaces ==== Root --> UI[๐Ÿง‘โ€๐Ÿ’ป Dev Interfaces]:::section UI --> TUI[Terminal UI (eg. TerminalGPT)]:::tool UI --> WebUI[Web GUI (eg. LM Studio, Chatbot-UI)]:::tool UI --> VSCode[VSCode Plugin/CLI]:::tool %% ==== Use Cases ==== Root --> UseCases[๐Ÿš€ Use Cases]:::section UseCases --> PRSummary[๐Ÿ“ Auto PR Summary Generator]:::usecase UseCases --> DocSearch[๐Ÿ” Project Documentation QA]:::usecase UseCases --> Refactor[๐Ÿ”ง On-Device Code Refactoring]:::usecase UseCases --> QueryAnswer[๐Ÿ’ก Prompt-aware Local Assistant]:::usecase UseCases --> DiffBot[๐Ÿงพ Git Commit Diff Summarizer]:::usecase %% === File Structure Conventions === Root --> FS[๐Ÿ—‚๏ธ File & Metadata Structure]:::section FS --> repos[๐Ÿ“ /repos/project-name]:::meta FS --> indexdb[๐Ÿ“ /embeddings/lancedb]:::meta FS --> config[๐Ÿ“„ config.yaml (model paths, chunk size, repo names)]:::meta FS --> logs[๐Ÿ“„ logs/*.jsonl (chat + indexing audit)]:::meta %% === Hardware Profile === Root --> Devices[๐Ÿ’ป Target Hardware]:::section Devices --> MacM4[MacBook Pro M4 Max]:::device Devices --> RyzenMiniPC[AMD Mini PC (32+ GB RAM)]:::device Devices --> Jetson[Jetson Xavier NX (Quantized)]:::device %% Styling classDef entry fill:#fff,stroke:#000,stroke-width:2px; classDef section fill:#eef,stroke:#88a,stroke-width:2px; classDef tool fill:#ccf,stroke:#55a,stroke-width:1px; classDef model fill:#cff,stroke:#399,stroke-width:1px; classDef vectordb fill:#fdf,stroke:#a3a,stroke-width:1px; classDef output fill:#efe,stroke:#3a3,stroke-width:1px; classDef usecase fill:#fcf,stroke:#a3a,stroke-width:1px; classDef meta fill:#ffe,stroke:#cc0,stroke-width:1px; classDef device fill:#ddf,stroke:#55f,stroke-width:1px;