Preserve composite ConfigKit provenance

This commit is contained in:
2026-10-04 13:34:27 +00:00
parent 428f435734
commit f1672f6f95
13 changed files with 200 additions and 145 deletions

View File

@@ -127,9 +127,11 @@ artifact key. Its tab-separated header is `key`, `source`, `definitions`,
`enabled`, `output`, `dependencies`, `family`, `character`, `family_source`, and
`party_source`. Definitions and effective dependencies are sorted comma-separated
lists, and control characters in fields are escaped. Family-member rows identify
their family, character, defining family file, and party file. An empty catalog
prints only the header. Ordinary artifacts can be inspected without a campaign;
party-driven families retain the campaign requirement. See
their family, character, contributing family source files, and party file.
Family source paths are comma-separated when ConfigKit reports a composite
origin. An empty catalog prints only the header. Ordinary artifacts can be
inspected without a campaign; party-driven families retain the campaign
requirement. See
[Scriptorium Artifact Entries](./config.md#scriptorium-artifact-entries) for the
configuration layout.

View File

@@ -67,7 +67,8 @@ not promised to be a reloadable authoring document. `config sources` prints a st
source projection instead of effective values: root/import/overlay/default
ownership plus campaign/party and generated-family records. Canonical derived
players trace to the party. `config artifacts` lists the concrete artifact map,
effective dependencies, and defining sources. The [CLI reference](cli.md#config-validate-config-show-config-sources-config-artifacts-and-config-diff)
effective dependencies, and definition contributor paths, which may identify
several files for one family member. The [CLI reference](cli.md#config-validate-config-show-config-sources-config-artifacts-and-config-diff)
owns command syntax and output conventions.
`config diff` compares normalized field values rather than YAML text or source

View File

@@ -74,7 +74,10 @@ commands do not marshal runtime objects directly.
`EffectivePipelineSources` and `EffectiveCampaignSources` provide the separate
safe provenance projection for `config sources`. Pipeline ownership begins with
the complete logical field paths projected from the schema and classifies
each contributor as root, import, overlay, or centralized default. The
each contributor as root, import, overlay, or centralized default. It reads
ConfigKit's effective origins and inheritance locations when building each
projection, so inherited values retain their contributors and controlling
directives without a second cached leaf-ownership table. The
projection replaces generated concrete member paths with paired family and
canonical-party records, and does the same for generated publish rules.
Campaign records identify campaign-owned fields and party inputs; canonical
@@ -84,8 +87,9 @@ records with selection metadata and never reparses configuration files.
`EffectiveArtifactCatalog` projects the same finalized concrete artifact map for
`config artifacts`. It derives source identity from each map key, carries sorted
effective dependencies, aggregates ConfigKit definition contributors, and adds
family/character/party provenance for generated members. It does not inspect
files named after artifacts or infer another runtime graph.
family/character/party provenance for generated members. Family source evidence
can name multiple contributing files. It does not inspect files named after
artifacts or infer another runtime graph.
`config diff` uses a thin paired loader that performs two independent ConfigKit
loads. When campaign
@@ -152,10 +156,8 @@ rediscovering additional conflicts.
The loaded pipeline retains private runtime metadata for the absolute root
path, ordered imports, selected overlay name, source, and path, original
ConfigKit metadata and source snapshots, effective digest,
and leaf ownership. Base
leaves retain their root/import owners, replaced leaves belong to the selected
overlay, and centrally supplied values use the synthetic `default` owner. This
ConfigKit metadata and source snapshots, and effective digest. Leaf source
records are projected from that retained native metadata when requested. This
metadata does not participate in YAML decoding or alter the public
configuration model.
@@ -179,8 +181,8 @@ for later runtime expansion.
## Test Surfaces
`pipeline_configkit_test.go` exercises real imports and fixed-path overlays,
base selection, unselected-overlay isolation, source attribution, and Narratio's
unique artifact/family base-declaration rule. Existing focused configuration
base selection, unselected-overlay isolation, source attribution, cross-file
inheritance, and effective composition. Existing focused configuration
tests protect defaults, explicit-value semantics, strict decoding, validation,
metadata, and root-relative path behavior. Application configuration-loader tests protect the
single-read boundary by changing the pipeline file after its initial load and

View File

@@ -140,7 +140,7 @@ Complete when valid cross-file composition/inheritance succeeds and invalid
effective configuration still fails before execution, without authored-source
acceptance gates. Keep native metadata available for the next stage.
## Stage 3: Simplify provenance inspection around native APIs
## Stage 3: Simplify provenance inspection around native APIs [x]
Purpose: preserve useful operator inspection without a parallel provenance
system or a unique-defining-file contract for composite entries.