@cosyte/synth 0.1.10 → 0.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,15 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.1.11
4
+
5
+ ### Patch Changes
6
+
7
+ - c913601: Docs: no example prints a whole message or a value that identifies a person any more, and a new section, What is safe to log, lists the result fields never to log. No code changes.
8
+
9
+ The HL7 v2 generators' TSDoc examples, the README, the quickstart and the HL7 example program now print the message type, codes and booleans, and show an identifying value only in a comment marked synthetic. The README and the installation page say to pin the exact version, since below 1.0 a breaking change can ship in a patch. What is safe to log, on the fatal codes page, names `content`, `original`, `deidentified` and a sentinel's `token` as the fields that hold a whole artifact or a planted value. Nothing a caller does changes.
10
+
11
+ - 70c322c: Docs: the golden fixture page is now `pin-a-golden-fixture` (it was `guides-overview`), the limitations page moves to Reference, and the reason the deid pairing loop reads only the patient fields has its own explanation page. The README links follow. No code changes.
12
+
3
13
  ## 0.1.10
4
14
 
5
15
  ### Patch Changes
package/README.md CHANGED
@@ -56,6 +56,14 @@ so this page does not repeat it.
56
56
  npm install @cosyte/synth @cosyte/hl7 @cosyte/fhir @cosyte/ccda @cosyte/x12 @cosyte/ncpdp @cosyte/astm @cosyte/deid
57
57
  ```
58
58
 
59
+ **Pin the exact version.** Below 1.0 a breaking change can ship in a patch release, so a caret
60
+ range (`^0.1.x`) does not protect you from one. Install with `--save-exact` (pnpm takes the same flag;
61
+ Yarn's is `--exact`) and read the changelog before you move the pin:
62
+
63
+ ```bash
64
+ npm install --save-exact @cosyte/synth
65
+ ```
66
+
59
67
  Node.js 22.12 or later, tested on 22.12, 22, 24, and 26. A generator loads its parser on first use
60
68
  through `require`, and Node.js loads an ES module that way only from 22.12, so a value you get back
61
69
  is an instance of the parser classes you import.
@@ -104,7 +112,8 @@ const corpus = hl7Corpus({ seed: 42, count: 7 }); // one of each family, cycled
104
112
  console.log(corpus.artifacts.every((a) => a.warnings.length === 0)); // true, all spec-clean
105
113
 
106
114
  // Dispatch by kind when the message type is data:
107
- console.log(roundTrip(generateHl7("VXU^V04", 12345)).content.split("\r")[0]); // its MSH segment
115
+ const vxu = roundTrip(generateHl7("VXU^V04", 12345)).content;
116
+ console.log(vxu.split("\r")[0]?.split("|")[8]); // VXU^V04, the type from MSH-9, never the whole segment
108
117
  ```
109
118
 
110
119
  ### Generate a spec-clean FHIR R4 / US Core resource
@@ -388,11 +397,11 @@ The full reference is on [docs.cosyte.com/synth](https://docs.cosyte.com/synth):
388
397
  [C-CDA](https://docs.cosyte.com/synth/guides-ccda), [X12](https://docs.cosyte.com/synth/guides-x12), [NCPDP](https://docs.cosyte.com/synth/guides-ncpdp),
389
398
  [ASTM](https://docs.cosyte.com/synth/guides-astm), [vendor quirks](https://docs.cosyte.com/synth/guides-quirks),
390
399
  [the `@cosyte/deid` pairing loop](https://docs.cosyte.com/synth/guides-deid), [synthetic values](https://docs.cosyte.com/synth/draw-synthetic-values),
391
- and [pinning a golden fixture](https://docs.cosyte.com/synth/guides-overview).
392
- - Explanation: [how it works](https://docs.cosyte.com/synth/concepts-archetype), [what it does and does not do](https://docs.cosyte.com/synth/limitations),
400
+ and [pinning a golden fixture](https://docs.cosyte.com/synth/pin-a-golden-fixture).
401
+ - Explanation: [how it works](https://docs.cosyte.com/synth/concepts-archetype), [why the removal check reads only the patient fields](https://docs.cosyte.com/synth/why-deid-checks-patient-fields),
393
402
  and [Synthea, faker and other generators](https://docs.cosyte.com/synth/synthea-faker-and-other-generators).
394
403
  - Reference: [generator options, kinds and profiles](https://docs.cosyte.com/synth/generator-options), [fatal codes](https://docs.cosyte.com/synth/fatal-codes),
395
- the [quirk catalog](https://docs.cosyte.com/synth/quirk-catalog), the [glossary](https://docs.cosyte.com/synth/glossary), and the
404
+ the [quirk catalog](https://docs.cosyte.com/synth/quirk-catalog), the [glossary](https://docs.cosyte.com/synth/glossary), [what it does and does not do](https://docs.cosyte.com/synth/limitations), and the
396
405
  [API reference](https://github.com/cosyte/synth/blob/main/docs-content/api/README.md), generated from the source.
397
406
  - [Troubleshooting](https://docs.cosyte.com/synth/troubleshooting), [testing and quality](https://docs.cosyte.com/synth/testing-and-quality), and [performance](https://docs.cosyte.com/synth/performance).
398
407
  - [`CHANGELOG.md`](https://github.com/cosyte/synth/blob/main/CHANGELOG.md): every release.