Configuration
Configuration uses TOML with a schema version. The validator rejects unknown fields and invalid values before the service starts.
Configure from the desktop app
Section titled “Configure from the desktop app”The desktop app covers the normal path without editing TOML:
- In Providers, add LM Studio, Ollama, OpenAI, Anthropic, or a compatible endpoint. API keys are stored in the macOS credential store.
- In Models & routes, create a stable alias, choose its provider, and enter the upstream model name expected by that provider.
- Return to Chat and select the alias or a route.
LiteGate starts without fictional providers or models. The gateway may be live
at 127.0.0.1:4100, but Chat stays gated until at least one model is configured.
An available example
Section titled “An available example”The repository includes tests/fixtures/config/valid-phase1.toml:
version = 1
[server]listen = "127.0.0.1:4000"request_timeout_ms = 120000max_body_bytes = 1048576max_concurrent_requests = 16
[[providers]]id = "mock"kind = "openai-compatible"base_url = "http://127.0.0.1:4100/v1"locality = "local"authentication = "none"
[[models]]id = "mock-chat"provider = "mock"upstream_model = "mock-chat-v1"The mock destination is example configuration: this file does not start a model
server. LiteGate does not run or download user models either.
Select and validate the file
Section titled “Select and validate the file”Use an explicit path for reproducible results:
cargo run -p litegate-cli -- config validate --config tests/fixtures/config/valid-phase1.tomlThe LITEGATE_CONFIG environment variable is also available. Selection prioritizes
--config, then that variable, and finally the platform path. When getting
started, use --config to avoid ambiguity.
Validation does not check network availability, credentials or actual model capabilities. Provider secrets are managed through the operating system’s credential store; do not add them to the example.