11 ms·
Apple Foundation Models
- _josh_meyer_ 4mo agothe github repo: https://github.com/anthropics/ClaudeForFoundationModels https://github.com/anthropics/ClaudeForFoundationModels
- tonyoconnell 4mo agoWhat it is Apple's Foundation Models framework (shipping in iOS 27 / macOS 27 this fall) is the standard Swift API for on-device AI — the same API Apple uses for their own small model. This package makes Claude plug into that same API as a drop-in swap. // Apple's on-device model let session = LanguageModelSession(model: SystemLanguageModel.default) // Claude — same API, just different model constructor let session = LanguageModelSession(model: ClaudeLanguageModel(name: .sonnet4_6, auth: auth)) One API, two tiers. You write your app once against the Foundation Models protocol. On-device model handles fast/free/private tasks; Claude handles heavy reasoning, long context, or capability gaps — you swap the model, not your code. You don't call the Anthropic API directly. Apple's framework handles streaming, tool calling, and structured output (@Generable) — you just get Claude's capability through it.
- daniel_iversen 4mo agoIs this Apple encouraging developers to go through their api abstraction layer to use LLMs so that when they launch their own (which I think we’ve heard they’ve been spending lots of money on training and might be somehow involved with Siri or current Apple AI?) that they can easily help devs make a seamless transition? Or is it just a developer nicety or something else?
- pprotas 4mo agoThe cynic (or realist?) in my thinks this abstraction layer is Apple's way of making sure that users give their own Apple Intelligence credit for the underlying LLM functionality, even if another company is actually providing the LLM.
- _the_inflator 4mo agoAssembled in Cupertino once more. ;)
- coldtea 4mo agoYeah, Apple just designs and writes the SoC, CPU, graphics unit, neural unit, compiler (Swift), OS, graphics layer, 3D API, core libs from graphics to persistence, filesystem, broadband chip, and a few more things besides...
- saagarjha 4mo agoNotably good models are not on that list.
- geden 4mo agoNeither are other capex heavy items like chip fabs.
- coldtea 4mo agoYeah, they also don't mine their own steel and copper. Such mere assemblers!
- coldtea 4mo agoYeah, that totally makes them merely assemblers then /s
- bigyabai 4mo agoApple Silicon is broadly unused for LLM training. Arguably, Apple isn't even helping to assemble real-world AI models, just the thin client hardware.
- Danox 4mo agoAI models in the end are just commodities the computer using public is not going to pay for them directly, in short, they’re not gonna bail out OpenAI, Meta, Google, Microsoft, Anthropic.
- mathisfun123 4mo ago> which I think we’ve heard they’ve been spending lots of money on training and might be somehow involved with Siri or current Apple AI Lol bro this is literally it this is the model they've been training (was Apple Foundation model not a big enough hint?)
- FinnKuhn 4mo agoMaybe they plan to have the providers pay for being the default model? So basically, what Google is doing right now for search engines. The difference however is that Google is making money with additional search requests while AIs are (as of now) losing money with additional requests. I don't see the business case for them yet though.
- thombles 4mo agoThere are already on-device models that you can use through this framework as a developer. Claude would just be an additional one.
- NorwegianDude 4mo agoA dark, but not totally unfair take: It makes it easier for Apple to take payment for the models others provide, and even allows Apple, if they want to, to use the data to build a dataset for training their own models based on how users use third party models. It's only on Apple devices this API is used, so they split up the market by not letting developers use the same system if they want things to work on iOS, locking users even more in.
- oefrha 4mo agoCall it Intelligence Store and charge… wait for it… 30%.
- cush 4mo agoThis is genuinely the only way Apple will make it out of the intelligence era alive and not become the next IBM
- aesthesia 4mo agoFrom the linked docs page: > Requests go directly from your app to the Claude API; Apple is not in the request path and does not see prompts or responses. Usage is billed to your Anthropic account at standard API pricing. Your app decides when to use Claude and when to use Apple's on-device model: pass whichever model you want to each session.
- tarcon 4mo agoApple has some clever mechanics to protect user data. I had to work with App tracking stuff lately and their approach to keeping user details private with anonymized cohorts (SKAN, Differential Privacy) before reporting tracking events to third party platforms was surprisingly well thought out. There is value in having them in your loop if you care about privacy.
- willis936 4mo agoIt would be cool if they offered some kind of prompt sanitation option.
- HDThoreaun 4mo agoMy read of the ATT stuff is basically that it forced all the apps to use meta ad tracking because they’re the only ones who figured out how to serve relevant ads despite it.
- drivebyhooting 4mo agoFigured out = do the forbidden PII join anyway with their partners in “clean rooms”.
- HDThoreaun 4mo agoRight, the lesson here is that if you make rules with exploitable loopholes youre probably only going to end up strengthening malicious actors who are willing to exploit loopholes.
- klausa 4mo agoThis is support for a new framework that ships with reality/mac/iPad/watch/tv/iOS 27 (and that they've promised to open-source later in the year, so presumably you'll also be able to lean on this if you ship Swift on your backend). The framework's whole deal is that it lets you use the same API to target either the device built-in models, the Apple-hosted online models (Private Cloud Computer), or write your own shims to call out to arbitrarily hosted online models. You can then dynamically route your calls to a different kind of model/provider, using system APIs, without having to write your own abstraction layer over "I want to use local model for this, but I want to use Claude for that", or having to integrate your own API integration with Anthropic/OpenAI APIs. It abstracts things like tool calling in one place; and has a bunch of other niceties/oddities (it keeps the same "transcript" going, even if you dynamically switch providers/models during a session) and some other things.
- claud_ia 4mo ago[dead]
- deleted 4mo ago[deleted]
- zkmon 4mo agoCoding agent itself an imposed layer. Now they are adding one more layer? Many times I think of coding agent as the vendor supervisor from the body shops of the 90's who promise the customer everything under the sky and thrash the poor contractor to deliver. Coding agents consume 10x more tokens just like how body shops charged their customers vs how they paid the contractors. For a simple test, the same task that makes the model to go out of context length when used via a coding agent, runs fine when prompted directly. Layers are luxury and remove control and transparency.
- gregman1 4mo agoSo actually the most successful AI was OpenRouter Intelligence? Pronounced as OÏ.
- rock_artist 4mo agoWhile I'm happy with Apple introducing this abstraction. my main concern was with local models. I'd love using Gemma4 as an example. but thinking of a user. if 10 Apps each uses same model and downloads it, the phone will be bloated. I still didn't understand if Apple provided a way for multiple apps uses same on-device model (without tricky namespaces and permissions). I didn't see anything suggesting that's the case.
- klausa 4mo agoThe apps can use the system provided on-device model using the same framework and APIs; but there's no affordances to deduplicate custom models between apps.
- jtfrench 4mo agoThat's a great opportunity for Apple to provide a universal unique model ID protocol and some shared storage space to allow devs to register models.
- trvz 4mo agoDo you guys not have phones (with at least 1TB of storage)?
- mft_ 4mo agoI have a Mac with 4TB of storage but it’s still annoying when every new AI app I try installs its own virtual environment with a fresh copy of Python, PyTorch, other duplicate libraries, and then models on top of that.
- DrScientist 4mo agoAs an occasional python user I'm always amazed and frustrated that it seems that the only way to be able to use/build anything is to create a whole separate environment. And now given everybody now does this I guess the incentive to stop breaking stuff reduces even further. Might as well have static binaries.
- mlpicker 4mo agoWhat I'm curious about is whether this is actually on-device. Apple's framework caps local models around 3B params last I looked, and Claude is way bigger than that. So either there's some hybrid setup I haven't seen documented, or this is mostly a Claude SDK in FM clothing. Anyone tried it on a plane?
- brookst 4mo agoRead the linked article? It is absolutely a cloud service. Neither Apple nor Anthropic is suggesting otherwise
- ABS 4mo agoit's cloud, the doc is explicit that requests go straight to api.anthropic.com with Apple not in the way. so Claude via FM dies offline while Apple's on-device SystemLanguageModel (the ~3B one) keeps working. It isn't a hybrid really: the framework just has both implement the same LanguageModelSession protocol so "local 3B" and "remote frontier model" become a one-argument swap. IMHO what's worth internalising is that the two share an API but nothing else: the on-device path runs on Apple's Neural Engine and costs battery (you can watch ANE power ramp while it works) while the cloud path costs API credits/tokens and does zero local compute. Same code, opposite cost model.
- me551ah 4mo agoSo where does the api key reside? You can’t ship it on the iOS client since anyone can read and abuse it
- deleted 4mo ago[deleted]
- laxmansharma 4mo agohttps://platform.claude.com/docs/en/cli-sdks-libraries/libraries/apple-foundation-models#proxy-production https://platform.claude.com/docs/en/cli-sdks-libraries/libra...
- yilugurlu 4mo agoit says put into your API layer and proxy it.
- hedora 4mo agoIsn’t that a privacy and compliance nightmare?
- _pdp_ 4mo agoFrom app developer standpoint why would anyone ship claude keys like that ... or am I missing something? From consumer standpoint - I guess they can use their own keys but it is not something that is very user friendly as you can imagine.
- nl 4mo agoit says: Proxy (production) For production, route requests through your own back end with .proxied. The relay at baseURL adds the Claude API credential server-side, so the app ships no key. The headers you provide are sent on every request so your proxy can authorize the caller. https://platform.claude.com/docs/en/cli-sdks-libraries/libraries/apple-foundation-models#proxy-production https://platform.claude.com/docs/en/cli-sdks-libraries/libra...
- deleted 4mo ago[deleted]
- HelloUsername 4mo agoDoes "Apple Intelligence" need to be Turned On for this as well?
- deleted 4mo ago[deleted]
- Traster 4mo agoThis seems smart. Apple, despite not really leading in AI themselves, are right on the hot path of where developers are going to yolo slop into the ecosystem. Make a tonne of sense to define a nice clean API that places like Anthropic can build on top of and expose to developers. It's also smart for them to make sure the billing is going direct from Anthropic to the developer. The initial thought is "That means Apple's not taking a cut", but from the other side of it, developers who use this API are going to have to expose that cost to customers somehow, and that translates to subscription/InAppPurchase etc. on top of which Apple will get it's 30%.
- adithyassekhar 4mo ago> Requests go directly from your app to the Claude API; Apple is not in the request path and does not see prompts or responses. I know this is from a developer perspective. But as a consumer this is just funny.
- saretup 4mo agoWhy?
- 21-DOT-DEV 4mo ago> Usage is billed to your Anthropic account at standard API pricing. While expected, it’s still a bummer.
- isoprophlex 4mo agoThe pricing squeezes will continue until token spend improves!
- hit8run 4mo agoWhy would I want a nerfed model?
- jedisct1 4mo agoMisleading title. This is about Claude for Apple Foundation Models, not about Apple Foundation Models
- VadimPR 4mo agoHow can you practically use this in software if you're to deploy this to users? Asking a user to create and enter their own API key is a bar too high for good UX.
- Maxious 4mo ago> For production, route requests through your own back end with .proxied Apple is offering developers with less than 2 million downloads free AI models via their servers https://techcrunch.com/2026/06/08/apple-bets-cheaper-ai-will-woo-small-developers/ https://techcrunch.com/2026/06/08/apple-bets-cheaper-ai-will...
- klausa 4mo agoThe same way you did it before — by proxying the requests to your backend.
- nate 4mo agoUgh. It really is. I have allihat.com which is the only safari extension (i think still) that talks to claude. And it's well sought for. But you as a user have to enter a friggin claude api key. :( And I still don't grok their TOS around this. Like you can still type: ```setup-token Set up a long-lived authentication token (requires Claude subscription)``` but this seems like a trap? :) Whose using this? Doesn't this like insta break their TOS if you use that anywhere? Right now for allihat.com I just let people use the Apple model locally if you don't feel like using the claude key. And my conversions to paying user shot up like 3x! But it really isn't a replacement obviously to claude. I was hoping Apple would make proxying to Claude some kind of thing they do for me so I also don't have to proxy to my own server just to try and manage API to Claude usage.
- harrouet 4mo agoThis is Apple commoditizing LLMs while keeping control of the UX. They are a hardware company and will keep selling the best machine for AI use. Well done.
- klausa 4mo agoHow is this Apple keeping control of the UX?
- matwood 4mo agoThe betas of the next OS's include a Siri AI chatbot, and the AI features are built into various parts of the OS. A user has no idea what model is powering any of it - Apple controls the UX.
- klausa 4mo agoI'm aware. How is this relevant to the posted article?
- embedding-shape 4mo agoThe article is about (from the eyes of a user) white-labeled usage of Claude models on Apple devices, this subthread is about white-labeled usage of LLMs on Apple devices, how is it not relevant?
- klausa 4mo agoBecause that's not what the article is about; this is about a unified API for the _app developers_ to access different kind of models. That API has no user-facing components, and has no influence over UX of what the end-users are interacting with. The users won't know if you used Foundation Models API or integrated with OpenAI/Anthropic/Gemini SDK directly.
- embedding-shape 4mo ago
- londons_explore 4mo ago> A key bundled into an app is extractable from the shipping binary, and anyone who extracts it can make requests billed to your account. Use .apiKey for development only, and switch to a proxy before release. I don't like this model. Then all the user data is visible to the proxy. Far better would be some kind of micro payment architecture where a wallet is on the users device and coins are attached to each request. We just need to live in the alternate universe where micro payments succeeded.
- insumanth 4mo agoThis was expected. Apple will carefully choose what & how people can use AI in their ecosystem and will make sure of it. I hope "Apple Foundation Models" Eco-system grows with support from major model providers.
- pgt 4mo agoI’m surprised to see the model names hardcoded as an enum (e.g. `.sonnet4_6`), instead of a string with model discovery so that the user can select their preferred model without having to get a new app version through the App Store to support newer models.
- klausa 4mo ago>Model identifiers are values of ClaudeModel. Use a compiled-in constant, or construct one with explicit capabilities for an ID that isn't compiled in yet (see Capabilities): Special emphasis on the "isn't compiled in yet" and "or construct one" bit.
- mcintyre1994 4mo agoI think this is just Apple planning for their on-device models getting better, which makes sense given they have access to Gemini now. If developers use this for all their code calling an external LLM, then as Apple's model becomes more capable and covers more use cases it'll be easy to switch to it at individual call sites. That'll give apps better UX and save developers money on a bill that Apple doesn't get a cut of.
- embedding-shape 4mo ago> That'll give apps better UX and save developers money on a bill that Apple doesn't get a cut of. With other words, it's unlikely to happen as there is no money in it. Better for Apple to create some new subscription "AI" and "AI-lite" plans people can subscribe to, and since Apple is a company and we all know what those care about, it's unlikely to become a utopia of local models running on your phone.
- criddell 4mo agoHow does using Gemini lead to better on-device models?
- Danox 4mo agoUX is just another word for ecosystem building, which is what Apple does best in comparison to their competition and also doesn’t hurt to do hardware to go along with it. Microsoft and Nvidia aren’t teaming up for nothing.
- neuropacabra 4mo agoCan someone explain me what it means in the context of Apple and ChatGPT/Claude/Mistral...?
- bentt 4mo agoI didn’t understand what they were doing with Apple Foundation Models until this. It made it sound like they were training their own. Good strat tho!
- klausa 4mo ago> It made it sound like they were training their own. They are.
- stackedinserter 4mo agoI'm not sure if I want to touch anything Anthropic anymore.
- hedora 4mo agoOpenAI is worse from a public policy standpoint, and apparently Fable was yanked at Amazon’s request. Enough is enough. I’m seriously evaluating open models this week.
- mark_l_watson 4mo agoI think Apple has a fairly good plan for supplying a common API and default on device models. What confuses me about this article is: The code examples Python, Ruby, etc.) look to me like the original Anthropic APIs, not Apple’s abstraction. Did I miss something?
- deleted 4mo ago[deleted]
- ChrisArchitect 4mo agoAssociated blog post: https://claude.com/blog/claude-for-foundation-models https://claude.com/blog/claude-for-foundation-models
- post-it 4mo ago> a Swift package that makes Claude available as a server-side language model in Apple's Foundation Models framework Ahh I was hoping for the opposite: all of the existing features of Claude Code but somehow running locally on my laptop's neural engine. A pipe dream on an M2 with 8 GB of RAM, but I had a flicker of hope there.
- inickt 4mo agoCheck out this WWDC session. Obviously not going to compete with the frontier models (and I think 8GB is too small anyways), but Apple did demo MLX + OpenCode. https://developer.apple.com/videos/play/wwdc2026/232/ https://developer.apple.com/videos/play/wwdc2026/232/ https://www.youtube.com/watch?v=wykPErJ8M-8 https://www.youtube.com/watch?v=wykPErJ8M-8
- FuriouslyAdrift 4mo agoI've found most of the frontier coding models require somewhere between 300GB to 1TB to run with full capabilities.
- godzillabrennus 4mo agoIf only we could buy 1TB of unified memory in a Mac for $1k-$2k in total hardware costs. Apple would basically be able to extinguish the entirety of the market cap for Nvidia, OpenAI, Anthropic, and others all at once. In 10 years, I hope my MacBook Pro can run today's frontier models and has 1TB of unified Memory.
- manoDev 4mo agoI’m bullish on Apple because of that. Tech waves always oscillate between mainframe/thin-client models at first, then commodity hardware catches up. Apple is well positioned to deliver that with the M series, all it takes is for the current AI bubble to pop a bit and memory costs go down.
- dboreham 4mo agoThe people who train the frontier models want to recover their costs, so they're not going to let you do that.
- otter0 4mo agoFirst Microsoft has broken keyfabe by putting "Copilot is for entertainment purposes only" in the Copilot terms of use and putting warnings in copilot for excel "avoid using COPILOT for ... any task requiring accuracy or reproducibility ... Tasks with legal, regulatory or compliance implications". Then Apple quietly refuses to participate by not investing tens or hundreds of billions in creating a competing LLM. Sure, they resell Claude for the marks or utilize Gemini to placate the gullible fools but they know what's up. https://www.microsoft.com/en-us/microsoft-copilot/for-individuals/termsofuse/archives https://www.microsoft.com/en-us/microsoft-copilot/for-indivi... https://support.microsoft.com/en-US/Excel/copilot-function https://support.microsoft.com/en-US/Excel/copilot-function
- swordlucky666 4mo ago[flagged]
- xducn1 4mo ago[flagged]
- ryanshrott 4mo agoShared daemon is the only way this makes sense on-device. A 3B model at 4-bit is roughly 2GB - three apps loading their own copies would eat an 8GB phone.
- simianwords 4mo agoSerious question: this looks like a thin library on an API. Why is it a big deal?
- hedora 4mo agoShared daemon (as others pointed out), and, later shared revenue, probably with Apple receiving payments to ship ad-laden, “editorialized” models. Hopefully, it’ll go the other way, and Apple will subsidize high quality model training.
- theopsimist 4mo agoIs this included in the free AI tier for small developers? Big news if so
- cush 4mo agoSince Claude is technically a subscription, Apple will slowly weasel their way into skimming 30% of the token spend
- hmokiguess 4mo agoHow does it work now though? There is a Claude app on iOS
- GeekyBear 4mo agoThis isn't Claude specific. Developers can also write apps that call Google's server based Gemini models. > At WWDC, Apple announced that it's opening its Foundation Models framework to third-party cloud model providers. Starting with iOS 27, macOS 27, iPadOS 27, visionOS 27 and watchOS 27, model providers can implement the new public LanguageModel protocol to provide a common interface for model inference. We've made Gemini models available to the Foundation Models framework through the Firebase Apple SDK. This provides a fully native development experience — cloud-hosted Gemini models can plug directly into the Foundation Models framework using the same API. That means the on-device Apple model and cloud-hosted Gemini models sit behind a shared API surface, so you can easily swap between local and cloud inference to fit your use case. https://blog.google/innovation-and-ai/technology/developers-tools/bringing-gemini-models-to-apple-developers/ https://blog.google/innovation-and-ai/technology/developers-...
- jdgoesmarching 4mo agoThe important part is Apple rebranding “OpenAI-compatible API” to “language model protocol” and I think we should all rally around this immediately before we’re cursed with that awful tongue twister.
- klausa 4mo agoThat's not what that means. Protocol in this context means a Swift language feature, like interface in some other languages: https://docs.swift.org/swift-book/documentation/the-swift-programming-language/protocols/ https://docs.swift.org/swift-book/documentation/the-swift-pr...
- 64lamei 4mo ago[flagged]
- 5701652400 4mo agoso it is not "Private Cloud Compute"?
- r0fl 4mo agoSo many people have Apple a hard time for not focusing enough on ai. Seems that the UX will be enough to win over users and investors