lovelace config
View and manage all CLI configuration settings
The config command provides a unified interface for viewing, editing, and managing all Lovelace CLI configuration, including LLM providers, default settings, workspace preferences, and system paths.
Overview
Configuration management enables:
- View all settings - Display complete configuration
- Update settings - Modify individual configuration values
- Provider management - Configure LLM provider settings
- Workspace defaults - Set default workspace and preferences
- Path configuration - Customize storage locations
- Validation - Verify configuration is valid
All configuration is stored in ~/.lovelace/config.json with human-readable JSON format.
Usage
lovelace config [command] [options]
Subcommands
lovelace config show
Display current configuration.
lovelace config show [options]
Aliases: list, get
Options:
| Option | Description | Default |
|---|---|---|
--json | Output in JSON format | false |
-k, --key <key> | Show specific configuration key | All settings |
--providers | Show only provider configuration | false |
--paths | Show only path configuration | false |
Interactive Example:
$ lovelace config show
Lovelace CLI Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
LLM Providers:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Default: anthropic
Anthropic Claude:
Status: ✓ Configured
Default Model: claude-sonnet-4-5
API Key: sk-ant-api03-****....**** (configured)
OpenAI GPT:
Status: ✓ Configured
Default Model: gpt-4
API Key: sk-****....**** (configured)
Ollama (Local):
Status: ✓ Running
Endpoint: http://localhost:11434
Default Model: llama2
Workspace Settings:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Default Workspace: personal-projects
Auto-Save Sessions: Yes
Session History Limit: 100
Paths:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Config: ~/.lovelace/config.json
Data: ~/.lovelace/data/
Logs: ~/.lovelace/logs/
Sessions: ~/.lovelace/sessions/
General Settings:
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
CLI Version: 1.0.0
Auto Update Check: Enabled
Telemetry: Disabled
Editor: vim
Show Specific Key:
$ lovelace config show --key defaultProvider
defaultProvider: anthropic
JSON Output:
$ lovelace config show --json
{
"version": "1.0.0",
"defaultProvider": "anthropic",
"providers": {
"anthropic": {
"defaultModel": "claude-sonnet-4-5",
"apiKeyConfigured": true
},
"openai": {
"defaultModel": "gpt-4",
"apiKeyConfigured": true
},
"ollama": {
"endpoint": "http://localhost:11434",
"defaultModel": "llama2"
}
},
"workspace": {
"default": "personal-projects",
"autoSave": true,
"historyLimit": 100
},
"paths": {
"config": "~/.lovelace/config.json",
"data": "~/.lovelace/data/",
"logs": "~/.lovelace/logs/",
"sessions": "~/.lovelace/sessions/"
},
"general": {
"autoUpdateCheck": true,
"telemetry": false,
"editor": "vim"
}
}
Provider-Only View:
$ lovelace config show --providers
LLM Provider Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Default Provider: anthropic
Configured Providers:
✓ Anthropic Claude (claude-sonnet-4-5)
✓ OpenAI GPT (gpt-4)
✓ Ollama (llama2)
lovelace config set
Update configuration values.
lovelace config set <key> <value> [options]
Options:
| Option | Description |
|---|---|
--global | Set global configuration (default) |
--workspace | Set workspace-specific configuration |
Examples:
$ lovelace config set defaultProvider openai
✓ Updated defaultProvider: openai
✓ Configuration saved
Default LLM provider changed to OpenAI GPT
Set Nested Value:
$ lovelace config set providers.anthropic.defaultModel claude-3-opus-20240229
✓ Updated providers.anthropic.defaultModel
✓ Configuration saved
Set Multiple Values:
$ lovelace config set workspace.autoSave false
$ lovelace config set workspace.historyLimit 50
✓ Updated 2 configuration values
✓ Configuration saved
Boolean Values:
$ lovelace config set general.telemetry true
⚠️ Enable Telemetry
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Telemetry helps improve Lovelace CLI by collecting:
• CLI command usage (anonymous)
• Error reports (no personal data)
• Performance metrics
No code, prompts, or conversation data is collected.
Continue? (Y/n): y
✓ Telemetry enabled
✓ Configuration saved
lovelace config unset
Remove configuration values (restore defaults).
lovelace config unset <key>
Example:
$ lovelace config unset general.editor
✓ Removed general.editor
✓ Restored to default: $EDITOR or vim
lovelace config reset
Reset configuration to defaults.
lovelace config reset [options]
Options:
| Option | Description |
|---|---|
--all | Reset all configuration |
--providers | Reset only provider configuration |
--confirm | Skip confirmation prompt |
Interactive Example:
$ lovelace config reset --all
⚠️ WARNING: Reset All Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
This will reset all CLI configuration to defaults:
• Provider settings (API keys will be preserved)
• Workspace preferences
• General settings
• Custom paths
Current configuration will be backed up to:
~/.lovelace/config.json.backup
Type 'reset' to confirm: reset
✓ Configuration backed up
✓ Configuration reset to defaults
✓ API credentials preserved
Run 'lovelace setup' to reconfigure providers.
Reset Providers Only:
$ lovelace config reset --providers
⚠️ Reset Provider Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
This will reset:
• Default provider
• Model selections
• Provider-specific settings
API keys will be preserved.
Continue? (y/N): y
✓ Provider configuration reset
✓ Credentials preserved
Run 'lovelace setup' to reconfigure providers.
lovelace config edit
Open configuration file in editor.
lovelace config edit
Interactive Example:
$ lovelace config edit
Opening configuration in vim...
[Editor opens with ~/.lovelace/config.json]
{
"version": "1.0.0",
"defaultProvider": "anthropic",
"providers": {
"anthropic": {
"defaultModel": "claude-sonnet-4-5"
}
},
"workspace": {
"default": "personal-projects",
"autoSave": true
}
}
[After saving and closing]
Validating configuration...
✓ Configuration valid
✓ Changes saved
Validation Errors:
$ lovelace config edit
[Edit and save invalid JSON]
✗ Configuration validation failed:
• Line 5: Unexpected token '}'
• Invalid JSON syntax
Configuration NOT saved.
Fix errors and try again, or run: lovelace config reset
lovelace config validate
Validate configuration file.
lovelace config validate [options]
Options:
| Option | Description |
|---|---|
--fix | Attempt to auto-fix issues |
--verbose | Show detailed validation results |
Valid Configuration:
$ lovelace config validate
Validating Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
✓ JSON syntax valid
✓ Schema valid
✓ Provider configuration valid
✓ Paths exist and are writable
✓ No deprecated settings
Configuration is valid!
Invalid Configuration:
$ lovelace config validate
Validating Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
✗ Configuration has errors:
JSON Syntax:
✓ Valid
Schema:
✗ defaultProvider: "invalid" is not a valid provider
Valid options: anthropic, openai, ollama
Providers:
✗ providers.anthropic.defaultModel: "invalid-model" not recognized
✓ providers.openai: Valid
Paths:
✗ paths.logs: Directory does not exist: /invalid/path
✓ Other paths: Valid
Deprecations:
⚠️ workspace.maxSessions is deprecated, use workspace.historyLimit
Fix issues manually or run: lovelace config validate --fix
Auto-Fix:
$ lovelace config validate --fix
Validating and Fixing Configuration
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Found 3 issues:
✓ Fixed: defaultProvider reset to "anthropic"
✓ Fixed: Created missing logs directory
✓ Fixed: Migrated workspace.maxSessions → workspace.historyLimit
⚠️ Could not auto-fix:
• providers.anthropic.defaultModel: "invalid-model"
Manual fix required: Set to valid model
Configuration partially fixed. Review remaining issues.
lovelace config path
Show configuration file locations.
lovelace config path [options]
Options:
| Option | Description |
|---|---|
--config | Show config file path only |
--data | Show data directory only |
--logs | Show logs directory only |
--all | Show all paths (default) |
Example:
$ lovelace config path
Configuration Paths
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
Config File: ~/.lovelace/config.json
Data Directory: ~/.lovelace/data/
Logs Directory: ~/.lovelace/logs/
Auth Directory: ~/.lovelace/auth/
Sessions: ~/.lovelace/sessions/
Workspaces: ~/.lovelace/workspaces/
Specific Path:
$ lovelace config path --config
/Users/username/.lovelace/config.json
Common Use Cases
View Current Configuration
Check all settings:
$ lovelace config show
[Complete configuration displayed]
Change Default Provider
Switch from Anthropic to OpenAI:
$ lovelace config set defaultProvider openai
✓ Default provider changed to OpenAI GPT
Change Default Model
Update model for a specific provider:
$ lovelace config set providers.anthropic.defaultModel claude-3-opus-20240229
✓ Model updated
Disable Telemetry
Turn off usage tracking:
$ lovelace config set general.telemetry false
✓ Telemetry disabled
Find Configuration File
Locate config file for manual editing:
$ lovelace config path --config
/Users/username/.lovelace/config.json
Validate After Manual Edits
Check configuration after editing:
$ vim ~/.lovelace/config.json
[Make changes]
$ lovelace config validate
✓ Configuration is valid
Reset Corrupted Configuration
Restore defaults if config is broken:
$ lovelace config reset --all
✓ Configuration reset
✓ Backup created
Configuration Schema
Complete Configuration Structure
{
"version": "1.0.0",
"defaultProvider": "anthropic",
"providers": {
"anthropic": {
"defaultModel": "claude-sonnet-4-5",
"temperature": 0.7,
"maxTokens": 4096
},
"openai": {
"defaultModel": "gpt-4",
"temperature": 0.7,
"maxTokens": 4096
},
"ollama": {
"endpoint": "http://localhost:11434",
"defaultModel": "llama2"
}
},
"workspace": {
"default": "personal-projects",
"autoSave": true,
"historyLimit": 100
},
"paths": {
"config": "~/.lovelace/config.json",
"data": "~/.lovelace/data/",
"logs": "~/.lovelace/logs/",
"sessions": "~/.lovelace/sessions/"
},
"general": {
"autoUpdateCheck": true,
"telemetry": false,
"editor": "vim",
"colorOutput": true
}
}
Configuration Keys Reference
| Key | Type | Description | Default |
|---|---|---|---|
defaultProvider | string | Default LLM provider | "anthropic" |
providers.<name>.defaultModel | string | Default model for provider | Provider-specific |
providers.<name>.temperature | number | Model temperature (0-1) | 0.7 |
providers.<name>.maxTokens | number | Maximum tokens per request | 4096 |
workspace.default | string | Default workspace name | "default" |
workspace.autoSave | boolean | Auto-save session history | true |
workspace.historyLimit | number | Max session history entries | 100 |
general.autoUpdateCheck | boolean | Check for CLI updates | true |
general.telemetry | boolean | Send anonymous usage data | false |
general.editor | string | Preferred text editor | $EDITOR or "vim" |
general.colorOutput | boolean | Enable colored terminal output | true |
Configuration Storage
Configuration files and their purposes:
~/.lovelace/
├── config.json # Main configuration
├── config.json.backup # Automatic backup
├── auth/ # Authentication data
│ └── credentials.enc # Encrypted API keys
├── workspaces/ # Workspace-specific configs
│ ├── personal-projects.json
│ └── work.json
└── .config-version # Config schema version
Environment Variables
Configuration can be overridden via environment variables:
| Variable | Description | Example |
|---|---|---|
LOVELACE_CONFIG_PATH | Custom config file location | ~/custom/config.json |
LOVELACE_DEFAULT_PROVIDER | Override default provider | openai |
LOVELACE_EDITOR | Override editor | code --wait |
NO_COLOR | Disable colored output | 1 |
Note: Environment variables take precedence over config file.
Exit Codes
| Code | Meaning |
|---|---|
0 | Command succeeded |
1 | Configuration error |
2 | Validation failed |
3 | Invalid arguments |
Troubleshooting
Configuration File Corrupted
Error: Failed to parse configuration
Syntax error in ~/.lovelace/config.json
Solution:
1. Validate: lovelace config validate
2. Reset: lovelace config reset --all
3. Restore backup: cp ~/.lovelace/config.json.backup ~/.lovelace/config.json
Invalid Provider Configuration
Error: Invalid provider: "invalid"
Valid providers: anthropic, openai, ollama
Solution:
$ lovelace config set defaultProvider anthropic
Permission Denied
Error: Cannot write to ~/.lovelace/config.json
Permission denied
Solution:
$ chmod 644 ~/.lovelace/config.json
$ ls -la ~/.lovelace/config.json
Missing Configuration File
Warning: Configuration file not found
Creating default configuration...
✓ Created ~/.lovelace/config.json
✓ Run 'lovelace setup' to configure providers
Related Commands
- lovelace setup - Interactive provider configuration wizard
- lovelace doctor - Diagnose configuration issues
- lovelace workspace - Manage workspace settings
Related Guides
- Getting Started Guide - Initial configuration setup
- Provider Configuration - Detailed provider setup
See the Command Reference for all available commands.