Apple FM API Coverage Matrix

March 17, 2026 ยท View on GitHub

Status: FM-1, FM-2, FM-3, FM-4, FM-5, FM-6, FM-7, FM-8, and FM-9 landed matrix, updated 2026-03-10 from the retained Apple FM audit plus a direct scan of ~/code/python-apple-fm-sdk, after moving the current bridge contract and reusable client into psionic-apple-fm, after landing typed system-model availability, use-case, and guardrail coverage, after landing explicit session handles and transcript-backed restore via raw transcript JSON, and after landing typed generation-options coverage plus truthful estimated usage detail, and after landing SSE session streaming with snapshot semantics, and after landing typed transcript export/import and from_transcript-style restore coverage, and after landing structured generation with schema-guided typed decode plus a real live-bridge receipt, and after landing tool calling with a reusable Rust tool trait, loopback callback transport, and a real multi-tool live receipt, and after landing typed Foundation Models error mapping plus live invalid-schema, tool-failure, and context-overflow receipts.

This is the living coverage matrix for the Psionic Apple Foundation Models lane. It maps the exported Python SDK surface and its major behavioral families to the Rust/Psionic roadmap.

Legend:

  • landed = implemented on main
  • planned = explicitly queued in docs/ROADMAP_FM.md
  • n/a = truly not applicable in Rust; avoid using this unless the difference is real and documented

Public Surface

Python SDK surfaceRust / Psionic targetStatusRoadmap issueNotes
SystemLanguageModelpsionic-apple-fm::AppleFmSystemLanguageModellandedFM-2 / #3347Reusable Rust wrapper now carries model id, use-case, and guardrails.
SystemLanguageModelUseCasepsionic-apple-fm::AppleFmSystemLanguageModelUseCaselandedFM-2 / #3347Includes typed bridge decode plus unknown-value fallback.
SystemLanguageModelGuardrailspsionic-apple-fm::AppleFmSystemLanguageModelGuardrailslandedFM-2 / #3347Includes typed bridge decode plus unknown-value fallback.
SystemLanguageModelUnavailableReasonpsionic-apple-fm::AppleFmSystemLanguageModelUnavailableReasonlandedFM-2 / #3347Bridge and desktop now carry typed reason codes instead of only strings.
LanguageModelSessionpsionic-apple-fm::AppleFmSession + session client APIslandedFM-3 / #3348Reusable bridge client now creates, inspects, resets, deletes, and responds through explicit session IDs.
Transcriptpsionic-apple-fm::AppleFmTranscript + transcript export/import helperslandedFM-6 / #3351Typed transcript envelope, entry/content preservation, export, import, and restore are now landed.
GenerationOptionspsionic-apple-fm::AppleFmGenerationOptionslandedFM-4 / #3349Includes local validation for non-negative temperature and positive maximum response tokens.
SamplingModepsionic-apple-fm::AppleFmSamplingModelandedFM-4 / #3349Includes local validation for greedy-vs-random semantics and top versus probability_threshold.
SamplingModeTypepsionic-apple-fm::AppleFmSamplingModeTypelandedFM-4 / #3349Typed greedy/random discriminator now exposed in reusable Rust code.
GenerationSchemapsionic-apple-fm::AppleFmGenerationSchemalandedFM-7 / #3352Supports raw JSON input plus schemars-derived typed schema generation.
GeneratedContentpsionic-apple-fm::AppleFmGeneratedContentlandedFM-7 / #3352Supports JSON export, typed decode, and per-property decode helpers.
GenerationIDpsionic-apple-fm::AppleFmGenerationIdlandedFM-7 / #3352Bridge payloads and Rust generated content now carry stable generation IDs.
Generablepsionic-apple-fm::AppleFmStructuredType + schemars::JsonSchemalandedFM-7 / #3352Rust maps typed structured generation to JsonSchema-derived types instead of Python decorators.
GenerationGuide / guideschemars constraint annotations in typed Rust schemaslandedFM-7 / #3352Enum/choice, numeric-range, list-count, and regex guidance now map through schema metadata instead of prompt hacks.
generableRust-native typed-schema derive pathlandedFM-7 / #3352Syntax differs from Python, but the typed-schema semantics are now covered.
Toolpsionic-apple-fm::AppleFmTool + typed tool definitionslandedFM-8 / #3353Rust now registers typed tool definitions and executes real Apple FM tool callbacks through the reusable client runtime.
ToolCallErrorpsionic-apple-fm::AppleFmToolCallErrorlandedFM-8 / #3353Explicit tool-call failures now carry typed tool name + underlying error detail.
Foundation Models error familypsionic-apple-fm::{AppleFmErrorCode, AppleFmFoundationModelsError}landedFM-9 / #3354Reusable Rust lane now exposes the Python-SDK-aligned error family and bridge metadata fields instead of collapsing remote failures into strings.

Bridge Contract Ownership

Contract familyRust / Psionic ownerStatusRoadmap issueNotes
/health response shapepsionic-apple-fm::contract::AppleFmHealthResponselandedFM-1 / #3346Reusable typed contract moved out of desktop app code.
/v1/models response shapepsionic-apple-fm::contract::AppleFmModelsResponselandedFM-1 / #3346Includes typed model-list envelope + entry types.
/v1/chat/completions request shapepsionic-apple-fm::contract::AppleFmChatCompletionRequestlandedFM-4 / #3349Now carries typed Apple FM generation options in addition to the compatibility fields.
/v1/chat/completions response shapepsionic-apple-fm::contract::AppleFmChatCompletionResponselandedFM-1 / #3346Includes choice/message/usage shapes.
Reusable current bridge clientpsionic-apple-fm::AppleFmBridgeClientlandedFM-1 / #3346Desktop now consumes the shared client instead of owning the transport types.
Typed system-model availability/configuration contractpsionic-apple-fm::AppleFmSystemLanguageModelAvailabilitylandedFM-2 / #3347Health payload now reconstructs typed availability + configuration truth.
Typed model listing config/availability fieldspsionic-apple-fm::AppleFmModelInfolandedFM-2 / #3347/v1/models now carries typed use-case/guardrail fields and availability detail.
Session create/get/delete/reset/respond contractpsionic-apple-fm::{AppleFmSession*, AppleFmBridgeClient}landedFM-3 / #3348Bridge now owns explicit session IDs instead of one hidden shared LanguageModelSession.
Session-aware bridge protocolReusable bridge/session contractlandedFM-3 / #3348The bridge now uses explicit session handles; the old one-shot path remains only as a compatibility wrapper.
Plain-text generation request/responsepsionic-apple-fm::{AppleFmTextGenerationRequest, AppleFmTextGenerationResponse}landedFM-4 / #3349Reusable Rust lane now exposes first-class text generation without forcing callers through the OpenAI chat envelope.
Generation-options bridge protocolReusable typed options contractlandedFM-4 / #3349Chat and session-response endpoints now carry typed options and validate them before execution.
Streaming bridge protocolpsionic-apple-fm::{AppleFmAsyncBridgeClient, AppleFmTextResponseStream} + SSE session stream contractlandedFM-5 / #3350Session streaming now uses /v1/sessions/{id}/responses/stream with snapshot events and terminal completion payloads.
Transcript bridge protocolpsionic-apple-fm::{AppleFmTranscript, AppleFmBridgeClient} + /v1/sessions/{id}/transcriptlandedFM-6 / #3351Bridge now exports typed transcripts and accepts either typed transcript objects or raw transcript JSON on restore.
Structured-generation bridge protocolpsionic-apple-fm::{AppleFmStructuredGenerationRequest, AppleFmSessionStructuredGenerationRequest} + /v1/sessions/{id}/responses/structuredlandedFM-7 / #3352The bridge now exposes a real structured-generation route backed by Apple FM schema responses.
Tool-calling bridge protocolAppleFmToolDefinition + session loopback callback contractlandedFM-8 / #3353The bridge now builds real Apple FM Tool objects and calls back into the Rust-side runtime for tool execution.

Behavioral Contract

Behavior familyStatusRoadmap issueNotes
Current minimal bridge contract captured in reusable Rust types and clientlandedFM-1 / #3346The desktop no longer owns the transport contract types for the current retained endpoints.
Typed model availability/use-case/guardrail truthlandedFM-2 / #3347Desktop/provider runtime now carries typed system-model status instead of relying only on free-form strings.
Session-scoped request serialization semanticslandedFM-3 / #3348Each session now has an explicit in-flight contract and rejects overlapping same-session requests with concurrent_requests; separate sessions remain independent.
Reset-after-failure semanticslandedFM-3 / #3348Sessions expose a reusable reset hook without clearing transcript history; typed cancellation transport is still future work.
Plain-text generation with typed optionslandedFM-4 / #3349One-shot and sessioned responses now honor typed temperature, sampling, and maximum-response-token options.
Unsupported stream flag fails explicitlylandedFM-4 / #3349The compatibility chat endpoint now rejects stream: true instead of silently ignoring it before FM-5.
Usage truth distinguishes exact from estimatedlandedFM-4 / #3349Estimated bridge counts now live in usage detail with truth: estimated; raw exact counts remain unset when the bridge cannot report them truthfully.
Streaming snapshot semanticslandedFM-5 / #3350The stream yields full response snapshots, not deltas, and terminal completion includes final session state plus usage detail.
Transcript update timinglandedFM-5 / #3350Session transcript snapshots stay stable while a stream is in flight and update only after successful completion.
Raw transcript-backed restore semanticslandedFM-3 / #3348Sessions can still be recreated from bridge transcript JSON for compatibility.
Typed transcript export/import and restore semanticslandedFM-6 / #3351The Rust lane now exports typed transcript snapshots, restores from typed transcript objects or raw transcript JSON, and preserves the rule that transcript tool history does not enable new tools by itself.
Typed, structured-generation behaviorlandedFM-7 / #3352Structured generation now uses the Apple FM schema path, with nested/list coverage and a real ignored live-bridge receipt.
Real tool-calling flowlandedFM-8 / #3353Tool-enabled sessions now use a session-aware callback contract, with unit coverage and a real ignored multi-tool live receipt.
Typed error mappinglandedFM-9 / #3354Bridge clients and stream consumers now receive typed Foundation Models errors with failure reason, recovery suggestion, debug detail, refusal explanation, and tool metadata where available.
Desktop/macOS Mission Control Apple FM truthplannedFM-10 / #3355Mission Control is still GPT-OSS-first on main.

FM-1 Through FM-8 Landed Scope

The following is explicitly landed by FM-1 through FM-9 and should remain the starting point for later issues:

  • crates/psionic-apple-fm exists as the reusable crate for the Apple FM bridge contract and client
  • the current bridge request/response types are reusable Psionic-owned types
  • the current bridge has a reusable blocking client in Psionic
  • the desktop Apple FM worker uses those shared types instead of owning its own transport contract
  • the reusable crate now exposes typed system-model enums for use case, guardrails, and unavailable reason
  • bridge health/model listing responses now carry typed system-model configuration and availability truth
  • desktop/provider runtime state now carries typed Apple FM system-model readiness fields instead of only free-form availability text
  • the bridge now owns explicit Apple FM session IDs and session lifecycle endpoints for create/get/respond/reset/delete
  • session restore from raw transcript JSON is now real in the bridge and client
  • the hidden shared Swift LanguageModelSession assumption is gone from the bridge session path
  • the reusable crate now exposes typed generation-options and sampling-mode surface area with local validation mirroring the Python SDK rules
  • the bridge now carries typed generation options for both one-shot and sessioned text generation
  • the reusable crate now exposes first-class plain-text generation request and response types
  • usage detail can now mark counts as exact versus estimated, and the bridge currently marks its derived counts as estimated
  • the bridge now exposes a session-first SSE streaming contract with snapshot events and terminal completion events
  • the reusable crate now exposes an async Apple FM streaming client and stream item types for that session-first streaming lane
  • same-session stream cancellation now restores the session so a follow-up request can succeed without manual repair
  • transcript snapshots returned by session inspection stay stable during in-flight streaming and update only after successful completion
  • the reusable crate now exposes a typed AppleFmTranscript model for Foundation Models transcript snapshots
  • the bridge now exposes explicit typed transcript export at /v1/sessions/{id}/transcript
  • session create now accepts typed transcript dictionary payloads in addition to raw transcript_json compatibility input
  • the reusable client now supports typed transcript export plus from_transcript-style session restore helpers
  • invalid transcript input now fails explicitly and transcript/history tool mentions remain historical unless tools are supplied again
  • the reusable crate now exposes structured-generation schema/content/id types plus Rust-native typed structured-generation support
  • the bridge now exposes /v1/sessions/{id}/responses/structured for real schema-guided generation via Apple's structured-generation path
  • the reusable client now supports typed, explicit-schema, and raw JSON-schema structured generation plus typed decode helpers
  • structured-generation coverage now includes nested objects, lists, validation failures, and an ignored real live-bridge receipt on macOS
  • the reusable crate now exposes a Rust AppleFmTool trait, typed tool definitions, tool-call callback request/response types, and typed AppleFmToolCallError
  • the bridge now constructs real Apple FM tools from Rust-provided definitions and calls back into a loopback Rust-side tool runtime for execution
  • tool coverage now includes direct invocation, typed registration, complex argument payloads, explicit failure mapping, session registration behavior, and an ignored real multi-tool live receipt on macOS
  • the reusable crate now exposes AppleFmErrorCode and AppleFmFoundationModelsError so remote failures remain typed instead of collapsing into generic request strings
  • the Swift bridge now serializes Foundation Models failure reason, recovery suggestion, debug description, refusal explanation, and tool-call metadata when those fields exist
  • ignored live receipts now exist for invalid generation schema, tool-call failure, and context overflow through the retained Swift bridge

What is intentionally not closed by FM-1 through FM-9:

  • desktop Mission Control cutover