Installation

Set up LegalEase locally with Firebase emulators.

This guide walks through setting up LegalEase for local development. The process takes about 10 minutes.

Prerequisites

1. Clone the Repository

git clone https://github.com/AlliecatOwO/legalease-ai.git
cd legalease-ai

2. Install Dependencies

mise install      # Installs Node.js, pnpm as defined in .mise.toml
mise run install  # Installs npm/pnpm packages for all workspaces

3. Configure Environment

cp frontend/.env.example frontend/.env

Edit frontend/.env and add your Gemini API key:

# Required for AI features
GOOGLE_GENAI_API_KEY=your-gemini-api-key

# Use Firebase emulators (recommended for development)
NUXT_PUBLIC_USE_EMULATORS=true

# Transcription provider: 'gemini' (default) or 'chirp'
TRANSCRIPTION_PROVIDER=gemini

That's all you need for local development. The Firebase emulators handle Auth, Firestore, Storage, and Functions.

4. Start the Full Stack

mise run dev:local

This single command:

  1. Starts Docker services (Qdrant for vector search, Docling for document extraction)
  2. Builds and starts Firebase Functions
  3. Starts Firestore, Auth, and Storage emulators
  4. Starts the Nuxt frontend with hot reload

5. Access the Application

ServiceURL
Frontend Dashboardhttp://localhost:3000
Firebase Emulator UIhttp://localhost:4000
Qdrant Dashboardhttp://localhost:6333/dashboard
Docling UIhttp://localhost:5050/ui

6. Create a Test User

The Firebase Auth emulator starts empty. Create a user through the UI:

  1. Visit http://localhost:3000
  2. Click "Sign in with Google" or "Sign up with email"
  3. The emulator will create the user automatically

Or use the Firebase Emulator UI (http://localhost:4000) to manually create users.

Individual Commands

If you need more control, run services separately:

# Start only Docker services (Qdrant, Docling)
mise run services:up

# Start only Firebase emulators
firebase emulators:start --only functions,firestore,auth,storage

# Start only frontend (assumes emulators running)
cd frontend && NUXT_PUBLIC_USE_EMULATORS=true pnpm dev

# Stop Docker services
mise run services:down

Verify the Installation

  1. Create a case - Navigate to Cases and create a new case
  2. Upload a document - Add a PDF to the case and watch it process
  3. Upload audio - Add an audio file and receive a transcript with speaker diarization
  4. Search - Use the search feature to find content across your documents

GPU Acceleration (Optional)

If you have an NVIDIA GPU with nvidia-container-toolkit, Docling can process documents faster:

# Edit docker-compose.yml to enable GPU for docling service
# Then restart services
mise run services:down
mise run services:up

Troubleshooting

Emulators won't start

  • Check if ports 4000, 5001, 8080, 9099, 9199 are available
  • Try firebase emulators:start --only functions,firestore,auth,storage directly to see errors

Functions timeout on first run

  • Cold starts can take 10-15 seconds; subsequent calls are faster
  • Check the Firebase Emulator UI for function logs

Transcription fails

  • Verify GOOGLE_GENAI_API_KEY is set correctly in frontend/.env
  • Check function logs in the Emulator UI for detailed errors

Docker services won't start

  • Ensure Docker daemon is running
  • Check for port conflicts with docker compose logs

Next Steps

Built with Nuxt UI • LegalEase AI © 2025