Skip to content

Releases: ricky-stone/SwiftFM

SwiftFM 2.0.0

10 Apr 06:33

Choose a tag to compare

SwiftFM 2.0.0

SwiftFM 2.0.0 is a major beginner-first update for Apple's Foundation Models.

Highlights

  • new SwiftUI-style fluent builders with SwiftFM.configuration(), SwiftFM.request(), and SwiftFM.prompt(...)
  • chainable modifiers for Config, RequestConfig, PromptSpec, ContextOptions, and TextPostProcessing
  • dynamic schema generation and schema-driven structured streaming
  • typed structured streaming with streamJSON(...)
  • locale helpers, 26.4+ token counting, feedback attachment export, and custom adapter helpers
  • improved Foundation Models generation error descriptions
  • rewritten README focused on simpler beginner onboarding while keeping advanced features documented

Validation

  • swift test

SwiftFM 1.2.0

18 Feb 17:20

Choose a tag to compare

SwiftFM 1.2.0

Added

  • Structured prompt APIs with SwiftFM.PromptSpec (generateText(from:), streamText(from:), streamTextDeltas(from:), plus context overloads).
  • Output post-processing with SwiftFM.TextPostProcessing (whitespace cleanup, paragraph normalization, decimal rounding).
  • Context embedding controls with SwiftFM.ContextOptions (heading + JSON formatting).
  • Public source marker: SwiftFMVersion.current == "1.2.0".

Changed

  • Config and RequestConfig now support contextOptions and postProcessing.
  • Text generation and streaming now apply optional post-processing before returning results.
  • README fully rewritten with beginner-first + power-user Swift/SwiftUI examples.

SwiftFM v0.3.0

16 Aug 20:24

Choose a tag to compare

SwiftFM v0.3.0 Pre-release
Pre-release

This release updates the README to include Swift Testing examples, showing how to validate
text generation, streaming, and guided JSON output in practice.

Added

  • Testing section in README with real Swift Testing examples.
  • Examples include:
    • Plain text generation
    • Streaming text generation
    • Guided JSON with @generable models

Notes

  • No changes to the SwiftFM API.
  • Safe for Swift 6 with strict concurrency enabled.

SwiftFM v0.2.0 – Streaming Text & Docs Update

16 Aug 19:40

Choose a tag to compare

New Feature

  • Added streamText(for:) API
    • Supports progressive text generation using AsyncThrowingStream.
    • Enables more responsive UIs in SwiftUI (live output as chunks arrive).
    • Example usage included in README.

Documentation

  • Expanded README with:
    • Streaming text usage examples (console + SwiftUI).
    • Attribution section encouraging courtesy credit to Ricky Stone.
  • Clarified availability and platform support.

Why this release matters

This release marks SwiftFM’s evolution from simple one-shot responses to
supporting real-time generation. Developers can now build more interactive
apps with Foundation Models on-device.

SwiftFM v0.1.1

16 Aug 02:31

Choose a tag to compare

SwiftFM v0.1.1 Pre-release
Pre-release

SwiftFM is a lightweight façade over Apple’s new FoundationModels framework, designed to make working with on-device language models simple and beginner-friendly.

Features

  • Plain text generation – pass a prompt, get back a string
  • Guided typed generation – decode directly into your own Decodable & Generable structs
  • Beginner-friendly API – minimal surface and sensible defaults
  • Availability helpers – check if the model is ready on the device
  • On-device, no servers required

Requirements

  • iOS 26+ / iPadOS 26+ / macOS 26+
  • Apple Intelligence enabled on the device or Mac
  • Not supported on watchOS or tvOS

Notes

This is the first public release. The API is intentionally minimal, focusing on core use cases:

  • generateText(for:)
  • generateJSON(for:as:)
  • isModelAvailable and modelAvailabilityReason

Expect additional features such as streaming and advanced generation options in future versions.

License

MIT