Resolve configuration discovery order and import support
This commit is contained in:
@@ -24,6 +24,34 @@ and [configuration contract](https://forge.maximumdirect.net/base-layer/configki
|
|||||||
|
|
||||||
## Agreed Direction and Migration Work
|
## Agreed Direction and Migration Work
|
||||||
|
|
||||||
|
### Discovery Locations and Import Selection — Resolved
|
||||||
|
|
||||||
|
An explicit `--config` selects exactly that file. A missing, inaccessible, or
|
||||||
|
invalid explicit file is an error; do not fall back to discovery.
|
||||||
|
|
||||||
|
Without an explicit file, search in this order using ConfigKit's native presets
|
||||||
|
and filename rules with application name `audita`:
|
||||||
|
|
||||||
|
1. `WorkingDirectory` for project-local configuration.
|
||||||
|
2. `UserConfigDirectory` for personal configuration.
|
||||||
|
3. `UnixSystemDirectories` for system configuration.
|
||||||
|
|
||||||
|
Select the first matching file. Do not merge every discovered file or continue
|
||||||
|
searching after a selected file fails to load. Additional composition is explicit
|
||||||
|
through native imports and overlays. Recommend explicit configuration paths for
|
||||||
|
automation so its selection does not depend on the working directory.
|
||||||
|
|
||||||
|
Enable native imports for operator configuration sources, retaining upstream
|
||||||
|
defaults and declaration-level controls. Imports compose peer documents, not
|
||||||
|
higher-priority override layers. Missing optional imports may be absent;
|
||||||
|
operators use `required: true` for essential inputs. Invalid declarations,
|
||||||
|
unreadable selected files, and composition conflicts retain native errors.
|
||||||
|
|
||||||
|
Behavior when automatic discovery finds no file remains a separate open decision
|
||||||
|
below. This does not reopen the selected search order or import support.
|
||||||
|
|
||||||
|
### Migration Work
|
||||||
|
|
||||||
1. Move imports to `go.maximumdirect.net/configkit` with the coordinated
|
1. Move imports to `go.maximumdirect.net/configkit` with the coordinated
|
||||||
PromptKit cutover. Raise the toolchain as specified by the master roadmap.
|
PromptKit cutover. Raise the toolchain as specified by the master roadmap.
|
||||||
Replace `Resolution.Record` uses with the appropriate dedicated recording
|
Replace `Resolution.Record` uses with the appropriate dedicated recording
|
||||||
@@ -51,8 +79,8 @@ and [configuration contract](https://forge.maximumdirect.net/base-layer/configki
|
|||||||
6. Apply the resolved [PromptKit ownership decision](promptkit.md#backend-and-credential-ownership--resolved):
|
6. Apply the resolved [PromptKit ownership decision](promptkit.md#backend-and-credential-ownership--resolved):
|
||||||
remove Audita's separate backend mapping and LLM credential references from
|
remove Audita's separate backend mapping and LLM credential references from
|
||||||
its application schema. Native PromptKit resources own those settings and
|
its application schema. Native PromptKit resources own those settings and
|
||||||
their resolution. Coordinate the hard cutover and examples here; file discovery
|
their resolution. Coordinate the hard cutover and examples here, using the
|
||||||
and import selection remain open, without reopening semantic ownership.
|
resolved discovery and import policy above.
|
||||||
|
|
||||||
## Documentation and Acceptance
|
## Documentation and Acceptance
|
||||||
|
|
||||||
@@ -69,6 +97,11 @@ coverage for generic grammar rather than copying its test matrix. Verify the
|
|||||||
standard ckconfig surface through the assembled CLI and run the full application
|
standard ckconfig surface through the assembled CLI and run the full application
|
||||||
suite at the coordinated migration boundary.
|
suite at the coordinated migration boundary.
|
||||||
|
|
||||||
|
Check explicit-file selection without fallback, native working/user/system
|
||||||
|
search precedence, and terminal errors for a selected invalid file. Verify
|
||||||
|
optional and required imports and peer-composition errors through Audita's
|
||||||
|
integration. Cover discovery exhaustion after its behavior is selected below.
|
||||||
|
|
||||||
The earlier passing configuration suite is useful baseline evidence, not proof
|
The earlier passing configuration suite is useful baseline evidence, not proof
|
||||||
that operators see unchanged semantics. Native semantics and clear migration are
|
that operators see unchanged semantics. Native semantics and clear migration are
|
||||||
the target; preserving incidental old output or validation order is not.
|
the target; preserving incidental old output or validation order is not.
|
||||||
@@ -81,22 +114,25 @@ requirement and the smallest integration boundary that satisfies it.
|
|||||||
|
|
||||||
## Open Decisions
|
## Open Decisions
|
||||||
|
|
||||||
### Discovery Locations and Import Selection
|
### No Configuration File Found
|
||||||
|
|
||||||
**Recommendation:** replace custom discovery with ConfigKit's supported search
|
**Recommendation:** use ConfigKit's optional-search behavior: continue with
|
||||||
API, then select documented paths and import options based on suite conventions.
|
embedded defaults, underlays, and explicit CLI settings, then validate what the
|
||||||
Evaluate the current system-only search and disabled imports rather than carrying
|
requested command needs. A missing main file alone should not prevent resource
|
||||||
them forward automatically. Native API adoption is agreed; the exact search
|
inspection or execution whose required inputs are otherwise supplied. Do not
|
||||||
locations and import defaults still need selection before changing operator
|
invent an implicit model/profile choice to make incomplete execution settings
|
||||||
behavior. Preserve explicit-path error evidence and distinguish optional from
|
pass validation. Define filesystem context explicitly where overlays or relative
|
||||||
required imports using native semantics.
|
resource inputs need it; do not infer a base from unsuccessful search candidates.
|
||||||
|
|
||||||
**Alternative:** configure the native API with two system locations and imports
|
This follows the native absent-main lifecycle and supports lightweight command
|
||||||
disabled if deployment requirements justify that source-selection policy. This
|
invocations. It requires clear errors for missing command-specific inputs and
|
||||||
limits discovery flexibility and must stand on its own merits; compatibility with
|
inspection that accurately shows that no main file was selected.
|
||||||
today's installations carries no weight. Conversely, enabling all
|
|
||||||
possible searches/imports without a selected convention can load unintended
|
**Alternative:** require a discovered configuration file for configuration-dependent
|
||||||
sources and is not required for full API adoption.
|
commands, while keeping help/version independent. This gives deployments a
|
||||||
|
mandatory configuration anchor, but rejects otherwise sufficient defaults and
|
||||||
|
CLI settings and adds a requirement without an identified domain need. Explicit
|
||||||
|
file errors remain terminal under either choice.
|
||||||
|
|
||||||
### Application Schema Version
|
### Application Schema Version
|
||||||
|
|
||||||
|
|||||||
@@ -81,8 +81,8 @@ checks whose purpose was enforcing the removed application backend registry.
|
|||||||
|
|
||||||
Remove superseded fields, code, and tests in the major-release cutover and update
|
Remove superseded fields, code, and tests in the major-release cutover and update
|
||||||
the affected policies and current contracts with implementation. The ConfigKit
|
the affected policies and current contracts with implementation. The ConfigKit
|
||||||
outline still owns decisions about file locations, discovery, and imports; those
|
outline owns file discovery and import policy; those choices govern how native
|
||||||
choose how native resources are supplied, not who owns their semantics.
|
resources are supplied, not who owns their semantics.
|
||||||
|
|
||||||
### Bundled Prompts and Operator Replacements — Resolved
|
### Bundled Prompts and Operator Replacements — Resolved
|
||||||
|
|
||||||
@@ -111,8 +111,8 @@ mechanism supports production customization. Standard inspection, provenance,
|
|||||||
and request preview must make effective prompts and their origins understandable.
|
and request preview must make effective prompts and their origins understandable.
|
||||||
Audita's response schemas and domain validation continue to apply.
|
Audita's response schemas and domain validation continue to apply.
|
||||||
|
|
||||||
External source selection remains part of the ConfigKit discovery/import
|
External source selection follows the [ConfigKit discovery/import plan](configkit.md).
|
||||||
decision. This workflow is required PromptKit adoption scope and should use
|
This workflow is required PromptKit adoption scope and should use
|
||||||
native composition rather than a separate prompt loader or override system.
|
native composition rather than a separate prompt loader or override system.
|
||||||
|
|
||||||
### Profile Inspection and Summary — Resolved
|
### Profile Inspection and Summary — Resolved
|
||||||
|
|||||||
Reference in New Issue
Block a user