Skip to content

carakawedhatama/outline-llm

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

3 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Outline-LLM

Outline LLM Banner

AI-powered document assistant for Outline wiki

Query, summarize, and reason over your internal documentation using RAG.

MIT License Python React

Features β€’ Quick Start β€’ Configuration β€’ Architecture


Features

πŸ”„ Auto-Sync with Outline β€” Periodically fetches documents from your Outline wiki
πŸ” Semantic Search β€” Find relevant content using vector similarity search
πŸ’¬ Chat Interface β€” Natural language queries with AI-powered responses
πŸ“ Citations β€” Every answer includes source document references
πŸ”’ Security β€” PII detection and prompt injection defense
⚑ Fast β€” Lightweight stack with ChromaDB and LiteLLM

Quick Start

Prerequisites

  • Python 3.11+
  • Node.js 20+
  • uv (Python package manager)
  • An Outline account with API access
  • An OpenAI API key (or compatible LLM provider)

1. Clone and Setup

git clone https://github.com/carakawedhatama/outline-llm.git
cd outline-llm

# Copy environment template
cp .env.example .env

2. Configure Environment

Edit .env with your credentials:

# Required: Outline API (get token from Settings β†’ API)
OUTLINE_API_URL=https://app.getoutline.com
OUTLINE_API_TOKEN=your_outline_api_token

# Required: OpenAI
OPENAI_API_KEY=your_openai_api_key

# Optional: For production deployments with custom domain
CORS_ORIGINS=https://your-domain.com
VITE_API_URL=https://api.your-domain.com

3. Install Dependencies

make install

4. Start Development Servers

make dev

This starts:

5. Trigger Initial Sync

Open the web app and click "Sync Now" in the sidebar, or:

curl -X POST http://127.0.0.1:8000/api/sync/trigger

Configuration

Variable Description Default
OUTLINE_API_URL Outline instance URL https://app.getoutline.com
OUTLINE_API_TOKEN API token from Outline settings β€”
SYNC_INTERVAL_MINUTES Auto-sync frequency 15
LLM_MODEL LLM model to use gpt-4o-mini
EMBEDDING_MODEL Embedding model text-embedding-3-small
CORS_ORIGINS Allowed origins (comma-separated or *) *
VITE_API_URL API URL for frontend (cross-origin) (empty = same-origin)

See .env.example for all options.

Architecture

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                   React Frontend                         β”‚
β”‚              Chat UI + Sync Dashboard                    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                          β”‚ API Calls
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                   FastAPI Backend                        β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚
β”‚  β”‚ Sync Serviceβ”‚  β”‚ RAG Service  β”‚  β”‚ Security Layer  β”‚  |
β”‚  β”‚ (APScheduler)β”‚  β”‚ (Retrieval)  β”‚  β”‚ (PII/Injection)β”‚  |
β”‚  β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  |
β”‚         β”‚                β”‚                               β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”€β”                       β”‚
β”‚  β”‚ Outline API β”‚  β”‚    LiteLLM   β”‚                       β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜                       β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                          β”‚
            β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”΄β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
            β”‚                           β”‚
     β”Œβ”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”             β”Œβ”€β”€β”€β”€β”€β”€β–Όβ”€β”€β”€β”€β”€β”€β”
     β”‚  ChromaDB   β”‚             β”‚   SQLite    β”‚
     β”‚ (Vectors)   β”‚             β”‚ (Sync State)β”‚
     β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜             β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Project Structure

outline-llm/
β”œβ”€β”€ apps/
β”‚   β”œβ”€β”€ api/                 # FastAPI backend
β”‚   β”‚   β”œβ”€β”€ src/
β”‚   β”‚   β”‚   β”œβ”€β”€ models/      # Pydantic schemas
β”‚   β”‚   β”‚   β”œβ”€β”€ routes/      # API endpoints
β”‚   β”‚   β”‚   β”œβ”€β”€ services/    # Business logic
β”‚   β”‚   β”‚   └── main.py
β”‚   β”‚   β”œβ”€β”€ Dockerfile
β”‚   β”‚   └── pyproject.toml
β”‚   └── web/                 # React frontend
β”‚       β”œβ”€β”€ src/
β”‚       β”‚   β”œβ”€β”€ components/  # UI components
β”‚       β”‚   └── App.tsx
β”‚       β”œβ”€β”€ Dockerfile
β”‚       └── package.json
β”œβ”€β”€ docker-compose.yml
β”œβ”€β”€ Makefile
β”œβ”€β”€ .env.example             # ← Root env file (used by both apps)
└── README.md

Commands

make dev        # Start dev servers
make install    # Install dependencies
make build      # Build Docker images
make up         # Start Docker containers
make down       # Stop Docker containers
make logs       # View container logs
make test       # Run all tests

API Endpoints

Method Endpoint Description
POST /api/chat Send a RAG query
GET /api/sync/status Get sync status
POST /api/sync/trigger Trigger manual sync
GET /api/sync/documents List indexed documents
GET /health Health check

Docker Deployment

# Build and start
docker compose up -d

# View logs
docker compose logs -f

# Stop
docker compose down

Custom Domain Deployment

For deploying with a custom domain, set these in .env:

CORS_ORIGINS=https://docs.example.com
VITE_API_URL=https://api.example.com

License

MIT License. See LICENSE for details.


Made with ❀️ for better documentation search

About

An LLM-powered system that understands Outline documents, and helps teams query, summarize, and reason over them securely.

Topics

Resources

License

Stars

1 star

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors