ConfigManager ABC — eight abstract methods — and exposes a build_config_manager() factory. The skeleton’s config seam loads a provider by dynamic import of that factory, so there is no static edge in either direction.
Implement the contract
SubclassConfigManager and implement all eight abstract methods:
- Env surface —
read_envandwrite_env.write_envmerges, preserving keys absent from the new config. - Manifest reads —
read_manifest(the resolved view),read_manifest_preserved(the same document with every!ENV <expr>kept as its literal marker string, never resolved to a secret), andread_defaults_manifest. - Manifest writes —
write_manifest(a three-way merge reserved for config-layer internals such as bootstrap and the defaults merge; it preserves YAML!ENVtags), plus the two transactional write seams feature code uses:mutate_manifestandreplace_manifest.
mutate_manifest(mutator) reads the persisted preserved view, runs mutator to edit it in place, and persists the result — untouched keys keep their values. replace_manifest(document) swaps the whole stored document, dropping any key absent from document. Both hold exclusive access across the entire read-modify-write span, so a concurrent writer cannot interleave: a file-backed manager takes a lock, an API-backed one retries on an optimistic-concurrency conflict (which is why mutator must be re-runnable). Both are abstract — a subclass that implements only one cannot be instantiated. A missing source raises loudly (FileNotFoundError) — never a silent empty.
examples/config_provider/vault_config.py
Expose the factory
Expose a module-levelbuild_config_manager() that returns your manager — the selection convention every config provider follows. The example ends with exactly this factory.
Wire the config mode
A config provider is selected byTAI_CONFIG_MODE, not by a manifest module — it must be resolved before the manifest is read. The skeleton maps a mode name to your factory’s import path and loads it by dynamic import. Install your package, then set the mode:
tai42-contract (the interface) and tai42-kit (settings and manifest yaml helpers) only; never import the skeleton. Keep any client driver behind an optional extra. Document your provider’s own settings in your repository’s README.
Shipped implementations
tai42-config-k8s— the KubernetesConfigManager(env via Secrets, manifest via ConfigMaps).
See also
- Config and secrets — the config-provider seam and the built-in file provider.
- Deploy — selecting a config provider at runtime.
- Python SDK reference — the
ConfigManagercontract surface.

