Configuration Reference
Server Configuration
Configuration is loaded from server/config/sys.config or environment variables.
Core Settings
| Setting | Default | Description |
|---|---|---|
port | 21434 | HTTP listener port |
tls_enabled | false | Enable HTTPS |
tls_cert_file | — | TLS certificate path |
tls_key_file | — | TLS private key path |
auth_enabled | false | Require authentication |
auth_exempt_paths | ["/health",...] | Paths exempt from auth |
rate_limit_enabled | false | Enable per-key rate limiting |
cors_origin | "" | CORS Access-Control-Allow-Origin |
workspace_root | . | Workspace files root directory |
session_dir | ./sessions | Session storage directory |
Inference Settings
| Setting | Default | Description |
|---|---|---|
inference_bin | ./llama-server | llama.cpp server binary |
inference_gpu_layers | 99 | GPU layers to offload |
inference_ctx_size | 4096 | Context window size |
inference_threads | 4 | CPU threads |
Memory Settings
| Setting | Default | Description |
|---|---|---|
memory_pg_dsn | — | PostgreSQL DSN for vector storage |
memory_embed_model | — | Embedding model path |
ZMQ Settings
| Setting | Default | Description |
|---|---|---|
zmq_router_port | 5555 | ZMQ ROUTER bind port |
zmq_pub_port | 5556 | ZMQ PUB bind port |
Service Integration
| Setting | Default | Description |
|---|---|---|
mango_host | "127.0.0.1" | Mango auth service host |
mango_port | 5800 | Mango auth service port |
pg_reconnect_delay_ms | 5000 | PostgreSQL reconnect delay |
worker_heartbeat_timeout_ms | 15000 | Worker heartbeat timeout |
worker_heartbeat_check_ms | 10000 | Heartbeat check interval |
Monitoring
| Setting | Default | Description |
|---|---|---|
prometheus_enabled | true | Expose /metrics endpoint |
otel_enabled | false | OpenTelemetry tracing |
CLI Configuration
Stored at ~/.zerg/config.json:
json
{
"profiles": {
"default": {
"url": "https://api.nonsense.ws",
"token": "your-api-token"
},
"staging": {
"url": "https://staging.nonsense.ws",
"token": "staging-token"
}
}
}Luna Agent Configuration
Luna uses ~/.luna/config.json:
json
{
"provider": "anthropic",
"model": "claude-sonnet-4-20250514",
"permission_mode": "default",
"theme": "default",
"summarize_turns": false,
"web_search_provider": "duckduckgo",
"mcp_sampling_enabled": false,
"thinking_level": "medium",
"command_policy": "standard"
}Key Configuration Options
| Key | Default | Description |
|---|---|---|
summarize_turns | false | Per-turn summary generation (opt-in, uses tokens) |
web_search_provider | duckduckgo | Search: duckduckgo, searxng, brave, bing |
mcp_sampling_enabled | false | Allow MCP servers to request LLM sampling |
thinking_level | medium | minimal, low, medium, high, xhigh |
command_policy | standard | strict, standard, permissive |
sandbox_enabled | false | Bubblewrap sandbox for tool execution |
session_budget_usd | — | Maximum session cost in USD |
Keymaps
Customize TUI bindings in ~/.luna/keymaps.json. Modes: normal, input, search, menu. View all with /keymaps.
TUI Commands
| Command | Description |
|---|---|
/compact | Compact entire session |
/compact --from <id> | Compact messages before entry |
/compact --up-to <id> | Compact messages up to entry |
/keymaps | Display all key bindings |
Memory Taxonomy
4 types: fact, preference, procedure, relationship. Deduplication within each category.
Analytics
Client-side usage analytics in ~/.luna/analytics.db (SQLite). 6 tables, 90-day auto-cleanup. Opt-in.