apple_intelligence 0.1.0
apple_intelligence: ^0.1.0 copied to clipboard
Generate images on device with Apple Intelligence, streamed as they are made, plus the system Image Playground sheet. iOS and macOS.
0.1.0 #
Initial release: Apple Intelligence image generation for Flutter.
ImageCreator.generateproduces images on device with no UI, delivered as aStreamso the first can be shown while the rest are still being made. Cancelling the subscription cancels the work on the device.ImagePlaygroundSheet.presentshows Apple's own generation UI and returns the file it wrote, or null if the user cancelled.ImageCreator.availabilityreports the sheet and streaming separately, because the sheet is iOS 18.1 and streaming is 18.4 — a device can offer one and not the other.ImageConcept.textnames a subject;ImageConcept.extractedFromasks the system to find the subjects in a passage.- Errors arrive as a typed hierarchy —
OsTooOldException,GenerationUnavailableException,GenerationRefusedExceptionwith a specific reason — never as a barePlatformException.
Verified against real Apple Intelligence hardware: two PNGs of about 4 MB, the first at 6.8s and the second at 10.3s.
Not included: Writing Tools and Genmoji. Both are planned; Writing Tools attaches to a native text view while Flutter renders its own text, so it needs a design decision rather than a wrapper.