Plan the ConfigKit and PromptKit adoption

This commit is contained in:
2026-11-21 19:25:05 +00:00
parent 320526d3fc
commit 946181a13e
2 changed files with 427 additions and 123 deletions

View File

@@ -1,8 +1,10 @@
# ConfigKit v1.4.0 and PromptKit v0.24.0 adoption
Status: agreed adoption direction; implementation pending. Prepared 2026-11-21.
This document defines the target and remaining work, not implemented behavior
or authorization to publish releases.
This document defines the desired target and accepted scope, not implemented
behavior or authorization to publish releases. The
[implementation plan](implementation.md) owns execution stages and completion
evidence.
## Purpose and ownership
@@ -108,9 +110,9 @@ Provide the narrow capability needed for the shared handler to enumerate native
inspection paths. `ckprompt` supplies PromptKit's `HistoricalPaths()` directly;
ckconfig uses metadata to describe the returned paths' presence and explicitness.
Ordinary whole-result scopes continue to enumerate their native metadata paths.
Choose the concrete Go shape during implementation planning, considering the
existing [View and provider contracts](../../integrations/ckconfig/contracts.go).
Do not turn this small capability into a parallel inspection model.
The [implementation plan](implementation.md#stage-2-separate-native-path-enumeration-from-metadata-lookup)
selects the narrow provider extension and preserves existing custom-provider
behavior. This capability is not a parallel inspection model.
Retain the existing CLI filters (`--under`, `--historical`, and `--explicit`) on
the supplied enumeration. Preserve native application paths, such as
@@ -135,9 +137,9 @@ discovery, explanations, source evidence, and comparison. Applications retain
configuration acquisition and selection; the adapter supplies standard CLI
integration and delegates domain operations to ConfigKit.
Design this adapter together with the shared native path-enumeration capability.
Demonstrate one application section, such as storage settings, in the maintained
composed example. The section name is illustrative, not a new reserved scope.
The adapter shares the native path-enumeration capability. The maintained
composed example demonstrates one application section, such as storage settings.
The section name is illustrative, not a new reserved scope.
Preserve load diagnostics and error evidence through existing reporting and
outcome conventions. A focused inspection does not independently validate a
subtree or make whole-load evidence local to it.
@@ -173,8 +175,8 @@ this adoption. An options framework is unnecessary for the single path argument.
PromptKit uses the shared inspection capability directly. It need not pass
through this new helper if that would require converting its public inspection
type merely to fit the helper. The accepted API and evidence direction is recorded
in OD-2 below; exact declaration and internal factoring are implementation-plan
details within that direction.
in OD-2 below; the [implementation plan](implementation.md) owns the exact
declaration and internal factoring within that direction.
### Existing commands expose the new upstream evidence
@@ -192,118 +194,45 @@ implementation. Existing projections, such as requirements reports, should retai
the meaning of the updated native results. Hash semantics, schema resolution,
repair behavior, and error identities remain upstream-owned.
## Work needed
## Compatibility and delivery
### Dependency and configuration migration
The adopted configuration uses native `/promptkit` locations for complete
settings documents and inspection paths; resource IDs retain their names.
Wrapperless fragments and collection fragments use the corresponding upstream
input helpers. Removed schema options are replaced by supported inline,
source-relative, or explicit-root selection. The upstream migration and format
references above own their exact rules. Successful construction alone is not
migration evidence: old root-level resources can become application data while
disappearing from PromptKit catalogs.
1. Update both integration module graphs to ConfigKit v1.4.0 and ckprompt to
PromptKit v0.24.0. Tidy checksums and review the resulting graph. Update
affected root and module-local attribution entries and pinned source links
under the [OSS policy](../policy/oss.md).
2. Move complete-document PromptKit settings beneath `promptkit`. Use
`SettingsInput` for wrapperless settings fragments and `CollectionInput` for
collection fragments where appropriate. Discovery inputs remain root-mounted
unless the application sets their destination. Migrate fixture paths,
configuration overrides, and report assertions to the native locations;
resource IDs themselves do not gain a `promptkit` prefix.
3. Replace removed `Config.SchemaDir`, `WithSchemaFS`, and `WithSchemaFile` uses
with the applicable upstream configuration and resource contexts. Schema
selection supports inline values, source-relative `schema_file`, and
`schema_path` under an explicit applicable `schema_root`, including collection
roots. There is no implicit working-directory root. Follow upstream's
self-contained-schema rules rather than implementing resolution locally.
4. Update affected builders or examples from `*OutputContract` to
`*OutputContractInput` for `RunRequest.Validation`. Preserve whole-contract
replacement. Omitted/null repair budgets resolve to one for `basic`, `json`,
and `json_schema`, and zero for `none`; explicit zero disables repair.
Do not silently force the previous default in the integration. Document the
possible extra generation call, latency, and usage for application execution.
5. Account for `PromptOutputInspection.RepairAttempts` becoming a resolved
integer. Preserve native zero values and new schema fields in reports.
Applications own resource-version policy and sensitivity of extension fields;
do not recreate removed PromptKit validation in CommandKit.
Request builders use the upstream input contract for validation replacements,
including optional repair budgets. Native resolved repair budgets, including
zero, and schema/hash evidence reach reports without a local substitute.
The upstream enabled repair default may add a generation call, latency, and
usage to application execution. Applications retain resource-version policy and
sensitivity decisions for their extension fields. The adoption also retains the
intervening PromptKit timeout and cancellation identity corrections.
Old root-level resources can be accepted as application data while disappearing
from PromptKit catalogs. Migration verification must therefore check selected
resources and reports, not just successful engine construction.
Canonical GoDoc, CLI, consumer, developer, internal, and candidate release
guidance should agree with the completed integration. The maintained composed
example demonstrates shared loading and the native subtree adapter. Validation
protects CommandKit's acquisition, selection, adaptation, reporting, and outcomes;
upstream libraries own validation of their domain algorithms. Tests remain
offline and credential-independent.
### Adapter and example work
The independently versioned integration releases explain the changed provider
API and breaking PromptKit migration under the [release policy](../policy/release.md).
The coordinated target is released ckconfig followed by ckprompt selecting that
release, with the downstream integration advancing at least its minor version.
The [release runbook](../release.md) owns preparation and publication operations.
Local workspace validation and isolated checks with a local dependency are
identified separately from independent validation against released requirements.
Any remaining release coordination stays recorded until completed.
- Implement the accepted result-loader-plus-path API and scoped enumeration
through the shared configuration provider boundary together. Reuse existing
acquisition, diagnostics, comparison, and outcome conventions where they serve
the native capability; finalize the declaration and factoring in the plan.
- Wire PromptKit's native enumeration directly through the shared capability;
avoid an extra conversion layer solely to reuse the new adapter.
- Demonstrate registration and inspection of one application subtree, including
comparison and preservation of available diagnostics on failure.
- Restructure the composed example around the shared load, with local fixtures
and the existing injected client for smoke demonstrations. Update its consumer
walkthrough and meaningful tests together.
- Retain error causes, independent diagnostics, and available report evidence
through existing classification and delivery paths. The included v0.23.3
timeout/cancellation corrections should flow through without a local substitute.
- Replace the removed-schema-option fixture with a supported fixture for the
failure-classification behavior it was testing. Schema-file reads now occur
during preparation; do not preserve an obsolete constructor failure merely
to keep that test's shape.
### Documentation and release preparation
Update the canonical owners as implementation lands: exported GoDoc for changed
provider capabilities, [CLI reference](../cli.md) for scoped paths and reports,
[consumer guide](../consumers/guide.md) for shared loading and migration,
[developer guidance](../development.md) for working examples and dependency
alignment, and internal documentation where mechanics change. Link upstream
for its formats and rules rather than maintaining another schema reference.
Prepare integration release notes that identify the breaking PromptKit migration
and any changed ckconfig provider API. Select independent versions under the
[release policy](../policy/release.md); publish ckconfig before ckprompt, then
select that released ckconfig in ckprompt. The downstream integration release
advances at least its minor version under the existing alignment policy.
No core release is needed solely for this adoption. Unrelated core work, including
the optional Scriptorium proposal, is not a prerequisite.
During development, use the aligned workspace to exercise both local integration
changes. Validate ckconfig independently against its published dependencies;
after ckconfig publication, validate ckprompt independently against that release.
Follow the [release runbook](../release.md) for candidate preparation and
publication rather than introducing a separate process or new release gates.
## Validation and completion checklist
Use the [testing policy](../policy/testing.md): test CommandKit's adaptation and
operator behavior, not upstream domain algorithms. Extend existing coverage
where sufficient; compare meaningful report values rather than incidental YAML
layout or hash literals. Tests remain offline and credential-independent.
- [ ] Both integration graphs and affected attribution select the target releases.
- [ ] Configuration fixtures and maintained examples use the new layout and
supported schema APIs; expected resources remain discoverable.
- [ ] The composed example demonstrates application-owned shared loading through
existing callbacks, including distinct comparison selections.
- [ ] Scoped path enumeration uses upstream's listing; existing CLI filters and
metadata descriptions still work. A representative whole-load sibling verifies
that the adapter does not substitute full metadata enumeration.
- [ ] The public ckconfig adapter exposes a native subtree through the standard
scope commands using the ordinary typed loader and an explicit path, with a
maintained example and focused coverage of acquisition, native comparison, and
whole-load diagnostics/error propagation. Its public handoff is documented.
- [ ] Explicit paths, source evidence, focused rendering, and comparison preserve
native meaning and error handling, including available ancestor evidence.
- [ ] Reports preserve returned schema fields, repair-budget zero, and the new
message-content hash. Requirements projections preserve updated native evidence.
- [ ] Request-builder replacements and supported failure fixtures use the new
public APIs; error identity and existing outcome behavior remain covered at
CommandKit's boundary.
- [ ] Run each affected module's default suite independently and the aligned
workspace suites using the developer guide. Record any interim dependency
limitation honestly; workspace success alone is not independent-module evidence.
- [ ] Canonical documentation, upgrade guidance, and candidate notes match the
implemented result; validate local links and documentation diffs.
- [ ] Prepare and, when authorized, release ckconfig then ckprompt according to
the runbook; record remaining coordination work until completed.
No core release is needed solely for this adoption. Unrelated core work,
including the optional Scriptorium proposal, is not a prerequisite. The
[implementation plan](implementation.md) owns dependency migration, focused
coverage, candidate preparation, validation commands, and completion records.
## Scope retained outside this adoption
@@ -344,10 +273,8 @@ arbitrary inspection views in this adoption. Supporting preselected views and
different root types would require a broader acquisition handoff and is not
needed for the selected application workflow.
## Planning readiness
## Execution status
No significant open decisions remain before preparing the implementation plan.
The plan should settle the exact Go declarations, shared enumeration capability,
internal factoring, example changes, and focused validation within the accepted
scope. These are engineering details, not additional product decisions or
authority to expand the contracts. Implementation and release work remain pending.
The [staged implementation plan](implementation.md) is ready. No significant
product decisions remain open. Implementation and release work remain pending;
the plan records their separate completion evidence within this accepted scope.