# Install
Install the Agent Smith terminal client globally:
```bash
npm i -g @agent-smith/cli
```
A global `lm` command is available once installed.
## Quickstart
Create a config file at `~/.config/agent-smith/config.yml`:
```yml
backends:
default: "llamacpp"
llamacpp:
type: "openai"
url: "http://localhost:8080/v1"
openrouter:
type: "openai"
url: "https://openrouter.ai/api/v1"
apiKey: "$OPENROUTER_API_KEY"
```
Run the `conf` command to process the config and populate the SQLite database:
```bash
lm conf ~/.config/agent-smith/config.yml
```
The configuration is stored in a SQLite database at `~/.config/agent-smith/config.db`. The YAML file is the source of truth for backends, feature paths, plugins, and agent settings. Run `lm conf` to sync the YAML config into the database.
### Inference
Run an inference query with the q command:
```bash
lm q list the planets of the solar system
```
The default model is determined by your backend configuration. To use another model:
```bash
lm q list the planets of the solar system -m gemma4b
```
### Agents
List all available agents:
```bash
lm agents
```
Show an agent definition:
```bash
lm agent myagent
```
Next: Overview