From 2ee2bfa01db32bc26826959b82475d2cbf4c2990 Mon Sep 17 00:00:00 2001 From: sagar-develop Date: Tue, 9 Jun 2026 01:50:18 +0530 Subject: [PATCH] docs(readme): refresh "Architecture at a glance" to current Mermaid MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Replace the stale ASCII diagram (EngineRegistry / MediaPipe Text Embedder) with a Mermaid diagram matching the current stack: RAM-tier selection → LiteRT-LM LLM + EmbeddingGemma/USE-Lite (ONNX) embedder + RAG retrieval (vector + BM25 + rerank) + ModelManager. Renders inline on GitHub. Co-Authored-By: Claude Opus 4.8 --- README.md | 34 ++++++++++++++++------------------ 1 file changed, 16 insertions(+), 18 deletions(-) diff --git a/README.md b/README.md index 6a9a147..d63ef71 100644 --- a/README.md +++ b/README.md @@ -348,26 +348,24 @@ The download URLs + per-model metadata live in ## Architecture at a glance -``` - ┌─────────────────────────────────────────┐ - │ Your app (Compose / SwiftUI / …) │ - └─────────────────────────────────────────┘ - │ - ┌─────────────────▼─────────────────────────┐ - │ EngineRegistry ← HardwareProvider │ - │ (picks LiteRT vs MediaPipe vs fallback │ - │ based on device RAM tier) │ - └─────────────────┬─────────────────────────┘ - │ - ┌──────────────────────┼────────────────────────┐ - ▼ ▼ ▼ - LocalAiEngine EmbeddingEngine ModelManager - (LiteRT-LM / (MediaPipe Tasks (Ktor download - Gemma 4) Text Embedder) + SHA-256 + - atomic move) +```mermaid +flowchart TB + app["Your app (Compose / SwiftUI / …)"] + sel["RAM-tier selection · HardwareProvider
picks LLM + embedder + reranker for the device"] + lae["LocalAiEngine
LiteRT-LM / Gemma 4"] + ee["EmbeddingEngine
EmbeddingGemma / USE-Lite (ONNX, telemetry-free)"] + ret["DocumentRetriever
vector + BM25 + rerank (RAG)"] + mm["ModelManager
resumable download + SHA-256"] + app --> sel + sel --> lae + sel --> ee --> ret + sel --> mm + + classDef n fill:#f5f3ef,stroke:#7FA980,color:#1C1B1A; + class app,sel,lae,ee,ret,mm n; ``` -See [`ARCHITECTURE.md`](ARCHITECTURE.md) for the full design rationale, including how the RAM-tier policy works and why the OEM RAM-expansion detection is necessary. +See [`ARCHITECTURE.md`](ARCHITECTURE.md) for the full design — Mermaid diagrams of the engine/product split and the RAG pipeline, the device-tier policy, and why OEM RAM-expansion detection is necessary. ## Enterprise support, custom implementations & architectural advising