FoundationChat  by Dimillian

SwiftUI chat app for on-device AI

Created 2 months ago
256 stars

Top 98.7% on SourcePulse

GitHubView on GitHub
Project Summary

FoundationChat is a SwiftUI application demonstrating on-device AI capabilities using Apple's new Foundation Models framework. It targets developers building privacy-focused, offline AI experiences on Apple platforms, offering persistent chat history and real-time response streaming.

How It Works

The app leverages SwiftUI for its user interface and integrates directly with Apple's Foundation Models for AI processing. Conversation data, including messages and summaries, is persisted using SwiftData. A ChatEngine manages model sessions and streams responses, often structured via @Generable types, enabling features like tool integration (e.g., WebAnalyserTool for web content extraction) and automatic conversation summarization.

Quick Start & Requirements

  • Install/Run: Open FoundationChat.xcodeproj in Xcode and build on a supported device.
  • Prerequisites: iOS 26.0+, iPadOS 26.0+, macOS 26.0+, or visionOS 26.0+; Xcode 26.0+ (with iOS 26 SDK); a device with Apple Intelligence support enabled in Settings.
  • Notes: Simulator use is not recommended for optimal performance.

Highlighted Details

  • On-Device AI: All processing occurs locally, ensuring complete user privacy and offline functionality.
  • Real-time Streaming: AI responses are streamed live with structured output capabilities.
  • Tool Integration: Supports custom tools like WebAnalyserTool for extracting structured data from web pages.
  • Persistent Storage: Utilizes SwiftData for robust, local storage of conversation history and summaries.

Maintenance & Community

This project is presented as a demonstration of Apple's Foundation Models framework. Contributions for improvements and bug fixes are welcomed, but specific community channels or maintainer details are not provided.

Licensing & Compatibility

The project is released under the MIT License, which permits broad use, including commercial applications.

Limitations & Caveats

The application requires specific, recent Apple hardware and software versions (iOS 26+, Apple Intelligence enabled). As a demonstration project, it may lack the robustness or feature set required for production deployment without further development. Simulator performance is not guaranteed.


Health Check
Last Commit

2 months ago

Responsiveness

Inactive

Pull Requests (30d)
0
Issues (30d)
0
Star History
22 stars in the last 30 days

Explore Similar Projects

Feedback? Help us improve.