Configuration
Configure Daily Vibe with your preferred LLM providers and settings
Configuration
Daily Vibe uses cosmiconfig for flexible configuration management. You can configure it through command-line options, configuration files, or environment variables.
Configuration Methods
Daily Vibe automatically loads configuration from the following sources (in order of preference):
- Command-line arguments
- Environment variables
- Configuration files
- Default values
Configuration Files
Daily Vibe searches for configuration in these files:
package.json
(underdailyVibe
property).dailyviberc.json
.dailyviberc.js
dailyvibe.config.js
.config/daily-vibe.json
LLM Provider Configuration
OpenAI Configuration
# Basic OpenAI setup
daily-vibe config set --provider openai --api-key sk-proj-your-api-key
# With custom model
daily-vibe config set --provider openai --api-key sk-proj-your-api-key --model gpt-4-turbo
# View current configuration
daily-vibe config set --show
{
"llm": {
"provider": "openai",
"apiKey": "sk-proj-your-api-key",
"model": "gpt-4",
"baseUrl": "https://api.openai.com/v1"
}
}
export DAILY_VIBE_LLM_PROVIDER=openai
export DAILY_VIBE_LLM_API_KEY=sk-proj-your-api-key
export DAILY_VIBE_LLM_MODEL=gpt-4
Anthropic Claude Configuration
# Basic Claude setup
daily-vibe config set --provider anthropic --api-key sk-ant-your-api-key
# With specific model
daily-vibe config set --provider anthropic --api-key sk-ant-your-api-key --model claude-3-sonnet-20240229
{
"llm": {
"provider": "anthropic",
"apiKey": "sk-ant-your-api-key",
"model": "claude-3-sonnet-20240229"
}
}
export DAILY_VIBE_LLM_PROVIDER=anthropic
export DAILY_VIBE_LLM_API_KEY=sk-ant-your-api-key
export DAILY_VIBE_LLM_MODEL=claude-3-sonnet-20240229
Generic OpenAI-Compatible APIs
Daily Vibe supports any OpenAI-compatible API, such as DashScope, DeepSeek, or local deployments.
# Alibaba Cloud DashScope
daily-vibe config set \
--provider generic \
--base-url https://dashscope.aliyuncs.com/compatible-mode/v1 \
--api-key sk-your-dashscope-key \
--model qwen-plus
# DeepSeek API
daily-vibe config set \
--provider generic \
--base-url https://api.deepseek.com \
--api-key sk-your-deepseek-key \
--model deepseek-coder
# Local OpenAI-compatible server
daily-vibe config set \
--provider generic \
--base-url http://localhost:11434/v1 \
--api-key local-key \
--model llama2
Complete Configuration Reference
Example Configuration File
{
"llm": {
"provider": "openai",
"apiKey": "sk-proj-your-api-key",
"model": "gpt-4",
"baseUrl": "https://api.openai.com/v1",
"temperature": 0.1,
"maxTokens": 4096
},
"timezone": "Asia/Shanghai",
"outputDir": "./reports",
"redact": {
"enabled": true,
"patterns": [
"sk-[a-zA-Z0-9]{20,}",
"ghp_[a-zA-Z0-9]{36}",
"[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}\\.[0-9]{1,3}",
"\\b[A-Za-z0-9._%+-]+@[A-Za-z0-9.-]+\\.[A-Z|a-z]{2,}\\b"
],
"replacement": "[REDACTED]"
},
"dataSources": {
"claudeCode": {
"enabled": true,
"paths": ["~/.claude/projects/**/*.jsonl"]
},
"codexCli": {
"enabled": true,
"sessionPaths": ["~/.codex/sessions/**/*.jsonl"],
"historyPaths": ["~/.codex/history/**/*.jsonl"]
},
"specStory": {
"enabled": true,
"paths": ["**/.specstory/history/**"]
},
"vscode": {
"enabled": true
}
},
"analysis": {
"chunkSize": 10000,
"parallelism": 4,
"includeSystemMessages": false,
"minSessionDuration": 300
}
}
Configuration Options
LLM Settings
Option | Type | Description | Default |
---|---|---|---|
provider | string | LLM provider (openai , anthropic , generic ) | openai |
apiKey | string | API key for the provider | - |
model | string | Model name to use | gpt-4 |
baseUrl | string | Base URL for OpenAI-compatible APIs | - |
temperature | number | Sampling temperature (0-1) | 0.1 |
maxTokens | number | Maximum tokens per request | 4096 |
General Settings
Option | Type | Description | Default |
---|---|---|---|
timezone | string | Timezone for date filtering | System timezone |
outputDir | string | Default output directory | ./reports |
Data Redaction
Option | Type | Description | Default |
---|---|---|---|
redact.enabled | boolean | Enable/disable redaction | true |
redact.patterns | array | Regex patterns to redact | Built-in patterns |
redact.replacement | string | Replacement text | [REDACTED] |
Data Sources
Option | Type | Description | Default |
---|---|---|---|
dataSources.claudeCode.enabled | boolean | Enable Claude Code data source | true |
dataSources.codexCli.enabled | boolean | Enable Codex CLI data source | true |
dataSources.specStory.enabled | boolean | Enable SpecStory data source | true |
dataSources.vscode.enabled | boolean | Enable VS Code data source | true |
Analysis Settings
Option | Type | Description | Default |
---|---|---|---|
analysis.chunkSize | number | Text chunk size for processing | 10000 |
analysis.parallelism | number | Number of parallel analysis tasks | 4 |
analysis.includeSystemMessages | boolean | Include system messages in analysis | false |
analysis.minSessionDuration | number | Minimum session duration in seconds | 300 |
Environment Variables
All configuration options can be set via environment variables using the prefix DAILY_VIBE_
:
# LLM configuration
export DAILY_VIBE_LLM_PROVIDER=openai
export DAILY_VIBE_LLM_API_KEY=sk-proj-your-key
export DAILY_VIBE_LLM_MODEL=gpt-4
export DAILY_VIBE_LLM_BASE_URL=https://api.openai.com/v1
# General settings
export DAILY_VIBE_TIMEZONE=America/New_York
export DAILY_VIBE_OUTPUT_DIR=./my-reports
# Redaction
export DAILY_VIBE_REDACT_ENABLED=true
export DAILY_VIBE_REDACT_REPLACEMENT="***"
Configuration Validation
Daily Vibe validates your configuration on startup. Common validation errors:
Missing API Key: Ensure your API key is properly set in configuration or environment variables.
Invalid Model: Check that the model name is supported by your chosen provider.
Invalid Base URL: Verify the base URL is accessible and follows the correct format.
Testing Your Configuration
Verify your configuration is working correctly:
# Show current configuration
daily-vibe config set --show
# Test data source scanning
daily-vibe sources scan
# Run a quick analysis test
daily-vibe analyze today --json --out ./test
Configuration Profiles
You can maintain multiple configuration profiles by using different configuration files:
# Development profile
daily-vibe --config .dailyviberc.dev.json analyze today
# Production profile
daily-vibe --config .dailyviberc.prod.json analyze range --from yesterday --to today
Security Best Practices
API Key Security: Never commit API keys to version control. Use environment variables or local configuration files that are gitignored.
- Use Environment Variables: Set API keys via environment variables in production
- Restrict File Permissions: Ensure configuration files are readable only by you
chmod 600 .dailyviberc.json
- Use .gitignore: Exclude configuration files from version control
.dailyviberc.json .dailyviberc.js dailyvibe.config.js
Next Steps
With configuration complete, you're ready to:
- Learn Commands - Explore all available commands
- See Examples - View real-world usage scenarios
- Troubleshooting - Solve common issues