From 95aac6367fcc64da1e5aa361a36c72e944885c77 Mon Sep 17 00:00:00 2001 From: Eric Rakestraw Date: Fri, 27 Nov 2026 14:58:02 +0000 Subject: [PATCH] Define shared glossary inputs and canonical schema ownership --- docs/roadmap/audita.md | 90 ++++++++++++++++++++++++++++++++++-------- 1 file changed, 73 insertions(+), 17 deletions(-) diff --git a/docs/roadmap/audita.md b/docs/roadmap/audita.md index d6ca8bf..24c97d1 100644 --- a/docs/roadmap/audita.md +++ b/docs/roadmap/audita.md @@ -100,7 +100,7 @@ ConfigKit owns generic resolution, imports, inheritance, and composition through its native workflow. Audita owns final composition with its configuration, interpretation of the supplied collections, and processing. -Narratio supplies four separate logical collections: +Narratio prepares four shared domain collections and supplies all four to Audita: | Collection | Source and preparation | | --- | --- | @@ -109,6 +109,26 @@ Narratio supplies four separate logical collections: | `setting` | Select and prepare reference vocabulary from a catalog using a setting ID, such as `forgotten_realms`. | | `spells` | Select and prepare spell vocabulary from a catalog using a system ID, such as `5e`. | +These collections cover the anticipated vocabulary needs. Other subprocesses +may consume subsets or consumer-specific projections and combinations. Save all +prepared collections and projections as shared domain inputs with content +evidence, rather than private Audita-adapter files. Preserve named collections +where the consumer supports them; add a projection only for a demonstrated +consumer need, without a generic projection framework. + +Catalog definitions belong in application/pipeline configuration, supplied by +the installed catalog's importable fragment. Campaign configuration selects the +setting, system, and campaign vocabulary. Session configuration may override +those choices through the existing campaign/session input model; omission +inherits the campaign choice. + +Campaign vocabulary may be supplied by an external `glossary_file`, an inline +`glossary` collection with native `entries` and optional `instruction`, or both. +Use native ConfigKit import and composition semantics when both are supplied. +Both forms resolve to one campaign collection and share preparation, preflight, +and execution paths. Finalize external-file wiring and native precedence in the +configuration contract; do not introduce a separate merge mechanism. + Setting and system catalogs are configuration data mapping identifiers to reference sources, extensible without Go changes or a custom loader. Each identifier selects one entry file; that file may use native ConfigKit imports @@ -148,10 +168,40 @@ remains in the repair conversation. Preserve operator-supplied instructions; domain guidance can live in the selected recipe. Narratio supplies the native data format rather than maintaining Audita prompt templates or validator rules. -Keep the shared `glossary_file` and its preparation available to other consumers, -including Notarius. This adoption changes polish's handoff explicitly; it does -not implicitly change those other integrations or promise one file format for -every downstream application. +Notarius v0.9.0 adoption and upstream Notarius enhancements or feature requests +belong to a separate, subsequent roadmap. This scope establishes shared Narratio +inputs without prescribing that every consumer accept all four collections. +Reconcile existing uses of `glossary_file` and the monolithic glossary source +explicitly in the implementation plan; do not silently reinterpret downstream +bindings or add legacy format detection or conversion. + +### Canonical glossary format + +The reference-catalog repository owns the canonical interchange format document, +a versioned JSON Schema (for example, `schemas/glossary-v1.schema.json`), and +small valid and invalid examples. Narratio owns source selection, preparation, +and projection behavior and links to that format contract. A common format is +the intended basis for reuse across consumers; each consumer still owns its +interpretation and processing rules. + +Start with Audita's existing wrapperless mapping of collection names to +collections. Define a reusable collection schema with `entries` and optional +`instruction`; entries retain native `id`, `name`, `category`, optional fields, +and supported extensions. Reuse that schema for inline campaign vocabulary, +individual collections, and documents containing multiple collections. The four +Narratio roles do not restrict the names allowed by the general format schema. + +Validate decoded YAML data against JSON Schema after ConfigKit resolves imports, +inheritance, and composition. Do not require every authored fragment to satisfy +the complete-document schema. Integrate validation with shared acquisition and +preparation paths using existing library capabilities. Retain semantic checks +where needed, such as entry-ID uniqueness within a collection; schema validity +alone does not establish processing readiness. + +Version the format separately from vocabulary releases. Identify the format +through its schema identity and documented contract, without inserting a +top-level version field into Audita's collection mapping. Consumers use a pinned, +locally available schema rather than fetching it during execution. ### D&D recipes and operator readiness @@ -352,10 +402,12 @@ ordered/repeated processing where applicable, and native root/per-entry selector precedence without inventing a Narratio precedence rule. Cover party IDs/names/aliases in the native projection, separate collection -preservation, setting/system selection, preparation failures, and standalone +preservation, inline/file campaign vocabulary, setting/system selection, +preparation failures, and standalone snapshots from native imports and composition. Verify that preflight and polish -consume the same prepared vocabulary and unrelated shared glossary consumers -retain their existing inputs. Upstream owns the full native merge, instruction, and +consume the same prepared vocabulary and consumer bindings are changed only +through explicit input-contract changes. Verify the resolved schema contract +and saved projections at the shared input boundary. Upstream owns the full native merge, instruction, and inspection behavior; a representative controlled compatibility check is enough at Narratio's boundary. @@ -395,7 +447,8 @@ quality or live-provider readiness. ## Reference Catalog Distribution and Development The separate [narratio-reference-catalog repository][catalog] owns vocabulary, -catalog entries, source organization, attribution, and bundle release history. +catalog entries, the glossary format/schema, source organization, attribution, +and bundle release history. Narratio owns the catalog configuration contract, domain selection, projections, prepared inputs, and preflight. Audita owns native glossary interpretation. @@ -421,7 +474,8 @@ No submodule or Go workspace is required for the data repository. Develop the configuration contract and a minimal bundle together. The bundle should contain its catalog fragment, one setting entry, one system entry, and -representative vocabulary demonstrating native imports. Then exercise one +representative vocabulary demonstrating native imports, and the format schema +with validation examples. Then exercise one complete production path: selection, party/campaign preparation, all four prepared collections, and full Audita preflight. Expand reference content once that handoff works. Implementation stages belong in the subsequent plan. @@ -429,7 +483,8 @@ that handoff works. Implementation stages belong in the subsequent plan. Narratio's default tests use checked-in synthetic fixtures without sibling checkout dependencies. The catalog should have an offline compatibility check that loads its actual bundle through the supported configuration path and -checks the resulting collections against Audita's native contract. Controlled +checks the resulting collections against the pinned shared schema and Audita's +native contract. Controlled integration checks can exercise working checkouts before release; provider smoke calls remain explicit integration runs, not ordinary catalog tests. @@ -437,9 +492,10 @@ calls remain explicit integration runs, not ordinary catalog tests. ## Open Decisions -The catalog distribution and single-entry-file selection model are settled. -Before implementation planning, finalize the configuration contract shared with -the minimal catalog bundle: where catalog definitions and campaign selections -live, how campaign glossary terms are supplied, and whether sessions can override -those campaign choices. Use native ConfigKit semantics throughout. Exact prepared -filenames and package-level mechanics belong in the implementation plan. +The catalog model, configuration ownership, session overrides, shared glossary +format, and inline/file campaign vocabulary are settled. Finalize the concrete +configuration fields and external-file import wiring with the minimal catalog +bundle, including native precedence when both campaign vocabulary forms are +present. Identify the explicit cutover for existing glossary fields and source +IDs without expanding this scope into Notarius adoption. Exact prepared filenames +and package-level mechanics belong in the implementation plan.