foundation-models-server/README.md
A lightweight OpenAI-compatible HTTP server that wraps Apple's Foundation Models framework, enabling Jan to use on-device Apple Intelligence models on macOS 26+.
swift build -c release
The binary will be at .build/release/foundation-models-server.
# Check availability
foundation-models-server --check
# Start server on default port
foundation-models-server --port 8080
# Start server with API key
foundation-models-server --port 8080 --api-key <key>
The server exposes an OpenAI-compatible API:
GET /health — health checkGET /v1/models — lists the apple/on-device modelPOST /v1/chat/completions — chat completions (streaming and non-streaming)The model ID is always apple/on-device.