Skip to content

RAG-Stack Web App

The webapp lives in apps/ — a Vite + React 19 + shadcn/ui SPA, PWA-installable from a production build. Its FastAPI backend lives at rag_stack/server/.

Setup

cd apps
npm install

Usage

# 1. Start the RAG-Stack API backend with hot reload
conda activate rag-stack-refactor && uvicorn rag_stack.server.cost_model_api:app --port 8000 --reload --reload-dir rag_stack

# 2. Start the webapp (in a separate terminal)
conda activate rag-stack-refactor && cd apps && npm run dev -- --port 2333

# Optional: start the webapp with the dev service worker enabled for PWA install testing
conda activate rag-stack-refactor && cd apps && npm run dev:pwa -- --port 2333

Open http://localhost:2333 in your browser.

Configuration

Settings are stored in .rag_stack_settings.json at the project root by default. To use a custom path, set the environment variable before starting the server:

export RAG_STACK_SETTINGS_PATH=/path/to/my_settings.json

API keys and secrets are stored in a .env file (default: project root). The .env file path can be configured in the Settings UI under Keys & Secrets. Both .rag_stack_settings.json and .env are in .gitignore.

See the user guide's System settings section for the full settings-key reference and the cache-directory layout.