Stop grepping.
Start knowing.
repi ingests logs into PostgreSQL with pgvector, clusters them by signature, and runs an autonomous ReAct loop to surface root causes.
Everything you need to debug faster
Built on PostgreSQL and your existing LLM provider. No new infrastructure, no vendor lock-in.
Hybrid Search
BM25 full-text + pgvector HNSW dense retrieval fused with Reciprocal Rank Fusion for best-of-both recall.
Autonomous ReAct Loop
LLM thinks, calls tools, observes results — up to 10 iterations per investigation to surface the actual root cause.
Background File Watcher
Register a directory via API. The worker ingests new log bytes automatically, tracking byte offsets per file.
Multi-LLM
OpenAI, Anthropic, Mistral, Gemini, Ollama — swap your provider with a single environment variable.
Progressive Time Windows
Investigations start narrow and automatically expand their search window when results are sparse.
Full Audit Trail
Every thought, tool call, and observation is persisted to PostgreSQL. Replay any investigation step by step.
Up and running in 5m
Prerequisites: Docker, Python 3.11+, uv, Node.js (for the web UI).
Install dependencies
Resolves the lockfile into a local virtualenv via uv.
uv sync
Bootstrap
Starts Postgres + Redis in Docker, prompts for an LLM provider and API key, writes .env, applies the schema. Idempotent — safe to re-run.
repi init --with-docker
Start the API
Runs on http://localhost:8000. Swagger UI at /docs.
repi serve
Start the UI
Runs on http://localhost:3000 (configurable via UI_PORT). Open this in a second terminal.
repi ui
Always-on log ingestion
The worker watches directories for new log bytes and ingests them automatically. It tracks a byte offset per file so it only processes what's new — restarts are safe.
Register a watcher
curl -X POST http://localhost:8000/watchers \
-H "Content-Type: application/json" \
-d '{"service_name": "auth-svc", "watch_path": "/var/log/auth"}'Start the worker
python -m repi.worker
Configuration
Set via environment variables or a .env file at the project root.
| Variable | Default | Description |
|---|---|---|
REPI_ENV | production | production | development. Production is quiet (uvicorn log_level=warning, no reload). Development is verbose. |
DATABASE_URL | postgresql+asyncpg://lograg_user:password_here@localhost:5432/lograg | PostgreSQL asyncpg connection URL |
LLM_PROVIDER | openai | openai | anthropic | mistral | gemini | ollama |
LLM_MODEL | provider default | Override the default model for the selected provider |
OPENAI_API_KEY | — | Provider API key (also ANTHROPIC_API_KEY, MISTRAL_API_KEY, GEMINI_API_KEY) |
REDIS_URL | redis://localhost:6379 | Redis connection URL for response caching |
ENABLE_REDIS_CACHE | true | Set false to disable Redis caching |
TIME_WINDOW_INITIAL_MINUTES | 10 | Starting time window for investigations (minutes) |
TIME_WINDOW_EXPANSIONS | 60,360,1440 | Progressive window expansion in minutes (1h → 6h → 24h) |
UI_PORT | 3000 | Port the web UI binds to (read by `repi ui`) |
WATCHER_CONFIG_REFRESH_SECS | 30 | How often the worker polls DB for config changes |
OLLAMA_BASE_URL | http://localhost:11434 | Ollama API endpoint |
Investigate your first incident in under 5 minutes.
Self-hosted. No data leaves your infrastructure.