Commands and configuration¶
The pasture command changes pasture's settings, and pasture saves them in its
config file. This page lists the commands, the Ollama settings, and the config
keys that you edit by hand.
Commands¶
| Command | What it does |
|---|---|
pasture |
Say whether pasture runs, what the library holds, and whether the machine is paired, then suggest the commands that likely come next. |
pasture help |
List every command, grouped by what it is for. |
pasture onboard [flags] |
Find models that fit the machine and the work, and download the ones you choose. |
pasture browse [search] |
List models with what each is for and how it fits this machine, search them, and download one. Add --use-cases, --all, --offline, or --json. |
pasture status |
List the models, where each one is, and the disk numbers. Name a newer pasture release when available. Add --json for JSON. |
pasture budget <size> |
Cap the space models use, such as 200G, or off. |
pasture reserve <size> |
Keep this much of the disk free, or default for 10% of the disk, up to 20 GB. |
pasture pin <model> |
Never move this model away. |
pasture unpin <model> |
Let this model move away again. |
pasture archive <folder> |
Copy models here when they move away, or off. |
pasture allow <origin> |
Let web pages from this origin use your models. |
pasture allow |
List the web origins you allowed. |
pasture disallow <origin> |
Stop allowing a web origin. |
pasture evict <model> |
Move a model away now. |
pasture restore <model> |
Bring a model back now, such as before you go offline. |
pasture sweep |
Apply the budget and reserve now. |
pasture add <model> |
Download a model. |
pasture run <model> [prompt] |
Chat with a model, or answer one prompt. It brings a moved-away model back first, and takes ollama run's flags, such as --think=false. |
pasture stop <model> |
Unload a model from memory. |
pasture remove <model> |
Delete a model, and its archive copy. |
pasture env NAME=value |
Set a variable for ollama serve, and restart it. An empty value removes the variable. |
pasture env |
List the variables that pasture gives ollama serve. |
pasture install |
Run pasture at login on macOS or at boot on Linux, start it now, and offer to pair. |
pasture pair |
Pair this machine with your Cinchapi account. |
pasture unpair |
Remove this machine's pairing. |
pasture https <name> |
Serve HTTPS for this public name, or off. |
pasture key create <name> |
Make an API key for HTTPS callers. |
pasture key list |
List the API keys by name. |
pasture key delete <name> |
Delete an API key, which stops working at once. |
pasture uninstall |
Stop running pasture at login or boot, after it offers to bring moved-away models back. |
pasture serve |
Run the proxy and Ollama. The service that pasture install sets up runs this. |
pasture upgrade |
Install pasture's newest release. Restart the service if installed. Add --check to check without installing. |
pasture version |
Print pasture's version. |
On a terminal, pasture gives commands, model names, and states color and weight,
and marks finished steps with a ✓. Output to a pipe or a file is plain text
with no escape codes, so scripts read it as they always have. Set NO_COLOR=1
to keep the weight and drop the color.
Ollama settings¶
To change an Ollama setting, use pasture env. For example,
pasture env OLLAMA_CONTEXT_LENGTH=65536 gives the agents a 64K context window.
ollama serve runs as a child of the pasture service, so the variables you
export in your shell do not reach it.
The config file¶
pasture sets OLLAMA_HOST for ollama serve itself, so pasture env refuses
it. To change the addresses, edit ~/.config/pasture/config.json, then restart
pasture with pasture install:
| Key | What it sets |
|---|---|
listen |
The address pasture serves Ollama's API on, 127.0.0.1:11434 by default. |
backend |
The address of the ollama serve that pasture runs, 127.0.0.1:11435 by default. |
The page for each task describes the other keys that you edit by hand:
ollama_path in Install pasture, account_url in Pairing
and the link to your account, models_url
in Choose models with pasture
onboard, and https.email and
https.listen in Serve HTTPS on a public host.