The repository includes sample signals with 3 entities (Alice, Bob, Kremis) and their relationships.
cargo run -p kremis -- ingest -f examples/sample_signals.json -t json
3
Start the HTTP server
cargo run -p kremis -- server
The server starts on http://localhost:8080 by default.
4
Query the graph
In a separate terminal:
# Health checkcurl http://localhost:8080/health# Look up entity 1 (Alice)curl -X POST http://localhost:8080/query \ -H "Content-Type: application/json" \ -d '{"type": "lookup", "entity_id": 1}'# Traverse from node 0, depth 3curl -X POST http://localhost:8080/query \ -H "Content-Type: application/json" \ -d '{"type": "traverse", "node_id": 0, "depth": 3}'# Get properties of node 0curl -X POST http://localhost:8080/query \ -H "Content-Type: application/json" \ -d '{"type": "properties", "node_id": 0}'
CLI commands and the HTTP server cannot run simultaneously — redb holds an exclusive lock. Stop the server before using CLI commands like ingest, status, or export.
By default, API key authentication is disabled. The server logs a warning on startup. This is expected for local development. To enable authentication, set the KREMIS_API_KEY environment variable or add api_key under [security] in kremis.toml before exposing the server on a network.
docker build -t kremis .# MCP server (default) — pipe MCP stdio JSON-RPC; suitable for any MCP clientdocker run -i --rm kremis# HTTP API only — override the entrypointdocker run -d -p 8080:8080 -v kremis-data:/data \ --entrypoint kremis kremis server -H 0.0.0.0 -D /data/kremis.db