Status: [UNTESTED] Endpoints found: http://localhost:8000/api/chat http://localhost:8000/api/documents/upload Source: https://github.com/Wakiloo7/llm-rag-mobile-pwa-fastapi-ionic # Full LLM RAG Mobile/PWA Application Production-style starter for an Ionic React + Capacitor mobile/PWA frontend and Python FastAPI backend with document upload, RAG, GPT/Claude integration, vector database support, and Docker. ## Stack - Frontend: Ionic Framework, React, TypeScript, Capacitor, Vite, PWA service worker - Backend: Python, FastAPI, OpenAI/Anthropic, document parsing, RAG endpoints - Vector DB: Weaviate by default via Docker; Pinecone optional through env config - Deployment: Docker Compose locally; PWA build via Vite/Ionic; mobile via Capacitor iOS/Android ## Folder structure ```text llm-rag-pwa/ backend/ app/ api/routes.py services/document_processor.py services/embeddings.py services/llm.py services/vector_store.py config.py main.py schemas.py Dockerfile requirements.txt .env.example frontend/ src/ components/SourceList.tsx pages/Home.tsx services/api.ts theme/app.css theme/variables.css App.tsx main.tsx public/icons/ capacitor.config.ts Dockerfile index.html nginx.conf package.json tsconfig.json vite.config.ts scripts/create-structure.ps1 docker-compose.yml ``` ## From zero in VS Code PowerShell ```powershell # 1) Create/open workspace mkdir llm-rag-pwa cd llm-rag-pwa code . # 2) Or use the included ZIP and extract it, then open it code . # 3) Backend env Copy-Item backend\.env.example backend\.env notepad backend\.env ``` Set at least: ```env OPENAI_API_KEY=your_openai_key LLM_PROVIDER=openai VECTOR_DB=weaviate ``` For Claude answers instead of OpenAI chat: ```env LLM_PROVIDER=anthropic ANTHROPIC_API_KEY=your_anthropic_key ``` ## Run with Docker ```powershell docker compose up --build ``` Open: - Frontend PWA: http://localhost:8100 - Backend API docs: http://localhost:8000/docs - Weaviate: http://localhost:8080 ## Run backend locally without Docker ```powershell cd backend python