Configuration¶
Metaxy can be configured using TOML configuration files, environment variables, or programmatically.
Configuration Priority¶
When the same setting is defined in multiple places, Metaxy uses the following priority order (highest to lowest):
- Explicit arguments - Values passed directly to
MetaxyConfig() - Environment variables - Values from
METAXY_*environment variables - Configuration files - Values from
metaxy.tomlorpyproject.toml
Configuration files are discovered automatically by searching in the current or parent directories.
Configuration Options¶
store¶
Default metadata store to use
Type: str | Default: "dev"
stores¶
Named store configurations
Type: dict[str, metaxy.config.StoreConfig]
migrations_dir¶
Directory where migration files are stored
Type: str | Default: ".metaxy/migrations"
entrypoints¶
List of Python module paths to load for feature discovery
Type: list[str]
theme¶
Graph rendering theme for CLI visualization
Type: str | Default: "default"
hash_truncation_length¶
Truncate hash values to this length (minimum 8 characters).
Type: int | None
auto_create_tables¶
Auto-create tables when opening stores (development/testing only). WARNING: Do not use in production. Use proper database migration tools like Alembic.
Type: bool | Default: False
project¶
Project name for metadata isolation. Used to scope operations to enable multiple independent projects in a shared metadata store. Does not modify feature keys or table names. Project names must be valid alphanumeric strings with dashes, underscores, and cannot contain forward slashes (/) or double underscores (__)
Type: str | Default: "default"
Store Configuration¶
The stores field configures metadata store backends. Each store is defined by:
type: Full import path to the store class (e.g.,metaxy.metadata_store.duckdb.DuckDBMetadataStore)config: Dictionary of store-specific configuration options
Example: Multiple Stores with Fallback Stores¶
# Default store to use
store = "dev"
# Development store (in-memory) with fallback to production
[stores.dev]
type = "metaxy.metadata_store.duckdb.DuckDBMetadataStore"
[stores.dev.config]
db_path = ":memory:"
fallback_stores = ["prod"]
# Production store
[stores.prod]
type = "metaxy.metadata_store.duckdb.DuckDBMetadataStore"
[stores.prod.config]
db_path = "s3://my-bucket/metadata.duckdb"
[tool.metaxy]
store = "dev"
[tool.metaxy.stores.dev]
type = "metaxy.metadata_store.duckdb.DuckDBMetadataStore"
[tool.metaxy.stores.dev.config]
db_path = ":memory:"
fallback_stores = ["prod"]
[tool.metaxy.stores.prod]
type = "metaxy.metadata_store.duckdb.DuckDBMetadataStore"
[tool.metaxy.stores.prod.config]
db_path = "s3://my-bucket/metadata.duckdb"
Configuring Metadata Stores¶
Configuration options for metadata stores can be found at the respective store documentation page.
Configuring Metaxy Plugins¶
Configuration options for Metaxy plugins can be found at the respective plugin documentation page.