codybrom / afm-ts-sdk
PublicTypeScript/Node.js bindings for Apple's on-device Foundation Models (macOS 26+ only)
TypeScript/Node.js SDK for on-device Apple Intelligence inference using Apple's Foundation Models framework, supporting streaming text generation, structured outputs, tool calling, and transcript persistence without network or API requirements.
How It Works
You hear about this simple kit that lets your JavaScript apps on Mac use Apple's built-in smart AI for generating text and ideas right on your device.
Check that your Mac has the latest updates and Apple Intelligence turned on in the settings so everything works smoothly.
Bring the kit into your project with a quick install, no extra software needed beyond what's already on your Mac.
Set up a friendly AI assistant that checks if it's ready and waits patiently until it can start helping.
Give your assistant some personality instructions and start asking questions or giving tasks.
Get instant, streaming replies, structured information, or help from custom tools, all happening privately on your Mac.
Your app now delivers smart, offline AI results that feel powerful and keep your data safe at home.
Star Growth
Repurpose is a Pro feature
Generate ready-to-use prompts for X threads, LinkedIn posts, blog posts, YouTube scripts, and more -- with full repo context baked in.
Unlock RepurposeSimilar repos coming soon.