"in source order." ConfigKit distinguishes acquisition/import declaration order
from dependency-ready assembly order. Ready contributions are selected by their
stable source keys, so independent branches can interleave. The feature roadmap
and Stage 8 correctly rely on dependency-ready assembly rather than a Notarius
append pass.
An offline CLI probe declared imports in the order `z-first.yml`, then
`a-second.yml`, each contributing a different step and lane. Effective output
placed the step from `a-second.yml` first, then the step from `z-first.yml`.
Thus declaration order does not determine the resulting step list. This matters
because Notarius executes steps in the resolved list order and validates their
generated-reference dependencies.
Required changes:
- Replace the source-order claim with the native dependency-ready assembly rule
and link to ConfigKit v1.2.0's pinned composition contract for its full ordering
semantics. Do not promise declaration order or duplicate the upstream scheduler.
- Explain briefly why the maintained complete example's imported describe-session
step precedes the importing body's extract-events step: the imported dependency
is assembled before its importer. Keep the canonical operator rule in
`docs/config.md`; other documentation should link rather than redefine it.
Acceptance: the reference does not imply that reordering independent import
declarations necessarily reorders steps. The complete example's actual step
order and generated-reference handoffs remain unchanged. No custom sorting,
merging, or scheduler changes belong in this remediation.
### Stage-By-Stage Review Evidence
| Stage | Review result |
| --- | --- |
| 1 — Dependencies/toolchain | The selected graph builds with Go 1.27.0, both approved ConfigKit versions, PromptKit v0.12.0, and YAML rc.6; tidy reports no diff. |
| 2 — API/handoff | Application imports use the new package, old types remain in the PromptKit boundary, and LoadSource/MainSourcePath retain frozen inspection and detached runtime values. |
| 3 — Normalization/origins | Paths resolve before key movement; unchanged step identities retain leaf records, changed identities retain covering structural records. Existing tests and an additional temporary combined key/path-normalization probe pass. |
| 4 — Collections | The exact step-only identity registration delegates composition to ConfigKit. Real-file tests cover imports, upsert, replace, append, clearing, and source-relative references. Identified-record inheritance is checked only at loading/configuration validation; CK-3 records the missing runtime-consumer check. |
| 5 — Fixtures | Application fixtures use native controls and assignment timing; old PromptKit fixtures remain correctly scoped. The full suite passes. |
| 6 — CLI discovery | The shared loader describes File/SearchConfig sources once and returns the recorded selected file. Manual probe helpers are removed. |
| 7 — Discovery/failures | Controlled tests cover precedence, filename selection, required exhaustion, terminal failures, reports, symlinks, and debug provenance without relying on host system files. |
| 8 — Examples | Minimal, complete, and development pipelines validate without inference; the supporting fragment preserves module choices, step order, and handoffs. |
| 9 — Operator docs | Search, controls, path bases, CLI timing, and toolchain guidance are updated. CK-1 and CK-2 remain. |
| 10 — Internal/integration docs and notices | The mixed dependency boundary and pinned ConfigKit attribution match the selected graph. Accepted ADRs, policy, and project license/grant were not modified by the sprint. |
| 11 — Final verification | Full tests, vet, tidy, native build, dependency inspection, and provider-free validation/effective/explanation commands pass. The final documentation review missed CK-1 and CK-2. |
### ConfigKit Review Validation
-`GOTOOLCHAIN=go1.27.0 GOWORK=off go test ./...` passed.
-`GOTOOLCHAIN=go1.27.0 GOWORK=off go vet ./...` passed.
-`GOTOOLCHAIN=go1.27.0 GOWORK=off go test -race ./internal/core/config ./internal/cli` passed.
-`GOTOOLCHAIN=go1.27.0 GOWORK=off go mod tidy -diff` produced no changes.
- A native build in a temporary directory succeeded. Minimal, complete, and
development configuration validation, plus application and PromptKit effective
and explanation reports, succeeded without provider calls.
- Selected module inspection confirmed the four approved ConfigKit, PromptKit,
and YAML versions. Pinned local upstream documentation and notices were checked.
- Temporary fixtures outside the repository reproduced both documentation gaps
and verified combined identifier/reference-path normalization. No production
pipeline, credential lookup, or live model-quality evaluation was performed.
- The review document passed `git diff --check`; production code and current
operator documentation were not changed by this review.
Keep the earlier PromptKit findings separate from these two documentation fixes.
The deferred PromptKit/ConfigKit v1.2.1 upgrade and release work remain out of scope.
checkpoint identity, and CLI debug/output consumers.
-`GOTOOLCHAIN=go1.27.0 GOWORK=off go test ./internal/core/config ./internal/cli ./internal/framework/llm ./internal/framework/pipeline ./internal/modules/integration`
passed. This includes the maintained complete-example run, generated-reference
handoffs, command overrides, selected-path debug provenance, and profile reports.
- Temporary CLI fixtures outside the repository reproduced both step-inheritance
failures and verified the compatible validator-record alternative. An additional
author-identified validator list with whitespace-normalized module names also
passed pipeline validation.
- The full-suite, vet, race, tidy, and build results from the preceding review
remain applicable to the unchanged implementation. No live provider call or
missing-source/non-file fallback, absolute-path, and empty-cache behavior.
Memoization should reuse the native immutable source evidence without changing
source acquisition or application path policy.
- Reuse the existing path-origin and ownership tests. Verify the lookup is shared
across paths from one source and remains distinct across sources; no elapsed-time
assertion, real-world benchmark, new input limit, or release gate is warranted.
Acceptance: paths from the same source no longer repeatedly clone its unrelated
import-selection evidence. Runtime paths, inspection results, and load isolation
remain unchanged. This is a bounded optimization opportunity, not a correctness
failure or a claim that ordinary inference runs will become materially faster.
For sources with no empty selections, the current lookup cost is already small.
### Stage-By-Stage Algorithmic Assessment
| Stage | Assessment |
| --- | --- |
| 1 — Dependencies/toolchain | The mixed released graph is an approved choice; no new Notarius runtime algorithm was introduced here. |
| 2 — API/handoff | LoadSource is a single delegation. MainSourcePath makes one source-metadata snapshot and scan, linear in that snapshot's size, rather than repeating discovery. CK-4 concerns repeated callback lookups, not this one-time accessor. |
| 3 — Normalization/origins | Local passes visit each contained pipeline, step, lane, validator, and reference a bounded number of times. Deterministic key sorting costs `O(k log k)` per map. CK-4 identifies a hidden multiplicative snapshot cost inside those traversals. |
| 4 — Collections | Identity registration delegates to the selected native algorithms. No application-side step matcher, concatenation loop, or quadratic merge was added. |
| 5 — Fixtures | Mechanical fixture migration introduces no production algorithm. Previously recorded correctness/coverage findings remain separate. |
| 6 — CLI discovery | Source selection has a fixed number of local branches and native preset descriptions; manual probes were removed. Selected-source reporting is performed once. |
| 7 — Discovery/inspection coverage | The new tests exercise bounded cases; reports delegate to retained inspection. No extra load or source search was added for provenance. |
| 8 — Examples | The extra fragment uses native dependency ordering and does not add application composition machinery. |
| 9 — Operator docs | No runtime algorithm introduced. CK-1 and CK-2 already cover the relevant prose inaccuracies. |
| 10 — Internals/notices | No runtime algorithm introduced or new dependency-graph translation added. |
| 11 — Final verification | No production algorithm introduced; existing tests support correctness but do not establish complexity bounds. |
### Algorithmic Audit Evidence And Limits
- Inspected the production diff and traced traversal, original-path remapping,
recording, source lookup, and CLI handoff helpers through the code graph.
Nested collection loops traverse separate children rather than repeatedly
scanning one global collection. Original-path remapping is bypassed during the
pre-move path pass; its later worker-presence lookup has a fixed schema path.
- Inspected the exact ConfigKit v1.2.0 source for snapshot ownership costs. Its
record aggregation uses indexed reason/dependency sets, so repeated ancestor
recording was not misclassified as a quadratic scan.
- An offline temporary Go-overlay test verified that a single declaring-source
snapshot contains four empty optional-import records while multiple relative
reference paths normalize correctly. The probe passed; its files remain outside
the repository. No production code or repository tests were modified.
- Complexity conclusions come from source/data-flow analysis. No production
inference, timing benchmark, or real-world performance measurement was used.
Existing validation results remain applicable to the unchanged implementation.
No additional ordinary correctness bug was identified in this pass.