AI & BYOK
Tostada's AI features are bring-your-own-key. You paste an Anthropic API key into Settings; it is stored in your browser, sent with each request, and never saved on a server.
- Setting your key — where to get a key and how to save it
- Ask AI: generate tokens — the one AI hook live today, on Primitives
- Privacy — exactly what leaves your browser and what doesn't
What's live
| Surface | Status |
|---|---|
| Ask AI on Primitives — generate a palette from a prompt | ✅ live, real Anthropic call on your key |
| Spread (rewrite a page in your system) | ⏳ the engine works; the UI is next |
| Suggest layout principles from a description | ⏳ deferred |
| Drop a screenshot, get a token patch | ⏳ deferred |
Every AI surface has a manual fallback. The key gates AI-assisted shortcuts; nothing in Tostada requires a key. With no key set, Generate is disabled — and the theme picker, the colour ramps and Add colour all still do the same job by hand.
There is no mock mode. Earlier builds returned canned responses when no key was set; that made it impossible to tell a working feature from a broken one, so it's gone.
When it goes wrong
Every failure says what happened, whose end it happened on, and what you can do — and nothing is changed on your library when a call fails. Your prompt is kept, so you never retype it:
| What you'll see | What it means |
|---|---|
| Anthropic rejected your API key | The key is missing, expired, or not authorised. There's a link straight to Settings. |
| Rate limited | Anthropic's own limits. The countdown is the number they sent — Tostada never retries on its own, because that would spend your quota for you. |
| Anthropic is busy | Their side. Try again shortly. |
| Claude declined this request | Nothing broke; Claude chose not to answer. Rewording usually helps. |
| Unusable reply | Claude answered in a shape the feature can't apply. |