diff --git a/scripts/parser-template/README.md b/scripts/parser-template/README.md index 67facb7..1499f51 100644 --- a/scripts/parser-template/README.md +++ b/scripts/parser-template/README.md @@ -3,7 +3,7 @@ > {{TITLE}} parser, serializer, and builder for Node.js and TypeScript: **lenient on parse, > spec-clean on emit**. -`{{PKG}}` is a zero-dependency TypeScript toolkit that follows the cosyte parser archetype: a lenient +`{{PKG}}` is a zero-dependency TypeScript toolkit that follows the Cosyte parser archetype: a lenient parser that turns real-world, vendor-quirky input into **warnings** rather than failures, paired with a serializer that always emits spec-clean output (Postel's Law). It mirrors the API shape of the reference parser, [`@cosyte/hl7`](https://github.com/cosyte/hl7). @@ -30,7 +30,7 @@ result.warnings; // stable, positional tolerance warnings (never throws on quirk The parser is **lenient by default**: vendor quirks become warnings, not failures. A `{ strict: true }` mode (to be added) escalates every tolerated deviation to a thrown error. -## The cosyte parser archetype +## The Cosyte parser archetype - **Postel's Law**: liberal parser (lenient default + warnings), conservative serializer (always spec-clean), so quirks don't propagate downstream on round-trip. diff --git a/scripts/parser-template/docs-content/concepts-archetype.md b/scripts/parser-template/docs-content/concepts-archetype.md index 264a34b..cb81091 100644 --- a/scripts/parser-template/docs-content/concepts-archetype.md +++ b/scripts/parser-template/docs-content/concepts-archetype.md @@ -6,7 +6,7 @@ sidebar_position: 1 # Core Concepts -`{{PKG}}` follows the shared **cosyte parser archetype**: the same mental model every `@cosyte/*` +`{{PKG}}` follows the shared **Cosyte parser archetype**: the same mental model every `@cosyte/*` parser implements, so what you learn here transfers across the suite. `@cosyte/hl7` is the reference implementation; this package mirrors its shape. diff --git a/scripts/parser-template/docs-content/intro.md b/scripts/parser-template/docs-content/intro.md index f7a40ba..76c2cd6 100644 --- a/scripts/parser-template/docs-content/intro.md +++ b/scripts/parser-template/docs-content/intro.md @@ -7,7 +7,7 @@ sidebar_position: 1 # {{PKG}} Parse real-world, vendor-quirky {{TITLE}} and pull fields out in one line, without reading the spec. -`{{PKG}}` is a zero-dependency TypeScript toolkit following the cosyte parser archetype: a lenient +`{{PKG}}` is a zero-dependency TypeScript toolkit following the Cosyte parser archetype: a lenient parser, an immutable model, a spec-clean serializer, and a profile system for vendor quirks. It mirrors the API shape of the reference parser, `@cosyte/hl7`. diff --git a/scripts/parser-template/src/index.ts b/scripts/parser-template/src/index.ts index af76923..7decb72 100644 --- a/scripts/parser-template/src/index.ts +++ b/scripts/parser-template/src/index.ts @@ -24,7 +24,7 @@ export const VERSION = "0.0.0"; /** * The result of parsing a {{TITLE}} payload. * - * Mirrors the cosyte parser archetype: a parsed value plus the **warnings** the lenient parser + * Mirrors the Cosyte parser archetype: a parsed value plus the **warnings** the lenient parser * recovered from (Tier-2 deviations). The real model (an immutable document with dot-path access, * named helpers, and a spec-clean serializer) lands in subsequent phases; for now this captures the * minimal lenient-parse contract. diff --git a/scripts/parser-template/test/property/round-trip.property.test.ts b/scripts/parser-template/test/property/round-trip.property.test.ts index f3a88dc..83f31ce 100644 --- a/scripts/parser-template/test/property/round-trip.property.test.ts +++ b/scripts/parser-template/test/property/round-trip.property.test.ts @@ -1,5 +1,5 @@ /** - * Property-based conformance tests for the cosyte parser archetype, driven by the shared + * Property-based conformance tests for the Cosyte parser archetype, driven by the shared * `@cosyte/test-utils` invariant runners. The kit owns the **invariants**; this parser owns the * **format-specific arbitraries** (the `{{Pascal}}` generators below). *