Skip to main content

Configuration Commands

NikCLI provides comprehensive configuration management for AI models, environment variables, system settings, and application preferences. These commands help you customize and optimize your development environment.

Core Configuration Commands

/config

Display current system configuration and settings. Syntax:
Parameters:
  • section - Specific configuration section to display
Options:
  • --detailed - Show detailed configuration
  • --json - Output in JSON format
  • --export - Export configuration to file
Examples:
Configuration Sections:
  • models - AI model settings
  • environment - Environment variables
  • security - Security settings
  • performance - Performance tuning
  • integrations - External integrations
  • ui - User interface preferences

/model [name]

Switch AI model or show current model configuration. Syntax:
Parameters:
  • model-name - Name of AI model to switch to
Options:
  • --provider <provider> - Specify AI provider
  • --temperature <value> - Set model temperature
  • --max-tokens <count> - Set maximum tokens
  • --show-available - Show available models
Available Models:
  • claude-3-5-sonnet - Anthropic Claude 3.5 Sonnet
  • claude-3-opus - Anthropic Claude 3 Opus
  • gpt-4 - OpenAI GPT-4
  • gpt-4-turbo - OpenAI GPT-4 Turbo
  • gpt-3.5-turbo - OpenAI GPT-3.5 Turbo
  • gemini-pro - Google Gemini Pro
  • mistral-large - Mistral Large
  • ollama/* - Local Ollama models
Examples:

/models

List all available AI models with details and capabilities. Syntax:
Options:
  • --provider <provider> - Filter by provider
  • --capability <capability> - Filter by capability
  • --detailed - Show detailed model information
  • --benchmark - Show performance benchmarks
Examples:
Model Information Display:

/set-key [provider]

Set API keys for AI providers interactively. Syntax:
Parameters:
  • provider - AI provider name
Supported Providers:
  • anthropic - Anthropic Claude models
  • openai - OpenAI GPT models
  • google - Google Gemini models
  • mistral - Mistral AI models
  • openrouter - OpenRouter proxy
  • ollama - Local Ollama instance
  • perplexity - Perplexity AI
  • coinbase - Coinbase AgentKit
  • browserbase - Browser automation
Examples:
Interactive Key Setup:

/router [action]

Configure model routing and load balancing. Syntax:
Available Actions:
  • status - Show routing configuration
  • set - Set model for specific use case
  • balance - Configure load balancing
  • fallback - Set fallback models
  • reset - Reset routing configuration
Examples:
Routing Configuration:

Environment Management

/env [var] [value]

Manage environment variables and configuration. Syntax:
Parameters:
  • variable - Environment variable name
  • value - Variable value to set
Options:
  • --list - List all environment variables
  • --unset <var> - Unset variable
  • --export - Export to .env file
  • --load <file> - Load from file
Examples:
Environment Variable Categories: System Variables:
  • NODE_ENV - Node.js environment
  • PATH - System path
  • HOME - Home directory
  • USER - Current user
AI Provider Keys:
  • ANTHROPIC_API_KEY - Anthropic Claude
  • OPENAI_API_KEY - OpenAI GPT
  • GOOGLE_API_KEY - Google Gemini
  • MISTRAL_API_KEY - Mistral AI
Application Settings:
  • NIKCLI_LOG_LEVEL - Logging level
  • NIKCLI_CACHE_DIR - Cache directory
  • NIKCLI_CONFIG_DIR - Configuration directory

/temp [value]

Set AI model temperature for response creativity. Syntax:
Parameters:
  • temperature - Temperature value (0.0-2.0)
Options:
  • --model <model> - Set for specific model
  • --reset - Reset to default
  • --show - Show current temperature
Temperature Guidelines:
  • 0.0-0.3 - Deterministic, factual responses
  • 0.4-0.7 - Balanced creativity and accuracy
  • 0.8-1.2 - Creative, varied responses
  • 1.3-2.0 - Highly creative, experimental
Examples:

System Configuration

/system [action]

Manage system-level configuration and settings. Syntax:
Available Actions:
  • info - Show system information
  • limits - Configure resource limits
  • cache - Cache management
  • logs - Logging configuration
  • performance - Performance settings
Examples:
System Information Display:

/stats

Show detailed system and usage statistics. Syntax:
Parameters:
  • category - Statistics category
Categories:
  • usage - Usage statistics
  • performance - Performance metrics
  • models - Model usage stats
  • tokens - Token consumption
  • sessions - Session statistics
Examples:

/dashboard [action]

Control the system dashboard display. Syntax:
Available Actions:
  • start - Start dashboard
  • stop - Stop dashboard
  • expand - Expand dashboard view
  • collapse - Collapse dashboard view
  • refresh - Refresh dashboard data
Options:
  • --interval <seconds> - Refresh interval
  • --compact - Compact view
  • --metrics <list> - Specific metrics to show
Examples:

Advanced Configuration

Configuration Profiles

Manage Configuration Profiles:
Predefined Profiles: Development Profile:
  • Relaxed security settings
  • Debug logging enabled
  • Higher token limits
  • Development model preferences
Production Profile:
  • Strict security settings
  • Error logging only
  • Conservative token limits
  • Stable model preferences
Testing Profile:
  • Isolated environment
  • Verbose logging
  • Test-specific settings
  • Mock integrations

Model Configuration

Advanced Model Settings:

Integration Configuration

Configure External Integrations:

Configuration Files

Configuration File Locations

System Configuration:
  • ~/.nikcli/config.json - Main configuration
  • ~/.nikcli/profiles/ - Configuration profiles
  • ~/.nikcli/cache/ - Cache directory
  • ~/.nikcli/logs/ - Log files
Project Configuration:
  • .nikcli/config.json - Project-specific config
  • .nikcli/profiles/ - Project profiles
  • .env - Environment variables
  • .nikcli-ignore - Ignore patterns

Configuration Schema

Main Configuration Structure:

Troubleshooting Configuration

Common Configuration Issues

API Key Problems:
Model Access Issues:
Configuration Corruption:

Debug Commands

Best Practices

Configuration Management

  • Regular configuration backups
  • Use profiles for different environments
  • Document configuration changes
  • Validate configuration regularly
  • Keep sensitive data secure

Model Selection

  • Choose appropriate models for tasks
  • Monitor token usage and costs
  • Use routing for optimization
  • Set appropriate temperature values
  • Configure fallback models

Environment Variables

  • Use .env files for projects
  • Keep secrets secure
  • Document required variables
  • Use consistent naming conventions
  • Regular cleanup of unused variables

Performance Optimization

  • Monitor resource usage
  • Configure appropriate limits
  • Use caching effectively
  • Optimize model routing
  • Regular performance reviews

Security

  • Protect API keys
  • Use secure configuration storage
  • Regular security audits
  • Appropriate access controls
  • Monitor configuration changes