Specify glossary authoring precedence and shared input cutover
This commit is contained in:
@@ -126,8 +126,8 @@ Campaign vocabulary may be supplied by an external `glossary_file`, an inline
|
|||||||
`glossary` collection with native `entries` and optional `instruction`, or both.
|
`glossary` collection with native `entries` and optional `instruction`, or both.
|
||||||
Use native ConfigKit import and composition semantics when both are supplied.
|
Use native ConfigKit import and composition semantics when both are supplied.
|
||||||
Both forms resolve to one campaign collection and share preparation, preflight,
|
Both forms resolve to one campaign collection and share preparation, preflight,
|
||||||
and execution paths. Finalize external-file wiring and native precedence in the
|
and execution paths. The authoring contract below defines their selection and
|
||||||
configuration contract; do not introduce a separate merge mechanism.
|
native precedence; do not introduce a separate merge mechanism.
|
||||||
|
|
||||||
Setting and system catalogs are configuration data mapping identifiers to
|
Setting and system catalogs are configuration data mapping identifiers to
|
||||||
reference sources, extensible without Go changes or a custom loader. Each
|
reference sources, extensible without Go changes or a custom loader. Each
|
||||||
@@ -171,9 +171,138 @@ data format rather than maintaining Audita prompt templates or validator rules.
|
|||||||
Notarius v0.9.0 adoption and upstream Notarius enhancements or feature requests
|
Notarius v0.9.0 adoption and upstream Notarius enhancements or feature requests
|
||||||
belong to a separate, subsequent roadmap. This scope establishes shared Narratio
|
belong to a separate, subsequent roadmap. This scope establishes shared Narratio
|
||||||
inputs without prescribing that every consumer accept all four collections.
|
inputs without prescribing that every consumer accept all four collections.
|
||||||
Reconcile existing uses of `glossary_file` and the monolithic glossary source
|
Apply the explicit input cutover below without silently reinterpreting downstream
|
||||||
explicitly in the implementation plan; do not silently reinterpret downstream
|
bindings or adding legacy format detection or conversion.
|
||||||
bindings or add legacy format detection or conversion.
|
|
||||||
|
### Glossary authoring and precedence
|
||||||
|
|
||||||
|
Use these fields in the new configuration contract:
|
||||||
|
|
||||||
|
| Scope | Field | Meaning |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| Application/pipeline | `reference_catalog.settings` | Map of setting IDs to entry-file paths. |
|
||||||
|
| Application/pipeline | `reference_catalog.systems` | Map of system IDs to entry-file paths. |
|
||||||
|
| Campaign/session | `inputs.setting` | Selected setting ID. |
|
||||||
|
| Campaign/session | `inputs.system` | Selected system ID. |
|
||||||
|
| Campaign/session | `inputs.glossary_file` | Optional external named-collection file supplying `campaign`. |
|
||||||
|
| Campaign/session | `inputs.glossary` | Optional inline collection supplying `campaign`. |
|
||||||
|
|
||||||
|
Resolve catalog paths and `glossary_file` relative to their defining sources,
|
||||||
|
including imported fragments. External files use the canonical named-collection
|
||||||
|
document shape, not a bare collection or a legacy glossary. Their native imports
|
||||||
|
remain relative to each declaring file. Resolve the complete file before selecting
|
||||||
|
its named collection so native inheritance can reference sibling definitions.
|
||||||
|
|
||||||
|
Session omission inherits each campaign field independently. An explicitly
|
||||||
|
supplied session field replaces that field's campaign selection: a session file
|
||||||
|
selection does not implicitly clear inherited inline vocabulary, and a session
|
||||||
|
inline collection replaces the campaign inline collection rather than silently
|
||||||
|
combining both. Explicit empty/null values retain native typed meaning and undergo
|
||||||
|
domain validation; they must not trigger fallback to the campaign value.
|
||||||
|
|
||||||
|
For the selected campaign vocabulary, use a separate native ConfigKit layered
|
||||||
|
load: the selected external file is the lower tier, with imports enabled; the
|
||||||
|
selected inline collection is the higher input mounted at `campaign`. Omit an
|
||||||
|
absent contribution. Register entry identity by `id` using ConfigKit's supported
|
||||||
|
sequence-identity API, matching Audita. Native default upsert replaces a matching
|
||||||
|
entry in full, retains unmatched file entries, and appends new inline identities.
|
||||||
|
Native explicit collection modes continue to govern composition; no Narratio
|
||||||
|
entry-merging or collision algorithm is added. Preserve ConfigKit errors.
|
||||||
|
|
||||||
|
This load produces a separate domain input, not a rewritten effective campaign
|
||||||
|
or session configuration. File selection and inline data remain visible through
|
||||||
|
their ordinary configuration views. Prepared inputs contain the resolved result.
|
||||||
|
|
||||||
|
The following abbreviated future configuration illustrates the contract; other
|
||||||
|
required Narratio settings are omitted. The installed catalog fragment contains:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
reference_catalog:
|
||||||
|
settings:
|
||||||
|
forgotten_realms: ./settings/forgotten_realms.yml
|
||||||
|
systems:
|
||||||
|
5e: ./systems/5e.yml
|
||||||
|
```
|
||||||
|
|
||||||
|
Pipeline configuration imports that fragment through native `config.imports`:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
config:
|
||||||
|
imports:
|
||||||
|
- path: ./reference-catalog/catalog.yml
|
||||||
|
required: true
|
||||||
|
```
|
||||||
|
|
||||||
|
Campaign configuration selects its entries and supplies local vocabulary:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
campaign_id: sample-campaign
|
||||||
|
inputs:
|
||||||
|
setting: forgotten_realms
|
||||||
|
system: 5e
|
||||||
|
glossary_file: ./vocabulary.yml
|
||||||
|
glossary:
|
||||||
|
entries:
|
||||||
|
- {id: watch, name: Silver Watch, category: organization}
|
||||||
|
```
|
||||||
|
|
||||||
|
`vocabulary.yml` may import relative fragments using `config.imports`; its
|
||||||
|
resolved collection could be:
|
||||||
|
|
||||||
|
```yaml
|
||||||
|
campaign:
|
||||||
|
instruction: Use established campaign names.
|
||||||
|
entries:
|
||||||
|
- {id: watch, name: Old Watch, category: organization, aliases: [Old]}
|
||||||
|
- {id: harbor, name: North Harbor, category: place}
|
||||||
|
```
|
||||||
|
|
||||||
|
The prepared campaign retains the instruction and harbor entry, and replaces
|
||||||
|
the complete watch entry with the inline Silver Watch record, including removal
|
||||||
|
of the old alias. A session setting `inputs.glossary` to
|
||||||
|
`{instruction: "Session context."}` replaces the campaign inline contribution:
|
||||||
|
the file's Old Watch and
|
||||||
|
North Harbor remain, with the session instruction. A session overriding only
|
||||||
|
`inputs.glossary_file` instead uses that file beneath the inherited Silver Watch
|
||||||
|
inline contribution. These are explicit field selections followed by native
|
||||||
|
layered composition, not an additional campaign/session merge policy.
|
||||||
|
|
||||||
|
### Shared input identities and cutover
|
||||||
|
|
||||||
|
Prepare each collection as a standalone named-collection document:
|
||||||
|
|
||||||
|
| Collection | Source ID | Prepared path |
|
||||||
|
| --- | --- | --- |
|
||||||
|
| `party` | `narratio.input.glossary.party` | `inputs/glossaries/party.yml` |
|
||||||
|
| `campaign` | `narratio.input.glossary.campaign` | `inputs/glossaries/campaign.yml` |
|
||||||
|
| `setting` | `narratio.input.glossary.setting` | `inputs/glossaries/setting.yml` |
|
||||||
|
| `spells` | `narratio.input.glossary.spells` | `inputs/glossaries/spells.yml` |
|
||||||
|
|
||||||
|
Register these identities with shared input resolution, manifest evidence,
|
||||||
|
preparation/reuse, publication, and restore handling. Keep paths under the shared
|
||||||
|
workspace owner. Only requested consumer projections add further input identities;
|
||||||
|
do not create a speculative combined-glossary artifact.
|
||||||
|
|
||||||
|
Retire `narratio.input.glossary` and its `inputs/glossary.yml` preparation contract.
|
||||||
|
Reprepare affected inputs and reconsider dependent semantic evidence under normal
|
||||||
|
rules; an old file or manifest record does not satisfy a new source identity.
|
||||||
|
Do not provide a source alias or automatically rewrite operator configuration.
|
||||||
|
Migration guidance must replace old source references explicitly and move authored
|
||||||
|
campaign vocabulary to the native inline or named-file contract.
|
||||||
|
|
||||||
|
For the currently supported Notarius integration, the existing text `glossary`
|
||||||
|
slot can explicitly bind `narratio.input.glossary.campaign`; Narratio supplies its
|
||||||
|
prepared YAML as text through the existing reference mechanism. Update maintained
|
||||||
|
bindings accordingly. This does not introduce new Notarius slots or adopt v0.9.0.
|
||||||
|
Scriptorium bindings likewise select the new collection IDs explicitly; prompt
|
||||||
|
authors must update any expectations of the old content shape. Consumer-local
|
||||||
|
binding names such as `glossary` need not change when their source ID changes.
|
||||||
|
|
||||||
|
`narratio.input.party` and `narratio.input.players` retain their richer roster and
|
||||||
|
player contracts. `inputs.spell_catalog_file` and `narratio.input.spell_catalog`
|
||||||
|
retain the current structured Notarius spell-overlay contract until that separate
|
||||||
|
adoption addresses it. The new `spells` glossary is not a replacement for that
|
||||||
|
different input, and this roadmap adds no conversion between them.
|
||||||
|
|
||||||
### Canonical glossary format
|
### Canonical glossary format
|
||||||
|
|
||||||
@@ -368,9 +497,9 @@ and their omission semantics.
|
|||||||
Prepare and record all four glossary collections under the shared input/path
|
Prepare and record all four glossary collections under the shared input/path
|
||||||
owners. Bind polish's required inputs and semantic
|
owners. Bind polish's required inputs and semantic
|
||||||
evidence to the prepared content it actually consumes. Keep generated glossary
|
evidence to the prepared content it actually consumes. Keep generated glossary
|
||||||
data separate from immutable resolved Narratio configuration. Final filenames,
|
data separate from immutable resolved Narratio configuration. Use the authoring
|
||||||
projection details, and schema fields belong in the implementation plan once
|
fields, source identities, and prepared paths above. Package mechanics and any
|
||||||
the remaining configuration-contract choices are resolved. Use shared resolution/projection
|
additional consumer projections belong in the implementation plan. Use shared resolution/projection
|
||||||
helpers and reuse prepared content between preflight and execution rather than
|
helpers and reuse prepared content between preflight and execution rather than
|
||||||
independently rebuilding it for each path.
|
independently rebuilding it for each path.
|
||||||
|
|
||||||
@@ -431,6 +560,11 @@ debug selection, and shared credential forwarding. Cover empty selections,
|
|||||||
ordered/repeated processing where applicable, and native root/per-entry selector
|
ordered/repeated processing where applicable, and native root/per-entry selector
|
||||||
precedence without inventing a Narratio precedence rule.
|
precedence without inventing a Narratio precedence rule.
|
||||||
|
|
||||||
|
Exercise the authoring example's relative imports, whole-record entry upsert,
|
||||||
|
and independent session field replacements through ConfigKit. Verify the retired
|
||||||
|
monolithic source is not aliased, the four new source bindings resolve prepared
|
||||||
|
manifest evidence, and retained roster/player/spell-overlay contracts stay intact.
|
||||||
|
|
||||||
Cover party IDs/names/aliases in the native projection, separate collection
|
Cover party IDs/names/aliases in the native projection, separate collection
|
||||||
preservation, inline/file campaign vocabulary, setting/system selection,
|
preservation, inline/file campaign vocabulary, setting/system selection,
|
||||||
preparation failures, and standalone
|
preparation failures, and standalone
|
||||||
@@ -524,10 +658,9 @@ calls remain explicit integration runs, not ordinary catalog tests.
|
|||||||
|
|
||||||
## Open Decisions
|
## Open Decisions
|
||||||
|
|
||||||
The catalog model, configuration ownership, session overrides, shared glossary
|
The catalog model, authoring fields, native file/inline composition, session
|
||||||
format, and inline/file campaign vocabulary are settled. Finalize the concrete
|
selection behavior, and shared input cutover are settled. The minimal catalog
|
||||||
configuration fields and external-file import wiring with the minimal catalog
|
bundle and canonical schema still need to be authored and checked against the
|
||||||
bundle, including native precedence when both campaign vocabulary forms are
|
contract above. Package mechanics, schema packaging, and any demonstrated
|
||||||
present. Identify the explicit cutover for existing glossary fields and source
|
consumer-specific projections belong in implementation planning, not further
|
||||||
IDs without expanding this scope into Notarius adoption. Exact prepared filenames
|
product-scope decisions.
|
||||||
and package-level mechanics belong in the implementation plan.
|
|
||||||
|
|||||||
Reference in New Issue
Block a user