Hadrian is experimental alpha software. Do not use in production.
Hadrian

Getting Started

Install and configure Hadrian Gateway in minutes

Get Hadrian Gateway running in under a minute. No complex setup required.

Quick Start

Choose your installation method, platform, and feature profile:

Method
OS
Libc
Features

Production deployment

OpenAI
Anthropic
AWS Bedrock
Google Vertex AI
Azure OpenAI
SQLite
Embedded UI
Model catalog
Setup wizard
PostgreSQL
Redis caching
SSO (OIDC / OAuth)
CEL RBAC
S3 storage
Secrets managers
OTLP & Prometheus
OpenAPI docs
Embedded docs
Doc extraction
Cost forecasting
CSV export
Response validation
JSON schema
SAML SSO
Kreuzberg OCR
ClamAV scanning
curl -L \
  https://github.com/ScriptSmith/hadrian/releases/latest/download/hadrian-x86_64-unknown-linux-musl-standard.tar.gz \
  | tar xz
./hadrian

cargo install builds the headless profile, which includes all backend features but does not embed the web UI, documentation site, or model catalog. For the full experience with embedded assets, use a pre-built binary or build from source.

The gateway starts at http://localhost:8080 with the chat UI (when embedded assets are included). No database required for basic use.

Zero-Config Mode

Running hadrian without arguments automatically:

  • Creates ~/.config/hadrian/hadrian.toml with sensible defaults
  • Uses SQLite at ~/.local/share/hadrian/hadrian.db
  • Opens browser to the chat UI on first run

This is perfect for local development and single-user setups.

Custom Configuration

Generate a starter config file:

hadrian init --output my-config.toml

Or create a minimal hadrian.toml:

[providers.openai]
type = "open_ai"
api_key = "${OPENAI_API_KEY}"

Environment variables are interpolated using ${VAR_NAME} syntax. Never commit API keys to version control.

See the Configuration guide for all options.

Docker Compose Deployments

For persistent deployments, use the configurations in the deploy/ directory:

cd deploy

# Development (SQLite - simplest)
docker compose -f docker-compose.sqlite.yml up -d

# Development with caching (SQLite + Redis)
docker compose -f docker-compose.sqlite-redis.yml up -d

# Production (PostgreSQL + Redis)
cp .env.example .env
# Edit .env with your API keys and passwords
docker compose -f docker-compose.postgres.yml up -d

Available Configurations

ConfigurationUse Case
sqlite.ymlDevelopment, single-user
sqlite-redis.ymlDevelopment with rate limiting
postgres.ymlProduction, single-node
production.ymlFull production stack (HA, monitoring, auth)

See the Docker Deployment guide for details, or Advanced Deployment for high availability setups.

Verify Installation

Once running, verify everything is working:

# Check health endpoint
curl http://localhost:8080/health

# List available models
curl http://localhost:8080/v1/models

# Access the web UI
open http://localhost:8080

# View API documentation
open http://localhost:8080/api/docs

Building from Source

Build Hadrian with all features and embedded assets:

git clone https://github.com/ScriptSmith/hadrian.git
cd hadrian

# Build frontend assets
cd ui && pnpm install && pnpm build && cd ..

# Build documentation site
cd docs && pnpm install && pnpm build && cd ..

# Fetch model catalog
./scripts/fetch-model-catalog.sh

# Build the full binary
cargo build --release
./target/release/hadrian

To build without frontend assets (headless), skip the UI/docs/catalog steps:

cargo build --release --no-default-features --features headless

See Deployment for build profiles and feature flags.

Next Steps

On this page