Install opencode, understand tokens and costs, pick the right model, and put your apps online โ for free.
This is a real opencode session (it loops โ just watch):
You describe. The agent reads, searches, edits and proves. You check. That's the job.
Download the LTS version from nodejs.org and install it like any app. To check it worked, open a terminal and type:
node --version โ you should see a number like v22โฆ
In the terminal, run:
npm install -g opencode-ai
Full install guide with other options: opencode.ai/docs
Run opencode auth login and follow the steps on screen. We use the free models (the ones marked free in the model list โ $0). Ask Yan which one we're using this week.
Go into any project folder and start it:
cd my-project then opencode
First question to ask it: "What does this project do?" ๐
opencode can tell you how many tokens you used and what they cost. Try:
opencode stats โ all your sessions ยท opencode stats --days 7 โ this week
Make it a habit: check your stats at the end of every lesson. On free models the cost is $0 โ and we keep it that way. ๐
Screenshot opencode answering your first question + your opencode stats โ that's your setup proof for the portfolio. Then tick the mission on the task board!
AI doesn't read words โ it reads tokens: little pieces of words. Every message you send and every answer you get is counted in tokens. And tokens are what you pay for.
This is a friendly imitation โ real tokenizers split even smarter. Try the real one: platform.openai.com/tokenizer. Prices are examples per 1 million tokens โ they change all the time; always check the model list.
opencode stats exists.Models are like team members: different brains, different speeds, different prices.
Big Pickle & friends โ the ones marked free.
$0. Great for learning.
Sometimes needs more guidance.
The sprinter.
Fast and very cheap.
Perfect for small, clear tasks.
The everyday pro.
Smart, balanced price.
What most developers use daily.
The deep thinker.
Hardest problems, highest price.
Save it for when you're truly stuck.
We give each one our explicit flower-shop prompt. What usually happens:
| Free model | A good basic site. Might miss a detail or two โ guide it, ask again. Cost: $0. |
| Haiku-class | Quick and clean on small asks; split big jobs into steps for it. Cost: tiny. |
| Sonnet-class | Solid site on the first try โ understands the whole plan. Cost: cents. |
| Opus-class | Also nails the tricky parts (form checks, edge cases). Cost: the most. |
opencode stats before and after. Try the same prompt on two models and compare: that's a real engineer's experiment.A project on your laptop is homework. A project with a LINK is a product. ๐
Your code needs to live in a GitHub repo first (we do this in class).
Go to vercel.com โ Continue with GitHub โ pick the Hobby plan (that's the free one).
Add New โ Project โ pick your repo โ Deploy. That's it.
You get your-project.vercel.app โ send it to everyone. Every push to GitHub updates the site automatically.
Real engineers get surprise bills too. ๐ The habit of checking first is the skill.