Complete minimal D&D extraction cutover
This commit is contained in:
@@ -1,6 +1,6 @@
|
||||
# ADR-0009: Prefer minimal evidence-grounded extraction artifacts
|
||||
|
||||
**Status:** Proposed
|
||||
**Status:** Accepted
|
||||
**Date:** 2026-07-22
|
||||
|
||||
## Context
|
||||
|
||||
@@ -110,8 +110,8 @@ combines overlapping cited ranges once in document order and compares actors
|
||||
with the shared Unicode-aware NPC identity policy.
|
||||
|
||||
The production D&D registrar exposes the extractor and these validators. Its
|
||||
default extraction chain preserves this order: JSON syntax, private response
|
||||
schema, combat shape, source references, then source relatedness.
|
||||
default extraction chain preserves this order: JSON syntax, combat shape,
|
||||
source references, private response schema, then source relatedness.
|
||||
|
||||
## Normalization boundary
|
||||
|
||||
@@ -143,8 +143,8 @@ with `invalid_combat_turn_normalization` under policy
|
||||
`dnd.combat_turns.validator.normalized.v1`.
|
||||
|
||||
The production D&D registrar exposes the normalizer and normalized-invariants
|
||||
validator. Its default normalization chain is JSON syntax, durable schema,
|
||||
combat shape, normalized invariants, source references, then source
|
||||
validator. Its default normalization chain is JSON syntax, combat shape,
|
||||
normalized invariants, source references, durable schema, then source
|
||||
relatedness. The lane uses the framework's typed append-order merger and has no
|
||||
merge validator chain.
|
||||
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
This document defines the durable D&D NPC-list artifact, its JSON codec, and
|
||||
the selectable production NPC pipeline. The normalized JSON payload can be
|
||||
passed explicitly to the spell extractor as an optional caster-name registry
|
||||
or to the combat extractor and normalizer as an actor/target registry. It
|
||||
or to the combat extractor and normalizer as an actor registry. It
|
||||
remains a reference, not spell or combat evidence.
|
||||
|
||||
## Identity
|
||||
@@ -81,12 +81,13 @@ by source evidence. Groups, generic roles, invented labels, and descriptive or
|
||||
relationship enrichment are outside the contract.
|
||||
|
||||
The default extraction chain is `generic/valid_json`,
|
||||
`generic/valid_json_schema`, `extract/dnd/npcs/shape`,
|
||||
`extract/dnd/npcs/source_refs`, and
|
||||
`extract/dnd/npcs/source_relatedness`. The normalize chain adds
|
||||
`normalize/dnd/npcs/identity` before the source-reference and relatedness
|
||||
checks. Relatedness emits bounded warnings when an NPC canonical name is not
|
||||
present near its cited transcript text; opaque campaign
|
||||
`extract/dnd/npcs/shape`, `extract/dnd/npcs/source_refs`,
|
||||
`generic/valid_json_schema`, and `extract/dnd/npcs/source_relatedness`. The
|
||||
default normalize chain is `generic/valid_json`, `extract/dnd/npcs/shape`,
|
||||
`normalize/dnd/npcs/identity`, `extract/dnd/npcs/source_refs`,
|
||||
`generic/valid_json_schema`, and `extract/dnd/npcs/source_relatedness`.
|
||||
Relatedness emits bounded warnings when an NPC canonical name is not present
|
||||
near its cited transcript text; opaque campaign
|
||||
references may explain such a warning but do not become evidence.
|
||||
|
||||
## Manifest And Artifact Handoff
|
||||
|
||||
@@ -140,6 +140,11 @@ chain, the catalog validator rejects the candidate with `unknown_spell`; the
|
||||
explicit validator override that accepts the candidate promotes the unresolved
|
||||
warning normally.
|
||||
|
||||
The default extraction and normalization chains both preserve this registered
|
||||
order: JSON syntax, spell shape, catalog membership, source references, JSON
|
||||
Schema, then source relatedness. Extraction validates the private response
|
||||
schema; normalization validates the durable artifact schema.
|
||||
|
||||
## Manifest Metadata
|
||||
|
||||
The extractor adds prompt and response-schema provenance under the artifact lane
|
||||
|
||||
@@ -424,9 +424,9 @@ an unrelated actor. Actors use normalized consecutive-token matching. The
|
||||
normalized-invariants validator owns actor display normalization, canonical
|
||||
source-reference order, chronology, and exact duplicate identity; it defers
|
||||
shape and source-reference failures. All four validators are deterministic and
|
||||
expose local policy fingerprints. The D&D registrar orders them after generic
|
||||
JSON validation and before response-schema validation at extraction and
|
||||
normalization.
|
||||
expose local policy fingerprints. In the registered defaults, JSON syntax runs
|
||||
first; combat shape, normalized invariants when applicable, and source-reference
|
||||
validation precede JSON Schema validation; warning-only relatedness runs last.
|
||||
|
||||
## Production Registration
|
||||
|
||||
|
||||
@@ -7,19 +7,6 @@ not as committed release dates.
|
||||
|
||||
## Near-Term D&D Pipeline
|
||||
|
||||
### Simplify D&D Extraction Contracts
|
||||
|
||||
- Adopt the proposed principle in
|
||||
[ADR-0009](../adr/0009-minimal-evidence-grounded-extraction-artifacts.md)
|
||||
that extractors should return the smallest useful evidence-grounded facts
|
||||
needed to answer one narrow question.
|
||||
- Redesign the spell, NPC, and combat-turn durable contracts and prompts as
|
||||
described in
|
||||
[Minimal D&D Extraction Contracts](minimal-dnd-extraction-contracts.md).
|
||||
- Replace the unpublished v1 schema shapes in place rather than adding optional
|
||||
or synthetic compatibility fields, and evaluate the reduced outputs against
|
||||
human-reviewed transcripts after cutover.
|
||||
|
||||
### Evaluate Spell Extraction And Normalization
|
||||
|
||||
- Evaluate ordinary extraction retries and the completed normalization path
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Minimal D&D Extraction Contracts Implementation Plan
|
||||
|
||||
**Status:** Ready for implementation
|
||||
**Status:** Implemented
|
||||
|
||||
## Objective
|
||||
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
# Minimal D&D Extraction Contracts
|
||||
|
||||
**Status:** Proposed
|
||||
**Status:** Implemented
|
||||
|
||||
## Intent
|
||||
|
||||
@@ -213,8 +213,8 @@ and live model calls are evaluation aids rather than deterministic CI gates.
|
||||
## Documentation Ownership
|
||||
|
||||
The spell, NPC, and combat integration documents are the canonical owners of
|
||||
their redesigned durable schemas once implemented. Internal LLM and module
|
||||
documents own the corresponding current prompt, DTO, validator, normalizer, and
|
||||
NPC prompt-projection behavior. This roadmap owns the desired end state and
|
||||
policy; [the implementation plan](implementation.md) owns sequencing and
|
||||
completion criteria until the cutover is complete.
|
||||
their redesigned durable schemas. Internal LLM and module documents own the
|
||||
corresponding current prompt, DTO, validator, normalizer, and NPC
|
||||
prompt-projection behavior. This roadmap records the implemented design and
|
||||
policy; [the implementation plan](implementation.md) records the completed
|
||||
sequencing and completion criteria.
|
||||
|
||||
Reference in New Issue
Block a user