apple_fm_shim
apple_fm_shim
¶
Apple Foundation Models shim.
Thin FastAPI server exposing Apple Intelligence's on-device foundation
model as an OpenAI-compatible API. Only runs on macOS 26+ with Apple
Intelligence enabled. Wraps Apple's apple-fm-sdk's
LanguageModelSession as /v1/chat/completions and /v1/models
endpoints.
Token counts: The Apple FM SDK does not expose token counts. The shim returns 0 for all token counts. Throughput and energy benchmarks will reflect this limitation.
Usage: uvicorn openjarvis.engine.apple_fm_shim:app --host 127.0.0.1 --port 8079