Expand description
Raw FFI declarations matching the Swift @_cdecl exports in
swift-bridge/Sources/FoundationModelsBridge.
These are intentionally opaque (*mut c_void) and unsafe; safe wrappers
live in the parent modules.
Modules§
- status
- Status codes mirrored 1:1 from the
FM_*constants in Swift.
Structs§
- FFIGeneration
Options - Plain-old-data carrier for
crate::generation::GenerationOptions.
Functions§
- fm_
adapter_ ⚠compatibility_ async - Async version of
Adapter.compatibleAdapterIdentifiers(name:). - fm_
adapter_ ⚠compatible_ identifiers_ json - fm_
adapter_ ⚠compile - fm_
adapter_ ⚠create_ from_ file - fm_
adapter_ ⚠create_ from_ name - fm_
adapter_ ⚠create_ from_ name_ async - Async version of
Adapter(name:). - fm_
adapter_ ⚠metadata_ json - fm_
adapter_ ⚠remove_ obsolete - fm_
bytes_ ⚠free - fm_
decimal_ ⚠from_ generated_ content_ json - fm_
decimal_ ⚠to_ generated_ content_ json - fm_
generation_ ⚠id_ create - fm_
generation_ ⚠schema_ compile_ json - fm_
generation_ ⚠schema_ create_ typed_ json - fm_
generation_ ⚠schema_ validate_ json - fm_
object_ ⚠release - fm_
refusal_ ⚠explanation_ from_ transcript_ json - fm_
refusal_ ⚠explanation_ json - fm_
refusal_ ⚠explanation_ stream - fm_
refusal_ ⚠explanation_ stream_ from_ transcript_ json - fm_
session_ ⚠create - fm_
session_ ⚠create_ ex - fm_
session_ ⚠is_ responding - fm_
session_ ⚠log_ feedback - fm_
session_ ⚠log_ feedback_ attachment_ json - fm_
session_ ⚠prewarm - fm_
session_ ⚠prewarm_ prompt_ json - fm_
session_ ⚠respond - fm_
session_ ⚠respond_ request_ json - fm_
session_ ⚠respond_ with_ schema - fm_
session_ ⚠stream_ request_ json - fm_
session_ ⚠stream_ response - fm_
session_ ⚠transcript_ json - fm_
string_ ⚠dup - fm_
string_ ⚠free - fm_
system_ ⚠model_ availability_ code - fm_
system_ ⚠model_ availability_ code_ for - fm_
system_ ⚠model_ create - fm_
system_ ⚠model_ create_ default - fm_
system_ ⚠model_ create_ with_ adapter - fm_
system_ ⚠model_ is_ available - fm_
system_ ⚠model_ supported_ languages_ json - fm_
system_ ⚠model_ supports_ locale - fm_
system_ ⚠model_ token_ count_ prompt_ async
Type Aliases§
- FmAsync
Callback - 3-argument async callback used by the
async_apithunks inAsync.swift. - FmRespond
Callback - FmStream
Callback - FmTool
Callback