Your agent needs a language model to think. This is the one big decision — local or cloud — and how to choose a model without burning through tokens.
The model runs on a provider's servers, and your agent connects to it over the internet. This is how most people start, and it's the easiest path.
The model runs entirely on your own machine. Your agent and your data stay on your hardware, under your control.
Not all models cost the same to run, and not all of them need the same amount of "thinking" to get a job done. Here's the honest way to think about it:
The skill you'll develop over time is knowing which model to reach for. It's not about always using the biggest, most expensive model — it's about using the right one for the job. A capable small model will handle most of your daily work, and you'll learn to spot the moments when a heavier model is worth the extra cost.
Model names change quickly, and the "best" model shifts as new ones are released. So rather than pin you to a specific name that may be outdated by the time you read this, here's the honest way to choose:
Most providers offer a "flash" or "lite" tier — fast, cheap, and plenty capable for everyday work. This should be your daily driver. It will handle most tasks well and keep your token burn low while you learn.
Have access to a larger, smarter model for the genuinely hard problems — complex reasoning, big multi-step projects. You won't use it every day, but when a task is beyond the small model, you'll be glad it's there.
The best way to find what works for you is to try. Start with a small model, see how it handles your work, and reach for a bigger one when you hit its limits. You'll quickly develop a feel for which tasks each model handles well — and that instinct is worth more than any specific recommendation.
The trade-off you're always balancing is simple: smaller models are cheaper and faster but less powerful; larger models are smarter but cost more. As a beginner, start small, learn the ropes, and only expand when a task genuinely needs it. That's the honest, token-conscious way to build with an agent.
Before we get to the installation steps, there's one concept you'll run into right away, and it's worth understanding clearly: the API. An API (Application Programming Interface) is, in plain terms, the doorway that lets your agent talk to a model provider's service. When your agent wants the model to think, it sends a request through that doorway, and the model's answer comes back.
To use that doorway, you need a key — a kind of private password that identifies you and lets the provider track your usage. Think of it like a library card: the library (the model provider) lets you in to use its books (the models), and the card (your API key) is how it knows it's you. If you're using a cloud model, you'll need an API key from whichever provider you choose.
A model provider is simply a company or service that hosts language models and lets you use them, typically over the internet for a fee. When your agent needs to think, it sends the request to one of these providers, which runs the model and sends back the result.
There are a lot of providers, and they differ in the models they offer, the prices they charge, and how easy they are to use. Some you've probably heard of already: OpenAI (ChatGPT's maker), Google (Gemini), Anthropic (Claude), and Ollama (which we mentioned for local models). There are also aggregators like OpenRouter that give you access to hundreds of models from many providers through a single key and a single account — a very popular way to start, because one key covers almost everything.
The process is similar no matter which provider you pick:
Want to explore running a model entirely on your own machine? See The Local Option: Ollama →. Or if you're ready, get your agent running →.