# Describe it — Studio builds it

Say what your app should do. Studio writes it, checks it and puts it in your launcher — a DEV tile up front on any site, on your own Fave1 account. Keep talking to change it. No terminal, no setup.

- **Describe** (1 · say it) — Like you’d tell a friend: what it does on a page, what it remembers, what its app mode shows.
- **Written and checked** (2 · watch) — The code appears as it’s written. Studio checks it and fixes what it can on its own before anything uploads.
- **On real sites** (3 · try) — Your app is a DEV tile up front in Fave1 on any site and in My Fave1 — on your own account. Change it by saying so.

## Start a build

1. **Create the app** — In the [console](https://developers.fave1.com/apps), press **Create app** and give it a name. Set its **Concept** — an icon and one line on what it does; Studio builds from that line. Then open the **Studio** tab — or the **Describe it — Studio builds it** card on its Overview.
2. **Describe it and press Send** — Type what it should do — paste a screenshot if it shows what you mean ([Show it](#talk)) — or start from one of the ideas. Every message runs on your Fave1 credits — what it costs depends on what you ask ([Credits](#credits)). **Send** sits in a small secure frame so nothing else on the page can press it for you.
3. **Watch it** — The **Code** tab shows the files as they’re written; the steps on the left say where it is — writing, checking, putting it in your launcher. A first build usually takes under half a minute. **Stop** ends it; nothing is uploaded.
4. **See it run** — When it’s done, **Card mode** opens a sample shop or article with Fave1 already open on your app; **App mode** shows its own page ([App mode](https://developers.fave1.com/docs/app-mode.md)). Then try it for real ([On real sites](#real-sites)).
5. **Change it** — Say what should change — “make the button pink”, “on Amazon it can’t find the price”. Studio rewrites only the lines that change, checks again and puts the new build in your launcher.

## On real sites — your launcher and My Fave1

While you’re signed in to this console, the app you have open in Studio is a DEV tile in Fave1, at the front of the grid with a DEV badge, on every site — its latest build — and one of the first apps in [My Fave1](https://www.fave1.com/myapps). Open a real product page, an article, the screen you’re building for, and click Fave1 in your bookmarks bar. No address to paste, nothing to install. No Fave1 in your bookmarks bar? [Add it here](https://www.fave1.com/get-started), on a computer.

- **On your account.** The build runs as you, signed in, with its data in `<id>@dev` — a DEV slot on your own account, kept apart from the live app ([My account](https://developers.fave1.com/docs/testing.md#my-account)). Save something on a site and it’s there in app mode in My Fave1. The first time on each site, Fave1 asks **Use your Fave1 account here?** — the same prompt people will see.
- **Sign in to Fave1 with the same account.** The launcher reads your DEV builds from your Fave1 sign-in, which is separate from this console’s.
- **Only while you’re here.** Sign out of the console and your console builds leave the launcher and My Fave1 — Studio builds and [Test links](https://developers.fave1.com/docs/testing.md#test-link). Sign in again in the same browser, or open the app in Studio, and it comes back. Take a tile out with × and it stays out until you open that app in Studio again. Builds from `npm run dev` on your computer aren’t touched, and Studio never pushes them out of your eight DEV places — if all eight are full, take one out to make room.
- **Kept fresh.** A build’s link lasts 12 hours; while a console tab is open Studio renews it on its own, and a teammate’s newer upload replaces it.

> The **Card mode** and **App mode** previews inside Studio keep their own test data in that browser. Your launcher and My Fave1 use your account — so something saved in a preview won’t show in app mode, and the other way round.

## Get better results

- **Say where.** Card mode (on someone’s site) or app mode (its own page) — or both. “On any shop page … and in app mode, a list of everything I saved.”
- **Say what it reads.** The price, the title, the images, the text you select. Studio reads what it can straight from the page instead of paying for AI on every open.
- **Say what went wrong, and where.** “On Etsy listings it shows the shipping price instead of the item price.” Name the site and what you saw.
- **Show it.** Paste a screenshot into the message (⌘V / Ctrl+V), drop a picture on it, or press the picture button — up to four a message. “Make it look like this”, “this is what breaks on Amazon”. Pictures go to the AI with that message only and aren’t saved — the conversation keeps how many there were. Each costs less than a credit.
- **Name the feature.** Notifications, the camera, the microphone, live rooms, shared links, saved files, stickers — say it, or use `ctx.notify` and the like by name, and Studio reads that part of the docs for your request. A page like that adds a few credits to the request it’s read for.
- **One change at a time.** Small asks are cheaper, quicker and easier to undo.
- **Ask for AI when you want it.** “Summarize the article with AI” uses [ctx.ai](https://developers.fave1.com/docs/ctx-ai.md) — paid from each person’s own Fave1 credits when they use your app.

Studio answers in your language; the words people see in your app are written in English, in `locales/en.json`. Ask for another language and it adds the file ([ctx.locale · ctx.t](https://developers.fave1.com/docs/ctx-locale.md)).

## Credits

Studio runs on your own Fave1 credits — there’s no free allowance for building. You pay for what the AI reads and writes, at cost plus Fave1’s margin, the same rate as every Fave1 AI call. [Get credits](https://www.fave1.com/settings/credits) in Fave1 Settings.

| What | Usually |
| --- | --- |
| A first build | 15–30 credits |
| A change, while Studio is warm | 2–10 credits |
| A change to a project from the CLI | 10–20 credits — more for a big one, since the AI reads more of it |
| A change after a long pause | about a first build |
| Run my edit · Undo · Download | free |

**Warm** means a Studio build ran in the last few minutes — anyone’s. Studio reads the same docs every time, and for a few minutes after a build they cost a twentieth as much to read again.

- **Your last request always finishes.** With even 1 credit left, Studio runs your request to the end. If it costs more than you have, your balance goes below zero — shown as −n — and your next top-up pays that off first. While you’re below zero, nothing else runs on credits.
- **Stop pays for what was written.** When you press Stop, the AI stops too, and you pay for what it had already written.
- **A fix on its own costs a little.** When the check finds a problem, Studio asks the AI once more to fix it — on your credits, usually a few.

## What Studio writes

A new app in Studio is three files, the same shape as any Fave1 app: `manifest.json`, `src/index.js` and `locales/en.json`. The code is one plain JavaScript file — no TypeScript, no imports, no packages (not [@fave1/kit](https://developers.fave1.com/docs/kit.md) yet). Studio fills in the ID, name and version, and adds a permission when the code uses something that needs one ([Permissions](https://developers.fave1.com/docs/permissions.md)).

Before anything uploads, Studio checks it: the code parses, it calls `Fave1.defineApp`, there’s no `eval` or script loading, every `ctx.t` key is in `locales/en.json`, and every change it was asked to make actually landed. If something’s wrong, it fixes it once on its own. If it still isn’t right, nothing uploads — **What the checker found** under the message says why, so you can ask again.

A project you uploaded from the CLI keeps its own files and language — TypeScript stays TypeScript ([Studio and the CLI](#cli)).

Your conversation is saved with the build and goes to review with it — reviewers read what you asked for next to the code. Taking it to your editor? See [Studio and the CLI](#cli).

## Edit and undo

- **Edit.** In the Code tab, press **Edit**, change any file and press **Run my edit**. It’s checked and uploaded like any build — no credits. Pictures show in the Code tab but change in your editor.
- **Undo last change.** At the top of Studio. Puts back the build from before your last change — up to five steps back, fewer in a big project (Studio keeps 200 KB of them). An upload from the CLI starts the undo list over. No credits.

## Studio and the CLI — one app, either place

Build in Studio, in your own editor with the [CLI](https://developers.fave1.com/docs/quickstart.md), or switch back and forth. Both upload to the same place — your app’s Versions — and **whatever uploads last is the build**. Studio always shows it — the **Card mode** and **App mode** previews and its code — and while you have the app open in Studio, it’s also the DEV tile in your launcher and My Fave1.

1. **Download the project** — The download button at the top of Studio saves a ready CLI project as a .zip. An app made in Studio comes with `package.json`, `manifest.json`, `src/index.js`, `locales/` and an icon; a project from the CLI comes back as you uploaded it — pictures and icon included — plus the newest `types/fave1.d.ts` if it’s TypeScript (the CLI doesn’t upload `types/`). Either way your Studio conversation rides along in `src/studio.json`.
2. **Run it — on the latest** — Unzip it, then `npm install`, bring Fave1’s packages up to date — `npm install -D @fave1/cli@latest`, and `npm install @fave1/kit@latest` if it uses the kit — and `npm run dev`. It’s the same DEV source as any CLI app ([Quickstart](https://developers.fave1.com/docs/quickstart.md)).
3. **Upload it** — Put your publish key in `.env` and `npm run submit`. Open Studio again: it shows that upload, marked **from the CLI**, with your conversation where you left it.

- **TypeScript and several files work too.** Studio changes whatever you uploaded — `.ts`, `.tsx`, components in their own files, npm packages like [@fave1/kit](https://developers.fave1.com/docs/kit.md) — and checks and bundles it the way `npm run build` does: TypeScript’s type check with your tsconfig, then esbuild with the loaders in package.json’s `bundle` script. Packages come from npm — the same files `npm install` gets, at the versions in package.json — so the bundle matches the one from your computer. Pictures in `src/` and the app icon go up with `npm run submit` from CLI 0.1.13.
- **A type or bundling error stops the upload** — the same ones `npm run build` stops on — and Studio fixes it once on its own. One difference: Studio doesn’t download packages’ own type definitions, so calls into a package aren’t type-checked there (your editor’s `npm run check` still does).
- **Keep your editor on the latest.** Studio always works against the newest Fave1 API, docs and type definitions — no update for you to install there. Your computer keeps the versions you installed, so run the update line above whenever you come back to a project, then `npx fave1 types` — it replaces `types/fave1.d.ts` with the newest. Otherwise code Studio wrote can fail `npm run build` on an older setup.
- **The same version number is replaced while it’s Ready**, from either place. Changed it in Studio after you downloaded? Download again before you keep going in your editor — or your next `npm run submit` replaces it.

## Working as a team

Everyone on your team can open the same app in Studio. Studio isn’t Git — there’s one latest build, not branches — so it stops before anyone’s work gets replaced:

- **Someone uploads while you’re here.** Within a minute Studio switches to their build and says who it was — or that it came from the CLI.
- **You send on top of an older build.** If a teammate uploaded first, Studio doesn’t apply yours. It shows the latest and puts your words and pictures back in the box — press **Send** again to apply them on top. If it happens while the AI is already writing, nothing uploads; the credits for that run are spent.
- **You’re in the middle of an Edit.** Studio tells you, and **Run my edit** won’t replace their build. **Copy my edit** keeps your text — make it again on the latest.
- **An old download goes up from the CLI.** When the app changed in Studio after that copy was downloaded, `npm run submit` stops and says so. Download again — or replace it on purpose with `npm run submit -- --force`.
- **Who asked for what.** Once more than one person has talked to Studio, every message shows their name.

> Two people working in their own editors? Use Git between you as usual — Studio shows whatever was uploaded last.

## When Studio only shows a build

Studio changes any build you uploaded, from Studio or the CLI — big projects too: the AI reads the files your request names first, and the rest as it fits. Two kinds it can only show — previews and code — with a **View only** card over the chat that says which:

| Studio found | What to do |
| --- | --- |
| No source files | The build came from an older CLI that uploaded only the bundle. Upload it again with `npm run submit`. |
| No entry file | No file calls `Fave1.defineApp` and package.json’s `bundle` script names none. Point the script at it (`esbuild src/index.ts …`). |

> Pictures you import from `src/` — PNG, JPEG, GIF, WebP — go up with `npm run submit` from CLI 0.1.13, and Studio bundles them like your computer does. Upload once more with that CLI if a project from an older one stops at bundling over a picture. Fonts and other files aren’t uploaded.

## Ship it

A Studio build is a normal build. Fill in the [listing](https://developers.fave1.com/docs/publishing.md), run the pre-check, press **Submit for review** — the same steps as a build from the CLI. Studio reuses the version number while the build is only Ready, so trying ideas doesn’t burn through numbers; once a version is in review or live, the next Studio build takes the next number.

| Limit | Value |
| --- | --- |
| Studio runs per person | 150 every 24 hours |
| Studio runs per app | 300 every 24 hours |
| Code | one file up to 256 KB · a CLI project up to 2 MB of source |
| Pictures | 4 a message, read at up to 1568 px on the long side |
| Undo | 5 steps back |
