Configuration File Location
OpenGround stores configuration at:- Linux/macOS
- Windows
XDG_CONFIG_HOME is set:The config file is automatically created with default values when you first run any
openground command.View Configuration
Display your current configuration:View Defaults Only
See hardcoded default values (ignoring your custom settings):Get Config File Path
Print the path to the config file:Default Configuration
OpenGround uses these defaults:Set Configuration Values
Modify configuration settings using theconfig set command:
Configuration Examples
Get Configuration Values
Retrieve a specific configuration value:Get Examples
Reset Configuration
Delete your config file and restore defaults:Configuration Settings Reference
Database Settings
Path to LanceDB database directory. Stores embeddings and vector indexes.
Name of the LanceDB table for storing document chunks.
Directory for storing extracted JSON files before embedding.
Extraction Settings
Maximum number of concurrent HTTP requests during sitemap extraction. Higher values extract faster but use more resources.
Embedding Settings
Number of text chunks to embed in each batch. Larger batches are faster but use more memory.
Maximum number of characters per chunk when splitting documents. Affects embedding granularity.
Number of overlapping characters between consecutive chunks. Helps maintain context across chunk boundaries.
Name of the embedding model from Hugging Face. Must match the embedding backend.
Dimensionality of embedding vectors. Must match the model’s output dimensions.
Backend for generating embeddings. Options:
"fastembed" or "sentence-transformers"Query Settings
Default number of search results to return. Can be overridden with
--top-k flag.Source Settings
Automatically save library sources to
~/.openground/sources.json when adding libraries with --source flag.Custom path to sources.json file. If not set, uses standard search order (project → user → package).
Embedding Backend Options
OpenGround supports two embedding backends:FastEmbed (Default)
- ✅ Faster inference
- ✅ Lower memory usage
- ✅ Optimized for CPU
- ✅ No dependency on PyTorch
Sentence Transformers
- ✅ More model options
- ✅ Better GPU support
- ✅ Active development
- ✅ Widely used
How do I change embedding models?
How do I change embedding models?
- Set the new model:
- Delete existing embeddings:
- Re-embed your libraries:
embedding_dimensions matches your model’s output size.Chunking Configuration
Chunking parameters affect how documents are split before embedding:How do chunk_size and chunk_overlap affect search quality?
How do chunk_size and chunk_overlap affect search quality?
Larger chunks (800-1200 chars):
- Better context preservation
- Fewer total chunks (faster indexing)
- May include irrelevant content
- Good for conceptual queries
- More precise results
- Better for specific queries
- More chunks (slower indexing)
- May lose broader context
- Prevents information loss at boundaries
- Higher overlap = more context retention
- Higher overlap = more chunks
Source File Configuration
OpenGround searches for library source configurations in this order:- Custom path (if provided via
--sources-fileorsources.file_path) - Project-local:
./.openground/sources.json - User home:
~/.openground/sources.json - Package-level:
openground/extract/sources.json
Disable Auto-Add to Sources
By default, when you add a library with--source, it’s saved to ~/.openground/sources.json:
Custom Sources File
Environment Variables
OpenGround respects XDG Base Directory specification:Configuration in Python
Access configuration from Python code:Advanced Configuration Examples
High-Performance Setup
High-Quality Setup
Custom Storage Setup
Large-Scale Setup
Configuration Best Practices
Test Before Committing
Test configuration changes on a small library before re-embedding large libraries:
Should I commit config.json to version control?
Should I commit config.json to version control?
No -
config.json is user-specific and contains local paths. It should not be committed.Yes - .openground/sources.json is project-specific and can be shared with your team.What happens if I change chunk_size after embedding?
What happens if I change chunk_size after embedding?
Existing embeddings use the old chunk_size. They won’t automatically update. To apply new chunking:Or use
- Change the setting:
- Delete and re-add libraries:
nuke for all libraries:Can I use different configs for different projects?
Can I use different configs for different projects?
Yes! Use project-local sources:Each project can have different source configurations.
Troubleshooting
Config changes don't take effect
Config changes don't take effect
Clear the config cache:Or restart your Python process/terminal.
Invalid JSON error when loading config
Invalid JSON error when loading config
Your config file has syntax errors. View it:Fix JSON syntax or reset:
Permission denied writing config
Permission denied writing config
Check directory permissions:Fix permissions: