Plan the core and integration API migration
This commit is contained in:
@@ -10,6 +10,10 @@ This roadmap is the next implementation priority, before the remaining
|
||||
into an integration-author API initiative, rather than a private-helper cleanup.
|
||||
The document is a plan; this pass changes no application code.
|
||||
|
||||
[Implementation Plan](implementation.md) owns the ordered implementation stages
|
||||
and stage-specific validation. This document owns scope, target behavior, and
|
||||
the accepted design decisions.
|
||||
|
||||
The selected goals are:
|
||||
|
||||
1. Make the boundary between Notarius core and integrations clear and well defined.
|
||||
@@ -250,96 +254,29 @@ existing connections where necessary. Native LLM validators retain their one-sho
|
||||
assessment role; sharing usability/evidence support does not enroll them in the
|
||||
producer correction lifecycle.
|
||||
|
||||
## Work From The Baseline
|
||||
## Required Change Surface
|
||||
|
||||
### 1. Define And Exercise The Author-Facing Contract
|
||||
|
||||
- Inventory production and programmatic callers of the current producer/outcome
|
||||
helpers, typed operation requests/results, registration, and preparation.
|
||||
- Turn the accepted operation, evaluation-result, and correction-request designs
|
||||
into concrete API sketches for spell extraction, registry normalization, and a
|
||||
no-model branch. Include scene-plan interpretation that requests correction
|
||||
before a candidate can be materialized.
|
||||
- Exercise those same designs with email and NWS Forecast Discussion processing
|
||||
sketches. Check source/chunk inputs, domain metadata, result interpretation,
|
||||
correction guidance, and optional reconciliation for D&D assumptions before
|
||||
finalizing Go signatures. Keep format-specific decisions with the future integrations.
|
||||
- Specify which inputs are operation-owned or borrowed, which implementations
|
||||
are reused concurrently, and the lifetime of optional evidence hooks. Document
|
||||
actual behavior without promising arbitrary collaborator thread safety or
|
||||
prohibiting reasonable per-operation state.
|
||||
- Show how ordinary use avoids exposed assessor/cache replacement and terminal
|
||||
helper selection. Identify which existing types can be reused and which should
|
||||
become private or be replaced. Exact helper names/files are implementation choices.
|
||||
|
||||
This is an implementation design step, not a separate approval ceremony or a
|
||||
requirement to create a large specification before trying representative callers.
|
||||
|
||||
### 2. Establish Core-Owned Execution
|
||||
|
||||
- Implement core invocation of integration preparation and consumption of the
|
||||
returned typed operation. Adapt stage interfaces, registration/preparation, and
|
||||
runner completion where necessary, retaining the same core entry point for
|
||||
direct programmatic callers.
|
||||
- Implement explicit candidate evaluation results and replace parallel mutable
|
||||
candidate-associated state. Add the native correction convenience path and
|
||||
custom request builder on one shared request/execution mechanism.
|
||||
- Make deterministic completion, native execution, correctable interpretation,
|
||||
assessment, preparation dispositions, and supported fallback explicit paths
|
||||
owned by core. Separate candidate state from pending native capture state.
|
||||
- Keep existing cache, assessment, capture, and terminal helpers internally where
|
||||
they remain useful; replace their author-facing choreography, not merely names.
|
||||
- Integrate CAT-007's usability/detail correction and focused regressions.
|
||||
- Migrate one extractor and a no-model path end to end, including registration,
|
||||
capture, reuse, assessment, and final typed results. Private transitional adapters
|
||||
may help keep changes reviewable, but are not the completed authoring API.
|
||||
|
||||
### 3. Consolidate Reconciliation And Migrate Producers
|
||||
|
||||
- Build the shared reconciliation facility on the selected operation boundary.
|
||||
Move no-model/limit handling, current-proposal state, and common evidence/result
|
||||
assembly out of the three family procedures.
|
||||
- Migrate NPC, item, and location normalizers, retaining independent family
|
||||
expectations for identity, application, omissions, and fallback semantics.
|
||||
- Migrate all affected extractors and scene planning. Exercise combat-gated
|
||||
no-model branches and chunk-plan materialization/assessment/cache behavior.
|
||||
- Adapt deterministic stage completion as needed while preserving its ordinary
|
||||
one-production/assessment path. Do not force deterministic modules to declare
|
||||
model requests or reconciliation policies.
|
||||
- Keep one-shot model validation native, sharing the corrected usability boundary
|
||||
and any necessary evidence support without a new semantic retry mechanism.
|
||||
|
||||
### 4. Remove Superseded Plumbing And Teach The API
|
||||
|
||||
- Remove unused author-facing lifecycle fields, wrappers, and duplicate family
|
||||
state once callers have moved. Do not leave two competing supported authoring
|
||||
recipes simply to preserve the old internal arrangement.
|
||||
- Update [Module Internals](../internal/modules.md),
|
||||
[Pipeline Internals](../internal/pipeline.md), and
|
||||
[D&D Internals](../internal/dnd.md) alongside implementation. Update architecture
|
||||
ownership and record significant changed decisions through the existing ADR
|
||||
process, preserving accepted ADR bodies.
|
||||
- Supply one minimal working integration example and point to a richer registry
|
||||
example. Explain required/optional capabilities, no-model completion, domain
|
||||
guidance versus operational errors, fallback, concurrency, and evidence ownership.
|
||||
Prefer a small domain-neutral fixture for the introductory example, with D&D
|
||||
as the richer example, so learning the API does not require learning scene or
|
||||
registry semantics. No new demo application is needed.
|
||||
- Verify that the example can be understood without reading the core producer.
|
||||
Test actual registration/execution of the example where useful; do not add a
|
||||
subjective readability gate or a required external-author study.
|
||||
|
||||
### 5. Verify And Reassess The Audit
|
||||
|
||||
- Finish the relevant behavioral verification below and review remaining callers
|
||||
for old lifecycle composition that was merely relocated into integrations.
|
||||
- Reassess overlapping catalog entries against the resulting implementation.
|
||||
Record resolved, partially addressed, and remaining work with concrete evidence.
|
||||
- Resume the remaining audit remediation using that revised catalog. Completion
|
||||
of this roadmap does not require completing unrelated catalog work first.
|
||||
|
||||
These are coherent work units, not required release boundaries. Keep each unit
|
||||
reviewable and preserve working behavior during migration.
|
||||
- Author-facing typed stage contracts, registration, and core execution reflect
|
||||
preparation followed by core-owned production. The same executor serves
|
||||
registered and standalone callers. Deterministic work and preparation-limit
|
||||
dispositions have explicit paths without synthetic model requests.
|
||||
- Candidate evaluation, correction request construction, assessment, cache use,
|
||||
and evidence have clear owners. Candidate-associated information is replaced
|
||||
as one evaluation; native capture state is independent. Existing internal
|
||||
helpers may remain where useful, without requiring integrations to compose them.
|
||||
- Shared reconciliation connects existing neutral preparation, safety, and typed
|
||||
application mechanisms to the same lifecycle. The three registry families
|
||||
retain policy and diagnostics rather than duplicated coordination.
|
||||
- Affected extraction, scene planning, normalization, deterministic completion,
|
||||
and programmatic callers use the selected boundary. One-shot validators share
|
||||
native usability handling without acquiring a producer correction loop.
|
||||
- Module, pipeline, and D&D authoring guides describe the implemented API and
|
||||
its ownership and concurrency expectations. One minimal domain-neutral working
|
||||
example introduces the API; an existing registry provides the richer example.
|
||||
Architecture policy and significant ADR decisions reflect the resulting
|
||||
ownership while preserving accepted ADR bodies.
|
||||
- Superseded authoring plumbing is removed, and overlapping audit findings have
|
||||
evidence-based statuses. Unrelated audit remediation remains separate work.
|
||||
|
||||
## Verification And Completion Evidence
|
||||
|
||||
@@ -384,12 +321,12 @@ family tests. Simplify tests coupled to retired plumbing; do not derive expected
|
||||
domain outputs from the same helper under test. This is a coverage guide, not a
|
||||
new test for every row or an exhaustive cross-product requirement.
|
||||
|
||||
Run focused checks while iterating, then the repository's offline full tests,
|
||||
vet, and build for the shared-contract migration, with focused race checks for
|
||||
changed concurrency paths. Follow [Testing Policy](../policy/testing.md) and
|
||||
[Development](../development.md#validation). No paid inference, benchmark target,
|
||||
coverage percentage, or new release gate is required. This planning pass has not
|
||||
run those implementation checks.
|
||||
The [Implementation Plan](implementation.md) assigns focused and final checks
|
||||
under [Testing Policy](../policy/testing.md) and
|
||||
[Development](../development.md#validation). Completion evidence includes offline
|
||||
full tests, vet, build, and focused race checks for changed concurrency paths.
|
||||
No paid inference, benchmark target, coverage percentage, or new release gate is
|
||||
required. This planning pass has not run those implementation checks.
|
||||
|
||||
The roadmap is complete when affected production integrations use the selected
|
||||
API, ordinary authors no longer compose the shared lifecycle, obsolete paths are
|
||||
|
||||
Reference in New Issue
Block a user