2026-07-04 03:01:38 +00:00
# Configuration
2026-07-26 13:16:06 +00:00
This is the canonical reference for Notarius configuration. Configuration files
2026-09-13 17:12:56 +00:00
are YAML and must declare version 5. They select pipelines and their modules;
2026-07-26 13:16:06 +00:00
the [CLI reference ](cli.md ) owns invocation syntax, and
[Operations ](operations.md ) owns run-state procedures.
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
## Configuration Discovery And Precedence
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
Commands that load configuration choose a file in this order:
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
1. a non-empty * * --config** CLI value;
2. a non-empty **NOTARIUS_CONFIG ** environment value;
3. the installed default file at * * /usr/local/etc/notarius/config.yml**, when
it exists.
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
The command fails if none of these paths provides a configuration file.
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
For configuration values, precedence is:
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
1. built-in defaults;
2026-09-13 17:12:56 +00:00
2. composed YAML sources, including imports;
2026-09-25 21:46:35 +00:00
3. the selected ConfigKit overlay; and
2026-09-13 17:12:56 +00:00
4. explicitly supplied configuration-valued run flags.
2026-07-04 03:01:38 +00:00
2026-09-25 21:46:35 +00:00
`--config-overlay` selects a ConfigKit overlay from `overlays/<name>.yml`
2026-09-13 17:12:56 +00:00
beneath the selected configuration root. Empty and `default` select no overlay.
2026-09-25 21:46:35 +00:00
`profiles/<name>.yml` is not a fallback location, and `--config-profile` is no
longer accepted. Configuration overlays are distinct from PromptKit LLM profiles selected by
2026-09-13 17:12:56 +00:00
`llm_profile` or `--llm-profile` . The retired operational environment variables
have no effect; `NOTARIUS_CONFIG` remains a source-discovery input.
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
## Maintained Examples
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
- [Minimal D&D configuration ](../examples/dnd-minimal.config.yml ) is a
single-lane Seriatim-to-spell pipeline.
- [Complete D&D configuration ](../examples/dnd-complete.config.yml ) uses
ordered steps, all implemented D&D lanes, generated references, state
2026-08-03 17:21:42 +00:00
settings, bounded LLM concurrency, and the maintained
2026-09-13 17:24:55 +00:00
[LLM profile ](../examples/llm-profiles/dnd-extraction.yml ) and imports its
pipeline from [a fragment ](../examples/pipelines/dnd-session.yml ).
2026-07-26 13:16:06 +00:00
Use these complete files as starting points rather than combining the
illustrative fragments in this reference.
## File Shape And Defaults
Unknown fields, duplicate mapping keys, empty identifiers, and identifiers that
become duplicates after trimming whitespace are rejected. Every top-level field
other than **version ** is optional.
| Field | Type | Default | Rules |
| --- | --- | --- | --- |
2026-09-13 17:12:56 +00:00
| **version ** | integer or quoted string | none | Required; must be 5. Maintained files use `version: 5` . |
2026-07-30 05:22:41 +00:00
| **promptkit ** | object | none | Profile source and optional local-backend configuration. |
2026-07-26 13:16:06 +00:00
| **pipelines ** | map | empty | Maps pipeline IDs to pipeline definitions. |
| **concurrency ** | object | see below | Global LLM and extraction limits. |
| **output ** | object | see below | Published output settings. |
| **cache ** | object | see below | Chunk-plan and checkpoint settings. |
| **debug ** | object | see below | Debug-bundle root only; it does not enable capture. |
Built-in defaults are:
| Field | Default |
| --- | --- |
2026-08-03 19:16:18 +00:00
| **concurrency.total_llm ** | 16 |
2026-07-26 13:16:06 +00:00
| **concurrency.stage_workers.extract ** | Effective **total_llm ** |
| **output.directory ** | * * ./notarius-output** |
| **cache.chunk_plans.mode ** | **auto ** |
| **cache.chunk_plans.directory ** | Empty, selecting the per-user chunk-plan root |
| **cache.checkpoints.enabled ** | false |
| **cache.checkpoints.directory ** | Empty, selecting the per-user checkpoint root |
| **debug.directory ** | * * ./notarius-debug** |
An empty cache directory in YAML deliberately selects the corresponding
per-user root. An explicit empty output or debug directory is invalid.
2026-09-11 15:04:54 +00:00
Selecting a chunk-plan or checkpoint directory does not configure filesystem
access policy. Cache permissions come from deployment provisioning, process
umask, setgid inheritance, and default ACLs; see [Operations ](operations.md#cache-provisioning ).
2026-07-04 03:01:38 +00:00
2026-09-13 17:12:56 +00:00
Every nonempty relative configured destination or reference path resolves from
the canonical directory of the file that supplies its surviving declaration.
2026-09-25 21:46:35 +00:00
This includes imported fragments and selected configuration overlays. Built-in
2026-09-13 17:12:56 +00:00
relative destinations use the selected main configuration file's directory;
explicit `--output-dir` and `--debug-dir` values use the invocation working
directory. Absolute values remain unchanged.
The root file can use ConfigKit imports to compose disjoint definitions. Imports
2026-09-25 21:46:35 +00:00
and selected overlays remain under the configuration root; they do not merge or
append a pipeline's `steps` sequence. An overlay replaces sequences as defined
2026-09-13 17:12:56 +00:00
by ConfigKit, so changing an individual ordered binding requires supplying the
whole replacement sequence.
2026-07-28 16:52:49 +00:00
## PromptKit Profiles
2026-07-04 03:01:38 +00:00
2026-07-30 05:22:41 +00:00
The optional **promptkit ** object selects one source of profile definitions and
may register one conventional local OpenAI-compatible backend:
2026-07-28 16:52:49 +00:00
~~~yaml
2026-09-13 17:12:56 +00:00
version: 5
2026-07-30 05:22:41 +00:00
2026-07-28 16:52:49 +00:00
promptkit:
2026-07-30 05:22:41 +00:00
profile_dir: ./profiles
# profile_file: ./profiles.yml
local_backend:
endpoint: http://localhost:8000/v1
concurrency_limit: 2
2026-07-28 16:52:49 +00:00
~~~
2026-07-05 18:34:21 +00:00
2026-07-26 13:16:06 +00:00
| Field | Type | Rules |
| --- | --- | --- |
| **profile_dir ** | string | Non-empty directory containing profile files. |
| **profile_file ** | string | Non-empty profile file. |
2026-07-30 05:22:41 +00:00
| **local_backend ** | object | Optional registration for the conventional PromptKit backend ID **local ** . |
| **local_backend.endpoint ** | string | Required when **local_backend ** is present; absolute HTTP or HTTPS URL with a host. |
| **local_backend.concurrency_limit ** | integer | Optional non-negative limit; defaults to 0. |
2026-07-04 03:01:38 +00:00
2026-09-13 17:12:56 +00:00
Set at most one of **profile_dir ** and **profile_file ** . Every nonempty relative
configured filesystem path is resolved from the canonical directory of the
file that supplies it. The complete example's
2026-09-13 17:24:55 +00:00
`./llm-profiles/dnd-extraction.yml` value therefore resolves beside that example.
2026-09-13 17:12:56 +00:00
Use absolute paths for services and containers when their deployment layout is
not configuration-relative.
2026-08-03 17:21:42 +00:00
An operator source is optional. For a requested ID, PromptKit checks the
configured operator source first, then Notarius's embedded fallback profiles,
then its own built-in catalog. A matching profile is complete: it replaces a
lower-precedence definition rather than merging with it. The maintained
2026-09-13 17:24:55 +00:00
[`dnd-extraction` LLM profile ](../examples/llm-profiles/dnd-extraction.yml )
2026-08-03 17:21:42 +00:00
is a secret-free deployment artifact; production, development, and local
deployments can each provide a complete definition with that same workload ID.
Use workload-oriented IDs for new profiles instead of model names.
[Operations ](operations.md#promptkit-profile-deployment ) owns the deployment
workflow and credential-handling guidance.
2026-07-30 05:22:41 +00:00
When **local_backend ** is present, its endpoint is trimmed and must use HTTP or
HTTPS case-insensitively, be absolute, and have a non-empty host. URL paths are
allowed. User information, queries, and fragments are rejected. A zero
**concurrency_limit** leaves the local backend unrestricted inside PromptKit;
a positive value limits simultaneous local generations. The application-wide
**concurrency.total_llm** limit still applies in both cases. Neither local
backend field has an environment override. Omitting **local_backend ** registers
nothing and preserves existing built-in and endpoint-only profile behavior.
A file-backed PromptKit profile selects the registration by its case-sensitive
backend ID:
~~~yaml
id: local-summary
backend: local
model: example-model
~~~
Keep credentials out of the local-backend object. A PromptKit profile may name
its credential environment variable through `api_key_env` ; set that variable
only in the run environment. PromptKit owns the
2026-08-27 01:35:23 +00:00
[pinned profile-file format ](https://gitea.maximumdirect.net/eric/promptkit/src/tag/v0.9.0/docs/formats.md ),
2026-08-25 19:31:00 +00:00
including `base_profile` inheritance. Notarius passes profiles through without
merging them. Filesystem profiles cannot express PromptKit's in-memory
`APIKeyRequired` setting; an unset `api_key_env` is optional and may reach the
provider without authorization.
2026-07-30 05:22:41 +00:00
The [PromptKit upstream boundary ](integrations/pkg-promptkit.md ) identifies the
supported package API, and [Operations ](operations.md#operational-limits )
describes the effective concurrency layers.
2026-07-28 16:52:49 +00:00
2026-08-03 17:21:42 +00:00
`notarius config validate --pipeline <id>` resolves the selected pipeline and
inspects every explicit effective profile without contacting a provider or
requiring credential values. It rejects absent, malformed, or incompatible
profiles before a run prepares modules. Credential availability is checked only
when a generation is prepared.
2026-09-13 17:12:56 +00:00
## Version 5 Migration
2026-07-05 18:34:21 +00:00
2026-09-13 17:12:56 +00:00
Version 3 and version 4 files are rejected and are not rewritten at load time.
Use `version: 5` , rename the former `scriptorium` section to `promptkit` , and
convert every module binding to an object containing `module` . Convert every
external reference to `{path: ...}` and move any lane-level references to the
corresponding extraction binding. Put durable operational values in YAML or
use the documented explicit run flags; the former field-level environment
variables are not read.
2026-07-26 13:16:06 +00:00
## Concurrency, Output, Cache, And Debug
~~~yaml
concurrency:
total_llm: 2
stage_workers:
extract: 2
output:
directory: ./notarius-output
cache:
chunk_plans:
mode: auto
directory: ./notarius-cache/chunk-plans
checkpoints:
enabled: true
directory: ./notarius-cache/checkpoints
debug:
directory: ./notarius-debug
~~~
2026-07-17 08:21:24 +00:00
2026-07-26 13:16:06 +00:00
**concurrency.total_llm** must be greater than zero. The only supported
**concurrency.stage_workers** key is **extract ** ; its value must be from 1
through **total_llm ** . When omitted, it is recalculated from the effective
2026-09-25 21:46:35 +00:00
**total_llm** after imports, overlay selection, and explicit ConfigKit
2026-09-13 17:12:56 +00:00
overrides.
2026-07-17 08:21:24 +00:00
2026-07-26 13:16:06 +00:00
**cache.chunk_plans.mode** accepts **auto ** , **bypass ** , or **refresh ** .
**cache.checkpoints.enabled** is a boolean. The CLI can override the output
directory and chunk-plan mode for one run; see [CLI reference ](cli.md#run ).
2026-09-11 15:04:54 +00:00
Cache directory fields select only locations; Notarius has no cache permission
2026-09-13 17:12:56 +00:00
field or operational environment override.
2026-07-17 08:21:24 +00:00
2026-07-04 03:01:38 +00:00
## Pipelines
2026-07-26 13:16:06 +00:00
Each **pipelines ** entry has a unique, non-empty ID and the following shape:
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
~~~yaml
2026-07-05 14:52:52 +00:00
pipelines:
dnd-session:
2026-08-03 17:21:42 +00:00
llm_profile: dnd-extraction
2026-09-13 17:12:56 +00:00
input:
module: seriatim
chunk:
module: generic
output:
module: json
2026-07-05 14:52:52 +00:00
artifacts:
spells:
2026-09-13 17:12:56 +00:00
extract:
module: dnd/spells
merge:
module: appendorder
normalize:
module: dnd/spells
2026-07-26 13:16:06 +00:00
~~~
| Field | Type | Default | Rules |
| --- | --- | --- | --- |
2026-08-03 17:21:42 +00:00
| **llm_profile ** | string | none | Optional non-empty default PromptKit profile ID for selected LLM-backed bindings and validators. An explicitly present blank value is invalid. |
2026-08-25 20:04:56 +00:00
| **structured_output_repair_attempts ** | integer | prompt-owned (1 in maintained production prompts) | Optional structural-repair limit from 0 through 3 for selected LLM-backed bindings and validators. Omission leaves the prompt's declared policy in control; explicit 0 disables structural repair at that scope. |
2026-08-26 23:34:06 +00:00
| **validation_policy ** | object | see below | Optional terminal policy defaults for producer validation. Its fields inherit independently into chunk, extract, merge, and normalize bindings. |
2026-07-26 13:16:06 +00:00
| **input ** | module binding | none | Required. |
| **chunk ** | module binding | **generic ** | Optional. |
| **output ** | module binding | **json ** | Optional. |
| **artifacts ** | map | none | Compact single-step lane map. |
| **steps ** | list | none | Ordered lane definitions. Mutually exclusive with **artifacts ** . |
| **references ** | map | none | External reference defaults for eligible targets. |
Use either **artifacts ** or **steps ** . The compact **artifacts ** form is an
implicit single step. An explicit **steps ** list must be non-empty; every step
needs a unique non-empty **id ** , an **artifacts ** map, and may have
**references**. A lane ID must not appear more than once in a pipeline,
including across explicit steps.
2026-08-03 17:21:42 +00:00
For each selected LLM-backed binding or validator, profile selection occurs
after module, validator, and `--only` lane selection. It uses the
2026-08-03 17:15:07 +00:00
run-level * * --llm-profile** value first, then the binding's **llm_profile ** ,
then the pipeline's **llm_profile ** , and finally the PromptKit default.
Deterministic bindings do not receive these defaults or run overrides.
2026-08-25 19:55:39 +00:00
Structural output repair is resolved after module, validator, and `--only` lane
selection. An object's **structured_output_repair_attempts ** value takes
precedence over the pipeline value; otherwise, an LLM-backed binding or
validator inherits the pipeline value. If both are omitted, PromptKit uses the
prompt's declared repair policy. The value must be an integer from 0 through 3;
explicit `null` and non-integer values are invalid. An explicit value on a
deterministic binding or validator is invalid, while a pipeline value simply
does not apply to deterministic selections.
2026-08-27 01:35:23 +00:00
`validation_policy` controls terminal disposition for one complete producer
attempt and validator chain. It may appear on a pipeline or a **chunk ** ,
2026-08-26 23:34:06 +00:00
**extract**, **merge ** , or **normalize ** module binding; input, output, and
validator bindings reject it. Every field is optional and resolves in binding,
2026-08-27 01:35:23 +00:00
pipeline, then application-default order:
2026-08-26 23:34:06 +00:00
| Field | Values | Default |
| --- | --- | --- |
| **producer_structural_failure ** | **fail_run ** , **reject_output ** | **fail_run ** |
| **semantic_rejection ** | **fail_run ** , **reject_output ** | **fail_run ** |
| **validator_failure ** | **warn_continue ** , **fail_run ** | **warn_continue ** |
The policy object and its fields must be non-null, and unknown fields are
rejected. A deterministic producer may not explicitly set
**producer_structural_failure** on its binding, although a pipeline-level
default remains valid for pipelines that include LLM-backed producers.
2026-08-27 01:35:23 +00:00
After the producer binding's retry budget is exhausted, an invalid structured
response uses **producer_structural_failure ** . One or more semantic validator
rejections use **semantic_rejection ** ; rejection takes precedence over an
exhausted validator failure or skip. With no rejection, an exhausted validator
failure or skip uses **validator_failure ** . `reject_output` records the
terminal rejection without advancing that candidate. `warn_continue` is valid
only for validator execution failure: it advances a structurally valid,
otherwise unrejected result with incomplete-validation provenance and without
making it reusable checkpoint state.
2026-07-26 13:16:06 +00:00
A lane has these fields:
| Field | Type | Default | Rules |
| --- | --- | --- | --- |
| **extract ** | module binding | none | Required. |
| **merge ** | module binding | **appendorder ** | Optional. |
| **normalize ** | module binding | **noop ** | Optional. |
2026-09-13 17:12:56 +00:00
| **references ** | map | none | Not supported at lane scope; place references on the eligible binding. |
2026-07-26 13:16:06 +00:00
| **validators ** | list | none | Non-empty lane-level lists are rejected. Set validator overrides on a binding instead. |
2026-09-13 17:12:56 +00:00
Lane-level **references ** are not supported. Put a lane extraction reference
under **extract.references ** .
2026-07-26 13:16:06 +00:00
## Module Bindings And Validators
2026-09-13 17:12:56 +00:00
Every module and validator binding uses an object, even when it has no fields
beyond its module key:
2026-07-26 13:16:06 +00:00
~~~yaml
2026-09-13 17:12:56 +00:00
input:
module: seriatim
2026-07-26 13:16:06 +00:00
~~~
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
Use an object for fields:
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
~~~yaml
extract:
module: dnd/spells
2026-08-03 17:21:42 +00:00
llm_profile: dnd-extraction
2026-07-26 13:16:06 +00:00
retries: 2
references:
2026-09-13 17:12:56 +00:00
spell_catalog:
path: ./dnd-spell-catalog.json
2026-07-26 13:16:06 +00:00
~~~
| Binding field | Type | Default | Rules |
| --- | --- | --- | --- |
| **module ** | string | none | Required for an object binding. Must be a registered compatible key. |
2026-08-03 17:15:07 +00:00
| **llm_profile ** | string | none | Optional non-empty PromptKit profile ID for an LLM-backed binding. It overrides the pipeline default unless the run supplies * * --llm-profile**. |
2026-08-25 20:04:56 +00:00
| **structured_output_repair_attempts ** | integer | pipeline or prompt-owned (1 in maintained production prompts) | Optional structural-repair limit from 0 through 3 for an LLM-backed binding. It overrides the pipeline value; explicit 0 disables structural repair. |
2026-08-26 23:34:06 +00:00
| **validation_policy ** | object | pipeline or application defaults | Optional field-by-field terminal-policy override for a chunk, extract, merge, or normalize binding. |
2026-08-27 01:35:23 +00:00
| **retries ** | integer | 0 | Non-negative additional complete producer attempts for chunk, extract, merge, and normalize bindings. This single budget covers operational errors, invalid structured output, module-requested normalization retry, and semantic correction. |
2026-07-26 13:16:06 +00:00
| **options ** | object | none | Must satisfy the selected module. |
| **references ** | map | none | Valid only on chunk, extract, merge, and normalize bindings. |
| **validators ** | list | production chain | Valid only on chunk, extract, merge, and normalize bindings. |
Omitting **validators ** uses the registered chain. **validators: [] ** selects
an empty chain; a non-empty list replaces the chain in the listed order.
2026-08-25 19:55:39 +00:00
Validator bindings accept only **module ** , **llm_profile ** ,
2026-08-26 23:42:11 +00:00
**structured_output_repair_attempts**, **retries ** , and **options ** . Their
2026-08-27 01:35:23 +00:00
**retries** value is a non-negative additional validator-execution budget and
is valid only when the selected validator is LLM-backed. A validator retry
rechecks the same immutable candidate; it never regenerates the producer.
They reject
2026-08-26 23:42:11 +00:00
**validation_policy**, **references ** , and nested **validators ** . Deterministic
validators reject explicit **llm_profile ** and
**structured_output_repair_attempts**.
2026-08-25 19:55:39 +00:00
Deterministic module bindings also reject those explicit fields.
2026-07-26 13:16:06 +00:00
2026-08-27 01:35:23 +00:00
An LLM-backed chunk, extract, merge, or normalize producer with both a
non-empty validator chain and positive **retries ** must declare the supported
single-response correction capability. Preparation rejects a configuration
that could require semantic correction from a producer that cannot provide an
exact prior response. A deterministic producer, or an LLM attempt that did
not make a model call, cannot consume a semantic retry after rejection.
2026-07-27 18:28:02 +00:00
The **json ** output module accepts optional **include_chunk_map ** and
**evidence_context** settings:
2026-07-26 13:16:06 +00:00
~~~yaml
2026-07-23 15:06:33 +00:00
output:
module: json
options:
include_chunk_map: true
2026-07-27 18:28:02 +00:00
evidence_context:
enabled: true
window_units: 3
lanes:
2026-08-05 20:12:16 +00:00
- npc-registry
2026-07-27 18:28:02 +00:00
- spells
2026-07-26 13:16:06 +00:00
~~~
2026-07-23 15:06:33 +00:00
2026-07-26 13:16:06 +00:00
**include_chunk_map** is a boolean and defaults to false. It adds the accepted
chunk map when one exists; its wire format is defined in the
[chunk-map contract ](integrations/chunk-map.md ).
2026-07-23 15:06:33 +00:00
2026-07-27 18:28:02 +00:00
Omitting **evidence_context ** disables evidence publication. When present, it
is an object with these strict fields:
| Field | Type | Rules |
| --- | --- | --- |
| **enabled ** | boolean | Required. `false` permits no other evidence fields. |
| **lanes ** | array of strings | Required and non-empty when enabled. Each value is trimmed and must be unique; every value must name a configured pipeline lane. |
| **window_units ** | non-negative integer | Optional when enabled; defaults to 3. Zero retains only directly cited units. |
Unknown outer or nested option fields are rejected, as are incompatible YAML
types. The allowlist remains valid when a run uses lane filtering: a configured
lane that is not active for that invocation simply contributes no evidence.
Evidence publication is opt-in because it can persist source text and metadata.
2026-08-09 19:47:27 +00:00
When enabled, it publishes the selected source-unit excerpt defined by the
[Published Evidence Context contract ](integrations/evidence-context.md ).
2026-07-27 18:28:02 +00:00
2026-07-26 13:16:06 +00:00
## References And Ordered Handoffs
2026-07-07 21:21:12 +00:00
2026-09-13 17:12:56 +00:00
Reference maps bind named slots that the selected target declares. An external
reference is an object with `path` . Pipeline-level maps accept only external
paths; step-local and binding-local maps may also select a normalized artifact
from an earlier step:
2026-07-07 21:21:12 +00:00
2026-07-26 13:16:06 +00:00
~~~yaml
steps:
- id: describe-session
artifacts:
2026-08-05 20:12:16 +00:00
npc-registry:
2026-09-13 17:12:56 +00:00
extract:
module: dnd/npc-registry
normalize:
module: dnd/npc-registry
2026-07-26 13:16:06 +00:00
- id: extract-events
references:
2026-08-05 18:38:22 +00:00
npc_registry:
2026-07-26 13:16:06 +00:00
artifact:
step: describe-session
2026-08-05 20:12:16 +00:00
lane: npc-registry
2026-07-26 13:16:06 +00:00
artifacts:
spells:
2026-09-13 17:12:56 +00:00
extract:
module: dnd/spells
normalize:
module: dnd/spells
2026-07-26 13:16:06 +00:00
~~~
An artifact selector contains only **step ** and **lane ** . The producer must be
an earlier step and the selected artifact must be compatible with the consumer
slot. A generated binding supplies one accepted normalized artifact; it does
not name a file. A configured generated dependency remains required even when
that consumer slot is otherwise optional.
2026-08-29 12:34:31 +00:00
Pipeline references are configuration defaults. A matching step-local or
binding-local external path overrides a pipeline default. CLI reference
bindings are then operational overrides of configured external paths; their
pipeline, lane, and binding scopes and precedence are defined by the
[CLI reference ](cli.md#reference-selectors ). A CLI file reference cannot
replace a configured generated artifact handoff. Required slots must be bound
2026-09-13 17:12:56 +00:00
after configuration and CLI reference actions are applied. A YAML reference
path resolves from the file that supplies its surviving declaration, including
2026-09-25 21:46:35 +00:00
an imported fragment or selected overlay. CLI reference paths resolve relative
2026-09-13 17:12:56 +00:00
to the process working directory.
2026-07-26 13:16:06 +00:00
### D&D Reference Slots
The following slot names are accepted by the implemented D&D modules when the
selected target declares them:
| Slot | Source and use |
| --- | --- |
| **party ** | Optional text campaign context. This is the canonical party-roster spelling. |
| **roster ** | Accepted compatibility alias for **party ** . |
| **players ** | Optional text player context. |
| **glossary ** | Optional text campaign glossary. |
| **spell_catalog ** | Optional JSON spell-catalog overlay for spell extraction and normalization. See [spell-catalog overlays ](integrations/dnd-spell-catalog-overlays.md ). |
2026-08-05 19:13:37 +00:00
| **location_registry ** | Required normalized location registry for location-occurrence extraction and normalization. |
2026-08-05 20:12:16 +00:00
| **item_registry ** | Required normalized item registry for item-occurrence extraction and normalization. |
2026-08-05 19:00:55 +00:00
| **npc_registry ** | Normalized NPC registry. Optional for spells and combat turns; required for NPC occurrences and enemy-event extraction and normalization. |
2026-08-03 21:14:52 +00:00
| **scene_descriptions ** | Required normalized scene-description artifact for combat-turn and enemy-event extraction. |
| **combat_turns ** | Required normalized combat-turn artifact for enemy-event extraction. |
2026-08-05 19:00:55 +00:00
| **npc_occurrences ** | Required normalized NPC-occurrence artifact for enemy-event extraction. |
2026-07-26 13:16:06 +00:00
2026-08-05 20:12:16 +00:00
Registry-backed occurrence and enemy-event artifact slots have the following
exact binding contracts. Durable semantics and wire shapes remain in their
[NPC occurrence ](integrations/dnd-npc-occurrence-artifacts.md ),
[location occurrence ](integrations/dnd-location-occurrence-artifacts.md ),
[item occurrence ](integrations/dnd-item-occurrence-artifacts.md ), and
2026-08-04 00:51:43 +00:00
[enemy-event ](integrations/dnd-enemy-event-artifacts.md ) contracts.
2026-08-03 23:00:09 +00:00
| Slot | Accepted artifact kind | Media type | Maximum size | Required stage |
| --- | --- | --- | --- | --- |
2026-08-05 18:38:22 +00:00
| `npc_registry` | `dnd/npc-registry` | `application/json` | 1,048,576 bytes | extract and normalize |
2026-08-03 23:00:09 +00:00
| `scene_descriptions` | `dnd/scene-description-list` | `application/json` | 1,048,576 bytes | extract only |
| `combat_turns` | `dnd/combat-turn-list` | `application/json` | 1,048,576 bytes | extract only |
2026-08-05 19:00:55 +00:00
| `npc_occurrences` | `dnd/npc-occurrence-list` | `application/json` | 1,048,576 bytes | extract only |
2026-08-05 19:13:37 +00:00
| `location_registry` | `dnd/location-registry` | `application/json` | 1,048,576 bytes | location-occurrence extract and normalize |
2026-08-05 20:12:16 +00:00
| `item_registry` | `dnd/item-registry` | `application/json` | 1,048,576 bytes | item-occurrence extract and normalize |
2026-08-03 23:00:09 +00:00
2026-07-26 13:16:06 +00:00
Scene descriptions accept **party ** , **players ** , and **glossary ** , but not
2026-08-05 19:00:55 +00:00
**roster**. NPC occurrences require **npc_registry ** for both extraction and
2026-07-26 13:16:06 +00:00
normalization. Combat turns require **scene_descriptions ** for extraction; the
2026-08-05 18:38:22 +00:00
normalized combat-turn module may use optional **npc_registry ** . Location occurrences
2026-08-05 20:12:16 +00:00
require **location_registry ** for extraction and normalization. Item occurrences require
**item_registry** for extraction and normalization. Enemy-event extraction requires all
four of its JSON artifact slots; its normalizer requires **npc_registry ** .
2026-08-04 00:51:43 +00:00
The [complete example ](../examples/dnd-complete.config.yml ) shows the ordered
generated bindings.
2026-07-26 13:16:06 +00:00
## Production Module Keys
| Kind | Keys |
| --- | --- |
| Input | **seriatim ** |
| Chunk | **generic ** , **dnd/scenes ** |
2026-08-05 20:00:20 +00:00
| Extract | **dnd/spells ** , **dnd/npc-registry ** , **dnd/combat-turns ** , **dnd/item-occurrences ** , **dnd/item-registry ** , **dnd/npc-occurrences ** , **dnd/scene-descriptions ** , **dnd/enemy-events ** , **dnd/location-registry ** , **dnd/location-occurrences ** |
2026-07-26 13:16:06 +00:00
| Merge | **appendorder ** |
2026-08-05 20:00:20 +00:00
| Normalize | **noop ** , **dnd/spells ** , **dnd/npc-registry ** , **dnd/combat-turns ** , **dnd/item-occurrences ** , **dnd/item-registry ** , **dnd/npc-occurrences ** , **dnd/scene-descriptions ** , **dnd/enemy-events ** , **dnd/location-registry ** , **dnd/location-occurrences ** |
2026-07-26 13:16:06 +00:00
| Output | **json ** |
2026-08-05 20:12:16 +00:00
`dnd/scenes` and every D&D extractor are `llm_backed` . The
`dnd/npc-registry` , `dnd/location-registry` , and `dnd/item-registry`
normalizers are also `llm_backed` for bounded duplicate proposals; every other
D&D normalizer is `deterministic` . LLM-backed bindings use the effective
[PromptKit profile ](#promptkit-profiles ). The complete example binds each
registry in an earlier step before its occurrence consumer.
2026-08-04 00:51:43 +00:00
2026-07-26 13:16:06 +00:00
The D&D artifact contracts define each emitted schema:
[spells ](integrations/dnd-spell-artifacts.md ),
2026-08-05 18:38:22 +00:00
[NPC registry ](integrations/dnd-npc-registry-artifacts.md ),
2026-08-05 19:00:55 +00:00
[NPC occurrences ](integrations/dnd-npc-occurrence-artifacts.md ),
2026-07-26 13:16:06 +00:00
[combat turns ](integrations/dnd-combat-turn-artifacts.md ),
2026-08-05 19:39:06 +00:00
[item registry ](integrations/dnd-item-registry-artifacts.md ),
2026-08-05 20:12:16 +00:00
[item occurrences ](integrations/dnd-item-occurrence-artifacts.md ),
[scene descriptions ](integrations/dnd-scene-description-artifacts.md ),
2026-08-04 00:51:43 +00:00
[enemy events ](integrations/dnd-enemy-event-artifacts.md ),
2026-08-05 19:13:37 +00:00
[location registry ](integrations/dnd-location-registry-artifacts.md ), and
2026-08-04 00:51:43 +00:00
[location occurrences ](integrations/dnd-location-occurrence-artifacts.md ).
2026-07-26 13:16:06 +00:00
## Production Validator Keys And Default Chains
Available validator keys are:
| Family | Keys |
| --- | --- |
| Generic | **generic/always_accept ** , **generic/always_reject ** , **generic/valid_json ** , **generic/valid_json_schema ** |
| Spells | **extract/dnd/spells/shape ** , **extract/dnd/spells/catalog ** , **extract/dnd/spells/source_refs ** , **extract/dnd/spells/source_relatedness ** |
2026-08-05 18:38:22 +00:00
| NPC registry | **extract/dnd/npc-registry/shape ** , **extract/dnd/npc-registry/source_refs ** , **extract/dnd/npc-registry/source_relatedness ** , **normalize/dnd/npc-registry/identity ** |
2026-07-26 13:16:06 +00:00
| Combat turns | **extract/dnd/combat-turns/shape ** , **extract/dnd/combat-turns/source_refs ** , **extract/dnd/combat-turns/source_relatedness ** , **normalize/dnd/combat-turns/invariants ** |
2026-08-05 20:00:20 +00:00
| Item occurrences | **extract/dnd/item-occurrences/shape ** , **extract/dnd/item-occurrences/registry ** , **extract/dnd/item-occurrences/source_refs ** , **extract/dnd/item-occurrences/source_relatedness ** , **normalize/dnd/item-occurrences/invariants ** |
2026-08-05 19:39:06 +00:00
| Item registry | **extract/dnd/item-registry/shape ** , **extract/dnd/item-registry/source_refs ** , **extract/dnd/item-registry/source_relatedness ** , **normalize/dnd/item-registry/identity ** |
2026-08-05 19:00:55 +00:00
| NPC occurrences | **extract/dnd/npc-occurrences/shape ** , **extract/dnd/npc-occurrences/registry ** , **extract/dnd/npc-occurrences/source_refs ** , **extract/dnd/npc-occurrences/source_relatedness ** , **normalize/dnd/npc-occurrences/invariants ** |
2026-08-28 00:23:50 +00:00
| Scene descriptions | **extract/dnd/scene-descriptions/shape ** , **extract/dnd/scene-descriptions/source_refs ** , **extract/dnd/scene-descriptions/source_relatedness ** , **extract/dnd/scene-descriptions/combat_semantics ** (LLM-backed, opt-in), **normalize/dnd/scene-descriptions/invariants ** |
2026-08-28 02:26:14 +00:00
| Enemy events | **extract/dnd/enemy-events/shape ** , **extract/dnd/enemy-events/engagements ** , **extract/dnd/enemy-events/source_refs ** , **extract/dnd/enemy-events/source_relatedness ** , **normalize/dnd/enemy-events/invariants ** |
| Location registry | **extract/dnd/location-registry/shape ** , **extract/dnd/location-registry/source_refs ** , **extract/dnd/location-registry/source_relatedness ** , **normalize/dnd/location-registry/identity ** |
| Location occurrences | **extract/dnd/location-occurrences/shape ** , **extract/dnd/location-occurrences/registry ** , **extract/dnd/location-occurrences/source_refs ** , **extract/dnd/location-occurrences/source_relatedness ** , **normalize/dnd/location-occurrences/invariants ** |
2026-08-28 00:23:50 +00:00
`extract/dnd/scene-descriptions/combat_semantics` is not in a production default chain. To opt in, replace the scene extractor validator chain with the current ordered chain plus the semantic validator last, and set a positive producer retry budget if a rejection should request a corrected scene:
~~~yaml
extract:
module: dnd/scene-descriptions
retries: 1
validators:
2026-09-14 00:42:35 +00:00
- module: generic/valid_json
- module: extract/dnd/scene-descriptions/shape
- module: extract/dnd/scene-descriptions/source_refs
- module: generic/valid_json_schema
- module: extract/dnd/scene-descriptions/source_relatedness
2026-08-29 11:39:02 +00:00
- module: extract/dnd/scene-descriptions/combat_semantics
retries: 1
2026-08-28 00:23:50 +00:00
~~~
An override replaces, rather than extends, the default chain. See [Module Bindings And Validators ](#module-bindings-and-validators ) for binding, profile, repair, retry, and failure-policy rules.
2026-07-26 13:16:06 +00:00
2026-08-29 11:39:02 +00:00
The validator retry shown above permits one additional execution against the
same scene candidate when the LLM-backed validator itself fails; it is separate
from both the extractor's producer retry and PromptKit structural repair.
2026-07-26 13:16:06 +00:00
When no override is configured, production D&D bindings use the following
ordered chains. Each row lists extract then normalize; spell chains are the
same at both stages.
| Lane | Extract | Normalize |
| --- | --- | --- |
| Spells | generic/valid_json, extract/dnd/spells/shape, extract/dnd/spells/catalog, extract/dnd/spells/source_refs, generic/valid_json_schema, extract/dnd/spells/source_relatedness | Same as extract |
2026-08-05 18:38:22 +00:00
| NPC registry | generic/valid_json, extract/dnd/npc-registry/shape, extract/dnd/npc-registry/source_refs, generic/valid_json_schema, extract/dnd/npc-registry/source_relatedness | generic/valid_json, extract/dnd/npc-registry/shape, normalize/dnd/npc-registry/identity, extract/dnd/npc-registry/source_refs, generic/valid_json_schema, extract/dnd/npc-registry/source_relatedness |
2026-07-26 13:16:06 +00:00
| Combat turns | generic/valid_json, extract/dnd/combat-turns/shape, extract/dnd/combat-turns/source_refs, generic/valid_json_schema, extract/dnd/combat-turns/source_relatedness | generic/valid_json, extract/dnd/combat-turns/shape, normalize/dnd/combat-turns/invariants, extract/dnd/combat-turns/source_refs, generic/valid_json_schema, extract/dnd/combat-turns/source_relatedness |
2026-08-05 20:00:20 +00:00
| Item occurrences | generic/valid_json, extract/dnd/item-occurrences/shape, extract/dnd/item-occurrences/registry, extract/dnd/item-occurrences/source_refs, generic/valid_json_schema, extract/dnd/item-occurrences/source_relatedness | generic/valid_json, extract/dnd/item-occurrences/shape, extract/dnd/item-occurrences/registry, normalize/dnd/item-occurrences/invariants, extract/dnd/item-occurrences/source_refs, generic/valid_json_schema, extract/dnd/item-occurrences/source_relatedness |
2026-08-05 19:39:06 +00:00
| Item registry | generic/valid_json, extract/dnd/item-registry/shape, extract/dnd/item-registry/source_refs, generic/valid_json_schema, extract/dnd/item-registry/source_relatedness | generic/valid_json, extract/dnd/item-registry/shape, normalize/dnd/item-registry/identity, extract/dnd/item-registry/source_refs, generic/valid_json_schema, extract/dnd/item-registry/source_relatedness |
2026-08-05 19:00:55 +00:00
| NPC occurrences | generic/valid_json, extract/dnd/npc-occurrences/shape, extract/dnd/npc-occurrences/registry, extract/dnd/npc-occurrences/source_refs, generic/valid_json_schema, extract/dnd/npc-occurrences/source_relatedness | generic/valid_json, extract/dnd/npc-occurrences/shape, extract/dnd/npc-occurrences/registry, normalize/dnd/npc-occurrences/invariants, extract/dnd/npc-occurrences/source_refs, generic/valid_json_schema, extract/dnd/npc-occurrences/source_relatedness |
2026-07-26 13:16:06 +00:00
| Scene descriptions | generic/valid_json, extract/dnd/scene-descriptions/shape, extract/dnd/scene-descriptions/source_refs, generic/valid_json_schema, extract/dnd/scene-descriptions/source_relatedness | generic/valid_json, extract/dnd/scene-descriptions/shape, normalize/dnd/scene-descriptions/invariants, extract/dnd/scene-descriptions/source_refs, generic/valid_json_schema, extract/dnd/scene-descriptions/source_relatedness |
2026-08-03 23:00:09 +00:00
| Enemy events | generic/valid_json, extract/dnd/enemy-events/shape, extract/dnd/enemy-events/engagements, extract/dnd/enemy-events/source_refs, generic/valid_json_schema, extract/dnd/enemy-events/source_relatedness | generic/valid_json, extract/dnd/enemy-events/shape, normalize/dnd/enemy-events/invariants, extract/dnd/enemy-events/source_refs, generic/valid_json_schema, extract/dnd/enemy-events/source_relatedness |
2026-08-05 19:13:37 +00:00
| Location registry | generic/valid_json, extract/dnd/location-registry/shape, extract/dnd/location-registry/source_refs, generic/valid_json_schema, extract/dnd/location-registry/source_relatedness | generic/valid_json, extract/dnd/location-registry/shape, normalize/dnd/location-registry/identity, extract/dnd/location-registry/source_refs, generic/valid_json_schema, extract/dnd/location-registry/source_relatedness |
2026-08-04 00:51:43 +00:00
| Location occurrences | generic/valid_json, extract/dnd/location-occurrences/shape, extract/dnd/location-occurrences/registry, extract/dnd/location-occurrences/source_refs, generic/valid_json_schema, extract/dnd/location-occurrences/source_relatedness | generic/valid_json, extract/dnd/location-occurrences/shape, extract/dnd/location-occurrences/registry, normalize/dnd/location-occurrences/invariants, extract/dnd/location-occurrences/source_refs, generic/valid_json_schema, extract/dnd/location-occurrences/source_relatedness |
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
Chains are only registered for the D&D extract and normalize modules shown
above; select an explicit override when a different compatible chain is
required.
2026-07-07 21:48:19 +00:00
2026-07-26 13:16:06 +00:00
## Validation
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
Validate a file and one pipeline before running it:
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
~~~sh
go run ./cmd/notarius config validate \
--config examples/dnd-minimal.config.yml \
--pipeline dnd-session
~~~
2026-07-04 03:01:38 +00:00
2026-07-26 13:16:06 +00:00
Configuration validation rejects invalid YAML, unsupported fields, invalid
2026-09-13 17:12:56 +00:00
defaults or explicit CLI overrides, incompatible module keys, unknown options,
2026-07-26 13:16:06 +00:00
invalid reference bindings, missing required reference slots, invalid validator
overrides, and incompatible generated artifact handoffs. Use
[pipelines list ](cli.md#pipelines-list ) to inspect configured IDs.
2026-09-13 17:16:06 +00:00
## Inspection
Use [config effective ](cli.md#config-effective ) to write the selected composed
configuration as deterministic, redacted YAML. Use
[config explain ](cli.md#config-explain ) with a canonical JSON Pointer to inspect
the effective or historical provenance for one path, including a value displaced
2026-09-25 21:46:35 +00:00
by a selected overlay. Neither command resolves a pipeline, prepares modules,
2026-09-13 17:16:06 +00:00
materializes references, or requires provider credentials.